@splinetool/runtime 2.0.13 → 2.0.14

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 (347) hide show
  1. package/build/{runtime-aiAssistant-L3HFJZ2G.js → runtime-aiAssistant-CYJ626R5.js} +1 -1
  2. package/build/runtime-aiAssistant-CYJ626R5.js.br +0 -0
  3. package/build/runtime-aiAssistant-CYJ626R5.js.gz +0 -0
  4. package/build/{runtime-apiServices-KSRZJMJI.js → runtime-apiServices-QWPNWK6X.js} +1 -1
  5. package/build/runtime-apiServices-QWPNWK6X.js.br +0 -0
  6. package/build/runtime-apiServices-QWPNWK6X.js.gz +0 -0
  7. package/build/{runtime-audio-CNGZPKC5.js → runtime-audio-CZNFK3LE.js} +1 -1
  8. package/build/runtime-audio-CZNFK3LE.js.br +0 -0
  9. package/build/runtime-audio-CZNFK3LE.js.gz +0 -0
  10. package/build/{runtime-chunk-QMMGYOLW.js → runtime-chunk-2PDJQLZS.js} +1 -1
  11. package/build/runtime-chunk-2PDJQLZS.js.br +0 -0
  12. package/build/runtime-chunk-2PDJQLZS.js.gz +0 -0
  13. package/build/{runtime-chunk-5POGWSQZ.js → runtime-chunk-44ON5NFS.js} +1 -1
  14. package/build/runtime-chunk-44ON5NFS.js.br +0 -0
  15. package/build/runtime-chunk-44ON5NFS.js.gz +0 -0
  16. package/build/{runtime-chunk-JIIVUL2M.js → runtime-chunk-4SENJRD5.js} +1 -1
  17. package/build/runtime-chunk-4SENJRD5.js.br +0 -0
  18. package/build/runtime-chunk-4SENJRD5.js.gz +0 -0
  19. package/build/{runtime-chunk-WILQUYJ4.js → runtime-chunk-4UHPUSEP.js} +1 -1
  20. package/build/runtime-chunk-4UHPUSEP.js.br +0 -0
  21. package/build/runtime-chunk-4UHPUSEP.js.gz +0 -0
  22. package/build/{runtime-chunk-VAANBQKN.js → runtime-chunk-7PFZBRGF.js} +1 -1
  23. package/build/runtime-chunk-7PFZBRGF.js.br +0 -0
  24. package/build/runtime-chunk-7PFZBRGF.js.gz +0 -0
  25. package/build/{runtime-chunk-D3BWEUN6.js → runtime-chunk-AIWIOLR6.js} +1 -1
  26. package/build/runtime-chunk-AIWIOLR6.js.br +0 -0
  27. package/build/{runtime-chunk-D3BWEUN6.js.gz → runtime-chunk-AIWIOLR6.js.gz} +0 -0
  28. package/build/runtime-chunk-CHOZ3Y5I.js +1 -0
  29. package/build/runtime-chunk-CHOZ3Y5I.js.br +0 -0
  30. package/build/runtime-chunk-CHOZ3Y5I.js.gz +0 -0
  31. package/build/runtime-chunk-DHZVCYH4.js +1 -0
  32. package/build/runtime-chunk-DHZVCYH4.js.br +0 -0
  33. package/build/runtime-chunk-DHZVCYH4.js.gz +0 -0
  34. package/build/{runtime-chunk-YH55FWRI.js → runtime-chunk-DMRFHNRP.js} +1 -1
  35. package/build/runtime-chunk-DMRFHNRP.js.br +0 -0
  36. package/build/runtime-chunk-DMRFHNRP.js.gz +0 -0
  37. package/build/{runtime-chunk-OUQPS3VD.js → runtime-chunk-EJDIVLQA.js} +1 -1
  38. package/build/runtime-chunk-EJDIVLQA.js.br +0 -0
  39. package/build/runtime-chunk-EJDIVLQA.js.gz +0 -0
  40. package/build/{runtime-chunk-T4UMOSIQ.js → runtime-chunk-GZVBZLQ3.js} +1 -1
  41. package/build/{runtime-chunk-T4UMOSIQ.js.br → runtime-chunk-GZVBZLQ3.js.br} +0 -0
  42. package/build/runtime-chunk-GZVBZLQ3.js.gz +0 -0
  43. package/build/{runtime-chunk-ITI3UXPR.js → runtime-chunk-H2442PY7.js} +1 -1
  44. package/build/runtime-chunk-H2442PY7.js.br +0 -0
  45. package/build/runtime-chunk-H2442PY7.js.gz +0 -0
  46. package/build/{runtime-chunk-3IBXKX7I.js → runtime-chunk-HKD2ORV5.js} +1 -1
  47. package/build/runtime-chunk-HKD2ORV5.js.br +0 -0
  48. package/build/runtime-chunk-HKD2ORV5.js.gz +0 -0
  49. package/build/runtime-chunk-INDD2IUU.js +1 -0
  50. package/build/runtime-chunk-INDD2IUU.js.br +0 -0
  51. package/build/runtime-chunk-INDD2IUU.js.gz +0 -0
  52. package/build/{runtime-chunk-4GNBET46.js → runtime-chunk-L5SU5F5J.js} +1 -1
  53. package/build/runtime-chunk-L5SU5F5J.js.br +0 -0
  54. package/build/runtime-chunk-L5SU5F5J.js.gz +0 -0
  55. package/build/{runtime-chunk-WWYY25M2.js → runtime-chunk-LUASUHYM.js} +1 -1
  56. package/build/runtime-chunk-LUASUHYM.js.br +0 -0
  57. package/build/runtime-chunk-LUASUHYM.js.gz +0 -0
  58. package/build/{runtime-chunk-2GAIM5RJ.js → runtime-chunk-MF6PRJPV.js} +1 -1
  59. package/build/runtime-chunk-MF6PRJPV.js.br +0 -0
  60. package/build/runtime-chunk-MF6PRJPV.js.gz +0 -0
  61. package/build/runtime-chunk-MKUFNGGW.js +1 -0
  62. package/build/runtime-chunk-MKUFNGGW.js.br +0 -0
  63. package/build/runtime-chunk-MKUFNGGW.js.gz +0 -0
  64. package/build/{runtime-chunk-XUHTMJJD.js → runtime-chunk-N473U2V2.js} +1 -1
  65. package/build/runtime-chunk-N473U2V2.js.br +0 -0
  66. package/build/runtime-chunk-N473U2V2.js.gz +0 -0
  67. package/build/{runtime-chunk-BEWQ5BW5.js → runtime-chunk-NAJO6T26.js} +1 -1
  68. package/build/runtime-chunk-NAJO6T26.js.br +0 -0
  69. package/build/runtime-chunk-NAJO6T26.js.gz +0 -0
  70. package/build/{runtime-chunk-SJQBQYDG.js → runtime-chunk-NQ5JYNZM.js} +1 -1
  71. package/build/runtime-chunk-NQ5JYNZM.js.br +0 -0
  72. package/build/runtime-chunk-NQ5JYNZM.js.gz +0 -0
  73. package/build/runtime-chunk-PCGGIHOQ.js +1 -0
  74. package/build/runtime-chunk-PCGGIHOQ.js.br +0 -0
  75. package/build/runtime-chunk-PCGGIHOQ.js.gz +0 -0
  76. package/build/{runtime-chunk-JLL5C22M.js → runtime-chunk-PLKRHTT5.js} +1 -1
  77. package/build/runtime-chunk-PLKRHTT5.js.br +0 -0
  78. package/build/runtime-chunk-PLKRHTT5.js.gz +0 -0
  79. package/build/runtime-chunk-QYZPTNBH.js +1 -0
  80. package/build/runtime-chunk-QYZPTNBH.js.br +0 -0
  81. package/build/runtime-chunk-QYZPTNBH.js.gz +0 -0
  82. package/build/{runtime-chunk-4KZXQGUQ.js → runtime-chunk-RTLL6WIB.js} +1 -1
  83. package/build/runtime-chunk-RTLL6WIB.js.br +0 -0
  84. package/build/runtime-chunk-RTLL6WIB.js.gz +0 -0
  85. package/build/{runtime-chunk-PS74VRLB.js → runtime-chunk-S6KLXGEL.js} +1 -1
  86. package/build/runtime-chunk-S6KLXGEL.js.br +0 -0
  87. package/build/runtime-chunk-S6KLXGEL.js.gz +0 -0
  88. package/build/runtime-chunk-ST4VJ5DF.js +1 -0
  89. package/build/runtime-chunk-ST4VJ5DF.js.br +0 -0
  90. package/build/runtime-chunk-ST4VJ5DF.js.gz +0 -0
  91. package/build/{runtime-chunk-JSOWOATQ.js → runtime-chunk-U5366HDY.js} +1 -1
  92. package/build/runtime-chunk-U5366HDY.js.br +0 -0
  93. package/build/runtime-chunk-U5366HDY.js.gz +0 -0
  94. package/build/{runtime-chunk-2S2NQ44M.js → runtime-chunk-XOP32NU4.js} +1 -1
  95. package/build/runtime-chunk-XOP32NU4.js.br +0 -0
  96. package/build/runtime-chunk-XOP32NU4.js.gz +0 -0
  97. package/build/{runtime-chunk-HKFPEE5F.js → runtime-chunk-YURN6PI7.js} +1 -1
  98. package/build/runtime-chunk-YURN6PI7.js.br +0 -0
  99. package/build/runtime-chunk-YURN6PI7.js.gz +0 -0
  100. package/build/{runtime-chunk-MJYVLFQT.js → runtime-chunk-ZH7TNSZJ.js} +1 -1
  101. package/build/runtime-chunk-ZH7TNSZJ.js.br +0 -0
  102. package/build/runtime-chunk-ZH7TNSZJ.js.gz +0 -0
  103. package/build/{runtime-classicRuntime-ZJP7UOQK.js → runtime-classicRuntime-CTLZXFOK.js} +1 -1
  104. package/build/runtime-classicRuntime-CTLZXFOK.js.br +0 -0
  105. package/build/runtime-classicRuntime-CTLZXFOK.js.gz +0 -0
  106. package/build/runtime-cloners-6BXWHHH6.js +1 -0
  107. package/build/runtime-cloners-6BXWHHH6.js.br +0 -0
  108. package/build/runtime-cloners-6BXWHHH6.js.gz +0 -0
  109. package/build/runtime-components-YTMTPERH.js +1 -0
  110. package/build/runtime-components-YTMTPERH.js.br +0 -0
  111. package/build/runtime-components-YTMTPERH.js.gz +0 -0
  112. package/build/runtime-conditional-CEO237EN.js +1 -0
  113. package/build/runtime-conditional-CEO237EN.js.br +0 -0
  114. package/build/runtime-conditional-CEO237EN.js.gz +0 -0
  115. package/build/{runtime-createDestroy-MAV4GFE6.js → runtime-createDestroy-2RJVOGQP.js} +1 -1
  116. package/build/runtime-createDestroy-2RJVOGQP.js.br +0 -0
  117. package/build/runtime-createDestroy-2RJVOGQP.js.gz +0 -0
  118. package/build/{runtime-dragDrop-IZ74WMYA.js → runtime-dragDrop-CUXGIFGP.js} +1 -1
  119. package/build/runtime-dragDrop-CUXGIFGP.js.br +0 -0
  120. package/build/runtime-dragDrop-CUXGIFGP.js.gz +0 -0
  121. package/build/{runtime-gameControls-ALSYS4GT.js → runtime-gameControls-HKLCWLKJ.js} +1 -1
  122. package/build/runtime-gameControls-HKLCWLKJ.js.br +0 -0
  123. package/build/runtime-gameControls-HKLCWLKJ.js.gz +0 -0
  124. package/build/runtime-hair-R36ZBISB.js +1 -0
  125. package/build/runtime-hair-R36ZBISB.js.br +1 -0
  126. package/build/runtime-hair-R36ZBISB.js.gz +0 -0
  127. package/build/{runtime-mergeStaticGeometries-OPJK4T22.js → runtime-mergeStaticGeometries-RPBLPAJO.js} +1 -1
  128. package/build/runtime-mergeStaticGeometries-RPBLPAJO.js.br +0 -0
  129. package/build/runtime-mergeStaticGeometries-RPBLPAJO.js.gz +0 -0
  130. package/build/runtime-miscActions-V7N7OCRE.js +1 -0
  131. package/build/runtime-miscActions-V7N7OCRE.js.br +0 -0
  132. package/build/runtime-miscActions-V7N7OCRE.js.gz +0 -0
  133. package/build/{runtime-mouseHover-FM43SWSA.js → runtime-mouseHover-2FQXNHVN.js} +1 -1
  134. package/build/runtime-mouseHover-2FQXNHVN.js.br +0 -0
  135. package/build/runtime-mouseHover-2FQXNHVN.js.gz +0 -0
  136. package/build/{runtime-particles-NY5M47HQ.js → runtime-particles-JZREUE5L.js} +1 -1
  137. package/build/runtime-particles-JZREUE5L.js.br +0 -0
  138. package/build/runtime-particles-JZREUE5L.js.gz +0 -0
  139. package/build/{runtime-paths-LU43LMTP.js → runtime-paths-H3BLID6D.js} +1 -1
  140. package/build/runtime-paths-H3BLID6D.js.br +0 -0
  141. package/build/runtime-paths-H3BLID6D.js.gz +0 -0
  142. package/build/runtime-resize-ZD62VEBD.js +1 -0
  143. package/build/runtime-resize-ZD62VEBD.js.br +0 -0
  144. package/build/runtime-resize-ZD62VEBD.js.gz +0 -0
  145. package/build/{runtime-sceneTransition-4R6LM4MA.js → runtime-sceneTransition-UMLH7ZRG.js} +1 -1
  146. package/build/runtime-sceneTransition-UMLH7ZRG.js.br +0 -0
  147. package/build/runtime-sceneTransition-UMLH7ZRG.js.gz +0 -0
  148. package/build/{runtime-scroll-KEVND4W5.js → runtime-scroll-G27Z5O4C.js} +1 -1
  149. package/build/runtime-scroll-G27Z5O4C.js.br +0 -0
  150. package/build/runtime-scroll-G27Z5O4C.js.gz +0 -0
  151. package/build/runtime-shapeBlends-E6SX5CX3.js +1 -0
  152. package/build/runtime-shapeBlends-E6SX5CX3.js.br +0 -0
  153. package/build/runtime-shapeBlends-E6SX5CX3.js.gz +0 -0
  154. package/build/{runtime-text-43V5BJGN.js → runtime-text-MQDKSA5W.js} +1 -1
  155. package/build/runtime-text-MQDKSA5W.js.br +0 -0
  156. package/build/runtime-text-MQDKSA5W.js.gz +0 -0
  157. package/build/{runtime-textInputs-WPBZO7XI.js → runtime-textInputs-5DEQBIWS.js} +1 -1
  158. package/build/runtime-textInputs-5DEQBIWS.js.br +0 -0
  159. package/build/runtime-textInputs-5DEQBIWS.js.gz +0 -0
  160. package/build/runtime-timeline-Z7YJ7ASI.js +1 -0
  161. package/build/runtime-timeline-Z7YJ7ASI.js.br +0 -0
  162. package/build/runtime-timeline-Z7YJ7ASI.js.gz +0 -0
  163. package/build/{runtime-tracking-T55DMPAI.js → runtime-tracking-IW6LURXT.js} +1 -1
  164. package/build/runtime-tracking-IW6LURXT.js.br +0 -0
  165. package/build/runtime-tracking-IW6LURXT.js.gz +0 -0
  166. package/build/runtime-transitions-B5OB67GR.js +1 -0
  167. package/build/runtime-transitions-B5OB67GR.js.br +0 -0
  168. package/build/runtime-transitions-B5OB67GR.js.gz +0 -0
  169. package/build/{runtime-ui2d-FPEODT3M.js → runtime-ui2d-R4W643OE.js} +1 -1
  170. package/build/runtime-ui2d-R4W643OE.js.br +0 -0
  171. package/build/runtime-ui2d-R4W643OE.js.gz +0 -0
  172. package/build/{runtime-updater-A22NUPB5.js → runtime-updater-2CFDVEWY.js} +1 -1
  173. package/build/runtime-updater-2CFDVEWY.js.br +0 -0
  174. package/build/runtime-updater-2CFDVEWY.js.gz +0 -0
  175. package/build/{runtime-variables-MHCE3K3T.js → runtime-variables-S7QUT7HH.js} +1 -1
  176. package/build/runtime-variables-S7QUT7HH.js.br +0 -0
  177. package/build/runtime-variables-S7QUT7HH.js.gz +0 -0
  178. package/build/{runtime-vectorShapes-ZXLM5DCY.js → runtime-vectorShapes-ASLQ3T6K.js} +1 -1
  179. package/build/runtime-vectorShapes-ASLQ3T6K.js.br +0 -0
  180. package/build/runtime-vectorShapes-ASLQ3T6K.js.gz +0 -0
  181. package/build/{runtime-video-YA2L3X6S.js → runtime-video-SBFWLQQT.js} +1 -1
  182. package/build/runtime-video-SBFWLQQT.js.br +0 -0
  183. package/build/runtime-video-SBFWLQQT.js.gz +0 -0
  184. package/build/{runtime-webgpu-WHAEJKRX.js → runtime-webgpu-XRBI423N.js} +1 -1
  185. package/build/runtime-webgpu-XRBI423N.js.br +0 -0
  186. package/build/runtime-webgpu-XRBI423N.js.gz +0 -0
  187. package/build/runtime.cjs +429 -431
  188. package/build/runtime.js +1 -1
  189. package/build/runtime.js.br +0 -0
  190. package/build/runtime.js.gz +0 -0
  191. package/build/runtime.standalone.js +1 -1
  192. package/build/runtime.standalone.js.br +0 -0
  193. package/build/runtime.standalone.js.gz +0 -0
  194. package/build/runtime.standalone.webgl.js +1 -1
  195. package/build/runtime.standalone.webgl.js.br +0 -0
  196. package/build/runtime.standalone.webgl.js.gz +0 -0
  197. package/build/runtime.standalone.webgpu.js +1 -1
  198. package/build/runtime.standalone.webgpu.js.br +0 -0
  199. package/build/runtime.standalone.webgpu.js.gz +0 -0
  200. package/build/runtime.standalone.webgpu.micro.js +1 -1
  201. package/build/runtime.standalone.webgpu.micro.js.br +0 -0
  202. package/build/runtime.standalone.webgpu.micro.js.gz +0 -0
  203. package/build/runtime.standalone.webgpu.min.js +1 -1
  204. package/build/runtime.standalone.webgpu.min.js.br +0 -0
  205. package/build/runtime.standalone.webgpu.min.js.gz +0 -0
  206. package/package.json +2 -1
  207. package/build/runtime-aiAssistant-L3HFJZ2G.js.br +0 -0
  208. package/build/runtime-aiAssistant-L3HFJZ2G.js.gz +0 -0
  209. package/build/runtime-apiServices-KSRZJMJI.js.br +0 -0
  210. package/build/runtime-apiServices-KSRZJMJI.js.gz +0 -0
  211. package/build/runtime-audio-CNGZPKC5.js.br +0 -0
  212. package/build/runtime-audio-CNGZPKC5.js.gz +0 -0
  213. package/build/runtime-chunk-2GAIM5RJ.js.br +0 -0
  214. package/build/runtime-chunk-2GAIM5RJ.js.gz +0 -0
  215. package/build/runtime-chunk-2S2NQ44M.js.br +0 -0
  216. package/build/runtime-chunk-2S2NQ44M.js.gz +0 -0
  217. package/build/runtime-chunk-3IBXKX7I.js.br +0 -0
  218. package/build/runtime-chunk-3IBXKX7I.js.gz +0 -0
  219. package/build/runtime-chunk-4GNBET46.js.br +0 -0
  220. package/build/runtime-chunk-4GNBET46.js.gz +0 -0
  221. package/build/runtime-chunk-4KZXQGUQ.js.br +0 -0
  222. package/build/runtime-chunk-4KZXQGUQ.js.gz +0 -0
  223. package/build/runtime-chunk-5POGWSQZ.js.br +0 -0
  224. package/build/runtime-chunk-5POGWSQZ.js.gz +0 -0
  225. package/build/runtime-chunk-A7IMJ4FJ.js +0 -1
  226. package/build/runtime-chunk-A7IMJ4FJ.js.br +0 -0
  227. package/build/runtime-chunk-A7IMJ4FJ.js.gz +0 -0
  228. package/build/runtime-chunk-ALTKMFUV.js +0 -1
  229. package/build/runtime-chunk-ALTKMFUV.js.br +0 -0
  230. package/build/runtime-chunk-ALTKMFUV.js.gz +0 -0
  231. package/build/runtime-chunk-BEWQ5BW5.js.br +0 -0
  232. package/build/runtime-chunk-BEWQ5BW5.js.gz +0 -0
  233. package/build/runtime-chunk-D3BWEUN6.js.br +0 -0
  234. package/build/runtime-chunk-ESL2VL5C.js +0 -1
  235. package/build/runtime-chunk-ESL2VL5C.js.br +0 -0
  236. package/build/runtime-chunk-ESL2VL5C.js.gz +0 -0
  237. package/build/runtime-chunk-F5CUMYOK.js +0 -1
  238. package/build/runtime-chunk-F5CUMYOK.js.br +0 -0
  239. package/build/runtime-chunk-F5CUMYOK.js.gz +0 -0
  240. package/build/runtime-chunk-HKFPEE5F.js.br +0 -0
  241. package/build/runtime-chunk-HKFPEE5F.js.gz +0 -0
  242. package/build/runtime-chunk-ITI3UXPR.js.br +0 -0
  243. package/build/runtime-chunk-ITI3UXPR.js.gz +0 -0
  244. package/build/runtime-chunk-JIIVUL2M.js.br +0 -0
  245. package/build/runtime-chunk-JIIVUL2M.js.gz +0 -0
  246. package/build/runtime-chunk-JLL5C22M.js.br +0 -0
  247. package/build/runtime-chunk-JLL5C22M.js.gz +0 -0
  248. package/build/runtime-chunk-JSOWOATQ.js.br +0 -0
  249. package/build/runtime-chunk-JSOWOATQ.js.gz +0 -0
  250. package/build/runtime-chunk-KGZNRID6.js +0 -1
  251. package/build/runtime-chunk-KGZNRID6.js.br +0 -1
  252. package/build/runtime-chunk-KGZNRID6.js.gz +0 -0
  253. package/build/runtime-chunk-MJYVLFQT.js.br +0 -0
  254. package/build/runtime-chunk-MJYVLFQT.js.gz +0 -0
  255. package/build/runtime-chunk-OUQPS3VD.js.br +0 -0
  256. package/build/runtime-chunk-OUQPS3VD.js.gz +0 -0
  257. package/build/runtime-chunk-PS74VRLB.js.br +0 -0
  258. package/build/runtime-chunk-PS74VRLB.js.gz +0 -0
  259. package/build/runtime-chunk-QMMGYOLW.js.br +0 -0
  260. package/build/runtime-chunk-QMMGYOLW.js.gz +0 -0
  261. package/build/runtime-chunk-R43XZP65.js +0 -1
  262. package/build/runtime-chunk-R43XZP65.js.br +0 -0
  263. package/build/runtime-chunk-R43XZP65.js.gz +0 -0
  264. package/build/runtime-chunk-SJQBQYDG.js.br +0 -0
  265. package/build/runtime-chunk-SJQBQYDG.js.gz +0 -0
  266. package/build/runtime-chunk-T4UMOSIQ.js.gz +0 -0
  267. package/build/runtime-chunk-VAANBQKN.js.br +0 -0
  268. package/build/runtime-chunk-VAANBQKN.js.gz +0 -0
  269. package/build/runtime-chunk-VGEECQH4.js +0 -1
  270. package/build/runtime-chunk-VGEECQH4.js.br +0 -0
  271. package/build/runtime-chunk-VGEECQH4.js.gz +0 -0
  272. package/build/runtime-chunk-WGBR2HLR.js +0 -1
  273. package/build/runtime-chunk-WGBR2HLR.js.br +0 -0
  274. package/build/runtime-chunk-WGBR2HLR.js.gz +0 -0
  275. package/build/runtime-chunk-WILQUYJ4.js.br +0 -0
  276. package/build/runtime-chunk-WILQUYJ4.js.gz +0 -0
  277. package/build/runtime-chunk-WWYY25M2.js.br +0 -0
  278. package/build/runtime-chunk-WWYY25M2.js.gz +0 -0
  279. package/build/runtime-chunk-XUHTMJJD.js.br +0 -0
  280. package/build/runtime-chunk-XUHTMJJD.js.gz +0 -0
  281. package/build/runtime-chunk-YH55FWRI.js.br +0 -0
  282. package/build/runtime-chunk-YH55FWRI.js.gz +0 -0
  283. package/build/runtime-classicRuntime-ZJP7UOQK.js.br +0 -0
  284. package/build/runtime-classicRuntime-ZJP7UOQK.js.gz +0 -0
  285. package/build/runtime-cloners-V4TFNW2E.js +0 -1
  286. package/build/runtime-cloners-V4TFNW2E.js.br +0 -0
  287. package/build/runtime-cloners-V4TFNW2E.js.gz +0 -0
  288. package/build/runtime-components-P5ZGYATF.js +0 -1
  289. package/build/runtime-components-P5ZGYATF.js.br +0 -0
  290. package/build/runtime-components-P5ZGYATF.js.gz +0 -0
  291. package/build/runtime-conditional-66QFNGF3.js +0 -1
  292. package/build/runtime-conditional-66QFNGF3.js.br +0 -0
  293. package/build/runtime-conditional-66QFNGF3.js.gz +0 -0
  294. package/build/runtime-createDestroy-MAV4GFE6.js.br +0 -0
  295. package/build/runtime-createDestroy-MAV4GFE6.js.gz +0 -0
  296. package/build/runtime-dragDrop-IZ74WMYA.js.br +0 -0
  297. package/build/runtime-dragDrop-IZ74WMYA.js.gz +0 -0
  298. package/build/runtime-gameControls-ALSYS4GT.js.br +0 -0
  299. package/build/runtime-gameControls-ALSYS4GT.js.gz +0 -0
  300. package/build/runtime-hair-PML4TDM4.js +0 -1
  301. package/build/runtime-hair-PML4TDM4.js.br +0 -1
  302. package/build/runtime-hair-PML4TDM4.js.gz +0 -0
  303. package/build/runtime-mergeStaticGeometries-OPJK4T22.js.br +0 -0
  304. package/build/runtime-mergeStaticGeometries-OPJK4T22.js.gz +0 -0
  305. package/build/runtime-miscActions-JZQXYHKG.js +0 -1
  306. package/build/runtime-miscActions-JZQXYHKG.js.br +0 -0
  307. package/build/runtime-miscActions-JZQXYHKG.js.gz +0 -0
  308. package/build/runtime-mouseHover-FM43SWSA.js.br +0 -0
  309. package/build/runtime-mouseHover-FM43SWSA.js.gz +0 -0
  310. package/build/runtime-particles-NY5M47HQ.js.br +0 -0
  311. package/build/runtime-particles-NY5M47HQ.js.gz +0 -0
  312. package/build/runtime-paths-LU43LMTP.js.br +0 -0
  313. package/build/runtime-paths-LU43LMTP.js.gz +0 -0
  314. package/build/runtime-resize-BWOD7P3W.js +0 -1
  315. package/build/runtime-resize-BWOD7P3W.js.br +0 -0
  316. package/build/runtime-resize-BWOD7P3W.js.gz +0 -0
  317. package/build/runtime-sceneTransition-4R6LM4MA.js.br +0 -0
  318. package/build/runtime-sceneTransition-4R6LM4MA.js.gz +0 -0
  319. package/build/runtime-scroll-KEVND4W5.js.br +0 -0
  320. package/build/runtime-scroll-KEVND4W5.js.gz +0 -0
  321. package/build/runtime-shapeBlends-LXJ4P3XD.js +0 -1
  322. package/build/runtime-shapeBlends-LXJ4P3XD.js.br +0 -0
  323. package/build/runtime-shapeBlends-LXJ4P3XD.js.gz +0 -0
  324. package/build/runtime-text-43V5BJGN.js.br +0 -0
  325. package/build/runtime-text-43V5BJGN.js.gz +0 -0
  326. package/build/runtime-textInputs-WPBZO7XI.js.br +0 -0
  327. package/build/runtime-textInputs-WPBZO7XI.js.gz +0 -0
  328. package/build/runtime-timeline-AERFJWNC.js +0 -1
  329. package/build/runtime-timeline-AERFJWNC.js.br +0 -0
  330. package/build/runtime-timeline-AERFJWNC.js.gz +0 -0
  331. package/build/runtime-tracking-T55DMPAI.js.br +0 -0
  332. package/build/runtime-tracking-T55DMPAI.js.gz +0 -0
  333. package/build/runtime-transitions-SLQEEKRO.js +0 -1
  334. package/build/runtime-transitions-SLQEEKRO.js.br +0 -0
  335. package/build/runtime-transitions-SLQEEKRO.js.gz +0 -0
  336. package/build/runtime-ui2d-FPEODT3M.js.br +0 -0
  337. package/build/runtime-ui2d-FPEODT3M.js.gz +0 -0
  338. package/build/runtime-updater-A22NUPB5.js.br +0 -1
  339. package/build/runtime-updater-A22NUPB5.js.gz +0 -0
  340. package/build/runtime-variables-MHCE3K3T.js.br +0 -0
  341. package/build/runtime-variables-MHCE3K3T.js.gz +0 -0
  342. package/build/runtime-vectorShapes-ZXLM5DCY.js.br +0 -0
  343. package/build/runtime-vectorShapes-ZXLM5DCY.js.gz +0 -0
  344. package/build/runtime-video-YA2L3X6S.js.br +0 -0
  345. package/build/runtime-video-YA2L3X6S.js.gz +0 -0
  346. package/build/runtime-webgpu-WHAEJKRX.js.br +0 -0
  347. package/build/runtime-webgpu-WHAEJKRX.js.gz +0 -0
@@ -1 +1 @@
1
- import{a as t}from"./runtime-chunk-NTUTXO7Q.js";import{b as e}from"./runtime-chunk-A7IMJ4FJ.js";import{b as i,c as r,d as s,e as n}from"./runtime-chunk-VGEECQH4.js";import{E as a,b as h,k as o,o as l}from"./runtime-chunk-D3BWEUN6.js";import{a as d,b as u}from"./runtime-chunk-ML3Z74BL.js";var c,p,f,x=d((t,e)=>{function i(t,e,r,s){this.message=t,this.expected=e,this.found=r,this.location=s,this.name="SyntaxError","function"==typeof Error.captureStackTrace&&Error.captureStackTrace(this,i)}!function(t,e){function i(){this.constructor=t}i.prototype=e.prototype,t.prototype=new i}(i,Error),i.buildMessage=function(t,e){var i,r={literal:function(t){return'"'+n(t.text)+'"'},class:function(t){var e,i="";for(e=0;e<t.parts.length;e++)i+=t.parts[e]instanceof Array?a(t.parts[e][0])+"-"+a(t.parts[e][1]):a(t.parts[e]);return"["+(t.inverted?"^":"")+i+"]"},any:function(t){return"any character"},end:function(t){return"end of input"},other:function(t){return t.description}};function s(t){return t.charCodeAt(0).toString(16).toUpperCase()}function n(t){return t.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(t){return"\\x0"+s(t)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(t){return"\\x"+s(t)})}function a(t){return t.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(t){return"\\x0"+s(t)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(t){return"\\x"+s(t)})}function h(t){return r[t.type](t)}return"Expected "+function(t){var e,i,r=new Array(t.length);for(e=0;e<t.length;e++)r[e]=h(t[e]);if(r.sort(),r.length>0){for(e=1,i=1;e<r.length;e++)r[e-1]!==r[e]&&(r[i]=r[e],i++);r.length=i}switch(r.length){case 1:return r[0];case 2:return r[0]+" or "+r[1];default:return r.slice(0,-1).join(", ")+", or "+r[r.length-1]}}(t)+" but "+((i=e)?'"'+n(i)+'"':"end of input")+" found."},e.exports={SyntaxError:i,parse:function(t,e){e=void 0!==e?e:{};var r,s={},n={svg_path:xt},a=xt,h=function(t){if(!t)return[];for(var e=[],i=0;i<t.length;i++)e=e.concat.apply(e,t[i]);var r=e[0];return r&&"m"==r.code&&(delete r.relative,r.code="M"),e},o=function(t,e){return function(t,e){if(!e)return[t];for(var i=[t],r=0,s=e.length;r<s;r++)i[r+1]=e[r][1];return i}(t,e)},l=/^[Mm]/,d=ut(["M","m"],!1,!1),u=function(t,e,i){var r=jt(t,[e]);return i&&(r=r.concat(jt("M"==t?"L":"l",i[1]))),r},c=/^[Zz]/,p=ut(["Z","z"],!1,!1),f=function(){return jt("Z")},x=/^[Ll]/,g=ut(["L","l"],!1,!1),m=function(t,e){return jt(t,e)},y=/^[Hh]/,v=ut(["H","h"],!1,!1),w=function(t,e){return jt(t,e.map(function(t){return{x:t}}))},_=/^[Vv]/,S=ut(["V","v"],!1,!1),B=function(t,e){return jt(t,e.map(function(t){return{y:t}}))},b=/^[Cc]/,M=ut(["C","c"],!1,!1),C=function(t,e,i){return{x1:t.x,y1:t.y,x2:e.x,y2:e.y,x:i.x,y:i.y}},k=/^[Ss]/,A=ut(["S","s"],!1,!1),T=function(t,e){return{x2:t.x,y2:t.y,x:e.x,y:e.y}},P=/^[Qq]/,z=ut(["Q","q"],!1,!1),R=function(t,e){return{x1:t.x,y1:t.y,x:e.x,y:e.y}},E=/^[Tt]/,O=ut(["T","t"],!1,!1),H=/^[Aa]/,L=ut(["A","a"],!1,!1),F=function(t,e,i,r,s,n){return{rx:t,ry:e,xAxisRotation:i,largeArc:r,sweep:s,x:n.x,y:n.y}},U=function(t,e){return{x:t,y:e}},N=function(t){return 1*t},j=function(t){return 1*t.join("")},I=/^[01]/,D=ut(["0","1"],!1,!1),W=function(t){return"1"==t},V=function(){return""},X=",",q=dt(",",!1),Y=function(t){return t.join("")},$=".",G=dt(".",!1),Q=/^[eE]/,J=ut(["e","E"],!1,!1),Z=/^[+\-]/,K=ut(["+","-"],!1,!1),tt=/^[0-9]/,et=ut([["0","9"]],!1,!1),it=function(t){return t.join("")},rt=/^[ \t\n\r]/,st=ut([" ","\t","\n","\r"],!1,!1),nt=0,at=[{line:1,column:1}],ht=0,ot=[],lt=0;if("startRule"in e){if(!(e.startRule in n))throw new Error("Can't start parsing from rule \""+e.startRule+'".');a=n[e.startRule]}function dt(t,e){return{type:"literal",text:t,ignoreCase:e}}function ut(t,e,i){return{type:"class",parts:t,inverted:e,ignoreCase:i}}function ct(e){var i,r=at[e];if(r)return r;for(i=e-1;!at[i];)i--;for(r={line:(r=at[i]).line,column:r.column};i<e;)10===t.charCodeAt(i)?(r.line++,r.column=1):r.column++,i++;return at[e]=r,r}function pt(t,e){var i=ct(t),r=ct(e);return{start:{offset:t,line:i.line,column:i.column},end:{offset:e,line:r.line,column:r.column}}}function ft(t){nt<ht||(nt>ht&&(ht=nt,ot=[]),ot.push(t))}function xt(){var t,e,i,r,n;for(t=nt,e=[],i=Ot();i!==s;)e.push(i),i=Ot();if(e!==s)if(i=function(){var t,e,i,r,n,a;if(t=nt,(e=gt())!==s){for(i=[],r=nt,n=[],a=Ot();a!==s;)n.push(a),a=Ot();for(n!==s&&(a=gt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;){for(i.push(r),r=nt,n=[],a=Ot();a!==s;)n.push(a),a=Ot();n!==s&&(a=gt())!==s?r=n=[n,a]:(nt=r,r=s)}i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),i===s&&(i=null),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?t=e=h(i):(nt=t,t=s)}else nt=t,t=s;else nt=t,t=s;return t}function gt(){var e,i,r,n,a,h;if(e=nt,i=function(){var e,i,r,n,a,h,o;if(e=nt,l.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(d)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s&&(n=bt())!==s?(a=nt,(h=At())===s&&(h=null),h!==s&&(o=yt())!==s?a=h=[h,o]:(nt=a,a=s),a===s&&(a=null),a!==s?e=i=u(i,n,a):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}(),i!==s){for(r=[],n=nt,a=[],h=Ot();h!==s;)a.push(h),h=Ot();for(a!==s&&(h=mt())!==s?n=a=[a,h]:(nt=n,n=s);n!==s;){for(r.push(n),n=nt,a=[],h=Ot();h!==s;)a.push(h),h=Ot();a!==s&&(h=mt())!==s?n=a=[a,h]:(nt=n,n=s)}r!==s?e=i=o(i,r):(nt=e,e=s)}else nt=e,e=s;return e}function mt(){var e,i;return c.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(p)),i!==s&&(i=f()),(e=i)===s&&(e=function(){var e,i,r,n;if(e=nt,x.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(g)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s&&(n=yt())!==s?e=i=m(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,y.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(v)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s&&(n=vt())!==s?e=i=w(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,_.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(S)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s&&(n=vt())!==s?e=i=B(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,b.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(M)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=wt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=wt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=wt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,k.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(A)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=_t())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=_t())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=_t())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,P.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(z)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=St())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=St())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=St())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,E.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(O)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,H.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(L)),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=Bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=Bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=Bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}()),e}function yt(){var t,e,i,r,n,a;if(t=nt,(e=bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}function vt(){var t,e,i,r,n,a;if(t=nt,(e=Ct())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=Ct())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=Ct())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}function wt(){var t,e,i,r,n,a;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?((n=At())===s&&(n=null),n!==s&&(a=bt())!==s?t=e=C(e,r,a):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s),t}function _t(){var t,e,i,r;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?t=e=T(e,r):(nt=t,t=s)):(nt=t,t=s),t}function St(){var t,e,i,r;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?t=e=R(e,r):(nt=t,t=s)):(nt=t,t=s),t}function Bt(){var t,e,i,r,n,a,h,o,l,d,u;return t=nt,(e=Mt())!==s?((i=At())===s&&(i=null),i!==s&&(r=Mt())!==s?((n=At())===s&&(n=null),n!==s&&(a=Ct())!==s&&At()!==s&&(h=kt())!==s?((o=At())===s&&(o=null),o!==s&&(l=kt())!==s?((d=At())===s&&(d=null),d!==s&&(u=bt())!==s?t=e=F(e,r,a,h,l,u):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s),t}function bt(){var t,e,i,r;return t=nt,(e=Ct())!==s?((i=At())===s&&(i=null),i!==s&&(r=Ct())!==s?t=e=U(e,r):(nt=t,t=s)):(nt=t,t=s),t}function Mt(){var t;return(t=Pt())===s&&(t=Et()),t!==s&&(t=N(t)),t}function Ct(){var t,e,i;return t=nt,(e=Rt())===s&&(e=null),e!==s&&(i=Pt())!==s?t=e=[e,i]:(nt=t,t=s),t===s&&(t=nt,(e=Rt())===s&&(e=null),e!==s&&(i=Et())!==s?t=e=[e,i]:(nt=t,t=s)),t!==s&&(t=j(t)),t}function kt(){var e;return I.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(D)),e!==s&&(e=W(e)),e}function At(){var t,e,i,r,n;if(t=nt,e=[],(i=Ot())!==s)for(;i!==s;)e.push(i),i=Ot();else e=s;if(e!==s)if((i=Tt())===s&&(i=null),i!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?t=e=[e,i,r]:(nt=t,t=s)}else nt=t,t=s;else nt=t,t=s;if(t===s){if(t=nt,e=nt,(i=Tt())!==s){for(r=[],n=Ot();n!==s;)r.push(n),n=Ot();r!==s?e=i=[i,r]:(nt=e,e=s)}else nt=e,e=s;e!==s&&(e=V()),t=e}return t}function Tt(){var e;return 44===t.charCodeAt(nt)?(e=X,nt++):(e=s,0===lt&&ft(q)),e}function Pt(){var e,i,r;return e=nt,i=function(){var e,i,r,n;return e=nt,(i=Et())===s&&(i=null),i!==s?(46===t.charCodeAt(nt)?(r=$,nt++):(r=s,0===lt&&ft(G)),r!==s&&(n=Et())!==s?e=i=[i,r,n]:(nt=e,e=s)):(nt=e,e=s),e===s&&(e=nt,(i=Et())!==s?(46===t.charCodeAt(nt)?(r=$,nt++):(r=s,0===lt&&ft(G)),r!==s?e=i=[i,r]:(nt=e,e=s)):(nt=e,e=s)),e!==s&&(e=Y(e)),e}(),i!==s?((r=zt())===s&&(r=null),r!==s?e=i=[i,r]:(nt=e,e=s)):(nt=e,e=s),e===s&&(e=nt,(i=Et())!==s&&(r=zt())!==s?e=i=[i,r]:(nt=e,e=s)),e!==s&&(e=Y(e)),e}function zt(){var e,i,r,n;return e=nt,Q.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(J)),i!==s?((r=Rt())===s&&(r=null),r!==s&&(n=Et())!==s?e=i=[i,r,n]:(nt=e,e=s)):(nt=e,e=s),e!==s&&(e=Y(e)),e}function Rt(){var e;return Z.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(K)),e}function Et(){var e,i;if(e=[],tt.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(et)),i!==s)for(;i!==s;)e.push(i),tt.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(et));else e=s;return e!==s&&(e=it(e)),e}function Ot(){var e;return rt.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(st)),e!==s&&(e=V()),e}var Ht,Lt,Ft,Ut={m:"moveto",l:"lineto",h:"horizontal lineto",v:"vertical lineto",c:"curveto",s:"smooth curveto",q:"quadratic curveto",t:"smooth quadratic curveto",a:"elliptical arc",z:"closepath"};for(var Nt in Ut)Ut[Nt.toUpperCase()]=Ut[Nt];function jt(t,e){e||(e=[{}]);for(var i=e.length;i--;){var r={code:t,command:Ut[t]};for(var s in t==t.toLowerCase()&&(r.relative=!0),e[i])r[s]=e[i][s];e[i]=r}return e}if((r=a())!==s&&nt===t.length)return r;throw r!==s&&nt<t.length&&ft({type:"end"}),Ht=ot,Lt=ht<t.length?t.charAt(ht):null,Ft=ht<t.length?pt(ht,ht+1):pt(ht,ht),new i(i.buildMessage(Ht,Lt),Ht,Lt,Ft)}}}),g=d((t,e)=>{var i=x().parse;i.parseSVG=i,i.makeAbsolute=function(t){var e,i={x:0,y:0},r={x:"x0",y:"y0",x1:"x0",y1:"y0",x2:"x0",y2:"y0"};return t.forEach(function(t){for(var s in"moveto"===t.command&&(e=t),t.x0=i.x,t.y0=i.y,r)s in t&&(t[s]+=t.relative?t[r[s]]:0);"x"in t||(t.x=i.x),"y"in t||(t.y=i.y),t.relative=!1,t.code=t.code.toUpperCase(),"closepath"==t.command&&(t.x=e.x,t.y=e.y),i=t}),t},e.exports=i});function m(){if(!p){if(!c)return Promise.reject(new Error("HanaRenderer: no Hana UI loader registered. Call setHanaUILoader() from the host app before initializing a HanaRenderer."));(p=c()).catch(()=>{p=void 0})}return p}function y(t){f=t}function v(){return c||(c=async()=>async function(t,e){return await t.default(e?{module_or_path:e}:void 0),Object.getOwnPropertyDescriptor(t.Engine.prototype,"scene")||Object.defineProperty(t.Engine.prototype,"scene",{get:function(){let e=Object.create(t.SceneController.prototype);return e.__wbg_ptr=this.__wbg_ptr,e}}),{createEngine:e=>t.Engine.create(e,JSON.parse('{"schema":13,"scenes":[{"fi":0,"id":"32603ebf4-bd9a-54ba-c1e9-6645c3ee7a53","data":{"name":"Page","backgroundColor":[0,0,0,0],"objects":[]}}],"assets":{"images":{},"videos":{},"colors":{},"audios":{},"numbers":{},"booleans":{},"strings":{},"dynamicVariables":{"counters":{},"randoms":{},"timers":{},"times":{}},"fonts":{},"animations":{},"geometries":{},"emojiArt":{}},"publish":{"logo":true,"presentationSizing":"Contain","allowPageScroll":true,"showBackground":true},"framePublish":{},"components":{}}'),!0)}}(await import("./hana-ui.js"),f??function(){let t=typeof process<"u"?"2.0.13":void 0;return`https://cdn.spline.design/@splinetool/runtime${t?`@${t}`:""}/build/hana-ui.wasm`}())),m().then(()=>{})}var w=Math.PI/180;Math.PI;var _,S=1e-10;function B(t,e){let[[i,r],[s,n]]=t,[[a,h],[o,l]]=e,d=(i-s)*(h-l)-(r-n)*(a-o);if(0===d)return!1;let u=((i-a)*(h-l)-(r-h)*(a-o))/d,c=-((i-s)*(r-h)-(r-n)*(i-a))/d;return u>=0&&u<=1&&c>=0&&c<=1}(t=>{function e(t){return[t[0],t[3],t[1],t[4],t[2],t[5]]}t.identity=function(){return[1,0,0,0,1,0,0,0,1]},t.copy=function(e,i=t.identity()){for(let t=0,r=e.length;t<r;t++)i[t]=e[t];return i},t.create=function(e,i,r,s,n,a){return t.setAbcdef(t.identity(),e,i,r,s,n,a)},t.setAbcdef=function(t,e,i,r,s,n,a){return t[0]=e,t[1]=r,t[2]=n,t[3]=i,t[4]=s,t[5]=a,t},t.append=function(i,r){let[s,n,a,h,o,l]=e(i),[d,u,c,p,f,x]=e(r),g=d*s+u*a,m=d*n+u*h,y=c*s+p*a,v=c*n+p*h,w=f*s+x*a+o,_=f*n+x*h+l;return t.create(g,m,y,v,w,_)},t.prepend=function(i,r){let[s,n,a,h,o,l]=e(i),[d,u,c,p,f,x]=e(r),g=s,m=n,y=a,v=h;(1!==d||0!==u||0!==c||1!==p)&&(g=s*d+n*c,m=s*u+n*p,y=a*d+h*c,v=a*u+h*p);let w=o*d+l*c+f,_=o*u+l*p+x;return t.create(g,m,y,v,w,_)},t.getAbcdef=e,t.invert=function(e){let[i,r,s,n,a,h]=t.getAbcdef(e),o=i*n-r*s,l=n/o,d=-r/o,u=-s/o,c=i/o,p=(s*h-n*a)/o,f=-(i*h-r*a)/o;return t.create(l,d,u,c,p,f)},t.apply=function([e,i],r){let[s,n,a,h,o,l]=t.getAbcdef(r);return[s*e+a*i+o,n*e+h*i+l]},t.applyInverse=function(e,i){let[r,s,n,a,h,o]=t.getAbcdef(i),l=1/(r*a+n*-s),[d,u]=e;return[a*l*d+-n*l*u+(o*n-h*a)*l,r*l*u+-s*l*d+(-o*r+h*s)*l]},t.scale=function(e,i,r=i){let[s,n,a,h,o,l]=t.getAbcdef(e);return t.setAbcdef(e,s*i,n*r,a*i,h*r,o*i,l*r),e},t.rotate=function(e,i){let r=Math.cos(i),s=Math.sin(i),[n,a,h,o,l,d]=t.getAbcdef(e);return t.setAbcdef(e,n*r-a*s,n*s+a*r,h*r-o*s,h*s+o*r,l*r-d*s,l*s+d*r),e},t.rotateAround=function(e,i,r){let[s,n]=r,a=t.translate(e,-s,-n);return a=t.rotate(a,i),a=t.translate(a,s,n),a},t.translate=function(e,i,r){let[s,n,a,h,o,l]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,o+i,l+r),e},t.setTranslate=function(e,i,r){let[s,n,a,h]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,i,r),e},t.setPosition=function(e,i,r){let[s,n,a,h]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,i,r),e},t.getScale=function(e){let[i,r,s,n]=t.getAbcdef(e);return[Math.sqrt(i*i+r*r),Math.sqrt(s*s+n*n)]},t.getPosition=function(e){let[,,,,i,r]=t.getAbcdef(e);return[i,r]},t.getRotation=function(e,i){return t.decompose(e,i).rotation},t.decompose=function(e,i){let[r,s,n,a,h,o]=t.getAbcdef(e),{rotation:l,scale:d,shear:u}=function(t){let e=t[0][0],i=t[1][0],r=t[0][1],s=t[1][1],n=Math.sqrt(e*e+i*i),a=n>S?e/n:1,h=n>S?i/n:0,o=a*e+h*i,l=a*s-h*r,d=a*r+h*s;return{rotation:Math.atan2(h,a),scale:[o,l],shear:[Math.abs(l)>S?d/l:0,0]}}([[r,n],[s,a]]);return{position:[h+(i[0]*r+i[1]*n)-i[0],o+(i[0]*s+i[1]*a)-i[1]],scale:d,rotation:l,shear:u,pivot:i}},t.compose=function(e,i,r,s,n=[0,0]){let[a,h]=e,[o,l]=s,[d,u,c,p]=function({rotation:t,scale:e,shear:i}){let r=Math.cos(t),s=Math.sin(t),n=i[0]*e[1],a=i[1]*e[0];return[r*e[0]-s*a,s*e[0]+r*a,r*n-s*e[1],s*n+r*e[1]]}({rotation:r,scale:i,shear:n}),f=a-(o*d+l*c)+o,x=h-(o*u+l*p)+l;return t.create(d,u,c,p,f,x)}})(_||(_={}));var b,M,C,k,A,T=[[-1,1],[-1,-1],[1,-1],[1,1]],P=(t,e,i)=>{let r=t.getCenter(),s=t.getHalfSize(),n=_.append(e,t.worldMatrix);0===s[0]&&0===s[1]?i.push(_.apply(r,n)):T.forEach(t=>{let e=[t[0]*s[0]+r[0],t[1]*s[1]+r[1]];i.push(_.apply(e,n))})},z=class{constructor(){this.matrix=_.identity(),this.min=[1/0,1/0],this.max=[-1/0,-1/0],this.vertices=[],this.edges=[]}setFromObjectSize(t,e=!1){t.updateWorldMatrix(),this.makeEmpty(),_.copy(t.worldMatrix,this.matrix);let i=_.invert(t.worldMatrix);this.expandByObjectSize(t,i,e)}expandByObjectSize(t,e,i=!1){let r=[],s=!0===t.isBaseGroup?t:void 0;!0===i&&void 0!==s?s.traverse(t=>{t.visible&&P(t,e,r)}):P(t,e,r),this.setFromPoints(r)}setFromSize(t,e,i){this.makeEmpty(),_.copy(i,this.matrix),this.expandBySize(t,e,i)}expandBySize(t,e,i){[_.apply([0,0],i),_.apply([0,e],i),_.apply([t,e],i),_.apply([t,0],i)].forEach(t=>this.expandByPoint(t))}getCenter(){let[t,e]=this.min,[i,r]=this.getHalfSize();return _.apply([t+i,e+r],this.matrix)}getSize(){return[this.max[0]-this.min[0],this.max[1]-this.min[1]]}getHalfSize(){return[.5*(this.max[0]-this.min[0]),.5*(this.max[1]-this.min[1])]}makeEmpty(){this.min=[1/0,1/0],this.max=[-1/0,-1/0]}setFromPoints(t){this.makeEmpty();for(let e of t)this.expandByPoint(e)}expandByPoint(t){this.min=[Math.min(this.min[0],t[0]),Math.min(this.min[1],t[1])],this.max=[Math.max(this.max[0],t[0]),Math.max(this.max[1],t[1])]}computeVertices(){let[t,e]=this.getHalfSize(),i=this.getCenter(),[r,s,n,a]=_.getAbcdef(this.matrix),h=_.create(r,s,n,a,i[0],i[1]);this.vertices=T.map(([i,r])=>_.apply([i*t,r*e],h))}computeEdges(){this.edges=[];for(let t=0,e=this.vertices.length;t<e;++t)this.edges.push([this.vertices[t],this.vertices[(t+1)%e]])}project(t,e){let i=this.matrix;return e&&(i=_.append(e.worldMatrix,i)),_.applyInverse(t,i)}intersects(t,e,i){return this.intersectsInLocalSpace(...this.project([t,e],i))}intersectsInLocalSpace(t,e){let{min:i,max:r}=this;return t>=i[0]&&t<=r[0]&&e>=i[1]&&e<=r[1]}containsPoint(t){let[e,i]=t,[r,s]=this.min,[n,a]=this.max;return e>=r&&e<=n&&i>=s&&i<=a}intersectsBBox2D(t){for(let e=0,i=this.edges.length;e<i;e++){let i=this.edges[e];for(let e=0,r=t.edges.length;e<r;e++)if(B(i,t.edges[e]))return!0}for(let e=0,i=t.vertices.length;e<i;e++){let i=t.vertices[e];if(this.containsPoint(i))return!0}return!1}ensureMinMax(){let t=this.min,e=this.max;this.min=[Math.min(t[0],e[0]),Math.min(t[1],e[1])],this.max=[Math.max(t[0],e[0]),Math.max(t[1],e[1])]}copy(t){this.min=[...t.min],this.max=[...t.max],_.copy(t.matrix,this.matrix),this.computeVertices(),this.computeEdges()}clone(){let t=new z;return t.copy(this),t}},R=class{constructor(e,i,r){this.uuid=e,this.data=i,this.isObject2D=!0,this.localMatrix=_.identity(),this.worldMatrix=_.identity(),this.ignoreCameraZoom=!1,this.visible=!0,this._singleBBox=new z,this._recursiveBBox=new z,this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0,this.stateSelection=null,this.prevState=null,this.currentState=null,this.reversibleToState=null,this.currentTransitionEvent=null,this.previousAction=null,this.name="",this.position=[0,0],this.scale=[1,1],this.rotation=0,this.shear=[0,0],this.emitter=t(),this.dpr=r.dpr??1,this.dataPatched=i}project(t,e){let i=this.worldMatrix;return e&&(i=_.append(e.worldMatrix,i)),_.applyInverse(t,i)}intersects(t,e,i,r=!1){return this.visible&&!this.data.raycastLock&&this.intersectsInLocalSpace(...this.project([t,e],i),r)}intersectsInLocalSpace(t,e,i=!1){let{min:r,max:s}=i?this.recursiveBBox:this.singleBBox;return t>=r[0]&&t<=s[0]&&e>=r[1]&&e<=s[1]}applyTransforms(t){t.setTransform(this.worldMatrix,this.ignoreCameraZoom)}get singleBBox(){return this.singleBBoxNeedsUpdate&&(this.singleBBoxNeedsUpdate=!1,this._singleBBox.setFromObjectSize(this,!1),this._singleBBox.computeVertices(),this._singleBBox.computeEdges()),this._singleBBox}get recursiveBBox(){return this.recursiveBBoxNeedsUpdate&&(this.recursiveBBoxNeedsUpdate=!1,this._recursiveBBox.setFromObjectSize(this,!0),this._recursiveBBox.computeVertices(),this._recursiveBBox.computeEdges()),this._recursiveBBox}updateLocalMatrix(){this.localMatrix=_.compose(this.position,this.scale,this.rotation*w,n.getPivot(this.dataPatched),this.shear)}updateWorldMatrix(t,e,i){let r=this.parent;e&&null!=r&&r.updateWorldMatrix(t,!0,!1),t&&this.updateLocalMatrix(),this.parent?this.worldMatrix=_.append(this.parent.worldMatrix,this.localMatrix):this.worldMatrix=_.copy(this.localMatrix),this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0}get pivot(){return n.getPivot(this.data)}getCenter(){return[0,0]}getHalfSize(){return[0,0]}get id(){return this.uuid}resetBBoxNeedsUpdateSelf(){this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0}resetBBoxNeedsUpdate(){this.resetBBoxNeedsUpdateSelf(),this.traverseAncestors(t=>{t.resetBBoxNeedsUpdateSelf()})}updateTransformState(t){let e=!1;void 0!==t.position&&(e=!0,this.position=t.position),void 0!==t.rotation&&(e=!0,this.rotation=t.rotation),void 0!==t.scale&&(e=!0,this.scale=t.scale),void 0!==t.shear&&(e=!0,this.shear=t.shear),e&&(this.updateWorldMatrix(!0,!1,!0),this.resetBBoxNeedsUpdate())}updateByOp(t,r,s){0===t.type&&void 0!==t.props.visible&&(this.visible=t.props.visible),this.data=r,this.data=r;let n=t,a=e(t.path,["states","*"]);if(null!==a){if(0===t.type){let[e]=a;if(this?.stateSelection===e){let e={...t.props};if(delete e.name,Object.values(t.props).some(t=>void 0===t)){let i=this.data;if(void 0!==i){let r=l.zoom(i,t.path.slice(2));if(r)for(let i in t.props)void 0===t.props[i]&&i in r&&(e[i]=r[i])}}n={...t,props:e,path:t.path.slice(2)}}}}else if(0===t.type){let e=this.stateSelection?this.data.states.data(this.stateSelection):void 0;if(void 0!==e){if(void 0!==t.props.name&&e.name){let{name:t,...i}=e;e=i}let i=l.removeOverridden(t.path,t.props,e);n={...t,props:i}}}this.updateByPatchedOpBase(n,i.patch(this.data,this.stateSelection?this.data.states.data(this.stateSelection):void 0),s)}changeSelectedState(t,e,r=!1){if(0!==this.data.states.length||r){for(let t of this.data.states)i.toOps(this.data,t.data).forEach(t=>{let i=o.replaceProps(t,this.data);this.dataPatched=this.data,this.updateByPatchedOp(i,this.data,e)});if(null!==t){let r=this.data.states.data(t);r&&(this.dataPatched=i.patch(this.data,r),i.toOps(this.data,r).forEach(t=>{this.updateByPatchedOp(t,this.dataPatched,e)}))}r&&this.updateTransformState(this.dataPatched),this.stateSelection=t}}updateState(t,e){void 0!==t.name&&(this.name=t.name),void 0!==t.visible&&(this.visible=t.visible),this.updateTransformState(t)}updateByPatchedOpBase(t,e,i){this.dataPatched=e,this.updateByPatchedOp(t,e,i)}updateByPatchedOp(t,e,i){0===t.path.length&&0===t.type&&this.updateState(t.props,i),this.requestRender()}traverseFrameAncestors(t){this.traverseAncestors(e=>{"frame2d"===e.data.type&&t(e)})}traverseAncestors(t){let e=this.parent;for(;e;)t(e),e=e.parent}requestRender(){this.traverseFrameAncestors(t=>{t.requestRender()})}clone(t){let e=new R(this.uuid,this.data,t);return e.parent=void 0,e}addEventListener(t,e){this.emitter.on(t,e)}removeEventListener(t,e){this.emitter.off(t,e)}dispatchEvent(t){this.emitter.emit(t.type,{...t,target:t.target??this})}traverseSortNextHelper(){let t=this.parent;if(t){let e=t.children;if(e){let i=e.indexOf(this)+1;return e[i]?e[i]:t.traverseSortNextHelper()}}}sortNext(){let t=this.children;return t&&t.length>0&&t[0]?t[0]:this.traverseSortNextHelper()}isDescendantOf(t){t instanceof R&&(t=t.uuid);let e=this;for(;e.parent;){if(e.parent.uuid===t)return!0;e=e.parent}return!1}},E=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.blurRadius=0,this.offset=[0,0],this.spread=0,this.update(e)}update(t){void 0!==t.color&&(this.color=t.color),void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.blurRadius&&(this.blurRadius=t.blurRadius),void 0!==t.offset&&(this.offset=t.offset),void 0!==t.spread&&(this.spread=t.spread)}},O=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.radius=0,this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.radius&&(this.radius=t.radius)}},H=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.color&&(this.color=t.color)}},L=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.thickness=0,this.mode="inside",this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.color&&(this.color=t.color),void 0!==t.thickness&&(this.thickness=t.thickness),void 0!==t.mode&&(this.mode=t.mode)}},F=class extends R{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.autoClose=!0,this.fill=new H(t+"-fill",e.fill,i),this.stroke=new L(t+"-stroke",e.stroke,i),this.dropShadow=new E(t+"-dropShadow",e.dropShadow,i),this.innerShadow=new E(t+"-innerShadow",e.innerShadow,i),this.backgroundBlur=new O(t+"-backgroundBlur",e.backgroundBlur,i),this.layerBlur=new O(t+"-layerBlur",e.layerBlur,i)}applyFillStroke(t){t.fillColor=this.fill.enabled?this.fill.color:a.transparent,t.strokeColor=this.stroke.enabled&&this.stroke.thickness>0?this.stroke.color:a.transparent,t.strokeMode=this.stroke.mode,t.lineWidth=this.stroke.thickness}applyFilters(t){this.layerBlur.enabled?t.layerBlur=5*this.layerBlur.radius:t.layerBlur=0,this.backgroundBlur.enabled?t.backgroundBlur=5*this.backgroundBlur.radius:t.backgroundBlur=0,this.dropShadow.enabled?(t.dropShadowBlur=5*this.dropShadow.blurRadius,t.dropShadowColor=this.dropShadow.color,t.dropShadowOffsetX=this.dropShadow.offset[0],t.dropShadowOffsetY=this.dropShadow.offset[1]):t.dropShadowColor=a.transparent,this.innerShadow.enabled?(t.innerShadowSpread=this.innerShadow.spread,t.innerShadowBlur=5*this.innerShadow.blurRadius,t.innerShadowColor=this.innerShadow.color,t.innerShadowOffsetX=this.innerShadow.offset[0],t.innerShadowOffsetY=this.innerShadow.offset[1]):t.innerShadowColor=a.transparent}innerDraw(t){}draw(t){!this.visible||(t.save(),this.applyTransforms(t),this.applyFilters(t),this.applyFillStroke(t),t.beginPath(),this.innerDraw(t),this.autoClose&&t.closePath(),this.fill.enabled&&t.fill(),this.stroke.enabled&&t.stroke(),t.restore())}updateByPatchedOp(t,i,r){super.updateByPatchedOp(t,i,r),0===t.type&&(e(t.path,["fill"])?this.fill.update(t.props):e(t.path,["stroke"])?this.stroke.update(t.props):e(t.path,["dropShadow"])?this.dropShadow.update(t.props):e(t.path,["innerShadow"])?this.innerShadow.update(t.props):e(t.path,["layerBlur"])?this.layerBlur.update(t.props):e(t.path,["backgroundBlur"])?this.backgroundBlur.update(t.props):this.resetBBoxNeedsUpdate())}updateState(t,e){super.updateState(t,e),void 0!==t.fill&&this.fill.update(t.fill),void 0!==t.stroke&&this.stroke.update(t.stroke),void 0!==t.dropShadow&&this.dropShadow.update(t.dropShadow),void 0!==t.innerShadow&&this.innerShadow.update(t.innerShadow),void 0!==t.layerBlur&&this.layerBlur.update(t.layerBlur),void 0!==t.backgroundBlur&&this.backgroundBlur.update(t.backgroundBlur)}clone(t){let e=new F(this.uuid,this.data,t);return e.parent=void 0,e}},U=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.width=0,this.height=0,this.updateState(e,i)}innerDraw(t){t.ellipse(.5*this.width,.5*this.height,.5*this.width,.5*this.height,0,0,2*Math.PI)}intersectsInLocalSpace(t,e){return function(t,e,i,r,s,n){let a=t-i,h=e-r;return a*a/(s*s)+h*h/(n*n)<=1}(t,e,.5*this.width,.5*this.height,.5*this.width,.5*this.height)}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t)}clone(t){let e=new U(this.uuid,this.data,t);return e.parent=void 0,e}},N=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.width=0,this.height=0,this.cornerRadius=[0,0,0,0],this.updateState(e,i)}innerDraw(t){t.rect(0,0,this.width,this.height,...this.cornerRadius)}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateCornerState(t){void 0!==t.cornerRadius&&(this.cornerRadius=t.cornerRadius)}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateCornerState(t)}clone(t){let e=new N(this.uuid,this.data,t);return e.parent=void 0,e}},j=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this._textHeight=0,this._textHeightDirty=!0,this.width=0,this.height=0,this.updateState(e,i)}get textHeight(){return this._textHeight}applyFillStroke(t){t.fillColor=this.fill.enabled?this.fill.color:a.transparent,t.strokeColor=this.stroke.enabled&&this.stroke.thickness>0?this.stroke.color:a.transparent,t.strokeMode="center",t.lineWidth=this.stroke.thickness}innerDraw(t){this._fontHolder?.arrayBuffer&&this._fontHolder.arrayBuffer.byteLength>1&&this.data.font&&t.registerFont(this._fontHolder.arrayBuffer,this.data.font);let e=this.data.textTransform,i=this.data.text.textValue.toString(),r=2===e?i.toUpperCase():3===e?i.toLowerCase():i,{height:s}=t.drawText(r,{x:0,y:0,width:this.width,height:this.height,fontSize:this.data.fontSize,lineHeight:this.data.lineHeight??1,letterSpacing:this.data.letterSpacing??0,horizontalAlign:this.data.horizontalAlign,verticalAlign:this.data.verticalAlign,font:this.data.font});this._textHeight=s}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateFontState(t,{shared:e}){void 0!==t.font&&(this._fontHolder=e.getFont(t.font),this._fontHolder&&!this._fontHolder.isLoaded&&this._fontHolder.loadingPromise.then(()=>{this.requestRender()}))}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateFontState(t,e)}clone(t){let e=new j(this.uuid,this.data,t);return e.parent=void 0,e}},I=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.curves=[],this.extremasBBox={min:[0,0],max:[0,0]},this.updateState(e,i)}computeExtremas(){0===this.curves.length&&this.computeCurves();let t=this.curves.map(t=>b.extremas(t)),e=[1/0,1/0],i=[-1/0,-1/0];for(let r=0,s=t.length;r<s;r++){let s=t[r];s[0][0]<e[0]&&(e[0]=s[0][0]),s[0][1]<e[1]&&(e[1]=s[0][1]),s[1][0]>i[0]&&(i[0]=s[1][0]),s[1][1]>i[1]&&(i[1]=s[1][1])}return this.extremasBBox.min=[e[0],e[1]],this.extremasBBox.max=[i[0],i[1]],this.extremasBBox}computeCurves(){this.curves=[];for(let t=1,e=this.data.points.length;t<e;t++){let e=this.data.points[t].data,i=this.data.points[t-1].data,r={start:i.position,cp1:i.controlNext.position,cp2:e.controlPrevious.position,end:e.position};this.curves.push(r)}let t=this.data.points[0].data,e=this.data.points[this.data.points.length-1].data;if(this.data.isClosed){let i={start:e.position,cp1:e.controlNext.position,cp2:t.controlPrevious.position,end:t.position};this.curves.push(i)}}getCenter(){let[t,e]=this.extremasBBox.min,[i,r]=this.getHalfSize();return[t+i,e+r]}getHalfSize(){let{min:t,max:e}=this.extremasBBox;return[.5*(e[0]-t[0]),.5*(e[1]-t[1])]}innerDraw(t){for(let e=0,i=this.data.points.length;e<i;e++){let i=this.data.points[e].data;if(0===e){let[e,r]=i.position;t.moveTo(e,r)}else{let r=this.data.points[e-1].data,[s,n]=r.controlNext.position,[a,h]=i.controlPrevious.position,[o,l]=i.position,d={start:r.position,cp1:r.controlNext.position,cp2:i.controlPrevious.position,end:i.position};b.derive(d),t.bezierCurveTo(s,n,a,h,o,l)}}let e=this.data.points[0].data,i=this.data.points[this.data.points.length-1].data;if(this.data.isClosed){let[r,s]=i.controlNext.position,[n,a]=e.controlPrevious.position,[h,o]=e.position;t.bezierCurveTo(r,s,n,a,h,o)}}updateState(t,e){super.updateState(t,e),this.computeExtremas()}clone(t){let e=new I(this.uuid,this.data,t);return e.parent=void 0,e}};(t=>{function e(t,e,i,r=!1){let s=t-2*e+i;if(0!==s){let r=-Math.sqrt(Math.abs(e*e-t*i)),n=-t+e;return[-(r+n)/s,-(-r+n)/s]}return e!==i&&0===s?[(2*e-i)/(2*(e-i))]:[]}t.derive=function(t){let e=t.start,i=t.cp1,r=t.cp2,s=t.end,n={start:[3*(i[0]-e[0]),3*(i[1]-e[1])],cp:[3*(r[0]-i[0]),3*(r[1]-i[1])],end:[3*(s[0]-r[0]),3*(s[1]-r[1])]};return t.derivative=n,n.derivative=M.derive(n),n},t.droot=function(i){let r=i.derivative??t.derive(i),s=r.start,n=r.cp,a=r.end;return[e(s[0],n[0],a[0]),e(s[1],n[1],a[1])]},t.extremas=function(e){let[i,r]=t.droot(e),s=[e.start[0],e.end[0]],n=[e.start[1],e.end[1]];for(let r of i)s.push(t.compute(e,Math.min(1,Math.max(0,r)))[0]);for(let i of r)n.push(t.compute(e,Math.min(1,Math.max(0,i)))[1]);return s.sort((t,e)=>t-e),n.sort((t,e)=>t-e),[[s[0],n[0]],[s[s.length-1],n[n.length-1]]]},t.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=1-e,r=i*i,s=e*e,n=r*i,a=r*e*3,h=i*s*3,o=e*s;return[n*t.start[0]+a*t.cp1[0]+h*t.cp2[0]+o*t.end[0],n*t.start[1]+a*t.cp1[1]+h*t.cp2[1]+o*t.end[1]]}})(b||(b={})),(C=M||(M={})).derive=function(t){let e=t.start,i=t.cp,r=t.end,s={start:[2*(i[0]-e[0]),2*(i[1]-e[1])],end:[2*(r[0]-i[0]),2*(r[1]-i[1])]};return s.derivative=k.derive(s),t.derivative=s,s},C.droot=function(t){let e=t.derivative??C.derive(t),i=e.start,r=e.end;return[i[0]!==r[0]?i[0]/(i[0]-r[0]):0,i[1]!==r[1]?i[1]/(i[1]-r[1]):0]},C.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=1-e,r=i*i,s=i*e*2,n=e*e;return[r*t.start[0]+s*t.cp[0]+n*t.end[0],r*t.start[1]+s*t.cp[1]+n*t.end[1]]},(A=k||(k={})).derive=function(t){let e=t.start,i=t.end,r=[i[0]-e[0],i[1]-e[1]];return t.derivative=r,t.derivative},A.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=t.start,r=t.end;return[i[0]+(r[0]-i[0])*e,i[1]+(r[1]-i[1])*e]};var D=class extends R{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.context=i,this.isBaseGroup=!0,this.children=[]}add(t){t.parent&&t.parent instanceof D&&t.parent.remove(t),this.children.push(t),t.parent=this}remove(t){let e=this.children.indexOf(t);e>=0&&(this.children.splice(e,1),t.parent=void 0)}traverse(t){let e=t(this);if(!0!==e)for(let i of this.children)i instanceof D?i.traverse(t):e=t(i)}intersectsChildrenHelper(t,e,i,r,s){for(let n of this.children)if(n.intersects(t,e,i,!1)&&(s.push(n),r)||n instanceof D&&n.intersectsChildrenHelper(t,e,i,r,s))return!0;return!1}intersectsChildren(t,e,i,r=!1,s=[],n=!1){return this.intersectsChildrenHelper(t,e,i,r,s),s}intersectsChildrenHelperReverse(t,e,i,r,s){for(let n of this.children)if(n instanceof D&&n.intersectsChildrenHelperReverse(t,e,i,r,s)||n.intersects(t,e,i,!1)&&(s.push(n),r))return!0;return!1}intersectsChildrenReverse(t,e,i,r=!1,s=[],n=!1){return this.intersectsChildrenHelperReverse(t,e,i,r,s),s}updateWorldMatrix(t,e,i){if(super.updateWorldMatrix(t,e,i),i&&this.children)for(let e of this.children)e.updateWorldMatrix(t,!1,!0)}find(t){let e;return this.traverse(i=>{i.uuid===t&&(e=i)}),e}innerDrawChildren(t){for(let e=this.children.length-1;e>=0;e--)this.children[e].draw(t)}resetBBoxNeedsUpdate(){super.resetBBoxNeedsUpdate(),this.traverse(t=>{t.resetBBoxNeedsUpdateSelf()})}clone(t){let e=new D(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},W=class extends D{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.updateState(e,i)}draw(t){!this.visible||(t.save(),this.applyTransforms(t),this.innerDrawChildren(t),t.restore())}clone(t){let e=new W(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},V=class extends D{constructor(t,e,i){super(t,e,i),this.uuid=t,this.width=0,this.height=0,this.clipped=!0,this.background=new N(t+"-background",r.defaultData,i),this.background.parent=this,this.updateState(e,i)}get fill(){return this.background.fill}get stroke(){return this.background.stroke}get backgroundBlur(){return this.background.backgroundBlur}get layerBlur(){return this.background.layerBlur}get dropShadow(){return this.background.dropShadow}get innerShadow(){return this.background.innerShadow}get cornerRadius(){return this.background.cornerRadius}set cornerRadius(t){this.background.cornerRadius=t}updateLocalMatrix(){super.updateLocalMatrix(),this.background?.updateLocalMatrix()}updateWorldMatrix(t,e,i){super.updateWorldMatrix(t,e,i),this.background?.updateWorldMatrix(t,e,i)}draw(t){if(!this.visible)return;t.save();let e=this.width,i=this.height;this.applyTransforms(t),this.background.width=e,this.background.height=i,this.background.draw(t),this.clipped&&t.clipRect(0,0,e,i,...this.cornerRadius),this.innerDrawChildren(t),t.restore()}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateCornerState(t){void 0!==t.cornerRadius&&(this.cornerRadius=t.cornerRadius)}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateCornerState(t),void 0!==t.fill&&this.fill.update(t.fill),void 0!==t.stroke&&this.stroke.update(t.stroke),void 0!==t.dropShadow&&this.dropShadow.update(t.dropShadow),void 0!==t.innerShadow&&this.innerShadow.update(t.innerShadow),void 0!==t.layerBlur&&this.layerBlur.update(t.layerBlur),void 0!==t.backgroundBlur&&this.backgroundBlur.update(t.backgroundBlur),void 0!==t.clipped&&(this.clipped=t.clipped)}requestRender(){super.requestRender(),this.dispatchEvent({type:"render"})}dispose(){this.removeEventListener("render")}updateByPatchedOp(t,i,r){super.updateByPatchedOp(t,i,r),0===t.type&&(e(t.path,["fill"])?this.fill.update(t.props):e(t.path,["stroke"])?this.stroke.update(t.props):e(t.path,["dropShadow"])?this.dropShadow.update(t.props):e(t.path,["innerShadow"])?this.innerShadow.update(t.props):e(t.path,["layerBlur"])?this.layerBlur.update(t.props):e(t.path,["backgroundBlur"])?this.backgroundBlur.update(t.props):this.resetBBoxNeedsUpdate())}clone(t){let e=new V(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},X=u(g(),1),q=new Map,Y=null,$=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this._pathBBox=new DOMRect,this.path="",this.updateState(e,i),this.autoClose=!1,this.computeSVGBBox()}computeSVGBBox(){let t=this.path;G(this.path)&&(console.warn("Invalid SVG path",this.uuid),t=""),this._pathBBox=function(t){let e=q.get(t);if(void 0!==e)return e;if(null===Y||!Y.isConnected){let t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("aria-hidden","true"),t.style.cssText="position:absolute;width:0;height:0;overflow:hidden;visibility:hidden;pointer-events:none",Y=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(Y),document.body.appendChild(t)}Y.setAttribute("d",t);let i=Y.getBBox();return q.size>=4096&&q.clear(),q.set(t,i),i}(t)}innerDraw(t){t.path(this.path)}intersectsInLocalSpace(t,e){return t>=this._pathBBox.x&&t<=this._pathBBox.x+this._pathBBox.width&&e>=this._pathBBox.y&&e<=this._pathBBox.y+this._pathBBox.height}getCenter(){return[(this._pathBBox.x+this._pathBBox.width)/2,(this._pathBBox.y+this._pathBBox.height)/2]}getHalfSize(){return[(this._pathBBox.x+this._pathBBox.width)/2,(this._pathBBox.y+this._pathBBox.height)/2]}updateState(t,e){super.updateState(t,e),void 0!==t.path&&(this.path=t.path,this.computeSVGBBox())}clone(t){let e=new $(this.uuid,this.data,t);return e.parent=void 0,e}};function G(t){return/NaN/.test(t)}function Q(t,e=1,i=1){if(e<=0||i<=0)return t;if(G(t))return console.warn("Cannot scale invalid path",t),J([]);if(1===e&&1===i)return t;try{return J((0,X.parseSVG)(t).map(t=>{let r={...t};return"x"in r&&(r.x=r.x*e),"y"in r&&(r.y=r.y*i),"x1"in r&&(r.x1=r.x1*e),"x2"in r&&(r.x2=r.x2*e),"y1"in r&&(r.y1=r.y1*i),"y2"in r&&(r.y2=r.y2*i),"rx"in r&&(r.rx=r.rx*e),"ry"in r&&(r.ry=r.ry*i),r}))}catch(t){return console.warn("Error parsing SVG path",t),J([])}}function J(t){let e,i=["rx","ry","xAxisRotation","largeArc","sweep","x1","y1","x2","y2","x","y"];return t.map(t=>{let r=[];i.forEach(e=>{if(e in t){let i=1*t[e];r.length&&i>=0&&r.push(","),r.push(i)}});let s=(e===t.code?r[0]<0?"":",":t.code)+r.join("");return e=t.code,s}).join("")}var Z=class{constructor(t,e,i){this.uuid=t,this.data=e,this.group=new W(Z.GROUP_ID,{...s.defaultData},i),this.createChildrenObjects(e.objects,this.group,i)}createObject(t,e,i,r,s,n){let a=function(t,e,i){switch(e.type){case"ellipse2d":return new U(t,e,i);case"rectangle2d":return new N(t,e,i);case"text2d":return new j(t,e,i);case"vector2d":return new I(t,e,i);case"path2d":return new $(t,e,i);case"frame2d":return new V(t,e,i);default:return new W(t,e,i)}}(t,e,n);a&&(r.add(a),r.children.splice(s,0,r.children.pop()),a.updateWorldMatrix(),i.length>0&&(a instanceof W||a instanceof V)&&this.createChildrenObjects(i,a,n))}createChildrenObjects(t,e,i){let r=0;for(let s of t)this.createObject(s.id,s.data,s.children,e,r,i),r+=1}draw(t){this.group.draw(t)}updateEntityByOp(t,e,i,r){let s=this.find(t);if(s)try{s.updateByOp(e,i,{shared:r})}catch(t){console.error(t)}}updateTreeByOp(t,e){if(0===t.path.length&&7===t.type){let i=null===t.parent?this.group:this.find(t.parent);void 0!==i&&i instanceof D&&(this.createObject(t.id,t.data,t.children,i,t.localIndex,e),i.requestRender())}else if(0===t.path.length&&8===t.type){let e=this.find(t.id);if(void 0!==e&&void 0!==e.parent&&e.parent instanceof D){let t=e.parent;e.resetBBoxNeedsUpdate(),t?.remove(e),t?.requestRender()}}else if(0===t.path.length&&9===t.type){let e=this.find(t.id);if(void 0!==e){let i=e.parent,r=null===t.parent?this:this.find(t.parent);if(r instanceof D||r===this){r.add(e);let s=t.localIndex;r.children.splice(s,0,r.children.pop()),e.updateWorldMatrix(!0,!1,!0),i?.requestRender(),e.requestRender()}e.resetBBoxNeedsUpdate()}}}add(t){this.group.add(t)}remove(t){this.group.remove(t)}traverse(t){this.group.traverse(e=>{e!==this.group&&t(e)})}intersectsChildren(t,e,i,r=!1,s=[]){return this.group.intersectsChildren(t,e,i,r,s,!0)}intersectsChildrenReverse(t,e,i,r=!1,s=[]){return this.group.intersectsChildrenReverse(t,e,i,r,s,!0)}find(t){return this.group.find(t)}get children(){return this.group.children}project(t,e){return this.group.project(t,e)}getWithSortKey(t){let e=this.find(t);if(void 0===e)return;let i=[],r=e;for(;r!==this.group;){let t=r;r=r.parent;let e=r.children.indexOf(t);i.splice(0,0,e)}return{entity:e,sortKey:i}}getAllSorted(t){let e=[];for(let i of t){let t=this.getWithSortKey(i.id);void 0!==t&&e.push(t)}return e.sort((t,e)=>h(t.sortKey,e.sortKey)),e.map(t=>t.entity)}},K=Z;K.GROUP_ID="scene2d";var tt=u(g(),1);function et(t,e,i,r,s,n,a,h,o,l){if(e===o&&i===l)return;if(r=Math.abs(r),s=Math.abs(s),0===r||0===s)return void t.push({LineTo:{x:o,y:l}});let d=n*Math.PI/180,u=Math.cos(d),c=Math.sin(d),p=(e-o)/2,f=(i-l)/2,x=u*p+c*f,g=-c*p+u*f,m=x*x/(r*r)+g*g/(s*s);if(m>1){let t=Math.sqrt(m);r*=t,s*=t}let y=r*r,v=s*s,w=y*v-y*g*g-v*x*x,_=y*g*g+v*x*x,S=(a!==h?1:-1)*Math.sqrt(Math.max(0,w/_)),B=S*(r*g)/s,b=S*(-s*x)/r,M=u*B-c*b+(e+o)/2,C=c*B+u*b+(i+l)/2,k=Math.atan2((g-b)/s,(x-B)/r),A=Math.atan2((-g-b)/s,(-x-B)/r)-k;!h&&A>0?A-=2*Math.PI:h&&A<0&&(A+=2*Math.PI);let T=Math.max(1,Math.ceil(Math.abs(A)/(Math.PI/2))),P=A/T,z=4/3*Math.tan(P/4),R=k,E=e,O=i;for(let e=0;e<T;e++){let e=R+P,i=Math.cos(R),n=Math.sin(R),a=Math.cos(e),h=Math.sin(e),o=M+r*a*u-s*h*c,l=C+r*a*c+s*h*u,d=-r*n*u-s*i*c,p=-r*n*c+s*i*u,f=-r*h*u-s*a*c,x=-r*h*c+s*a*u;t.push({CurveTo:[{x:E+z*d,y:O+z*p},{x:o-z*f,y:l-z*x},{x:o,y:l}]}),R=e,E=o,O=l}}var it=.5522847498307936,rt=3408/2816,st=1536/2816,nt=!1;function at(){nt||(nt=!0,console.warn("[HanaRenderer] clipRect: precise clipping of rotated/complex content is not supported by the Hana UI overlay yet; drawing unclipped. (Axis-aligned rectangles are clipped geometrically.)"))}var ht=class{constructor(t,e=1){this.canvas=t,this._dpr=e,this._width=0,this._height=0,this._isSizeDirty=!1,this._crashed=!1,this._shapes=[],this._lastPushedJSON="",this._ctm=_.identity(),this._stack=[],this._clips=[],this._pathEls=[],this._simpleShape=null,this._pathPrimitives=0,this._fillColor=a.transparent,this._strokeColor=a.transparent,this._lineWidth=1,this._strokeMode="inside",this._layerBlur=0,this._backgroundBlur=0,this._dropShadowBlur=0,this._dropShadowOffsetX=0,this._dropShadowOffsetY=0,this._dropShadowColor=a.transparent,this._innerShadowBlur=0,this._innerShadowOffsetX=0,this._innerShadowOffsetY=0,this._innerShadowSpread=0,this._innerShadowColor=a.transparent,this._fonts=new Map,this._fontsFlushed=new Set,this._fontXPerEm=new Map,this._measureCache=new Map;try{let i=t.getBoundingClientRect();t.width=i.width*e,t.height=i.height*e}catch{console.log(t.width,e)}}get dpr(){return this._dpr}set dpr(t){this._dpr=t,this._isSizeDirty=!0}get width(){return this._width}get height(){return this._height}async init(){if(!this._engine&&!this._crashed){try{this._context=await m(),this._engine=await this._context.createEngine(this.canvas)}catch(t){return this._crashed=!0,void console.error("[HanaRenderer] Failed to load the Hana UI engine; UI scenes will not render.",t)}if(this._width>0&&this._height>0)this._syncViewport();else{let t=this.canvas.getBoundingClientRect();t.width>0&&t.height>0&&(this._width=t.width,this._height=t.height,this._syncViewport())}this._flushFonts(),this.uiFontReady=this._watchUiFont()}}_watchUiFont(){return new Promise(t=>{let e=this._engine;if(!e||"function"!=typeof e.scene.isUiFontLoaded)return void t();let i=()=>{let t=!1;return this._guard(()=>{t=e.scene.isUiFontLoaded()}),t};if(i())return void t();let r=Date.now(),s=setInterval(()=>{this._crashed||Date.now()-r>3e5?clearInterval(s):i()&&(clearInterval(s),t())},150)})}_syncViewport(){let t=this._engine;if(!t||this._crashed)return;let e=this._width,i=this._height;this.canvas.style.width=e+"px",this.canvas.style.height=i+"px",this.canvas.width=Math.max(1,Math.ceil(e*this._dpr)),this.canvas.height=Math.max(1,Math.ceil(i*this._dpr)),this._guard(()=>{t.resize([e,i],this._dpr),t.scene.updateCamera({position:[e/2,i/2],zoom:1})})}setSize(t,e){!this._isSizeDirty&&t===this._width&&e===this._height||(this._isSizeDirty=!1,this._width=t,this._height=e,this._engine?this._syncViewport():(this.canvas.style.width=t+"px",this.canvas.style.height=e+"px",this.canvas.width=Math.max(1,Math.ceil(t*this._dpr)),this.canvas.height=Math.max(1,Math.ceil(e*this._dpr))))}_guard(t){if(!this._crashed)try{t()}catch(t){this._crashed=!0,console.error("[HanaRenderer] Hana engine call failed; disabling this renderer instance.",t)}}async loadFont(t,e){try{let i=await fetch(t);if(!i.ok)return void console.error(`[HanaRenderer] loadFont: ${t} returned HTTP ${i.status}; skipping "${e}"`);let r=await i.arrayBuffer();if(0===r.byteLength)return void console.error(`[HanaRenderer] loadFont: ${t} was empty; skipping "${e}"`);this.registerFont(r,e)}catch(i){console.error(`[HanaRenderer] loadFont failed for "${e}" (${t}):`,i)}}registerFont(t,e){if(this._fonts.has(e))return;this._fonts.set(e,t);let i=function(t){try{let e=new DataView(t),i=e.getUint32(0);if(65536!==i&&1330926671!==i&&1953658213!==i)return;let r=e.getUint16(4),s=-1,n=-1;for(let t=0;t<r;t++){let i=12+16*t,r=e.getUint32(i);1751474532===r&&(s=e.getUint32(i+8)),1330851634===r&&(n=e.getUint32(i+8))}if(s<0||n<0)return;let a=e.getUint16(s+18),h=e.getUint16(n);if(0===a||h<2)return;let o=e.getInt16(n+86);return o>0?o/a:void 0}catch{return}}(t);void 0!==i&&this._fontXPerEm.set(e,i),this._flushFonts()}_flushFonts(){let t=this._engine;if(t)for(let[e,i]of this._fonts)this._fontsFlushed.has(e)||(this._fontsFlushed.add(e),this._guard(()=>{t.scene.addLocalFont(e,new Uint8Array(i))}))}set strokeColor(t){this._strokeColor=t}set fillColor(t){this._fillColor=t}set lineWidth(t){this._lineWidth=t}set strokeMode(t){this._strokeMode=t}set dropShadowBlur(t){this._dropShadowBlur=t}set dropShadowColor(t){this._dropShadowColor=t}set dropShadowOffsetX(t){this._dropShadowOffsetX=t}set dropShadowOffsetY(t){this._dropShadowOffsetY=t}set innerShadowBlur(t){this._innerShadowBlur=t}set innerShadowColor(t){this._innerShadowColor=t}set innerShadowOffsetX(t){this._innerShadowOffsetX=t}set innerShadowOffsetY(t){this._innerShadowOffsetY=t}set innerShadowSpread(t){this._innerShadowSpread=t}set layerBlur(t){this._layerBlur=t}set backgroundBlur(t){this._backgroundBlur=t}save(){this._stack.push({ctm:_.copy(this._ctm),clipLen:this._clips.length})}restore(){let t=this._stack.pop();!t||(this._ctm=t.ctm,this._clips.length=t.clipLen)}setTransform(t,e=!1){let i=_.identity();if(this.camera?.enabled&&(i=_.append(i,this.camera.worldMatrix),e)){let t=_.getScale(this.camera.worldMatrix);i=_.scale(i,1/t[0],1/t[1])}this._ctm=_.append(i,t)}transform(t){this._ctm=_.append(this._ctm,t)}beginPath(){this._pathEls=[],this._simpleShape=null,this._pathPrimitives=0}closePath(){0!==this._pathEls.length&&"ClosePath"!==this._pathEls[this._pathEls.length-1]&&this._pathEls.push("ClosePath")}_startFreeform(){this._simpleShape=null,this._pathPrimitives++}moveTo(t,e){this._startFreeform(),this._pathEls.push({MoveTo:{x:t,y:e}})}lineTo(t,e){this._startFreeform(),this._pathEls.push({LineTo:{x:t,y:e}})}bezierCurveTo(t,e,i,r,s,n){this._startFreeform(),this._pathEls.push({CurveTo:[{x:t,y:e},{x:i,y:r},{x:s,y:n}]})}quadraticCurveTo(t,e,i,r){this._startFreeform(),this._pathEls.push({QuadTo:[{x:t,y:e},{x:i,y:r}]})}path(t){this._startFreeform(),this._pathEls.push(...function(t){let e,i=[];try{e=(0,tt.makeAbsolute)((0,tt.parseSVG)(t))}catch(t){return console.error("[HanaRenderer] Failed to parse SVG path:",t),i}let r=0,s=0,n=0,a=0,h=null,o=null;for(let t of e){let e=null,l=null;switch(t.code){case"M":r=n=t.x,s=a=t.y,i.push({MoveTo:{x:r,y:s}});break;case"L":r=t.x,s=t.y,i.push({LineTo:{x:r,y:s}});break;case"H":r=t.x,i.push({LineTo:{x:r,y:s}});break;case"V":s=t.y,i.push({LineTo:{x:r,y:s}});break;case"C":{let n={x:t.x1,y:t.y1},a={x:t.x2,y:t.y2};r=t.x,s=t.y,i.push({CurveTo:[n,a,{x:r,y:s}]}),e=a;break}case"S":{let n=h?{x:2*r-h.x,y:2*s-h.y}:{x:r,y:s},a={x:t.x2,y:t.y2};r=t.x,s=t.y,i.push({CurveTo:[n,a,{x:r,y:s}]}),e=a;break}case"Q":{let e={x:t.x1,y:t.y1};r=t.x,s=t.y,i.push({QuadTo:[e,{x:r,y:s}]}),l=e;break}case"T":{let e=o?{x:2*r-o.x,y:2*s-o.y}:{x:r,y:s};r=t.x,s=t.y,i.push({QuadTo:[e,{x:r,y:s}]}),l=e;break}case"A":{let e=r,n=s;r=t.x,s=t.y,et(i,e,n,t.rx,t.ry,t.xAxisRotation,t.largeArc,t.sweep,r,s);break}case"Z":r=n,s=a,i.push("ClosePath")}h=e,o=l}return i}(t))}rect(t,e,i,r,s=0,n=0,a=0,h=0){if(!ct([t,e,i,r]))return;let o={x:t,y:e,w:i,h:r,radii:[s,n,a,h]};this._pathPrimitives++,this._simpleShape=1===this._pathPrimitives&&0===this._pathEls.length?{kind:"rect",rect:o,smoothing:0}:null,gt(this._pathEls,o)}ellipse(t,e,i,r,s,n,a,h){if(ct([t,e,i,r])){if(i<0||r<0)throw Error("radii cannot be negative");this._pathPrimitives++,this._simpleShape=1===this._pathPrimitives&&0===this._pathEls.length?{kind:"ellipse",cx:t,cy:e,rx:i,ry:r}:null,function(t,e,i,r,s){let n=r*it,a=s*it;t.push({MoveTo:{x:e+r,y:i}},{CurveTo:[{x:e+r,y:i+a},{x:e+n,y:i+s},{x:e,y:i+s}]},{CurveTo:[{x:e-n,y:i+s},{x:e-r,y:i+a},{x:e-r,y:i}]},{CurveTo:[{x:e-r,y:i-a},{x:e-n,y:i-s},{x:e,y:i-s}]},{CurveTo:[{x:e+n,y:i-s},{x:e+r,y:i-a},{x:e+r,y:i}]},"ClosePath")}(this._pathEls,t,e,i,r)}}clipRect(t,e,i,r,s=0,n=0,a=0,h=0){let o=_.invert(this._ctm);!o||this._clips.push({m:_.copy(this._ctm),inv:o,rect:{x:t,y:e,w:i,h:r,radii:[s,n,a,h]}})}fill(){this._emit(!0)}stroke(){this._strokeColor.a<=0||this._lineWidth<=0||this._emit(!1)}_emit(t){let e=this._effectChain(t);if(t&&this._fillColor.a<=0&&!e)return;let i=this._classifyShape();if(!i)return;let r=this._applyClips(i);if("skip"===r)return;if(!t&&r!==i){let t=ft(i);if(t)return void this._emitClippedRectStroke(t,e)}i=r;let s={shape:i,color:t?ut(this._fillColor):[0,0,0,0],transform:_.getAbcdef(this._ctm)};t||(s.stroke=this._strokeDesc()),e&&(s.effect_chain=e),this._shapes.push(s)}_emitClippedRectStroke(t,e){let i=this._lineWidth,r="outside"===this._strokeMode?i:"center"===this._strokeMode?i/2:0,s=i-r,n=Math.min(t.w,t.h)/2,a=t.radii.map(t=>Math.max(0,Math.min(t,n))),h={x:t.x-r,y:t.y-r,w:t.w+2*r,h:t.h+2*r,radii:a.map(t=>t>0?t+r:0)},o=t.w-2*s,l=t.h-2*s,d=o>0&&l>0?{x:t.x+s,y:t.y+s,w:o,h:l,radii:a.map(t=>Math.max(0,t-s))}:null,u=this._applyClips(pt(h,0));if("skip"===u)return;let c=ft(u)??h,p=null;if(d){let t=this._applyClips(pt(d,0));p="skip"===t?null:ft(t)??d}let f=[];gt(f,c),p&&function(t,e){let{x:i,y:r,w:s,h:n}=e,a=Math.min(s,n)/2,[h,o,l,d]=e.radii.map(t=>Math.max(0,Math.min(t,a)));if(0===h&&0===o&&0===l&&0===d)return void t.push({MoveTo:{x:i,y:r}},{LineTo:{x:i,y:r+n}},{LineTo:{x:i+s,y:r+n}},{LineTo:{x:i+s,y:r}},"ClosePath");let u=1-it;t.push({MoveTo:{x:i+h,y:r}}),h>0&&t.push({CurveTo:[{x:i+h*u,y:r},{x:i,y:r+h*u},{x:i,y:r+h}]}),t.push({LineTo:{x:i,y:r+n-d}}),d>0&&t.push({CurveTo:[{x:i,y:r+n-d*u},{x:i+d*u,y:r+n},{x:i+d,y:r+n}]}),t.push({LineTo:{x:i+s-l,y:r+n}}),l>0&&t.push({CurveTo:[{x:i+s-l*u,y:r+n},{x:i+s,y:r+n-l*u},{x:i+s,y:r+n-l}]}),t.push({LineTo:{x:i+s,y:r+o}}),o>0&&t.push({CurveTo:[{x:i+s,y:r+o*u},{x:i+s-o*u,y:r},{x:i+s-o,y:r}]}),t.push("ClosePath")}(f,p);let x={shape:{Custom:f},color:ut(this._strokeColor),transform:_.getAbcdef(this._ctm)};e&&(x.effect_chain=e),this._shapes.push(x)}_classifyShape(){let t=this._simpleShape;return t?"rect"===t.kind?pt(t.rect,t.smoothing):{Ellipse:{center_x:t.cx,center_y:t.cy,rx:t.rx,ry:t.ry}}:0===this._pathEls.length?null:{Custom:this._pathEls.slice()}}_strokeDesc(){return{width:this._lineWidth,line_join:"Miter",color:ut(this._strokeColor),align:ot[this._strokeMode],cap:"Butt"}}_effectChain(t){let e=this.camera?.scale??1,i=[];if(t&&this._dropShadowColor.a>0&&i.push({DropShadow:{position:[this._dropShadowOffsetX*e,this._dropShadowOffsetY*e],blur:{Uniform:{size:2*this._dropShadowBlur*e}},spread:0,color:ut(this._dropShadowColor)}}),t&&this._backgroundBlur>0){let[t,e]=_.getScale(this._ctm),r=(t+e)/2;i.push({BackgroundBlur:{blur:{Uniform:{size:2*this._backgroundBlur*r}}}})}if(this._layerBlur>0&&i.push({LayerBlur:{blur:{Uniform:{size:2*this._layerBlur*e}}}}),t&&this._innerShadowColor.a>0){let[t,r,s,n]=_.getAbcdef(this._ctm),a=this._innerShadowOffsetX,h=this._innerShadowOffsetY;i.push({InnerShadow:{position:[t*a+s*h,r*a+n*h],blur:{Uniform:{size:2*this._innerShadowBlur*e}},spread:this._innerShadowSpread*e,color:ut(this._innerShadowColor)}})}return i.length>0?i:void 0}_applyClips(t){if(0===this._clips.length)return t;let e=t;for(let t of this._clips){let i=_.append(t.inv,this._ctm),[r,s,n,a,h,o]=_.getAbcdef(i),l=Math.abs(s)<=1e-6*(Math.abs(r)+Math.abs(a))&&Math.abs(n)<=1e-6*(Math.abs(r)+Math.abs(a)),d=xt(e);if(!d)return e;if(!l){at();continue}let u=r*d.minX+h,c=r*d.maxX+h,p=a*d.minY+o,f=a*d.maxY+o,x=Math.min(u,c),g=Math.max(u,c),m=Math.min(p,f),y=Math.max(p,f),v=t.rect,w=Math.max(x,v.x),S=Math.max(m,v.y),B=Math.min(g,v.x+v.w),b=Math.min(y,v.y+v.h);if(w>=B||S>=b)return"skip";if(w===x&&S===m&&B===g&&b===y)continue;let M=ft(e);if(!M||0===r||0===a){at();continue}let C=(w-h)/r,k=(B-h)/r,A=(S-o)/a,T=(b-o)/a,P=Math.min(C,k),z=Math.min(A,T),R=Math.abs(k-C),E=Math.abs(T-A),[O,H,L,F]=M.radii,U=P!==M.x,N=z!==M.y,j=P+R!==M.x+M.w,I=z+E!==M.y+M.h,D=Math.min(R,E)/2;e=pt({x:P,y:z,w:R,h:E,radii:[U||N?0:Math.min(O,D),j||N?0:Math.min(H,D),j||I?0:Math.min(L,D),U||I?0:Math.min(F,D)]},0)}return e}drawText(t,e){let i=this._fontXPerEm.get(e.font),r=i?i/st:1,s={TextSimple:{text:t,font_size:e.fontSize*rt*r,size:[e.width,e.height],horizontal_align:lt[e.horizontalAlign]??"Left",vertical_align:dt[e.verticalAlign]??"Top"}},n=this._effectChain(!0),a=this._fillColor.a>0,h=this._strokeColor.a>0&&this._lineWidth>0;if(a||h||n){let t={shape:s,color:a?ut(this._fillColor):[0,0,0,0],transform:_.getAbcdef(_.append(this._ctm,_.translate(_.identity(),e.x,e.y)))};h&&(t.stroke=this._strokeDesc()),n&&(t.effect_chain=n),this._shapes.push(t)}return{height:this._measureTextHeight(t,e)}}_measureTextHeight(t,e){let i=`${e.font}|${e.fontSize}|${e.lineHeight}|${e.letterSpacing}|${e.width}|${t}`,r=this._measureCache.get(i);if(void 0!==r)return r;let s=0,n=this._engine;if(n&&!this._crashed&&this._fontsFlushed.has(e.font))try{let[,i]=n.scene.measureTextNaturalSize({size:[e.width,e.height],text:t,fontSize:e.fontSize,horizontalAlign:lt[e.horizontalAlign]??"Left",verticalAlign:dt[e.verticalAlign]??"Top",lineHeight:e.lineHeight,letterSpacing:e.letterSpacing,textTransform:"None",font:e.font,version:0,autoSize:"None",truncate:"None"});s=i}catch{}if(!(s>0)){let i=.55*e.fontSize+Math.max(0,e.letterSpacing),r=Math.max(1,Math.floor(e.width/i)),n=0;for(let e of t.split("\n"))n+=Math.max(1,Math.ceil(e.length/r));s=n*e.fontSize*e.lineHeight}return this._measureCache.size>512&&this._measureCache.clear(),this._measureCache.set(i,s),s}clear(){this._shapes=[],this._ctm=_.identity(),this._stack.length=0,this._clips.length=0}render(){let t=this._engine;if(!t||this._crashed)return;let e=JSON.stringify(this._shapes);e!==this._lastPushedJSON&&(this._guard(()=>t.scene.updateUiShapes(this._shapes)),this._lastPushedJSON=e),this._guard(()=>t.onFrame())}},ot={inside:"Inside",outside:"Outside",center:"Center"},lt={1:"Left",2:"Right",3:"Center",4:"Justify"},dt={1:"Top",2:"Center",3:"Bottom"};function ut({r:t,g:e,b:i,a:r}){return[t,e,i,r]}function ct(t){for(let e=0;e<t.length;e++)if(void 0!==t[e]&&!Number.isFinite(t[e]))return!1;return!0}function pt(t,e){let[i,r,s,n]=t.radii;return 0===i&&0===r&&0===s&&0===n?{Rectangle:{x:t.x,y:t.y,width:t.w,height:t.h}}:{RoundedRectangle:{x:t.x,y:t.y,width:t.w,height:t.h,radius:[i,r,s,n],corner_smoothing:e}}}function ft(t){if("Rectangle"in t){let e=t.Rectangle;return{x:e.x,y:e.y,w:e.width,h:e.height,radii:[0,0,0,0]}}if("RoundedRectangle"in t){let e=t.RoundedRectangle;return{x:e.x,y:e.y,w:e.width,h:e.height,radii:[e.radius[0],e.radius[1],e.radius[2],e.radius[3]]}}return null}function xt(t){let e=ft(t);if(e)return{minX:e.x,minY:e.y,maxX:e.x+e.w,maxY:e.y+e.h};if("Ellipse"in t){let e=t.Ellipse;return{minX:e.center_x-e.rx,minY:e.center_y-e.ry,maxX:e.center_x+e.rx,maxY:e.center_y+e.ry}}if("TextSimple"in t){let e=t.TextSimple;return{minX:0,minY:0,maxX:e.size[0],maxY:e.size[1]}}if("Custom"in t){let e=1/0,i=1/0,r=-1/0,s=-1/0,n=t=>{t.x<e&&(e=t.x),t.y<i&&(i=t.y),t.x>r&&(r=t.x),t.y>s&&(s=t.y)};for(let e of t.Custom)"ClosePath"!==e&&("MoveTo"in e?n(e.MoveTo):"LineTo"in e?n(e.LineTo):"QuadTo"in e?e.QuadTo.forEach(n):"CurveTo"in e&&e.CurveTo.forEach(n));return e===1/0?null:{minX:e,minY:i,maxX:r,maxY:s}}return null}function gt(t,e){let{x:i,y:r,w:s,h:n}=e,a=Math.min(s,n)/2,[h,o,l,d]=e.radii.map(t=>Math.max(0,Math.min(t,a)));if(0===h&&0===o&&0===l&&0===d)return void t.push({MoveTo:{x:i,y:r}},{LineTo:{x:i+s,y:r}},{LineTo:{x:i+s,y:r+n}},{LineTo:{x:i,y:r+n}},"ClosePath");let u=1-it;t.push({MoveTo:{x:i+h,y:r}}),t.push({LineTo:{x:i+s-o,y:r}}),o>0&&t.push({CurveTo:[{x:i+s-o*u,y:r},{x:i+s,y:r+o*u},{x:i+s,y:r+o}]}),t.push({LineTo:{x:i+s,y:r+n-l}}),l>0&&t.push({CurveTo:[{x:i+s,y:r+n-l*u},{x:i+s-l*u,y:r+n},{x:i+s-l,y:r+n}]}),t.push({LineTo:{x:i+d,y:r+n}}),d>0&&t.push({CurveTo:[{x:i+d*u,y:r+n},{x:i,y:r+n-d*u},{x:i,y:r+n-d}]}),t.push({LineTo:{x:i,y:r+h}}),h>0&&t.push({CurveTo:[{x:i,y:r+h*u},{x:i+h*u,y:r},{x:i+h,y:r}]}),t.push("ClosePath")}function mt({constraints:t,newParentWidth:e,newParentHeight:i,initialParentWidth:r,initialParentHeight:s,objectInitialWidth:n,objectInitialHeight:a,objectInitialPosition:h}){let{horizontalConstraint:o,verticalConstraint:l}=t,d=e-r,u=i-s,c=n,p=a,f=h[0],x=h[1];if(0!==o)if(1===o)f+=d;else if(3===o)f+=d/2;else if(2===o)c=Math.max(1,c+d);else if(4===o){let t=e/r;c*=t,f*=t}if(0!==l)if(1===l)x+=u;else if(3===l)x+=u/2;else if(2===l)p=Math.max(1,p+u);else if(4===l){let t=i/s;p*=t,x*=t}return{width:c,height:p,position:[f,x]}}u(g(),1);export{_ as a,y as b,v as c,ht as d,F as e,U as f,N as g,j as h,W as i,V as j,$ as k,Q as l,K as m,mt as n};
1
+ import{a as t}from"./runtime-chunk-NTUTXO7Q.js";import{b as e}from"./runtime-chunk-QYZPTNBH.js";import{b as i,c as r,d as s,e as n}from"./runtime-chunk-DHZVCYH4.js";import{D as a,b as h,j as o,n as l}from"./runtime-chunk-AIWIOLR6.js";import{a as d,b as u}from"./runtime-chunk-ML3Z74BL.js";var c,p,f,x=d((t,e)=>{function i(t,e,r,s){this.message=t,this.expected=e,this.found=r,this.location=s,this.name="SyntaxError","function"==typeof Error.captureStackTrace&&Error.captureStackTrace(this,i)}!function(t,e){function i(){this.constructor=t}i.prototype=e.prototype,t.prototype=new i}(i,Error),i.buildMessage=function(t,e){var i,r={literal:function(t){return'"'+n(t.text)+'"'},class:function(t){var e,i="";for(e=0;e<t.parts.length;e++)i+=t.parts[e]instanceof Array?a(t.parts[e][0])+"-"+a(t.parts[e][1]):a(t.parts[e]);return"["+(t.inverted?"^":"")+i+"]"},any:function(t){return"any character"},end:function(t){return"end of input"},other:function(t){return t.description}};function s(t){return t.charCodeAt(0).toString(16).toUpperCase()}function n(t){return t.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(t){return"\\x0"+s(t)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(t){return"\\x"+s(t)})}function a(t){return t.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(t){return"\\x0"+s(t)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(t){return"\\x"+s(t)})}function h(t){return r[t.type](t)}return"Expected "+function(t){var e,i,r=new Array(t.length);for(e=0;e<t.length;e++)r[e]=h(t[e]);if(r.sort(),r.length>0){for(e=1,i=1;e<r.length;e++)r[e-1]!==r[e]&&(r[i]=r[e],i++);r.length=i}switch(r.length){case 1:return r[0];case 2:return r[0]+" or "+r[1];default:return r.slice(0,-1).join(", ")+", or "+r[r.length-1]}}(t)+" but "+((i=e)?'"'+n(i)+'"':"end of input")+" found."},e.exports={SyntaxError:i,parse:function(t,e){e=void 0!==e?e:{};var r,s={},n={svg_path:xt},a=xt,h=function(t){if(!t)return[];for(var e=[],i=0;i<t.length;i++)e=e.concat.apply(e,t[i]);var r=e[0];return r&&"m"==r.code&&(delete r.relative,r.code="M"),e},o=function(t,e){return function(t,e){if(!e)return[t];for(var i=[t],r=0,s=e.length;r<s;r++)i[r+1]=e[r][1];return i}(t,e)},l=/^[Mm]/,d=ut(["M","m"],!1,!1),u=function(t,e,i){var r=jt(t,[e]);return i&&(r=r.concat(jt("M"==t?"L":"l",i[1]))),r},c=/^[Zz]/,p=ut(["Z","z"],!1,!1),f=function(){return jt("Z")},x=/^[Ll]/,g=ut(["L","l"],!1,!1),m=function(t,e){return jt(t,e)},y=/^[Hh]/,v=ut(["H","h"],!1,!1),w=function(t,e){return jt(t,e.map(function(t){return{x:t}}))},_=/^[Vv]/,S=ut(["V","v"],!1,!1),B=function(t,e){return jt(t,e.map(function(t){return{y:t}}))},b=/^[Cc]/,M=ut(["C","c"],!1,!1),C=function(t,e,i){return{x1:t.x,y1:t.y,x2:e.x,y2:e.y,x:i.x,y:i.y}},k=/^[Ss]/,A=ut(["S","s"],!1,!1),T=function(t,e){return{x2:t.x,y2:t.y,x:e.x,y:e.y}},P=/^[Qq]/,z=ut(["Q","q"],!1,!1),R=function(t,e){return{x1:t.x,y1:t.y,x:e.x,y:e.y}},O=/^[Tt]/,E=ut(["T","t"],!1,!1),H=/^[Aa]/,L=ut(["A","a"],!1,!1),F=function(t,e,i,r,s,n){return{rx:t,ry:e,xAxisRotation:i,largeArc:r,sweep:s,x:n.x,y:n.y}},U=function(t,e){return{x:t,y:e}},N=function(t){return 1*t},j=function(t){return 1*t.join("")},I=/^[01]/,D=ut(["0","1"],!1,!1),W=function(t){return"1"==t},V=function(){return""},X=",",q=dt(",",!1),Y=function(t){return t.join("")},$=".",G=dt(".",!1),Q=/^[eE]/,Z=ut(["e","E"],!1,!1),J=/^[+\-]/,K=ut(["+","-"],!1,!1),tt=/^[0-9]/,et=ut([["0","9"]],!1,!1),it=function(t){return t.join("")},rt=/^[ \t\n\r]/,st=ut([" ","\t","\n","\r"],!1,!1),nt=0,at=[{line:1,column:1}],ht=0,ot=[],lt=0;if("startRule"in e){if(!(e.startRule in n))throw new Error("Can't start parsing from rule \""+e.startRule+'".');a=n[e.startRule]}function dt(t,e){return{type:"literal",text:t,ignoreCase:e}}function ut(t,e,i){return{type:"class",parts:t,inverted:e,ignoreCase:i}}function ct(e){var i,r=at[e];if(r)return r;for(i=e-1;!at[i];)i--;for(r={line:(r=at[i]).line,column:r.column};i<e;)10===t.charCodeAt(i)?(r.line++,r.column=1):r.column++,i++;return at[e]=r,r}function pt(t,e){var i=ct(t),r=ct(e);return{start:{offset:t,line:i.line,column:i.column},end:{offset:e,line:r.line,column:r.column}}}function ft(t){nt<ht||(nt>ht&&(ht=nt,ot=[]),ot.push(t))}function xt(){var t,e,i,r,n;for(t=nt,e=[],i=Et();i!==s;)e.push(i),i=Et();if(e!==s)if(i=function(){var t,e,i,r,n,a;if(t=nt,(e=gt())!==s){for(i=[],r=nt,n=[],a=Et();a!==s;)n.push(a),a=Et();for(n!==s&&(a=gt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;){for(i.push(r),r=nt,n=[],a=Et();a!==s;)n.push(a),a=Et();n!==s&&(a=gt())!==s?r=n=[n,a]:(nt=r,r=s)}i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),i===s&&(i=null),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?t=e=h(i):(nt=t,t=s)}else nt=t,t=s;else nt=t,t=s;return t}function gt(){var e,i,r,n,a,h;if(e=nt,i=function(){var e,i,r,n,a,h,o;if(e=nt,l.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(d)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s&&(n=bt())!==s?(a=nt,(h=At())===s&&(h=null),h!==s&&(o=yt())!==s?a=h=[h,o]:(nt=a,a=s),a===s&&(a=null),a!==s?e=i=u(i,n,a):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}(),i!==s){for(r=[],n=nt,a=[],h=Et();h!==s;)a.push(h),h=Et();for(a!==s&&(h=mt())!==s?n=a=[a,h]:(nt=n,n=s);n!==s;){for(r.push(n),n=nt,a=[],h=Et();h!==s;)a.push(h),h=Et();a!==s&&(h=mt())!==s?n=a=[a,h]:(nt=n,n=s)}r!==s?e=i=o(i,r):(nt=e,e=s)}else nt=e,e=s;return e}function mt(){var e,i;return c.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(p)),i!==s&&(i=f()),(e=i)===s&&(e=function(){var e,i,r,n;if(e=nt,x.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(g)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s&&(n=yt())!==s?e=i=m(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,y.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(v)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s&&(n=vt())!==s?e=i=w(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,_.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(S)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s&&(n=vt())!==s?e=i=B(i,n):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,b.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(M)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=wt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=wt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=wt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,k.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(A)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=_t())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=_t())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=_t())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,P.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(z)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=St())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=St())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=St())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,O.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(E)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}())===s&&(e=function(){var e,i,r,n;if(e=nt,H.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(L)),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?(n=function(){var t,e,i,r,n,a;if(t=nt,(e=Bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=Bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=Bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}(),n!==s?e=i=m(i,n):(nt=e,e=s)):(nt=e,e=s)}else nt=e,e=s;return e}()),e}function yt(){var t,e,i,r,n,a;if(t=nt,(e=bt())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=bt())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}function vt(){var t,e,i,r,n,a;if(t=nt,(e=Ct())!==s){for(i=[],r=nt,(n=At())===s&&(n=null),n!==s&&(a=Ct())!==s?r=n=[n,a]:(nt=r,r=s);r!==s;)i.push(r),r=nt,(n=At())===s&&(n=null),n!==s&&(a=Ct())!==s?r=n=[n,a]:(nt=r,r=s);i!==s?t=e=o(e,i):(nt=t,t=s)}else nt=t,t=s;return t}function wt(){var t,e,i,r,n,a;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?((n=At())===s&&(n=null),n!==s&&(a=bt())!==s?t=e=C(e,r,a):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s),t}function _t(){var t,e,i,r;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?t=e=T(e,r):(nt=t,t=s)):(nt=t,t=s),t}function St(){var t,e,i,r;return t=nt,(e=bt())!==s?((i=At())===s&&(i=null),i!==s&&(r=bt())!==s?t=e=R(e,r):(nt=t,t=s)):(nt=t,t=s),t}function Bt(){var t,e,i,r,n,a,h,o,l,d,u;return t=nt,(e=Mt())!==s?((i=At())===s&&(i=null),i!==s&&(r=Mt())!==s?((n=At())===s&&(n=null),n!==s&&(a=Ct())!==s&&At()!==s&&(h=kt())!==s?((o=At())===s&&(o=null),o!==s&&(l=kt())!==s?((d=At())===s&&(d=null),d!==s&&(u=bt())!==s?t=e=F(e,r,a,h,l,u):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s)):(nt=t,t=s),t}function bt(){var t,e,i,r;return t=nt,(e=Ct())!==s?((i=At())===s&&(i=null),i!==s&&(r=Ct())!==s?t=e=U(e,r):(nt=t,t=s)):(nt=t,t=s),t}function Mt(){var t;return(t=Pt())===s&&(t=Ot()),t!==s&&(t=N(t)),t}function Ct(){var t,e,i;return t=nt,(e=Rt())===s&&(e=null),e!==s&&(i=Pt())!==s?t=e=[e,i]:(nt=t,t=s),t===s&&(t=nt,(e=Rt())===s&&(e=null),e!==s&&(i=Ot())!==s?t=e=[e,i]:(nt=t,t=s)),t!==s&&(t=j(t)),t}function kt(){var e;return I.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(D)),e!==s&&(e=W(e)),e}function At(){var t,e,i,r,n;if(t=nt,e=[],(i=Et())!==s)for(;i!==s;)e.push(i),i=Et();else e=s;if(e!==s)if((i=Tt())===s&&(i=null),i!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?t=e=[e,i,r]:(nt=t,t=s)}else nt=t,t=s;else nt=t,t=s;if(t===s){if(t=nt,e=nt,(i=Tt())!==s){for(r=[],n=Et();n!==s;)r.push(n),n=Et();r!==s?e=i=[i,r]:(nt=e,e=s)}else nt=e,e=s;e!==s&&(e=V()),t=e}return t}function Tt(){var e;return 44===t.charCodeAt(nt)?(e=X,nt++):(e=s,0===lt&&ft(q)),e}function Pt(){var e,i,r;return e=nt,i=function(){var e,i,r,n;return e=nt,(i=Ot())===s&&(i=null),i!==s?(46===t.charCodeAt(nt)?(r=$,nt++):(r=s,0===lt&&ft(G)),r!==s&&(n=Ot())!==s?e=i=[i,r,n]:(nt=e,e=s)):(nt=e,e=s),e===s&&(e=nt,(i=Ot())!==s?(46===t.charCodeAt(nt)?(r=$,nt++):(r=s,0===lt&&ft(G)),r!==s?e=i=[i,r]:(nt=e,e=s)):(nt=e,e=s)),e!==s&&(e=Y(e)),e}(),i!==s?((r=zt())===s&&(r=null),r!==s?e=i=[i,r]:(nt=e,e=s)):(nt=e,e=s),e===s&&(e=nt,(i=Ot())!==s&&(r=zt())!==s?e=i=[i,r]:(nt=e,e=s)),e!==s&&(e=Y(e)),e}function zt(){var e,i,r,n;return e=nt,Q.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(Z)),i!==s?((r=Rt())===s&&(r=null),r!==s&&(n=Ot())!==s?e=i=[i,r,n]:(nt=e,e=s)):(nt=e,e=s),e!==s&&(e=Y(e)),e}function Rt(){var e;return J.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(K)),e}function Ot(){var e,i;if(e=[],tt.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(et)),i!==s)for(;i!==s;)e.push(i),tt.test(t.charAt(nt))?(i=t.charAt(nt),nt++):(i=s,0===lt&&ft(et));else e=s;return e!==s&&(e=it(e)),e}function Et(){var e;return rt.test(t.charAt(nt))?(e=t.charAt(nt),nt++):(e=s,0===lt&&ft(st)),e!==s&&(e=V()),e}var Ht,Lt,Ft,Ut={m:"moveto",l:"lineto",h:"horizontal lineto",v:"vertical lineto",c:"curveto",s:"smooth curveto",q:"quadratic curveto",t:"smooth quadratic curveto",a:"elliptical arc",z:"closepath"};for(var Nt in Ut)Ut[Nt.toUpperCase()]=Ut[Nt];function jt(t,e){e||(e=[{}]);for(var i=e.length;i--;){var r={code:t,command:Ut[t]};for(var s in t==t.toLowerCase()&&(r.relative=!0),e[i])r[s]=e[i][s];e[i]=r}return e}if((r=a())!==s&&nt===t.length)return r;throw r!==s&&nt<t.length&&ft({type:"end"}),Ht=ot,Lt=ht<t.length?t.charAt(ht):null,Ft=ht<t.length?pt(ht,ht+1):pt(ht,ht),new i(i.buildMessage(Ht,Lt),Ht,Lt,Ft)}}}),g=d((t,e)=>{var i=x().parse;i.parseSVG=i,i.makeAbsolute=function(t){var e,i={x:0,y:0},r={x:"x0",y:"y0",x1:"x0",y1:"y0",x2:"x0",y2:"y0"};return t.forEach(function(t){for(var s in"moveto"===t.command&&(e=t),t.x0=i.x,t.y0=i.y,r)s in t&&(t[s]+=t.relative?t[r[s]]:0);"x"in t||(t.x=i.x),"y"in t||(t.y=i.y),t.relative=!1,t.code=t.code.toUpperCase(),"closepath"==t.command&&(t.x=e.x,t.y=e.y),i=t}),t},e.exports=i});function m(){if(!p){if(!c)return Promise.reject(new Error("HanaRenderer: no Hana UI loader registered. Call setHanaUILoader() from the host app before initializing a HanaRenderer."));(p=c()).catch(()=>{p=void 0})}return p}function y(t){f=t}function v(){return c||(c=async()=>async function(t,e){return await t.default(e?{module_or_path:e}:void 0),Object.getOwnPropertyDescriptor(t.Engine.prototype,"scene")||Object.defineProperty(t.Engine.prototype,"scene",{get:function(){let e=Object.create(t.SceneController.prototype);return e.__wbg_ptr=this.__wbg_ptr,e}}),{createEngine:e=>t.Engine.create(e,JSON.parse('{"schema":13,"scenes":[{"fi":0,"id":"32603ebf4-bd9a-54ba-c1e9-6645c3ee7a53","data":{"name":"Page","backgroundColor":[0,0,0,0],"objects":[]}}],"assets":{"images":{},"videos":{},"colors":{},"audios":{},"numbers":{},"booleans":{},"strings":{},"dynamicVariables":{"counters":{},"randoms":{},"timers":{},"times":{}},"fonts":{},"animations":{},"geometries":{},"emojiArt":{}},"publish":{"logo":true,"presentationSizing":"Contain","allowPageScroll":true,"showBackground":true},"framePublish":{},"components":{}}'),!0)}}(await import("./hana-ui.js"),f??function(){let t=typeof process<"u"?"2.0.14":void 0;return`https://cdn.spline.design/@splinetool/runtime${t?`@${t}`:""}/build/hana-ui.wasm`}())),m().then(()=>{})}var w=Math.PI/180;Math.PI;var _,S=1e-10;function B(t,e){let[[i,r],[s,n]]=t,[[a,h],[o,l]]=e,d=(i-s)*(h-l)-(r-n)*(a-o);if(0===d)return!1;let u=((i-a)*(h-l)-(r-h)*(a-o))/d,c=-((i-s)*(r-h)-(r-n)*(i-a))/d;return u>=0&&u<=1&&c>=0&&c<=1}(t=>{function e(t){return[t[0],t[3],t[1],t[4],t[2],t[5]]}t.identity=function(){return[1,0,0,0,1,0,0,0,1]},t.copy=function(e,i=t.identity()){for(let t=0,r=e.length;t<r;t++)i[t]=e[t];return i},t.create=function(e,i,r,s,n,a){return t.setAbcdef(t.identity(),e,i,r,s,n,a)},t.setAbcdef=function(t,e,i,r,s,n,a){return t[0]=e,t[1]=r,t[2]=n,t[3]=i,t[4]=s,t[5]=a,t},t.append=function(i,r){let[s,n,a,h,o,l]=e(i),[d,u,c,p,f,x]=e(r),g=d*s+u*a,m=d*n+u*h,y=c*s+p*a,v=c*n+p*h,w=f*s+x*a+o,_=f*n+x*h+l;return t.create(g,m,y,v,w,_)},t.prepend=function(i,r){let[s,n,a,h,o,l]=e(i),[d,u,c,p,f,x]=e(r),g=s,m=n,y=a,v=h;(1!==d||0!==u||0!==c||1!==p)&&(g=s*d+n*c,m=s*u+n*p,y=a*d+h*c,v=a*u+h*p);let w=o*d+l*c+f,_=o*u+l*p+x;return t.create(g,m,y,v,w,_)},t.getAbcdef=e,t.invert=function(e){let[i,r,s,n,a,h]=t.getAbcdef(e),o=i*n-r*s,l=n/o,d=-r/o,u=-s/o,c=i/o,p=(s*h-n*a)/o,f=-(i*h-r*a)/o;return t.create(l,d,u,c,p,f)},t.apply=function([e,i],r){let[s,n,a,h,o,l]=t.getAbcdef(r);return[s*e+a*i+o,n*e+h*i+l]},t.applyInverse=function(e,i){let[r,s,n,a,h,o]=t.getAbcdef(i),l=1/(r*a+n*-s),[d,u]=e;return[a*l*d+-n*l*u+(o*n-h*a)*l,r*l*u+-s*l*d+(-o*r+h*s)*l]},t.scale=function(e,i,r=i){let[s,n,a,h,o,l]=t.getAbcdef(e);return t.setAbcdef(e,s*i,n*r,a*i,h*r,o*i,l*r),e},t.rotate=function(e,i){let r=Math.cos(i),s=Math.sin(i),[n,a,h,o,l,d]=t.getAbcdef(e);return t.setAbcdef(e,n*r-a*s,n*s+a*r,h*r-o*s,h*s+o*r,l*r-d*s,l*s+d*r),e},t.rotateAround=function(e,i,r){let[s,n]=r,a=t.translate(e,-s,-n);return a=t.rotate(a,i),a=t.translate(a,s,n),a},t.translate=function(e,i,r){let[s,n,a,h,o,l]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,o+i,l+r),e},t.setTranslate=function(e,i,r){let[s,n,a,h]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,i,r),e},t.setPosition=function(e,i,r){let[s,n,a,h]=t.getAbcdef(e);return t.setAbcdef(e,s,n,a,h,i,r),e},t.getScale=function(e){let[i,r,s,n]=t.getAbcdef(e);return[Math.sqrt(i*i+r*r),Math.sqrt(s*s+n*n)]},t.getPosition=function(e){let[,,,,i,r]=t.getAbcdef(e);return[i,r]},t.getRotation=function(e,i){return t.decompose(e,i).rotation},t.decompose=function(e,i){let[r,s,n,a,h,o]=t.getAbcdef(e),{rotation:l,scale:d,shear:u}=function(t){let e=t[0][0],i=t[1][0],r=t[0][1],s=t[1][1],n=Math.sqrt(e*e+i*i),a=n>S?e/n:1,h=n>S?i/n:0,o=a*e+h*i,l=a*s-h*r,d=a*r+h*s;return{rotation:Math.atan2(h,a),scale:[o,l],shear:[Math.abs(l)>S?d/l:0,0]}}([[r,n],[s,a]]);return{position:[h+(i[0]*r+i[1]*n)-i[0],o+(i[0]*s+i[1]*a)-i[1]],scale:d,rotation:l,shear:u,pivot:i}},t.compose=function(e,i,r,s,n=[0,0]){let[a,h]=e,[o,l]=s,[d,u,c,p]=function({rotation:t,scale:e,shear:i}){let r=Math.cos(t),s=Math.sin(t),n=i[0]*e[1],a=i[1]*e[0];return[r*e[0]-s*a,s*e[0]+r*a,r*n-s*e[1],s*n+r*e[1]]}({rotation:r,scale:i,shear:n}),f=a-(o*d+l*c)+o,x=h-(o*u+l*p)+l;return t.create(d,u,c,p,f,x)}})(_||(_={}));var b,M,C,k,A,T=[[-1,1],[-1,-1],[1,-1],[1,1]],P=(t,e,i)=>{let r=t.getCenter(),s=t.getHalfSize(),n=_.append(e,t.worldMatrix);0===s[0]&&0===s[1]?i.push(_.apply(r,n)):T.forEach(t=>{let e=[t[0]*s[0]+r[0],t[1]*s[1]+r[1]];i.push(_.apply(e,n))})},z=class{constructor(){this.matrix=_.identity(),this.min=[1/0,1/0],this.max=[-1/0,-1/0],this.vertices=[],this.edges=[]}setFromObjectSize(t,e=!1){t.updateWorldMatrix(),this.makeEmpty(),_.copy(t.worldMatrix,this.matrix);let i=_.invert(t.worldMatrix);this.expandByObjectSize(t,i,e)}expandByObjectSize(t,e,i=!1){let r=[],s=!0===t.isBaseGroup?t:void 0;!0===i&&void 0!==s?s.traverse(t=>{t.visible&&P(t,e,r)}):P(t,e,r),this.setFromPoints(r)}setFromSize(t,e,i){this.makeEmpty(),_.copy(i,this.matrix),this.expandBySize(t,e,i)}expandBySize(t,e,i){[_.apply([0,0],i),_.apply([0,e],i),_.apply([t,e],i),_.apply([t,0],i)].forEach(t=>this.expandByPoint(t))}getCenter(){let[t,e]=this.min,[i,r]=this.getHalfSize();return _.apply([t+i,e+r],this.matrix)}getSize(){return[this.max[0]-this.min[0],this.max[1]-this.min[1]]}getHalfSize(){return[.5*(this.max[0]-this.min[0]),.5*(this.max[1]-this.min[1])]}makeEmpty(){this.min=[1/0,1/0],this.max=[-1/0,-1/0]}setFromPoints(t){this.makeEmpty();for(let e of t)this.expandByPoint(e)}expandByPoint(t){this.min=[Math.min(this.min[0],t[0]),Math.min(this.min[1],t[1])],this.max=[Math.max(this.max[0],t[0]),Math.max(this.max[1],t[1])]}computeVertices(){let[t,e]=this.getHalfSize(),i=this.getCenter(),[r,s,n,a]=_.getAbcdef(this.matrix),h=_.create(r,s,n,a,i[0],i[1]);this.vertices=T.map(([i,r])=>_.apply([i*t,r*e],h))}computeEdges(){this.edges=[];for(let t=0,e=this.vertices.length;t<e;++t)this.edges.push([this.vertices[t],this.vertices[(t+1)%e]])}project(t,e){let i=this.matrix;return e&&(i=_.append(e.worldMatrix,i)),_.applyInverse(t,i)}intersects(t,e,i){return this.intersectsInLocalSpace(...this.project([t,e],i))}intersectsInLocalSpace(t,e){let{min:i,max:r}=this;return t>=i[0]&&t<=r[0]&&e>=i[1]&&e<=r[1]}containsPoint(t){let[e,i]=t,[r,s]=this.min,[n,a]=this.max;return e>=r&&e<=n&&i>=s&&i<=a}intersectsBBox2D(t){for(let e=0,i=this.edges.length;e<i;e++){let i=this.edges[e];for(let e=0,r=t.edges.length;e<r;e++)if(B(i,t.edges[e]))return!0}for(let e=0,i=t.vertices.length;e<i;e++){let i=t.vertices[e];if(this.containsPoint(i))return!0}return!1}ensureMinMax(){let t=this.min,e=this.max;this.min=[Math.min(t[0],e[0]),Math.min(t[1],e[1])],this.max=[Math.max(t[0],e[0]),Math.max(t[1],e[1])]}copy(t){this.min=[...t.min],this.max=[...t.max],_.copy(t.matrix,this.matrix),this.computeVertices(),this.computeEdges()}clone(){let t=new z;return t.copy(this),t}},R=class{constructor(e,i,r){this.uuid=e,this.data=i,this.isObject2D=!0,this.localMatrix=_.identity(),this.worldMatrix=_.identity(),this.ignoreCameraZoom=!1,this.visible=!0,this._singleBBox=new z,this._recursiveBBox=new z,this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0,this.stateSelection=null,this.prevState=null,this.currentState=null,this.reversibleToState=null,this.currentTransitionEvent=null,this.previousAction=null,this.name="",this.position=[0,0],this.scale=[1,1],this.rotation=0,this.shear=[0,0],this.emitter=t(),this.dpr=r.dpr??1,this.dataPatched=i}project(t,e){let i=this.worldMatrix;return e&&(i=_.append(e.worldMatrix,i)),_.applyInverse(t,i)}intersects(t,e,i,r=!1){return this.visible&&!this.data.raycastLock&&this.intersectsInLocalSpace(...this.project([t,e],i),r)}intersectsInLocalSpace(t,e,i=!1){let{min:r,max:s}=i?this.recursiveBBox:this.singleBBox;return t>=r[0]&&t<=s[0]&&e>=r[1]&&e<=s[1]}applyTransforms(t){t.setTransform(this.worldMatrix,this.ignoreCameraZoom)}get singleBBox(){return this.singleBBoxNeedsUpdate&&(this.singleBBoxNeedsUpdate=!1,this._singleBBox.setFromObjectSize(this,!1),this._singleBBox.computeVertices(),this._singleBBox.computeEdges()),this._singleBBox}get recursiveBBox(){return this.recursiveBBoxNeedsUpdate&&(this.recursiveBBoxNeedsUpdate=!1,this._recursiveBBox.setFromObjectSize(this,!0),this._recursiveBBox.computeVertices(),this._recursiveBBox.computeEdges()),this._recursiveBBox}updateLocalMatrix(){this.localMatrix=_.compose(this.position,this.scale,this.rotation*w,n.getPivot(this.dataPatched),this.shear)}updateWorldMatrix(t,e,i){let r=this.parent;e&&null!=r&&r.updateWorldMatrix(t,!0,!1),t&&this.updateLocalMatrix(),this.parent?this.worldMatrix=_.append(this.parent.worldMatrix,this.localMatrix):this.worldMatrix=_.copy(this.localMatrix),this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0}get pivot(){return n.getPivot(this.data)}getCenter(){return[0,0]}getHalfSize(){return[0,0]}get id(){return this.uuid}resetBBoxNeedsUpdateSelf(){this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0}resetBBoxNeedsUpdate(){this.resetBBoxNeedsUpdateSelf(),this.traverseAncestors(t=>{t.resetBBoxNeedsUpdateSelf()})}updateTransformState(t){let e=!1;void 0!==t.position&&(e=!0,this.position=t.position),void 0!==t.rotation&&(e=!0,this.rotation=t.rotation),void 0!==t.scale&&(e=!0,this.scale=t.scale),void 0!==t.shear&&(e=!0,this.shear=t.shear),e&&(this.updateWorldMatrix(!0,!1,!0),this.resetBBoxNeedsUpdate())}updateByOp(t,r,s){0===t.type&&void 0!==t.props.visible&&(this.visible=t.props.visible),this.data=r,this.data=r;let n=t,a=e(t.path,["states","*"]);if(null!==a){if(0===t.type){let[e]=a;if(this?.stateSelection===e){let e={...t.props};if(delete e.name,Object.values(t.props).some(t=>void 0===t)){let i=this.data;if(void 0!==i){let r=l.zoom(i,t.path.slice(2));if(r)for(let i in t.props)void 0===t.props[i]&&i in r&&(e[i]=r[i])}}n={...t,props:e,path:t.path.slice(2)}}}}else if(0===t.type){let e=this.stateSelection?this.data.states.data(this.stateSelection):void 0;if(void 0!==e){if(void 0!==t.props.name&&e.name){let{name:t,...i}=e;e=i}let i=l.removeOverridden(t.path,t.props,e);n={...t,props:i}}}this.updateByPatchedOpBase(n,i.patch(this.data,this.stateSelection?this.data.states.data(this.stateSelection):void 0),s)}changeSelectedState(t,e,r=!1){if(0!==this.data.states.length||r){for(let t of this.data.states)i.toOps(this.data,t.data).forEach(t=>{let i=o.replaceProps(t,this.data);this.dataPatched=this.data,this.updateByPatchedOp(i,this.data,e)});if(null!==t){let r=this.data.states.data(t);r&&(this.dataPatched=i.patch(this.data,r),i.toOps(this.data,r).forEach(t=>{this.updateByPatchedOp(t,this.dataPatched,e)}))}r&&this.updateTransformState(this.dataPatched),this.stateSelection=t}}updateState(t,e){void 0!==t.name&&(this.name=t.name),void 0!==t.visible&&(this.visible=t.visible),this.updateTransformState(t)}updateByPatchedOpBase(t,e,i){this.dataPatched=e,this.updateByPatchedOp(t,e,i)}updateByPatchedOp(t,e,i){0===t.path.length&&0===t.type&&this.updateState(t.props,i),this.requestRender()}traverseFrameAncestors(t){this.traverseAncestors(e=>{"frame2d"===e.data.type&&t(e)})}traverseAncestors(t){let e=this.parent;for(;e;)t(e),e=e.parent}requestRender(){this.traverseFrameAncestors(t=>{t.requestRender()})}clone(t){let e=new R(this.uuid,this.data,t);return e.parent=void 0,e}addEventListener(t,e){this.emitter.on(t,e)}removeEventListener(t,e){this.emitter.off(t,e)}dispatchEvent(t){this.emitter.emit(t.type,{...t,target:t.target??this})}traverseSortNextHelper(){let t=this.parent;if(t){let e=t.children;if(e){let i=e.indexOf(this)+1;return e[i]?e[i]:t.traverseSortNextHelper()}}}sortNext(){let t=this.children;return t&&t.length>0&&t[0]?t[0]:this.traverseSortNextHelper()}isDescendantOf(t){t instanceof R&&(t=t.uuid);let e=this;for(;e.parent;){if(e.parent.uuid===t)return!0;e=e.parent}return!1}},O=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.blurRadius=0,this.offset=[0,0],this.spread=0,this.update(e)}update(t){void 0!==t.color&&(this.color=t.color),void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.blurRadius&&(this.blurRadius=t.blurRadius),void 0!==t.offset&&(this.offset=t.offset),void 0!==t.spread&&(this.spread=t.spread)}},E=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.radius=0,this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.radius&&(this.radius=t.radius)}},H=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.color&&(this.color=t.color)}},L=class{constructor(t,e,i){this.uuid=t,this.data=e,this.enabled=!1,this.color=a.transparent,this.thickness=0,this.mode="inside",this.update(e)}update(t){void 0!==t.enabled&&(this.enabled=t.enabled),void 0!==t.color&&(this.color=t.color),void 0!==t.thickness&&(this.thickness=t.thickness),void 0!==t.mode&&(this.mode=t.mode)}},F=class extends R{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.autoClose=!0,this.fill=new H(t+"-fill",e.fill,i),this.stroke=new L(t+"-stroke",e.stroke,i),this.dropShadow=new O(t+"-dropShadow",e.dropShadow,i),this.innerShadow=new O(t+"-innerShadow",e.innerShadow,i),this.backgroundBlur=new E(t+"-backgroundBlur",e.backgroundBlur,i),this.layerBlur=new E(t+"-layerBlur",e.layerBlur,i)}applyFillStroke(t){t.fillColor=this.fill.enabled?this.fill.color:a.transparent,t.strokeColor=this.stroke.enabled&&this.stroke.thickness>0?this.stroke.color:a.transparent,t.strokeMode=this.stroke.mode,t.lineWidth=this.stroke.thickness}applyFilters(t){this.layerBlur.enabled?t.layerBlur=5*this.layerBlur.radius:t.layerBlur=0,this.backgroundBlur.enabled?t.backgroundBlur=5*this.backgroundBlur.radius:t.backgroundBlur=0,this.dropShadow.enabled?(t.dropShadowBlur=5*this.dropShadow.blurRadius,t.dropShadowColor=this.dropShadow.color,t.dropShadowOffsetX=this.dropShadow.offset[0],t.dropShadowOffsetY=this.dropShadow.offset[1]):t.dropShadowColor=a.transparent,this.innerShadow.enabled?(t.innerShadowSpread=this.innerShadow.spread,t.innerShadowBlur=5*this.innerShadow.blurRadius,t.innerShadowColor=this.innerShadow.color,t.innerShadowOffsetX=this.innerShadow.offset[0],t.innerShadowOffsetY=this.innerShadow.offset[1]):t.innerShadowColor=a.transparent}innerDraw(t){}draw(t){!this.visible||(t.save(),this.applyTransforms(t),this.applyFilters(t),this.applyFillStroke(t),t.beginPath(),this.innerDraw(t),this.autoClose&&t.closePath(),this.fill.enabled&&t.fill(),this.stroke.enabled&&t.stroke(),t.restore())}updateByPatchedOp(t,i,r){super.updateByPatchedOp(t,i,r),0===t.type&&(e(t.path,["fill"])?this.fill.update(t.props):e(t.path,["stroke"])?this.stroke.update(t.props):e(t.path,["dropShadow"])?this.dropShadow.update(t.props):e(t.path,["innerShadow"])?this.innerShadow.update(t.props):e(t.path,["layerBlur"])?this.layerBlur.update(t.props):e(t.path,["backgroundBlur"])?this.backgroundBlur.update(t.props):this.resetBBoxNeedsUpdate())}updateState(t,e){super.updateState(t,e),void 0!==t.fill&&this.fill.update(t.fill),void 0!==t.stroke&&this.stroke.update(t.stroke),void 0!==t.dropShadow&&this.dropShadow.update(t.dropShadow),void 0!==t.innerShadow&&this.innerShadow.update(t.innerShadow),void 0!==t.layerBlur&&this.layerBlur.update(t.layerBlur),void 0!==t.backgroundBlur&&this.backgroundBlur.update(t.backgroundBlur)}clone(t){let e=new F(this.uuid,this.data,t);return e.parent=void 0,e}},U=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.width=0,this.height=0,this.updateState(e,i)}innerDraw(t){t.ellipse(.5*this.width,.5*this.height,.5*this.width,.5*this.height,0,0,2*Math.PI)}intersectsInLocalSpace(t,e){return function(t,e,i,r,s,n){let a=t-i,h=e-r;return a*a/(s*s)+h*h/(n*n)<=1}(t,e,.5*this.width,.5*this.height,.5*this.width,.5*this.height)}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t)}clone(t){let e=new U(this.uuid,this.data,t);return e.parent=void 0,e}},N=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.width=0,this.height=0,this.cornerRadius=[0,0,0,0],this.updateState(e,i)}innerDraw(t){t.rect(0,0,this.width,this.height,...this.cornerRadius)}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateCornerState(t){void 0!==t.cornerRadius&&(this.cornerRadius=t.cornerRadius)}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateCornerState(t)}clone(t){let e=new N(this.uuid,this.data,t);return e.parent=void 0,e}},j=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this._textHeight=0,this._textHeightDirty=!0,this.width=0,this.height=0,this.updateState(e,i)}get textHeight(){return this._textHeight}applyFillStroke(t){t.fillColor=this.fill.enabled?this.fill.color:a.transparent,t.strokeColor=this.stroke.enabled&&this.stroke.thickness>0?this.stroke.color:a.transparent,t.strokeMode="center",t.lineWidth=this.stroke.thickness}innerDraw(t){this._fontHolder?.arrayBuffer&&this._fontHolder.arrayBuffer.byteLength>1&&this.data.font&&t.registerFont(this._fontHolder.arrayBuffer,this.data.font);let e=this.data.textTransform,i=this.data.text.textValue.toString(),r=2===e?i.toUpperCase():3===e?i.toLowerCase():i,{height:s}=t.drawText(r,{x:0,y:0,width:this.width,height:this.height,fontSize:this.data.fontSize,lineHeight:this.data.lineHeight??1,letterSpacing:this.data.letterSpacing??0,horizontalAlign:this.data.horizontalAlign,verticalAlign:this.data.verticalAlign,font:this.data.font});this._textHeight=s}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateFontState(t,{shared:e}){void 0!==t.font&&(this._fontHolder=e.getFont(t.font),this._fontHolder&&!this._fontHolder.isLoaded&&this._fontHolder.loadingPromise.then(()=>{this.requestRender()}))}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateFontState(t,e)}clone(t){let e=new j(this.uuid,this.data,t);return e.parent=void 0,e}},I=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.curves=[],this.extremasBBox={min:[0,0],max:[0,0]},this.updateState(e,i)}computeExtremas(){0===this.curves.length&&this.computeCurves();let t=this.curves.map(t=>b.extremas(t)),e=[1/0,1/0],i=[-1/0,-1/0];for(let r=0,s=t.length;r<s;r++){let s=t[r];s[0][0]<e[0]&&(e[0]=s[0][0]),s[0][1]<e[1]&&(e[1]=s[0][1]),s[1][0]>i[0]&&(i[0]=s[1][0]),s[1][1]>i[1]&&(i[1]=s[1][1])}return this.extremasBBox.min=[e[0],e[1]],this.extremasBBox.max=[i[0],i[1]],this.extremasBBox}computeCurves(){this.curves=[];for(let t=1,e=this.data.points.length;t<e;t++){let e=this.data.points[t].data,i=this.data.points[t-1].data,r={start:i.position,cp1:i.controlNext.position,cp2:e.controlPrevious.position,end:e.position};this.curves.push(r)}let t=this.data.points[0].data,e=this.data.points[this.data.points.length-1].data;if(this.data.isClosed){let i={start:e.position,cp1:e.controlNext.position,cp2:t.controlPrevious.position,end:t.position};this.curves.push(i)}}getCenter(){let[t,e]=this.extremasBBox.min,[i,r]=this.getHalfSize();return[t+i,e+r]}getHalfSize(){let{min:t,max:e}=this.extremasBBox;return[.5*(e[0]-t[0]),.5*(e[1]-t[1])]}innerDraw(t){for(let e=0,i=this.data.points.length;e<i;e++){let i=this.data.points[e].data;if(0===e){let[e,r]=i.position;t.moveTo(e,r)}else{let r=this.data.points[e-1].data,[s,n]=r.controlNext.position,[a,h]=i.controlPrevious.position,[o,l]=i.position,d={start:r.position,cp1:r.controlNext.position,cp2:i.controlPrevious.position,end:i.position};b.derive(d),t.bezierCurveTo(s,n,a,h,o,l)}}let e=this.data.points[0].data,i=this.data.points[this.data.points.length-1].data;if(this.data.isClosed){let[r,s]=i.controlNext.position,[n,a]=e.controlPrevious.position,[h,o]=e.position;t.bezierCurveTo(r,s,n,a,h,o)}}updateState(t,e){super.updateState(t,e),this.computeExtremas()}clone(t){let e=new I(this.uuid,this.data,t);return e.parent=void 0,e}};(t=>{function e(t,e,i,r=!1){let s=t-2*e+i;if(0!==s){let r=-Math.sqrt(Math.abs(e*e-t*i)),n=-t+e;return[-(r+n)/s,-(-r+n)/s]}return e!==i&&0===s?[(2*e-i)/(2*(e-i))]:[]}t.derive=function(t){let e=t.start,i=t.cp1,r=t.cp2,s=t.end,n={start:[3*(i[0]-e[0]),3*(i[1]-e[1])],cp:[3*(r[0]-i[0]),3*(r[1]-i[1])],end:[3*(s[0]-r[0]),3*(s[1]-r[1])]};return t.derivative=n,n.derivative=M.derive(n),n},t.droot=function(i){let r=i.derivative??t.derive(i),s=r.start,n=r.cp,a=r.end;return[e(s[0],n[0],a[0]),e(s[1],n[1],a[1])]},t.extremas=function(e){let[i,r]=t.droot(e),s=[e.start[0],e.end[0]],n=[e.start[1],e.end[1]];for(let r of i)s.push(t.compute(e,Math.min(1,Math.max(0,r)))[0]);for(let i of r)n.push(t.compute(e,Math.min(1,Math.max(0,i)))[1]);return s.sort((t,e)=>t-e),n.sort((t,e)=>t-e),[[s[0],n[0]],[s[s.length-1],n[n.length-1]]]},t.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=1-e,r=i*i,s=e*e,n=r*i,a=r*e*3,h=i*s*3,o=e*s;return[n*t.start[0]+a*t.cp1[0]+h*t.cp2[0]+o*t.end[0],n*t.start[1]+a*t.cp1[1]+h*t.cp2[1]+o*t.end[1]]}})(b||(b={})),(C=M||(M={})).derive=function(t){let e=t.start,i=t.cp,r=t.end,s={start:[2*(i[0]-e[0]),2*(i[1]-e[1])],end:[2*(r[0]-i[0]),2*(r[1]-i[1])]};return s.derivative=k.derive(s),t.derivative=s,s},C.droot=function(t){let e=t.derivative??C.derive(t),i=e.start,r=e.end;return[i[0]!==r[0]?i[0]/(i[0]-r[0]):0,i[1]!==r[1]?i[1]/(i[1]-r[1]):0]},C.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=1-e,r=i*i,s=i*e*2,n=e*e;return[r*t.start[0]+s*t.cp[0]+n*t.end[0],r*t.start[1]+s*t.cp[1]+n*t.end[1]]},(A=k||(k={})).derive=function(t){let e=t.start,i=t.end,r=[i[0]-e[0],i[1]-e[1]];return t.derivative=r,t.derivative},A.compute=function(t,e){if(0===e)return[...t.start];if(1===e)return[...t.end];let i=t.start,r=t.end;return[i[0]+(r[0]-i[0])*e,i[1]+(r[1]-i[1])*e]};var D=class extends R{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.context=i,this.isBaseGroup=!0,this.children=[]}add(t){t.parent&&t.parent instanceof D&&t.parent.remove(t),this.children.push(t),t.parent=this}remove(t){let e=this.children.indexOf(t);e>=0&&(this.children.splice(e,1),t.parent=void 0)}traverse(t){let e=t(this);if(!0!==e)for(let i of this.children)i instanceof D?i.traverse(t):e=t(i)}intersectsChildrenHelper(t,e,i,r,s){for(let n of this.children)if(n.intersects(t,e,i,!1)&&(s.push(n),r)||n instanceof D&&n.intersectsChildrenHelper(t,e,i,r,s))return!0;return!1}intersectsChildren(t,e,i,r=!1,s=[],n=!1){return this.intersectsChildrenHelper(t,e,i,r,s),s}intersectsChildrenHelperReverse(t,e,i,r,s){for(let n of this.children)if(n instanceof D&&n.intersectsChildrenHelperReverse(t,e,i,r,s)||n.intersects(t,e,i,!1)&&(s.push(n),r))return!0;return!1}intersectsChildrenReverse(t,e,i,r=!1,s=[],n=!1){return this.intersectsChildrenHelperReverse(t,e,i,r,s),s}updateWorldMatrix(t,e,i){if(super.updateWorldMatrix(t,e,i),i&&this.children)for(let e of this.children)e.updateWorldMatrix(t,!1,!0)}find(t){let e;return this.traverse(i=>{i.uuid===t&&(e=i)}),e}innerDrawChildren(t){for(let e=this.children.length-1;e>=0;e--)this.children[e].draw(t)}resetBBoxNeedsUpdate(){super.resetBBoxNeedsUpdate(),this.traverse(t=>{t.resetBBoxNeedsUpdateSelf()})}clone(t){let e=new D(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},W=class extends D{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this.updateState(e,i)}draw(t){!this.visible||(t.save(),this.applyTransforms(t),this.innerDrawChildren(t),t.restore())}clone(t){let e=new W(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},V=class extends D{constructor(t,e,i){super(t,e,i),this.uuid=t,this.width=0,this.height=0,this.clipped=!0,this.background=new N(t+"-background",r.defaultData,i),this.background.parent=this,this.updateState(e,i)}get fill(){return this.background.fill}get stroke(){return this.background.stroke}get backgroundBlur(){return this.background.backgroundBlur}get layerBlur(){return this.background.layerBlur}get dropShadow(){return this.background.dropShadow}get innerShadow(){return this.background.innerShadow}get cornerRadius(){return this.background.cornerRadius}set cornerRadius(t){this.background.cornerRadius=t}updateLocalMatrix(){super.updateLocalMatrix(),this.background?.updateLocalMatrix()}updateWorldMatrix(t,e,i){super.updateWorldMatrix(t,e,i),this.background?.updateWorldMatrix(t,e,i)}draw(t){if(!this.visible)return;t.save();let e=this.width,i=this.height;this.applyTransforms(t),this.background.width=e,this.background.height=i,this.background.draw(t),this.clipped&&t.clipRect(0,0,e,i,...this.cornerRadius),this.innerDrawChildren(t),t.restore()}getCenter(){return[.5*this.width,.5*this.height]}getHalfSize(){return[.5*this.width,.5*this.height]}updateCornerState(t){void 0!==t.cornerRadius&&(this.cornerRadius=t.cornerRadius)}updateSizeState(t){let e=!1;void 0!==t.width&&(this.width="number"==typeof t.width?t.width:this.width,e=!0),void 0!==t.height&&(this.height="number"==typeof t.height?t.height:this.height,e=!0),e&&this.updateWorldMatrix(!0,!1,!0)}updateState(t,e){super.updateState(t,e),this.updateSizeState(t),this.updateCornerState(t),void 0!==t.fill&&this.fill.update(t.fill),void 0!==t.stroke&&this.stroke.update(t.stroke),void 0!==t.dropShadow&&this.dropShadow.update(t.dropShadow),void 0!==t.innerShadow&&this.innerShadow.update(t.innerShadow),void 0!==t.layerBlur&&this.layerBlur.update(t.layerBlur),void 0!==t.backgroundBlur&&this.backgroundBlur.update(t.backgroundBlur),void 0!==t.clipped&&(this.clipped=t.clipped)}requestRender(){super.requestRender(),this.dispatchEvent({type:"render"})}dispose(){this.removeEventListener("render")}updateByPatchedOp(t,i,r){super.updateByPatchedOp(t,i,r),0===t.type&&(e(t.path,["fill"])?this.fill.update(t.props):e(t.path,["stroke"])?this.stroke.update(t.props):e(t.path,["dropShadow"])?this.dropShadow.update(t.props):e(t.path,["innerShadow"])?this.innerShadow.update(t.props):e(t.path,["layerBlur"])?this.layerBlur.update(t.props):e(t.path,["backgroundBlur"])?this.backgroundBlur.update(t.props):this.resetBBoxNeedsUpdate())}clone(t){let e=new V(this.uuid,this.data,t);e.parent=void 0;for(let i of this.children)e.add(i.clone(t));return e}},X=u(g(),1),q=new Map,Y=null,$=class extends F{constructor(t,e,i){super(t,e,i),this.uuid=t,this.data=e,this._pathBBox=new DOMRect,this.path="",this.updateState(e,i),this.autoClose=!1,this.computeSVGBBox()}computeSVGBBox(){let t=this.path;G(this.path)&&(console.warn("Invalid SVG path",this.uuid),t=""),this._pathBBox=function(t){let e=q.get(t);if(void 0!==e)return e;if(null===Y||!Y.isConnected){let t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("aria-hidden","true"),t.style.cssText="position:absolute;width:0;height:0;overflow:hidden;visibility:hidden;pointer-events:none",Y=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(Y),document.body.appendChild(t)}Y.setAttribute("d",t);let i=Y.getBBox();return q.size>=4096&&q.clear(),q.set(t,i),i}(t)}innerDraw(t){t.path(this.path)}intersectsInLocalSpace(t,e){return t>=this._pathBBox.x&&t<=this._pathBBox.x+this._pathBBox.width&&e>=this._pathBBox.y&&e<=this._pathBBox.y+this._pathBBox.height}getCenter(){return[(this._pathBBox.x+this._pathBBox.width)/2,(this._pathBBox.y+this._pathBBox.height)/2]}getHalfSize(){return[(this._pathBBox.x+this._pathBBox.width)/2,(this._pathBBox.y+this._pathBBox.height)/2]}updateState(t,e){super.updateState(t,e),void 0!==t.path&&(this.path=t.path,this.computeSVGBBox())}clone(t){let e=new $(this.uuid,this.data,t);return e.parent=void 0,e}};function G(t){return/NaN/.test(t)}function Q(t,e=1,i=1){if(e<=0||i<=0)return t;if(G(t))return console.warn("Cannot scale invalid path",t),Z([]);if(1===e&&1===i)return t;try{return Z((0,X.parseSVG)(t).map(t=>{let r={...t};return"x"in r&&(r.x=r.x*e),"y"in r&&(r.y=r.y*i),"x1"in r&&(r.x1=r.x1*e),"x2"in r&&(r.x2=r.x2*e),"y1"in r&&(r.y1=r.y1*i),"y2"in r&&(r.y2=r.y2*i),"rx"in r&&(r.rx=r.rx*e),"ry"in r&&(r.ry=r.ry*i),r}))}catch(t){return console.warn("Error parsing SVG path",t),Z([])}}function Z(t){let e,i=["rx","ry","xAxisRotation","largeArc","sweep","x1","y1","x2","y2","x","y"];return t.map(t=>{let r=[];i.forEach(e=>{if(e in t){let i=1*t[e];r.length&&i>=0&&r.push(","),r.push(i)}});let s=(e===t.code?r[0]<0?"":",":t.code)+r.join("");return e=t.code,s}).join("")}var J=class{constructor(t,e,i){this.uuid=t,this.data=e,this.group=new W(J.GROUP_ID,{...s.defaultData},i),this.createChildrenObjects(e.objects,this.group,i)}createObject(t,e,i,r,s,n){let a=function(t,e,i){switch(e.type){case"ellipse2d":return new U(t,e,i);case"rectangle2d":return new N(t,e,i);case"text2d":return new j(t,e,i);case"vector2d":return new I(t,e,i);case"path2d":return new $(t,e,i);case"frame2d":return new V(t,e,i);default:return new W(t,e,i)}}(t,e,n);a&&(r.add(a),r.children.splice(s,0,r.children.pop()),a.updateWorldMatrix(),i.length>0&&(a instanceof W||a instanceof V)&&this.createChildrenObjects(i,a,n))}createChildrenObjects(t,e,i){let r=0;for(let s of t)this.createObject(s.id,s.data,s.children,e,r,i),r+=1}draw(t){this.group.draw(t)}updateEntityByOp(t,e,i,r){let s=this.find(t);if(s)try{s.updateByOp(e,i,{shared:r})}catch(t){console.error(t)}}updateTreeByOp(t,e){if(0===t.path.length&&7===t.type){let i=null===t.parent?this.group:this.find(t.parent);void 0!==i&&i instanceof D&&(this.createObject(t.id,t.data,t.children,i,t.localIndex,e),i.requestRender())}else if(0===t.path.length&&8===t.type){let e=this.find(t.id);if(void 0!==e&&void 0!==e.parent&&e.parent instanceof D){let t=e.parent;e.resetBBoxNeedsUpdate(),t?.remove(e),t?.requestRender()}}else if(0===t.path.length&&9===t.type){let e=this.find(t.id);if(void 0!==e){let i=e.parent,r=null===t.parent?this:this.find(t.parent);if(r instanceof D||r===this){r.add(e);let s=t.localIndex;r.children.splice(s,0,r.children.pop()),e.updateWorldMatrix(!0,!1,!0),i?.requestRender(),e.requestRender()}e.resetBBoxNeedsUpdate()}}}add(t){this.group.add(t)}remove(t){this.group.remove(t)}traverse(t){this.group.traverse(e=>{e!==this.group&&t(e)})}intersectsChildren(t,e,i,r=!1,s=[]){return this.group.intersectsChildren(t,e,i,r,s,!0)}intersectsChildrenReverse(t,e,i,r=!1,s=[]){return this.group.intersectsChildrenReverse(t,e,i,r,s,!0)}find(t){return this.group.find(t)}get children(){return this.group.children}project(t,e){return this.group.project(t,e)}getWithSortKey(t){let e=this.find(t);if(void 0===e)return;let i=[],r=e;for(;r!==this.group;){let t=r;r=r.parent;let e=r.children.indexOf(t);i.splice(0,0,e)}return{entity:e,sortKey:i}}getAllSorted(t){let e=[];for(let i of t){let t=this.getWithSortKey(i.id);void 0!==t&&e.push(t)}return e.sort((t,e)=>h(t.sortKey,e.sortKey)),e.map(t=>t.entity)}},K=J;K.GROUP_ID="scene2d";var tt=u(g(),1);function et(t,e,i,r,s,n,a,h,o,l){if(e===o&&i===l)return;if(r=Math.abs(r),s=Math.abs(s),0===r||0===s)return void t.push({LineTo:{x:o,y:l}});let d=n*Math.PI/180,u=Math.cos(d),c=Math.sin(d),p=(e-o)/2,f=(i-l)/2,x=u*p+c*f,g=-c*p+u*f,m=x*x/(r*r)+g*g/(s*s);if(m>1){let t=Math.sqrt(m);r*=t,s*=t}let y=r*r,v=s*s,w=y*v-y*g*g-v*x*x,_=y*g*g+v*x*x,S=(a!==h?1:-1)*Math.sqrt(Math.max(0,w/_)),B=S*(r*g)/s,b=S*(-s*x)/r,M=u*B-c*b+(e+o)/2,C=c*B+u*b+(i+l)/2,k=Math.atan2((g-b)/s,(x-B)/r),A=Math.atan2((-g-b)/s,(-x-B)/r)-k;!h&&A>0?A-=2*Math.PI:h&&A<0&&(A+=2*Math.PI);let T=Math.max(1,Math.ceil(Math.abs(A)/(Math.PI/2))),P=A/T,z=4/3*Math.tan(P/4),R=k,O=e,E=i;for(let e=0;e<T;e++){let e=R+P,i=Math.cos(R),n=Math.sin(R),a=Math.cos(e),h=Math.sin(e),o=M+r*a*u-s*h*c,l=C+r*a*c+s*h*u,d=-r*n*u-s*i*c,p=-r*n*c+s*i*u,f=-r*h*u-s*a*c,x=-r*h*c+s*a*u;t.push({CurveTo:[{x:O+z*d,y:E+z*p},{x:o-z*f,y:l-z*x},{x:o,y:l}]}),R=e,O=o,E=l}}var it=.5522847498307936,rt=3408/2816,st=1536/2816,nt=!1;function at(){nt||(nt=!0,console.warn("[HanaRenderer] clipRect: precise clipping of rotated/complex content is not supported by the Hana UI overlay yet; drawing unclipped. (Axis-aligned rectangles are clipped geometrically.)"))}var ht=class{constructor(t,e=1){this.canvas=t,this._dpr=e,this._width=0,this._height=0,this._isSizeDirty=!1,this._crashed=!1,this._shapes=[],this._lastPushedJSON="",this._ctm=_.identity(),this._stack=[],this._clips=[],this._pathEls=[],this._simpleShape=null,this._pathPrimitives=0,this._fillColor=a.transparent,this._strokeColor=a.transparent,this._lineWidth=1,this._strokeMode="inside",this._layerBlur=0,this._backgroundBlur=0,this._dropShadowBlur=0,this._dropShadowOffsetX=0,this._dropShadowOffsetY=0,this._dropShadowColor=a.transparent,this._innerShadowBlur=0,this._innerShadowOffsetX=0,this._innerShadowOffsetY=0,this._innerShadowSpread=0,this._innerShadowColor=a.transparent,this._fonts=new Map,this._fontsFlushed=new Set,this._fontXPerEm=new Map,this._measureCache=new Map;try{let i=t.getBoundingClientRect();t.width=i.width*e,t.height=i.height*e}catch{console.log(t.width,e)}}get dpr(){return this._dpr}set dpr(t){this._dpr=t,this._isSizeDirty=!0}get width(){return this._width}get height(){return this._height}async init(){if(!this._engine&&!this._crashed){try{this._context=await m(),this._engine=await this._context.createEngine(this.canvas)}catch(t){return this._crashed=!0,void console.error("[HanaRenderer] Failed to load the Hana UI engine; UI scenes will not render.",t)}if(this._width>0&&this._height>0)this._syncViewport();else{let t=this.canvas.getBoundingClientRect();t.width>0&&t.height>0&&(this._width=t.width,this._height=t.height,this._syncViewport())}this._flushFonts(),this.uiFontReady=this._watchUiFont()}}_watchUiFont(){return new Promise(t=>{let e=this._engine;if(!e||"function"!=typeof e.scene.isUiFontLoaded)return void t();let i=()=>{let t=!1;return this._guard(()=>{t=e.scene.isUiFontLoaded()}),t};if(i())return void t();let r=Date.now(),s=setInterval(()=>{this._crashed||Date.now()-r>3e5?clearInterval(s):i()&&(clearInterval(s),t())},150)})}_syncViewport(){let t=this._engine;if(!t||this._crashed)return;let e=this._width,i=this._height;this.canvas.style.width=e+"px",this.canvas.style.height=i+"px",this.canvas.width=Math.max(1,Math.ceil(e*this._dpr)),this.canvas.height=Math.max(1,Math.ceil(i*this._dpr)),this._guard(()=>{t.resize([e,i],this._dpr),t.scene.updateCamera({position:[e/2,i/2],zoom:1})})}setSize(t,e){!this._isSizeDirty&&t===this._width&&e===this._height||(this._isSizeDirty=!1,this._width=t,this._height=e,this._engine?this._syncViewport():(this.canvas.style.width=t+"px",this.canvas.style.height=e+"px",this.canvas.width=Math.max(1,Math.ceil(t*this._dpr)),this.canvas.height=Math.max(1,Math.ceil(e*this._dpr))))}_guard(t){if(!this._crashed)try{t()}catch(t){this._crashed=!0,console.error("[HanaRenderer] Hana engine call failed; disabling this renderer instance.",t)}}async loadFont(t,e){try{let i=await fetch(t);if(!i.ok)return void console.error(`[HanaRenderer] loadFont: ${t} returned HTTP ${i.status}; skipping "${e}"`);let r=await i.arrayBuffer();if(0===r.byteLength)return void console.error(`[HanaRenderer] loadFont: ${t} was empty; skipping "${e}"`);this.registerFont(r,e)}catch(i){console.error(`[HanaRenderer] loadFont failed for "${e}" (${t}):`,i)}}registerFont(t,e){if(this._fonts.has(e))return;this._fonts.set(e,t);let i=function(t){try{let e=new DataView(t),i=e.getUint32(0);if(65536!==i&&1330926671!==i&&1953658213!==i)return;let r=e.getUint16(4),s=-1,n=-1;for(let t=0;t<r;t++){let i=12+16*t,r=e.getUint32(i);1751474532===r&&(s=e.getUint32(i+8)),1330851634===r&&(n=e.getUint32(i+8))}if(s<0||n<0)return;let a=e.getUint16(s+18),h=e.getUint16(n);if(0===a||h<2)return;let o=e.getInt16(n+86);return o>0?o/a:void 0}catch{return}}(t);void 0!==i&&this._fontXPerEm.set(e,i),this._flushFonts()}_flushFonts(){let t=this._engine;if(t)for(let[e,i]of this._fonts)this._fontsFlushed.has(e)||(this._fontsFlushed.add(e),this._guard(()=>{t.scene.addLocalFont(e,new Uint8Array(i))}))}set strokeColor(t){this._strokeColor=t}set fillColor(t){this._fillColor=t}set lineWidth(t){this._lineWidth=t}set strokeMode(t){this._strokeMode=t}set dropShadowBlur(t){this._dropShadowBlur=t}set dropShadowColor(t){this._dropShadowColor=t}set dropShadowOffsetX(t){this._dropShadowOffsetX=t}set dropShadowOffsetY(t){this._dropShadowOffsetY=t}set innerShadowBlur(t){this._innerShadowBlur=t}set innerShadowColor(t){this._innerShadowColor=t}set innerShadowOffsetX(t){this._innerShadowOffsetX=t}set innerShadowOffsetY(t){this._innerShadowOffsetY=t}set innerShadowSpread(t){this._innerShadowSpread=t}set layerBlur(t){this._layerBlur=t}set backgroundBlur(t){this._backgroundBlur=t}save(){this._stack.push({ctm:_.copy(this._ctm),clipLen:this._clips.length})}restore(){let t=this._stack.pop();!t||(this._ctm=t.ctm,this._clips.length=t.clipLen)}setTransform(t,e=!1){let i=_.identity();if(this.camera?.enabled&&(i=_.append(i,this.camera.worldMatrix),e)){let t=_.getScale(this.camera.worldMatrix);i=_.scale(i,1/t[0],1/t[1])}this._ctm=_.append(i,t)}transform(t){this._ctm=_.append(this._ctm,t)}beginPath(){this._pathEls=[],this._simpleShape=null,this._pathPrimitives=0}closePath(){0!==this._pathEls.length&&"ClosePath"!==this._pathEls[this._pathEls.length-1]&&this._pathEls.push("ClosePath")}_startFreeform(){this._simpleShape=null,this._pathPrimitives++}moveTo(t,e){this._startFreeform(),this._pathEls.push({MoveTo:{x:t,y:e}})}lineTo(t,e){this._startFreeform(),this._pathEls.push({LineTo:{x:t,y:e}})}bezierCurveTo(t,e,i,r,s,n){this._startFreeform(),this._pathEls.push({CurveTo:[{x:t,y:e},{x:i,y:r},{x:s,y:n}]})}quadraticCurveTo(t,e,i,r){this._startFreeform(),this._pathEls.push({QuadTo:[{x:t,y:e},{x:i,y:r}]})}path(t){this._startFreeform(),this._pathEls.push(...function(t){let e,i=[];try{e=(0,tt.makeAbsolute)((0,tt.parseSVG)(t))}catch(t){return console.error("[HanaRenderer] Failed to parse SVG path:",t),i}let r=0,s=0,n=0,a=0,h=null,o=null;for(let t of e){let e=null,l=null;switch(t.code){case"M":r=n=t.x,s=a=t.y,i.push({MoveTo:{x:r,y:s}});break;case"L":r=t.x,s=t.y,i.push({LineTo:{x:r,y:s}});break;case"H":r=t.x,i.push({LineTo:{x:r,y:s}});break;case"V":s=t.y,i.push({LineTo:{x:r,y:s}});break;case"C":{let n={x:t.x1,y:t.y1},a={x:t.x2,y:t.y2};r=t.x,s=t.y,i.push({CurveTo:[n,a,{x:r,y:s}]}),e=a;break}case"S":{let n=h?{x:2*r-h.x,y:2*s-h.y}:{x:r,y:s},a={x:t.x2,y:t.y2};r=t.x,s=t.y,i.push({CurveTo:[n,a,{x:r,y:s}]}),e=a;break}case"Q":{let e={x:t.x1,y:t.y1};r=t.x,s=t.y,i.push({QuadTo:[e,{x:r,y:s}]}),l=e;break}case"T":{let e=o?{x:2*r-o.x,y:2*s-o.y}:{x:r,y:s};r=t.x,s=t.y,i.push({QuadTo:[e,{x:r,y:s}]}),l=e;break}case"A":{let e=r,n=s;r=t.x,s=t.y,et(i,e,n,t.rx,t.ry,t.xAxisRotation,t.largeArc,t.sweep,r,s);break}case"Z":r=n,s=a,i.push("ClosePath")}h=e,o=l}return i}(t))}rect(t,e,i,r,s=0,n=0,a=0,h=0){if(!ct([t,e,i,r]))return;let o={x:t,y:e,w:i,h:r,radii:[s,n,a,h]};this._pathPrimitives++,this._simpleShape=1===this._pathPrimitives&&0===this._pathEls.length?{kind:"rect",rect:o,smoothing:0}:null,gt(this._pathEls,o)}ellipse(t,e,i,r,s,n,a,h){if(ct([t,e,i,r])){if(i<0||r<0)throw Error("radii cannot be negative");this._pathPrimitives++,this._simpleShape=1===this._pathPrimitives&&0===this._pathEls.length?{kind:"ellipse",cx:t,cy:e,rx:i,ry:r}:null,function(t,e,i,r,s){let n=r*it,a=s*it;t.push({MoveTo:{x:e+r,y:i}},{CurveTo:[{x:e+r,y:i+a},{x:e+n,y:i+s},{x:e,y:i+s}]},{CurveTo:[{x:e-n,y:i+s},{x:e-r,y:i+a},{x:e-r,y:i}]},{CurveTo:[{x:e-r,y:i-a},{x:e-n,y:i-s},{x:e,y:i-s}]},{CurveTo:[{x:e+n,y:i-s},{x:e+r,y:i-a},{x:e+r,y:i}]},"ClosePath")}(this._pathEls,t,e,i,r)}}clipRect(t,e,i,r,s=0,n=0,a=0,h=0){let o=_.invert(this._ctm);!o||this._clips.push({m:_.copy(this._ctm),inv:o,rect:{x:t,y:e,w:i,h:r,radii:[s,n,a,h]}})}fill(){this._emit(!0)}stroke(){this._strokeColor.a<=0||this._lineWidth<=0||this._emit(!1)}_emit(t){let e=this._effectChain(t);if(t&&this._fillColor.a<=0&&!e)return;let i=this._classifyShape();if(!i)return;let r=this._applyClips(i);if("skip"===r)return;if(!t&&r!==i){let t=ft(i);if(t)return void this._emitClippedRectStroke(t,e)}i=r;let s={shape:i,color:t?ut(this._fillColor):[0,0,0,0],transform:_.getAbcdef(this._ctm)};t||(s.stroke=this._strokeDesc()),e&&(s.effect_chain=e),this._shapes.push(s)}_emitClippedRectStroke(t,e){let i=this._lineWidth,r="outside"===this._strokeMode?i:"center"===this._strokeMode?i/2:0,s=i-r,n=Math.min(t.w,t.h)/2,a=t.radii.map(t=>Math.max(0,Math.min(t,n))),h={x:t.x-r,y:t.y-r,w:t.w+2*r,h:t.h+2*r,radii:a.map(t=>t>0?t+r:0)},o=t.w-2*s,l=t.h-2*s,d=o>0&&l>0?{x:t.x+s,y:t.y+s,w:o,h:l,radii:a.map(t=>Math.max(0,t-s))}:null,u=this._applyClips(pt(h,0));if("skip"===u)return;let c=ft(u)??h,p=null;if(d){let t=this._applyClips(pt(d,0));p="skip"===t?null:ft(t)??d}let f=[];gt(f,c),p&&function(t,e){let{x:i,y:r,w:s,h:n}=e,a=Math.min(s,n)/2,[h,o,l,d]=e.radii.map(t=>Math.max(0,Math.min(t,a)));if(0===h&&0===o&&0===l&&0===d)return void t.push({MoveTo:{x:i,y:r}},{LineTo:{x:i,y:r+n}},{LineTo:{x:i+s,y:r+n}},{LineTo:{x:i+s,y:r}},"ClosePath");let u=1-it;t.push({MoveTo:{x:i+h,y:r}}),h>0&&t.push({CurveTo:[{x:i+h*u,y:r},{x:i,y:r+h*u},{x:i,y:r+h}]}),t.push({LineTo:{x:i,y:r+n-d}}),d>0&&t.push({CurveTo:[{x:i,y:r+n-d*u},{x:i+d*u,y:r+n},{x:i+d,y:r+n}]}),t.push({LineTo:{x:i+s-l,y:r+n}}),l>0&&t.push({CurveTo:[{x:i+s-l*u,y:r+n},{x:i+s,y:r+n-l*u},{x:i+s,y:r+n-l}]}),t.push({LineTo:{x:i+s,y:r+o}}),o>0&&t.push({CurveTo:[{x:i+s,y:r+o*u},{x:i+s-o*u,y:r},{x:i+s-o,y:r}]}),t.push("ClosePath")}(f,p);let x={shape:{Custom:f},color:ut(this._strokeColor),transform:_.getAbcdef(this._ctm)};e&&(x.effect_chain=e),this._shapes.push(x)}_classifyShape(){let t=this._simpleShape;return t?"rect"===t.kind?pt(t.rect,t.smoothing):{Ellipse:{center_x:t.cx,center_y:t.cy,rx:t.rx,ry:t.ry}}:0===this._pathEls.length?null:{Custom:this._pathEls.slice()}}_strokeDesc(){return{width:this._lineWidth,line_join:"Miter",color:ut(this._strokeColor),align:ot[this._strokeMode],cap:"Butt"}}_effectChain(t){let e=this.camera?.scale??1,i=[];if(t&&this._dropShadowColor.a>0&&i.push({DropShadow:{position:[this._dropShadowOffsetX*e,this._dropShadowOffsetY*e],blur:{Uniform:{size:2*this._dropShadowBlur*e}},spread:0,color:ut(this._dropShadowColor)}}),t&&this._backgroundBlur>0){let[t,e]=_.getScale(this._ctm),r=(t+e)/2;i.push({BackgroundBlur:{blur:{Uniform:{size:2*this._backgroundBlur*r}}}})}if(this._layerBlur>0&&i.push({LayerBlur:{blur:{Uniform:{size:2*this._layerBlur*e}}}}),t&&this._innerShadowColor.a>0){let[t,r,s,n]=_.getAbcdef(this._ctm),a=this._innerShadowOffsetX,h=this._innerShadowOffsetY;i.push({InnerShadow:{position:[t*a+s*h,r*a+n*h],blur:{Uniform:{size:2*this._innerShadowBlur*e}},spread:this._innerShadowSpread*e,color:ut(this._innerShadowColor)}})}return i.length>0?i:void 0}_applyClips(t){if(0===this._clips.length)return t;let e=t;for(let t of this._clips){let i=_.append(t.inv,this._ctm),[r,s,n,a,h,o]=_.getAbcdef(i),l=Math.abs(s)<=1e-6*(Math.abs(r)+Math.abs(a))&&Math.abs(n)<=1e-6*(Math.abs(r)+Math.abs(a)),d=xt(e);if(!d)return e;if(!l){at();continue}let u=r*d.minX+h,c=r*d.maxX+h,p=a*d.minY+o,f=a*d.maxY+o,x=Math.min(u,c),g=Math.max(u,c),m=Math.min(p,f),y=Math.max(p,f),v=t.rect,w=Math.max(x,v.x),S=Math.max(m,v.y),B=Math.min(g,v.x+v.w),b=Math.min(y,v.y+v.h);if(w>=B||S>=b)return"skip";if(w===x&&S===m&&B===g&&b===y)continue;let M=ft(e);if(!M||0===r||0===a){at();continue}let C=(w-h)/r,k=(B-h)/r,A=(S-o)/a,T=(b-o)/a,P=Math.min(C,k),z=Math.min(A,T),R=Math.abs(k-C),O=Math.abs(T-A),[E,H,L,F]=M.radii,U=P!==M.x,N=z!==M.y,j=P+R!==M.x+M.w,I=z+O!==M.y+M.h,D=Math.min(R,O)/2;e=pt({x:P,y:z,w:R,h:O,radii:[U||N?0:Math.min(E,D),j||N?0:Math.min(H,D),j||I?0:Math.min(L,D),U||I?0:Math.min(F,D)]},0)}return e}drawText(t,e){let i=this._fontXPerEm.get(e.font),r=i?i/st:1,s={TextSimple:{text:t,font_size:e.fontSize*rt*r,size:[e.width,e.height],horizontal_align:lt[e.horizontalAlign]??"Left",vertical_align:dt[e.verticalAlign]??"Top"}},n=this._effectChain(!0),a=this._fillColor.a>0,h=this._strokeColor.a>0&&this._lineWidth>0;if(a||h||n){let t={shape:s,color:a?ut(this._fillColor):[0,0,0,0],transform:_.getAbcdef(_.append(this._ctm,_.translate(_.identity(),e.x,e.y)))};h&&(t.stroke=this._strokeDesc()),n&&(t.effect_chain=n),this._shapes.push(t)}return{height:this._measureTextHeight(t,e)}}_measureTextHeight(t,e){let i=`${e.font}|${e.fontSize}|${e.lineHeight}|${e.letterSpacing}|${e.width}|${t}`,r=this._measureCache.get(i);if(void 0!==r)return r;let s=0,n=this._engine;if(n&&!this._crashed&&this._fontsFlushed.has(e.font))try{let[,i]=n.scene.measureTextNaturalSize({size:[e.width,e.height],text:t,fontSize:e.fontSize,horizontalAlign:lt[e.horizontalAlign]??"Left",verticalAlign:dt[e.verticalAlign]??"Top",lineHeight:e.lineHeight,letterSpacing:e.letterSpacing,textTransform:"None",font:e.font,version:0,autoSize:"None",truncate:"None"});s=i}catch{}if(!(s>0)){let i=.55*e.fontSize+Math.max(0,e.letterSpacing),r=Math.max(1,Math.floor(e.width/i)),n=0;for(let e of t.split("\n"))n+=Math.max(1,Math.ceil(e.length/r));s=n*e.fontSize*e.lineHeight}return this._measureCache.size>512&&this._measureCache.clear(),this._measureCache.set(i,s),s}clear(){this._shapes=[],this._ctm=_.identity(),this._stack.length=0,this._clips.length=0}render(){let t=this._engine;if(!t||this._crashed)return;let e=JSON.stringify(this._shapes);e!==this._lastPushedJSON&&(this._guard(()=>t.scene.updateUiShapes(this._shapes)),this._lastPushedJSON=e),this._guard(()=>t.onFrame())}},ot={inside:"Inside",outside:"Outside",center:"Center"},lt={1:"Left",2:"Right",3:"Center",4:"Justify"},dt={1:"Top",2:"Center",3:"Bottom"};function ut({r:t,g:e,b:i,a:r}){return[t,e,i,r]}function ct(t){for(let e=0;e<t.length;e++)if(void 0!==t[e]&&!Number.isFinite(t[e]))return!1;return!0}function pt(t,e){let[i,r,s,n]=t.radii;return 0===i&&0===r&&0===s&&0===n?{Rectangle:{x:t.x,y:t.y,width:t.w,height:t.h}}:{RoundedRectangle:{x:t.x,y:t.y,width:t.w,height:t.h,radius:[i,r,s,n],corner_smoothing:e}}}function ft(t){if("Rectangle"in t){let e=t.Rectangle;return{x:e.x,y:e.y,w:e.width,h:e.height,radii:[0,0,0,0]}}if("RoundedRectangle"in t){let e=t.RoundedRectangle;return{x:e.x,y:e.y,w:e.width,h:e.height,radii:[e.radius[0],e.radius[1],e.radius[2],e.radius[3]]}}return null}function xt(t){let e=ft(t);if(e)return{minX:e.x,minY:e.y,maxX:e.x+e.w,maxY:e.y+e.h};if("Ellipse"in t){let e=t.Ellipse;return{minX:e.center_x-e.rx,minY:e.center_y-e.ry,maxX:e.center_x+e.rx,maxY:e.center_y+e.ry}}if("TextSimple"in t){let e=t.TextSimple;return{minX:0,minY:0,maxX:e.size[0],maxY:e.size[1]}}if("Custom"in t){let e=1/0,i=1/0,r=-1/0,s=-1/0,n=t=>{t.x<e&&(e=t.x),t.y<i&&(i=t.y),t.x>r&&(r=t.x),t.y>s&&(s=t.y)};for(let e of t.Custom)"ClosePath"!==e&&("MoveTo"in e?n(e.MoveTo):"LineTo"in e?n(e.LineTo):"QuadTo"in e?e.QuadTo.forEach(n):"CurveTo"in e&&e.CurveTo.forEach(n));return e===1/0?null:{minX:e,minY:i,maxX:r,maxY:s}}return null}function gt(t,e){let{x:i,y:r,w:s,h:n}=e,a=Math.min(s,n)/2,[h,o,l,d]=e.radii.map(t=>Math.max(0,Math.min(t,a)));if(0===h&&0===o&&0===l&&0===d)return void t.push({MoveTo:{x:i,y:r}},{LineTo:{x:i+s,y:r}},{LineTo:{x:i+s,y:r+n}},{LineTo:{x:i,y:r+n}},"ClosePath");let u=1-it;t.push({MoveTo:{x:i+h,y:r}}),t.push({LineTo:{x:i+s-o,y:r}}),o>0&&t.push({CurveTo:[{x:i+s-o*u,y:r},{x:i+s,y:r+o*u},{x:i+s,y:r+o}]}),t.push({LineTo:{x:i+s,y:r+n-l}}),l>0&&t.push({CurveTo:[{x:i+s,y:r+n-l*u},{x:i+s-l*u,y:r+n},{x:i+s-l,y:r+n}]}),t.push({LineTo:{x:i+d,y:r+n}}),d>0&&t.push({CurveTo:[{x:i+d*u,y:r+n},{x:i,y:r+n-d*u},{x:i,y:r+n-d}]}),t.push({LineTo:{x:i,y:r+h}}),h>0&&t.push({CurveTo:[{x:i,y:r+h*u},{x:i+h*u,y:r},{x:i+h,y:r}]}),t.push("ClosePath")}function mt({constraints:t,newParentWidth:e,newParentHeight:i,initialParentWidth:r,initialParentHeight:s,objectInitialWidth:n,objectInitialHeight:a,objectInitialPosition:h}){let{horizontalConstraint:o,verticalConstraint:l}=t,d=e-r,u=i-s,c=n,p=a,f=h[0],x=h[1];if(0!==o)if(1===o)f+=d;else if(3===o)f+=d/2;else if(2===o)c=Math.max(1,c+d);else if(4===o){let t=e/r;c*=t,f*=t}if(0!==l)if(1===l)x+=u;else if(3===l)x+=u/2;else if(2===l)p=Math.max(1,p+u);else if(4===l){let t=i/s;p*=t,x*=t}return{width:c,height:p,position:[f,x]}}u(g(),1);export{_ as a,y as b,v as c,ht as d,F as e,U as f,N as g,j as h,W as i,V as j,$ as k,Q as l,K as m,mt as n};
@@ -0,0 +1 @@
1
+ import{f as t}from"./runtime-chunk-RTLL6WIB.js";import{h as e}from"./runtime-chunk-2PT2WH66.js";import{c as i}from"./runtime-chunk-TZCHGFVF.js";import{Aa as r,B as s,Ca as a,I as n,i as o,j as l,k as h,n as p,za as d}from"./runtime-chunk-AIWIOLR6.js";import{$c as c,Cc as u,Ec as m,Fc as f,Kd as y,Oc as g,Pc as v,Pd as x,Rc as S,Re as w,Xc as M,bd as b,cd as B,dd as P,kd as E,ld as A}from"./runtime-chunk-BVVSZMXD.js";var C={Cloner:null,changeEntityProptotype:()=>{},createEntity:()=>{}};function D(t,e){let i=[];if(e.length!==t.length)return null;{let r=0;for(;r<t.length;){if("*"===e[r])i.push(t[r]);else if(t[r]!==e[r])return null;r+=1}}return i}function W(t,e){let i=[];if(!(e.length<=t.length))return null;{let r=0;for(;r<e.length;){if("*"===e[r])i.push(t[r]);else if(t[r]!==e[r])return null;r+=1}}return i}var O=new f,V=new f,_=new g,T=[new f(-1,1,1),new f(-1,-1,1),new f(1,-1,1),new f(1,1,1),new f(-1,1,-1),new f(-1,-1,-1),new f(1,-1,-1),new f(1,1,-1)],R=[[0,3],[1,2],[5,6],[4,7],[0,1],[3,2],[7,6],[4,5],[0,4],[1,5],[2,6],[3,7]],U=[[0,2],[7,5],[4,1],[3,6],[4,3],[1,6]],I=(t,e,i)=>{t.updateEntityBoxSize(O,V),_.copy(e).multiply(t.matrixWorld),0===V.x&&0===V.y&&0===V.z?i.push(new f(O.x,O.y,O.z).applyMatrix4(_)):T.forEach(t=>{i.push(t.clone().multiply(V).add(O).applyMatrix4(_))})},L=class extends M{constructor(){super(...arguments),this.matrix=new g,this.vertices=[],this.faces=[],this.edges=[],this.centerEdges=[]}copy(t){return super.copy(t),this.matrix.copy(t.matrix),this.vertices=t.vertices.map(t=>t.clone()),this.faces=t.faces.map(t=>t.clone()),this.edges=t.edges.map(t=>t.clone()),this.centerEdges=t.centerEdges.map(t=>t.clone()),this}setFromObjectSize(t,e=!1){t.updateWorldMatrix(!1,e),this.makeEmpty(),this.matrix.copy(t.matrixWorld);let i=(new g).copy(t.matrixWorld).invert();return this.expandByObjectSize(t,i,e)}expandByObjectSize(t,e,i=!1){let r=[];if(!0===i){let i=[];t.traverseEntity(t=>{if(t.visible||t.cloner&&t.data.visible){if(!("geometry"in t))return _.copy(e).multiply(t.matrixWorld),void i.push((new f).applyMatrix4(_));I(t,e,r)}}),0===r.length&&r.push(...i)}else I(t,e,r);return this.setFromPoints(r)}getCenter(t){return(t=super.getCenter(t)).applyMatrix4(this.matrix),t}getPositionToCenter(t){return(t=super.getCenter(t)).applyMatrix4(_.copy(this.matrix).setPosition(0,0,0)),t}computeVertices(){this.getSize(V).multiplyScalar(.5),this.getCenter(O),_.copy(this.matrix).setPosition(O),this.vertices=T.map(t=>t.clone().multiply(V).applyMatrix4(_))}computeEdges(){this.vertices.length>0&&this.computeVertices(),this.edges=R.map(([t,e])=>new w(this.vertices[t],this.vertices[e])),this.centerEdges=this.edges.map(t=>t.getCenter(new f))}computeFaces(){this.vertices.length>0&&this.computeVertices(),this.faces=U.map(([t,e])=>this.vertices[t].clone().add(this.vertices[e]).multiplyScalar(.5))}},z=new f,N=new f,j=new f,F=new f,k=new f,q=new f,G=new g,H=1e-12,X=.01;function Z(t){let e=t.elements;z.set(e[0],e[1],e[2]),N.set(e[4],e[5],e[6]),j.set(e[8],e[9],e[10])}function $(){let t=Math.max(z.lengthSq(),N.lengthSq(),j.lengthSq());z.lengthSq()>H*t?F.copy(z).normalize():F.set(1,0,0),k.crossVectors(j,F),k.lengthSq()<=H*t&&(k.copy(N).addScaledVector(F,-N.dot(F)),k.lengthSq()<=H*t&&function(t,e){t.set(1,0,0).cross(e),t.lengthSq()<=H&&t.set(0,1,0).cross(e),t.normalize()}(k,F)),k.normalize(),q.crossVectors(F,k)}function K(t){return Z(t),$(),G.makeBasis(F,k,q)}var Y,J=new g;(Y||(Y={})).is=function(t){return t&&t.__isSPEObject};var Q=t=>class extends t{constructor(){super(...arguments),this.previousModelViewMatrix=new g,this.copyPreviousMatrix=!0,this.hiddenMatrix=new g,this.pivotMatrix=new g,this.matrixWorldRigid=new g,this.shearScale=new g,this.shearScaleInv=new g}get __isSPEObject(){return!0}getPhysicsLocalMatrix(t){return!!this.rigidBody?.isDynamic()&&(t.copy(this.matrixWorld),this.hasNonUniformScale&&t.multiply(this.shearScaleInv),this.parent&&t.premultiply(J.copy(this.parent.matrixWorld).invert()),t.premultiply(J.copy(this.hiddenMatrix).invert()),t.multiply(J.copy(this.pivotMatrix).invert()),!0)}isDescendantOf(t){t instanceof S&&(t=t.uuid);let e=this;for(;e.parent;){if(e.parent.uuid===t)return!0;e=e.parent}return!1}updateMatrixWorld(t){this.matrixAutoUpdate&&this.updateMatrix(),(this.matrixWorldNeedsUpdate||t)&&(null===this.parent?this.matrixWorld.multiplyMatrices(this.hiddenMatrix,this.matrix):(this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.hiddenMatrix),this.matrixWorld.multiplyMatrices(this.matrixWorld,this.matrix)),this.matrixWorld.multiply(this.pivotMatrix),this.matrixWorldNeedsUpdate=!1,t=!0);for(let e of this.children)e.updateMatrixWorld(t)}updateWorldMatrix(t,e){let i=this.parent;if(t&&null!==i&&i.updateWorldMatrix(!0,!1),this.matrixAutoUpdate&&this.updateMatrix(),null===this.parent?this.matrixWorld.multiplyMatrices(this.hiddenMatrix,this.matrix):(this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.hiddenMatrix),this.matrixWorld.multiplyMatrices(this.matrixWorld,this.matrix)),this.matrixWorld.multiply(this.pivotMatrix),e)for(let t of this.children)t.updateWorldMatrix(!1,!0)}traverseChildren(t,e=0){for(let i of this.children)Y.is(i)&&i.traverseObject(t,e+1)}traverseObject(t,e=0){if(!0!==t(this,e))for(let i of this.children)Y.is(i)&&i.traverseObject(t,e+1)}updateMatrixWorldRigid(){this.hasNonUniformScale=function(t,e,i){return Z(t),$(),e.makeBasis(F,k,q),i.set(F.dot(z),F.dot(N),F.dot(j),0,k.dot(z),k.dot(N),k.dot(j),0,q.dot(z),q.dot(N),q.dot(j),0,0,0,0,1),function(){let t=z.length(),e=N.length(),i=j.length(),r=Math.max(t,e,i);if(r-t>X||r-e>X||r-i>X)return!0;let s=X*r*r;return Math.abs(z.dot(N))>s||Math.abs(z.dot(j))>s||Math.abs(N.dot(j))>s}()}(this.matrixWorld,this.matrixWorldRigid,this.shearScale),this.matrixWorldRigid.copyPosition(this.matrixWorld),this.shearScaleInv.copy(this.shearScale).invert()}attach(t,e){this.updateWorldMatrix(!0,!1);let i=(new g).copy(this.matrixWorld).invert();return null!==t.parent&&(t.parent.updateWorldMatrix(!0,!1),i.multiply(t.parent.matrixWorld)),"hiddenMatrix"in t&&t.hiddenMatrix instanceof g?t.hiddenMatrix.premultiply(i):t.applyMatrix4(i),t.updateWorldMatrix(!1,!1),this.add(t),void 0!==e&&(this.children.pop(),this.children.splice(e,0,t)),this}copy(t,e=!1){return super.copy(t,e),this.hasNonUniformScale=t.hasNonUniformScale,this}onAfterRender(t,e,i,r,s,a){this.copyPreviousMatrix&&this.previousModelViewMatrix.copy(this.modelViewMatrix)}},tt=class extends x{constructor(){super()}getPoints(t=12){let e,i=[],r=this.getCurveLengths(),s=r[r.length-1]/r.length;for(let a=0,n=this.curves;a<n.length;a++){let o=n[a],l=0===a?r[a]:r[a]-r[a-1],h=Math.ceil(t*l/s),p=o.getPoints(h);for(let t=0;t<p.length;t++){let r=p[t];e&&e.equals(r)||(i.push(r),e=r)}}return this.autoClose&&i.length>1&&!i[i.length-1].equals(i[0])&&i.push(i[0]),i}},et=.001,it=new f,rt=new f,st=new f,at=new f,nt=new f,ot=new f,lt=new f,ht=new f,pt=new f;function dt(t,e,i){return it.subVectors(e,t),rt.subVectors(e,i),it.cross(rt).length()<=et}var ct,ut=new WeakMap;function mt(t){let e=ut.get(t.points);if(void 0!==e&&e.isClosed===t.isClosed)return e.curve;let i=function(t){let e=t.points,i=[e[0]],r=[new f(...e[0].data.position)];st.copy(r[0]);for(let t=0;t<e.length-1;t++)it.fromArray(e[t].data.position),rt.fromArray(e[t+1].data.position),nt.subVectors(it,st),lt.subVectors(it,rt),nt.cross(lt).length()>et&&(i.push(e[t]),r.push((new f).copy(it)),st.copy(it));let s=e[e.length-1];i.push(s),r.push(new f(...s.data.position));let a=t.isClosed,n=i.length-(a?0:1),o=i.length,l=[],h=[];for(let t=0;t<o;t++){let e=i[t].data;l.push(new f(...e.controlPrevious.position)),h.push(new f(...e.controlNext.position))}let p=[];for(let t=0;t<n;t++){let e=t===o-1?0:t+1;p.push(dt(r[t],h[t],r[e])&&dt(r[t],l[e],r[e]))}let d=[];for(let t=0;t<o;t++){let e=i[t].data,s=r[t],n={position:s,prevDir:void 0,nextDir:void 0,controlPrevious:l[t],controlNext:h[t],tan:void 0,baseRoundness:e.roundness,removedLength:0};if(d.push(n),0===e.roundness||!a&&(0===t||t===o-1))continue;let c=a&&0==t?o-1:t-1,u=a&&t==o-1?0:t+1,m=(new f).subVectors(r[c],s).normalize(),y=(new f).subVectors(r[u],s).normalize();n.prevDir=m,n.nextDir=y;let g=p[a&&0===t?o-1:t-1],v=p[t];if(g&&v){at.addVectors(m,y).normalize();let t=st.crossVectors(at,m).length()/m.dot(at);n.tan=t,n.removedLength=e.roundness/t}}for(let t=0;t<n;t++){let e=a&&t===o-1?0:t+1,i=d[t],r=d[e];if(0!==i.removedLength||0!==r.removedLength){let t=i.position.distanceTo(r.position);i.removedLength=Math.min(i.removedLength,t/2),r.removedLength=Math.min(r.removedLength,t/2)}}let c=new Array(2*o).fill(null);for(let t=0;t<n;t++){let e=a&&t===o-1?0:t+1,i=d[t],r=d[e],s=null;if(p[t]){let t=i.position.clone(),e=r.position.clone();(0!==i.removedLength||0!==r.removedLength)&&(i.nextDir&&t.add(st.copy(i.nextDir).setLength(i.removedLength)),r.prevDir&&e.add(st.copy(r.prevDir).setLength(r.removedLength))),t.distanceTo(e)>et&&(s=new y(t,t.clone().lerp(e,.3),e.clone().lerp(t,.3),e))}else i.position.distanceTo(r.position)>et&&(s=new y(i.position,i.controlNext,r.controlPrevious,r.position));c[2*t+1]=s}for(let t=0;t<o;t++){let e=d[t];if(0===e.removedLength)continue;let i=e.position,r=e.prevDir.clone().multiplyScalar(e.removedLength).add(i),s=e.nextDir.clone().multiplyScalar(e.removedLength).add(i),a=e.tan*e.removedLength;at.addVectors(e.prevDir,e.nextDir).normalize(),nt.copy(r).lerp(s,.5);let n=r.distanceTo(s)/2;pt.copy(at).multiplyScalar(Math.sqrt(Math.pow(a,2)-Math.pow(n,2))).add(nt),ot.copy(at).multiplyScalar(-a).add(pt);let o=i.distanceTo(ot)/i.distanceTo(nt);lt.copy(e.prevDir).multiplyScalar(o*i.distanceTo(r)).add(i),ht.copy(lt).lerp(ot,2);let l=r.clone().lerp(lt,4/3),h=s.clone().lerp(ht,4/3);c[2*t]=new y(r,l,h,s)}let u=new tt;for(let t=0;t<c.length;t++){let e=c[t];e&&u.add(e)}return u}(t);return ut.set(t.points,{isClosed:t.isClosed,curve:i}),i}(ct||(ct={})).is=function(t){return t&&t.__isEntity};var ft=t=>ct.is(t),yt={type:"completeState",isfromEntity:!0},gt=["x","y","z"],vt=new f,xt=new f(1,1,1),St=new m,wt=new v,Mt=(new f).set(0,1,0),bt=new g,Bt=new g,Pt=c=>class extends(Q(c)){constructor(){super(...arguments),this.raycastLock=!1,this.scaleLock=!1,this.disposed=!1,this.stateSelection=null,this.destroyedInAction=!1,this.instances=[],this.prevState=null,this.currentState=null,this.currentAnimationAction=null,this.reversibleToState=null,this.transitionState={settled:!0,state:null},this.currentTransitionEvent=null,this.previousAction=null,this._singleBBox=new L,this._recursiveBBox=new L,this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0,this._needApplyPathSnapping=!0,this.attachedPaths=new Set}get __isEntity(){return!0}entityChildren(t){let e=this.children[t];if(ct.is(e))return e}entityChildrenCount(){let t=this.children.length;for(;t--;)if(ct.is(this.children[t]))return t+1;return 0}get isConcreteEntity(){return"string"==typeof this.identity}get isVirtualEntity(){return"string"!=typeof this.identity}get isInstanceRoot(){return this.isConcreteEntity&&"Instance"===this.data.type}nearestInstanceSelfOrParent(){let t=this;for(;"Instance"!==t.data.type;){let e=t.parent;if(!ct.is(e))return;t=e}return t}forInstancesRec(t){this.instances.forEach(e=>{e.disposed||t(e),e.forInstancesRec(t)})}super_Entity(t,e){"string"==typeof t&&(this.uuid=t),this.identity=t,this.data=e,this.matrixAutoUpdate=!1,this.dataPatched=this.data}changeSelectedState(t,e,i=!1){if(0!==this.data.states.length||i){for(let t of this.data.states)a.toOps(this.data,t.data).forEach(t=>{let i=l.replaceProps(t,this.data);this.dataPatched=this.data,this.updateByPatchedOp(i,this.data,e)});if(null!==t){let i=this.data.states.data(t);i&&(this.dataPatched=a.patch(this.data,i),a.toOps(this.data,i).forEach(t=>{this.updateByPatchedOp(t,this.dataPatched,e)}))}i&&this.updateTransformState(this.dataPatched,e),this.stateSelection=t,this.updatePathSnapping(this.dataPatched.pathSnapping)}}get singleBBox(){return this.singleBBoxNeedsUpdate&&(this.singleBBoxNeedsUpdate=!1,this._singleBBox.setFromObjectSize(this,!1),this._singleBBox.computeVertices(),this._singleBBox.computeEdges(),this._singleBBox.computeFaces()),this._singleBBox}get recursiveBBox(){return this.recursiveBBoxNeedsUpdate&&(this.recursiveBBoxNeedsUpdate=!1,this._recursiveBBox.setFromObjectSize(this,!0),this._recursiveBBox.computeVertices(),this._recursiveBBox.computeEdges(),this._recursiveBBox.computeFaces()),this._recursiveBBox}updateEntityBoxSize(t,e){t.setScalar(0),e.setScalar(0)}resetBBoxNeedsUpdateSelf(){this.singleBBoxNeedsUpdate=!0,this.recursiveBBoxNeedsUpdate=!0}resetBBoxNeedsUpdate(){this.resetBBoxNeedsUpdateSelf(),this.traverseAncestors(t=>{ft(t)&&t.resetBBoxNeedsUpdateSelf()}),this.traverseEntity(t=>{t.resetBBoxNeedsUpdateSelf()})}find(t){let e;return this.traverseEntity(i=>{i.uuid===t&&(e=i)}),e}traverseSortNextHelper(){let t=this.parent;if(t){let e=t.children,i=e.indexOf(this)+1;if(ct.is(e[i]))return e[i];if(ct.is(t))return t.traverseSortNextHelper()}}sortNext(){let t=this.children;return this.children.length>0&&ct.is(this.children[0])?t[0]:this.traverseSortNextHelper()}goUp(t){let e=this;for(;t>0&&null!==e;)e=e.parent,t-=1;return e}hasAnccestorOrSelf(t){return this===t||this.hasAnccestor(t)}hasAnccestor(t){let e=this.parent;for(;e;){if(t===e)return!0;e=e.parent}return!1}countToAccestor(t){let e=0,i=this;for(;i!==t;){if(null===i)return-1;i=i.parent,e+=1}return e}forEachEntity(t){for(let e of this.children)ft(e)&&t(e)}traverseEntityAncestors(t){this.traverseAncestors(e=>{ct.is(e)&&t(e)})}traverseConcreteEntity(t,e=0){if(!0!==t(this,e))for(let i of this.children)ft(i)&&i.isConcreteEntity&&i.traverseEntity(t,e+1)}traverseEntity(t,e=0){if(!0!==t(this,e))for(let i of this.children)ft(i)&&i.traverseEntity(t,e+1)}traverseVisibleEntity(t){t(this);for(let e of this.children)ft(e)&&e.visible&&e.traverseVisibleEntity(t)}updateMatrix(){super.updateMatrix(),this.cloner&&this.cloner.onObjUpdateMatrix(),this.dispatchEvent({type:"updateMatrix"})}updateMatrixWorld(t){super.updateMatrixWorld(t),this.dispatchEvent({type:"updateMatrixWorld"})}copy(t,e=!1){return super.copy(t,e),this.dataPatched=t.dataPatched,this.raycastLock=t.raycastLock,this.scaleLock=t.scaleLock,this.hiddenMatrix.copy(t.hiddenMatrix),this}hasEntityChild(){return this.children.some(t=>ft(t))}isAncestorOf(t){if(this.uuid===t)return!1;let e=!1;return this.traverseEntity(i=>{i.uuid===t&&(e=!0)}),e}toObjectTransformState(e=[]){this.updateWorldMatrix(!0,!1);let i={position:this.position.toArray(),rotation:[this.rotation.x*u.RAD2DEG,this.rotation.y*u.RAD2DEG,this.rotation.z*u.RAD2DEG],scale:this.scale.toArray(),hiddenMatrix:this.hiddenMatrix.toArray(),pivot:[0,0,0],pivotRotation:[0,0,0]};return t(i,e)}getTransformValues(t,e,i){return e[t].map((e,r)=>i?.shared.getVariable(e,[this.uuid,t,gt[r]])??e)}updateTransformState(t,e){let i=!1;if(t.position&&(this.position.fromArray(this.getTransformValues("position",t,e)),i=!0),t.rotation&&(vt.fromArray(this.getTransformValues("rotation",t,e)).multiplyScalar(u.DEG2RAD),this.rotation.setFromVector3(vt),i=!0),t.scale&&(this.scale.fromArray(this.getTransformValues("scale",t,e)),i=!0),void 0!==t.hiddenMatrix&&(i=!0,this.hiddenMatrix.fromArray(t.hiddenMatrix??s.identity)),void 0!==t.pivot||void 0!==t.pivotRotation)if(i=!0,void 0!==t.pivot&&void 0!==t.pivotRotation)this.pivotMatrix.compose(vt.fromArray(t.pivot).negate(),St.setFromEuler(wt.fromArray(t.pivotRotation.map(t=>t*u.DEG2RAD))).invert(),xt);else if(void 0!==t.pivot)this.pivotMatrix.setPosition(-t.pivot[0],-t.pivot[1],-t.pivot[2]);else if(void 0!==t.pivotRotation){let e=vt.setFromMatrixPosition(this.pivotMatrix);St.setFromEuler(wt.fromArray(t.pivotRotation.map(t=>t*u.DEG2RAD))).invert(),this.pivotMatrix.compose(e,St,xt)}return i&&(this.updateMatrix(),this.resetBBoxNeedsUpdate(),this.invalidateClonerTransform(this),this.traverseEntityAncestors(t=>{t.invalidateClonerTransform(this)})),t.position&&t.rotation&&t.scale&&void 0!==t.hiddenMatrix&&this.updateWorldMatrix(!1,!0),i}onVariableUpdate(t=!1){t?this.resetBBoxNeedsUpdate():(this.updateMatrix(),this.resetBBoxNeedsUpdate(),this.invalidateClonerTransform(this),this.traverseEntityAncestors(t=>{t.invalidateClonerTransform(this)}),this.requestRender())}dispose(){this.disposed=!0,this.cloner&&(this.cloner.dispose(),this.cloner=void 0)}disposeChildrenRecursively(){for(let t of this.children)ct.is(t)&&t.disposeRecursively()}disposeRecursively(){this.dispose(),this.children.forEach(t=>{ct.is(t)&&t.disposeRecursively()})}toState(e=[]){let i={name:this.name,visible:this.visible,raycastLock:this.raycastLock,...this.toObjectTransformState(e)};return t(i,e)}updateByObjUpdateOp(t,e){void 0!==t&&this.updateByOp({type:0,props:t,path:[]},{...this.data,...t},e,!1)}updateByOp(t,e,i,s){let n=this.data;this.data=e;let l=t,c=W(t.path,["states","*"]);if(null!==c){if(0===t.type){let[e]=c;if(this?.stateSelection===e){let e={...t.props};if(delete e.name,Object.values(t.props).some(t=>void 0===t)){let i=this.data;if(void 0!==i){let r=p.zoom(i,t.path.slice(2));if(r)for(let i in t.props)void 0===t.props[i]&&i in r&&(e[i]=r[i])}}l={...t,props:e,path:t.path.slice(2)}}}}else if(0===t.type){let e=this.stateSelection?this.data.states.data(this.stateSelection):void 0;if(void 0!==e){if(void 0!==t.props.name&&e.name){let{name:t,...i}=e;e=i}if(void 0!==t.props.material&&"material"in e){let{material:t,...i}=e;e=i}let i=p.removeOverridden(t.path,t.props,e);l={...t,props:i}}}if(this.updateByPatchedOpBase(l,a.patch(this.data,this.stateSelection?this.data.states.data(this.stateSelection):void 0),i),W(t.path,["overrides"])){let r=[],s=[...t.path];for(r.push(s[1]),s.splice(0,2);s.length>0&&"descendants"===s[0];)r.push(s[1]),s.splice(0,2);if(void 0===r[r.length-1]){if(0===t.type)for(let e of Object.keys(t.props)){r[r.length-1]=e;let s=i.scene.findInstance([this.uuid,...r]);s&&(s.overrideData=t.props[e],s.updateState(o.apply(s.component.data,s.overrideData),i))}}else{let a=i.scene.findInstance([this.uuid,...r]);if(a){let n=p.zoom(a.component.data,s);if(0===(t={...t,path:s}).type){let e=t.props;if(n)for(let[i,r]of Object.entries(t.props))void 0===r&&(e===t.props&&(e={...t.props}),e[i]=n[i]);t={...t,props:e}}a.overrideData=d.resolve(e.overrides,r),a.updateByOp(t,h.applySimple(a.data,t),i,!1)}}}else if(this.instances.length>0){let s;if(0===t.path.length&&0===t.type){let e;for(let i of r.rootOverrideProps)i in t.props&&(void 0===e&&(e={}),e[i]=t.props[i]);e&&(s={...t,props:e})}else for(let e of r.rootOverrideProps)if(W(t.path,[e])){s=t;break}void 0!==s&&this.instances.forEach(t=>{if(t.isInstanceRoot){let e=o.filterOp(t.overrideData,s);e&&t.updateByOp(e,h.applySimple(t.data,e),i,!0)}}),this.instances.forEach(r=>{if(!r.isInstanceRoot){let s=o.filterOp(r.overrideData,t);if(s){let a;a=n===r.data&&t===s?e:h.applySimple(r.data,s),r.updateByOp(s,a,i,!0)}}})}}updateByPatchedOpBase(t,e,i){if(this.dataPatched=e,0===t.path.length&&0===t.type)void 0!==t.props.type&&!n.is(t.props.type)&&C.changeEntityProptotype(this,e,i);else if(1===t.path.length&&"geometry"===t.path[0]&&0===t.type&&"type"in t.props){C.changeEntityProptotype(this,e,i);for(let t of this.children)ct.is(t)&&t.updateVisible(i.scene)}this.updateByPatchedOp(t,e,i)}updateByPatchedOp(t,e,i){if(0===t.path.length&&0===t.type?this.updateState(t.props,i):0===t.type&&("resolutionLevel"in t.props||"useChildrenColors"in t.props)&&this.updateState(e,i),"morphTargetInfluences"===t.path[0]&&0===t.type){let r=e.morphTargetInfluences.get(t.path[1])?.data.name;r&&this.updateMorphInfluences(r,i.shared.getVariable(t.props.value,[this.uuid,"morphTargetInfluences",r]))}if(null!==W(t.path,["pathSnapping"])&&this.updatePathSnapping(e.pathSnapping),null!==W(t.path,["cloner"])){let r=h.drop(t,1);0===r.path.length&&0===r.type&&!0===r.props.disabled?this.setFromClonerState(null,i):this.cloner?this.cloner.updateState(e.cloner,i):(this.setFromClonerState(e.cloner,i),this.expandCloner(i)),this.updateVisible(i.scene)}}updatePathSnapping(t=this.dataPatched.pathSnapping){this._updatedPathSnapping=t,this._needApplyPathSnapping=!0}get updatedPathSnapping(){return this._updatedPathSnapping}applyPathSnapping(t){if(!1===this._needApplyPathSnapping)return;let e=this._updatedPathSnapping?.pathId??this.dataPatched.pathSnapping.pathId,i=this._updatedPathSnapping?.slide??this.dataPatched.pathSnapping.slide??0,r=this._updatedPathSnapping?.offset??this.dataPatched.pathSnapping.offset??0,s=this._updatedPathSnapping?.orientation??this.dataPatched.pathSnapping.orientation;if(null===e)return;let a=t.find(e);if(!a)return;this._needApplyPathSnapping=!1;let n=a.data;if(n.geometry.path.points.length<=1)return;let o=mt(n.geometry.path),l=(i+r)%1;i+r===1&&0===l&&(l=1);let h=null;try{h=o.curves.length?o.getPointAt(l):null}catch(t){}if(null===h)return;a.updateMatrixWorld();let p=this.parent?bt.copy(this.parent.matrixWorld).invert():bt.identity();p.multiply(a.matrixWorld),h.applyMatrix4(p);let d={position:h.toArray(),rotation:n.rotation};if("tangential"===s){let t=Bt.extractRotation(a.matrixWorld),e=o.getTangentAt(l).applyMatrix4(t).add(h),i=Bt.lookAt(h,e,Mt),r=vt.setFromEuler(wt.setFromRotationMatrix(i)).multiplyScalar(u.RAD2DEG);d={...d,rotation:r.toArray()}}this.updateTransformState(d),this.traverseEntity(t=>{t._cameraType&&t.dispatchEvent(yt)})}updateVisible(t){if(this.visible=this.dataPatched.visible&&(!this.dataPatched.cloner||(this.dataPatched.cloner.disabled??!1)||!0!==this.dataPatched.cloner?.hideBase),!t)return;let e=!1;this.traverseEntity(t=>{if("Splat"===t.data.type)return e=!0,!0}),e&&t.reloadSplats()}updateState_Entity(t,e){void 0!==t.name&&(this.name=t.name),void 0!==t.raycastLock&&(this.raycastLock=t.raycastLock),void 0!==t.visible&&(this.updateVisible(e?.scene),this.resetBBoxNeedsUpdate()),e&&"cloner"in t&&void 0!==t.cloner&&(this.setFromClonerState(t.cloner,e),this.updateVisible(e.scene)),this.updateTransformState(t,e)}get attachedSurfaceCloners(){return this.children.filter(t=>e(t)&&"toObject"===t.parameters.type)}setFromClonerState(t,e){if(!this.disposed)if(null===t||t.disabled)this.cloner&&this.cloner.dispose(),this.cloner=void 0;else if(void 0===this.cloner){if(null===C.Cloner)return void i("cloners","a cloner");this.cloner=new C.Cloner(this,t),e.scene.addPendingExpandCloner(this)}else this.cloner.updateState(t,e)}expandCloner(t){!this.disposed&&this.cloner&&this.cloner.expandClones(t)}invalidateClonerTransform(t){this.cloner&&this.cloner.invalidateTransform(t)}requestRender(){this.dispatchEvent({type:"requestRender"})}},Et=class{static create(t){return this.build(this.normalizeInputs(t))}static normalizeInputs(t,e){let i=Object.assign({},e?.parameters??{width:100,revolutions:2,segments:40,pathRadius:10,pathType:0,pathSegments:30,cornerRadius:30,cornerSegments:4},t.parameters),r=Math.abs(i.width),s=Math.abs(i.height??r),a=Math.abs(i.depth??r),n=Math.abs(Math.min(r,a))/2;return{parameters:Object.assign(i,{width:r,height:s,depth:a,radius:n,segments:Math.round(i.segments),pathSegments:Math.round(i.pathSegments),cornerSegments:Math.round(i.cornerSegments)})}}static build(t){let{width:e,height:i,depth:r,radius:s,revolutions:a,segments:n,pathRadius:o,pathType:l,pathSegments:h,cornerRadius:p,cornerSegments:d}=t.parameters,c=new Ot(!1,e,i,r,s,a,n,o,l,h,p,d);return Object.assign(c,{userData:{...t,type:"HelixGeometry"}})}},At=new c([0,0,0],1);function Ct(t){return"TorusGeometry"===t.type&&360===t.arc}var Dt,Wt,Ot=class extends P{constructor(t=!0,e=1,i=1,r=1,s=1,a=1,n=1,o=1,l=1,h=1,p=1,d=1){if(super(),0===a)return;let c=t&&1===a;c&&(d=0),p>100&&(p=100),0===p&&(d=0);let u,m,y,g,v,x,S,w,M=()=>new f,B=new f,P=M(),E=M(),A=M(),C=M(),D=M(),W=M(),O=M(),V=M(),_=M(),T=M(),R=M(),U=i-2*o+.001,I=U/a,L=Math.ceil(n*a),z=L+1,N=U/L,j=-U/2,F=h+1,k=2*Math.PI/h,q=Math.PI/2/d,G=Math.min((1-p/100)*o,o-.01),H=o-G,X=0,Z=2*d+2,$=F*Z/2,K=$+F*z,Y=Math.max(0,F*(z+Z)),[J,Q,tt]=[3,3,2].map(t=>Array(Y*t).fill(0)),et=[],it=s-o;function rt(e,i){let r=Math.PI/2;x=i*N,w=2*Math.PI*(x%I)/I+r,x+=j,S=Math.sin(w)*it,v=Math.cos(w)*it,t?e.set(v,S,x):e.set(v,x,S)}rt(B,-1e-10),rt(P,0),C.copy(B),rt(B,1);let st=B.distanceTo(P),at=c?0:H+G,nt=st*L+2*at,ot=G,lt=nt-at;for(let e=0;e<=L;e++){rt(E,e),R.subVectors(E,C).normalize(),C.copy(E),_.copy(E).setComponent(+t+1,0).normalize(),T.crossVectors(R,_).normalize();let i=0===e,r=e===L,s=i?3*Math.PI/2:q,a=i?ot:lt,n=i?F:K,l=i?0:Y-F,p=R.clone().multiplyScalar(i?-H:H).add(E),u=R.clone().multiplyScalar(i?-1:1).normalize();for(let t=0;t<F;t++){let m=t*k;if(D.addVectors(B.copy(_).multiplyScalar(o*Math.cos(m)),P.copy(T).multiplyScalar(o*Math.sin(m))),W.copy(D).normalize(),i||r){c||(X=l+t,[0,1,2].forEach(t=>{J[3*X+t]=p.getComponent(t),Q[3*X+t]=u.getComponent(t)}),tt[2*X]=+r,tt[2*X+1]=t/h),P.copy(W).multiplyScalar(G),A.addVectors(E,P);for(let e=0;e<d;e++){let r=e*q+s;O.addVectors(B.copy(R).multiplyScalar(H*Math.sin(r)),P.copy(W).multiplyScalar(H*Math.cos(r))),V.copy(O).normalize(),P.addVectors(A,O),O.normalize(),X=n+e*F+t,[0,1,2].forEach(t=>{J[3*X+t]=P.getComponent(t),Q[3*X+t]=V.getComponent(t)});let o=+i+Math.sin(r);tt[2*X]=(a+H*o)/nt,tt[2*X+1]=t/h}}P.addVectors(E,D),X=$+e*F+t,[0,1,2].forEach(t=>{J[3*X+t]=P.getComponent(t),Q[3*X+t]=W.getComponent(t)}),tt[2*X]=(at+e*st)/nt,tt[2*X+1]=t/h}}let ht=z+2*d+2,[pt,dt]=[+c,ht-1];for(let t=pt;t<=dt-1;t++){let e=c&&t===dt-1;for(let i=0;i<F-1;i++)u=t*F+i,m=u+1,y=(e?i:u)+F,g=(e?i+1:m)+F,0===t?et.push(m,g,y):t===ht-2?et.push(u,m,y):et.push(u,m,y,m,g,y)}this.setIndex(et),this.setAttribute("position",new b(J,3)),this.setAttribute("normal",new b(Q,3)),this.setAttribute("uv",new b(tt,2))}getClosedTorusIndicesForBooleanOrSubdiv(){let t,e,i,r,s=this.userData.parameters,a=Math.ceil(s.tubularSegments),n=s.radialSegments,o=n+1,l=[];for(let s=1;s<a;s++)for(let a=0;a<n;a++)t=s*o+a,e=t+1,i=t+o,r=e+o,l.push(t,e,i,e,r,i);for(let s=0;s<n;s++)t=a*o+s,e=t+1,i=s+o,r=s+1+o,l.push(t,e,i,e,r,i);return At.array=new Uint32Array(l),At.count=l.length,At}},Vt=new Map,_t=0;function Tt(t){return Wt||(Wt=async function(){let e=t??"https://cdn.spline.design/@splinetool/runtime@2.0.14/build",i=import("./boolean.js"),[r,s]=await Promise.all([i,fetch(`${e}/boolean.wasm`).then(t=>t.arrayBuffer())]);await r.default({module_or_path:s}),Dt=r}())}function Rt(){if(void 0===Dt)throw new Error("boolean-wasm is not loaded");return Dt}function Ut(t){let e=Vt.get(t);if(void 0===e)throw new Error("Unknown csg mesh set handle "+t);return e}function It(t){return Vt.set(++_t,t),_t}var Lt={0:0,1:1,2:2};function zt(t,e,i){if(void 0===Dt)return-1;let{positions:r,indices:s,normals:a}=function(t,e){if(e&&void 0!==t.userData.positions){let e=t.userData,i=[];for(let t=0,r=0;t<e.verticesPerFace.length;t++){let s=e.verticesPerFace[t];for(let t=1;t<s-1;t++)i.push(e.indices[r],e.indices[r+t],e.indices[r+t+1]);r+=s}return{positions:e.positions instanceof Float32Array?e.positions:new Float32Array(e.positions),indices:new Uint32Array(i)}}let i;i=Ct(t.userData.parameters)?t.getClosedTorusIndicesForBooleanOrSubdiv():t.getIndex();let r,s=t.getAttribute("position");if(null===i){r=new Uint32Array(s.count);for(let t=0;t<r.length;t++)r[t]=t}else r=i.array instanceof Uint32Array?i.array:new Uint32Array(i.array);let a=t.getAttribute("normal"),n=void 0!==a&&3===a.itemSize&&a.count===s.count&&a.array instanceof Float32Array&&!0!==a.isInterleavedBufferAttribute?a.array:void 0;return{positions:s.array,indices:r,normals:n}}(t,e);return It(new Dt.CsgMesh(r,s,a))}function Nt(t,e){let i=Rt(),r=Lt[e];if(void 0===r)throw new Error("Unknown boolean operation "+e);let s=t.map(Ut);if(1===s.length)return i.clone_mesh(s[0]);let a,n=[];if(2===e&&s.length>2){let t=s[0];for(let e=1;e<s.length-1;e++)t=i.boolean_mesh(t,s[e],0),n.push(t);a=i.boolean_mesh(s[s.length-1],t,2)}else if(2===e)a=i.boolean_mesh(s[1],s[0],2);else{let t=s[s.length-1];for(let e=0;e<s.length-1&&(t=i.boolean_mesh(t,s[e],r),n.push(t),0!==t.tri_count());e++);a=t,n.pop()}for(let t of n)t.free();return a}function jt(t,e,i,r){let s=Rt(),a=Nt(t,e),n=s.mesh_render_data(a,Math.max(r,0));if(i.setAttribute("position",new b(n.positions(),3)),i.setAttribute("normal",new b(n.normals(),3)),n.free(),null===i.boundingSphere&&(i.boundingSphere=new B),0===a.tri_count())i.boundingSphere.center.set(0,0,0),i.boundingSphere.radius=0,i.userData.parameters={width:0,height:0,depth:0};else{let t=a.bounds();i.boundingSphere.center.set(t[0],t[1],t[2]),i.boundingSphere.radius=(t[3]**2+t[4]**2+t[5]**2)**.5,i.userData.parameters={width:2*t[3],height:2*t[4],depth:2*t[5]}}return It(a)}function Ft(t,e){let i=Rt(),r=Nt(t,e),s=i.mesh_topological_data(r),a=s.positions(),n=s.indices();return s.free(),r.free(),{positions:a,indices:n,verticesPerFace:new Uint8Array(n.length/3).fill(3)}}function kt(t,e){Ut(t).transform(new Float32Array(e.elements))}function qt(t){let e=Vt.get(t);void 0!==e&&(e.free(),Vt.delete(t))}function Gt(t,e){return It(Rt().instanced_union(Ut(t),e))}function Ht(t){return null!==t&&"booleanOp"in t}var Xt=class extends(Pt(A)){constructor(){super(...arguments),this.booleanMeshSetAddress=-1,this.booleanWasTransformed=!1,this.booleanMatrixInvOld=new g}updateVisible(t){super.updateVisible(t),this.visible=!Ht(this.parent)&&this.visible,Ht(this.parent)&&this.parent.invalidateDownstreamBooleanData()}onClonerLayoutUpdated(){Ht(this.parent)&&this.invalidateDownstreamBooleanData()}freeBooleanPointer(){-1!==this.booleanMeshSetAddress&&(qt(this.booleanMeshSetAddress),this.booleanMeshSetAddress=-1)}invalidateDownstreamBooleanData(t=!1){return t?this.booleanWasTransformed=!0:this.freeBooleanPointer(),Ht(this.parent)?this.parent.invalidateDownstreamBooleanData():this}invalidateUpstreamBooleanData(){this.freeBooleanPointer();for(let t of this.children)t instanceof Xt&&(t.freeBooleanPointer(),Ht(t)&&t.invalidateUpstreamBooleanData())}updateTransformState(t,e){let i=super.updateTransformState(t,e);return i&&Ht(this.parent)&&this.invalidateDownstreamBooleanData(!0),i}onVariableUpdate(t=!1){super.onVariableUpdate(t),Ht(this.parent)&&this.invalidateDownstreamBooleanData(!0)}},Zt=new M;function $t(t,e=0,i=t.count,r,s){let a=1/0,n=1/0,o=1/0,l=-1/0,h=-1/0,p=-1/0;for(let r=e;r<i;r++){let e=t.getX(r),i=t.getY(r),s=t.getZ(r);e<a&&(a=e),i<n&&(n=i),s<o&&(o=s),e>l&&(l=e),i>h&&(h=i),s>p&&(p=s)}Zt.min.set(a,n,o),Zt.max.set(l,h,p),Zt.getCenter(r),Zt.getSize(s).multiplyScalar(.5)}var Kt=new P,Yt=new E,Jt=class extends Xt{constructor(t,e){super(Kt,Yt),this.super_Entity(t,e)}updateState(t,e){this.updateState_Entity(t,e)}raycast(t,e){super.raycast(t,e)}updateEntityBoxSize(t,e){let i=this.geometry.getAttribute("position");void 0!==i?$t(i,this.geometry.drawRange.start,this.geometry.drawRange.count<1/0?this.geometry.drawRange.count:i.count,t,e):super.updateEntityBoxSize(t,e)}};export{D as a,W as b,C as c,K as d,Y as e,Q as f,mt as g,ct as h,ft as i,Pt as j,Et as k,Ct as l,Ot as m,Tt as n,zt as o,jt as p,Ft as q,kt as r,qt as s,Gt as t,$t as u,Jt as v};
@@ -1 +1 @@
1
- function e(e,t=0,r={}){let n,i,f,a,o,s=!0===r.leading,u=!1!==r.trailing,c=void 0!==r.maxWait?Math.max(r.maxWait,t):void 0,l=0,g=t=>{let r=i,n=f;return i=f=void 0,l=t,a=e.apply(n,r),a},y=e=>{if(void 0===o)return!0;let r=e-o;return r>=t||r<0||void 0!==c&&e-l>=c},d=e=>(n=void 0,u&&i?g(e):(i=f=void 0,a)),p=()=>{let e=Date.now();y(e)?d(e):n=setTimeout(p,(e=>{let r=t-(e-o);return void 0!==c?Math.min(r,c-(e-l)):r})(e))},h=function(...e){let r=Date.now(),u=y(r);if(i=e,f=this,o=r,u){if(void 0===n)return l=r,n=setTimeout(p,t),s?g(r):a;if(void 0!==c)return n=setTimeout(p,t),g(r)}return void 0===n&&(n=setTimeout(p,t)),a};return h.cancel=()=>{void 0!==n&&clearTimeout(n),l=0,i=o=f=n=void 0},h.flush=()=>void 0===n?a:d(Date.now()),h}function t(t,r=0,n={}){return e(t,r,{leading:!1!==n.leading,trailing:!1!==n.trailing,maxWait:r})}function r(e){return n(e,new Map)}function n(e,t){if(null===e||"object"!=typeof e)return e;if(t.has(e))return t.get(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){let t=new RegExp(e.source,e.flags);return t.lastIndex=e.lastIndex,t}if(e instanceof ArrayBuffer)return e.slice(0);if(ArrayBuffer.isView(e))return new e.constructor(e.buffer.slice(0),e.byteOffset,e instanceof DataView?e.byteLength:e.length);if(e instanceof Map){let r=new Map;return t.set(e,r),e.forEach((e,i)=>r.set(n(i,t),n(e,t))),r}if(e instanceof Set){let r=new Set;return t.set(e,r),e.forEach(e=>r.add(n(e,t))),r}if(Array.isArray(e)){let r=new e.constructor(e.length);t.set(e,r);for(let[i,f]of Object.entries(e))r[i]=n(f,t);return r}let r=Object.create(Object.getPrototypeOf(e));t.set(e,r);for(let[i,f]of Object.entries(e))r[i]=n(f,t);return r}function i(e,t){if(Object.is(e,t)||e!=e&&t!=t)return!0;if(null===e||null===t||"object"!=typeof e||"object"!=typeof t)return!1;if(e instanceof Date||t instanceof Date)return e instanceof Date&&t instanceof Date&&e.getTime()===t.getTime();if(e instanceof RegExp||t instanceof RegExp)return e instanceof RegExp&&t instanceof RegExp&&e.source===t.source&&e.flags===t.flags;if(Array.isArray(e)||Array.isArray(t))return!(!Array.isArray(e)||!Array.isArray(t)||e.length!==t.length)&&e.every((e,r)=>i(e,t[r]));if(ArrayBuffer.isView(e)||ArrayBuffer.isView(t))return!(!ArrayBuffer.isView(e)||!ArrayBuffer.isView(t)||e.constructor!==t.constructor||e.length!==t.length)&&e.every((e,r)=>Object.is(e,t[r]));if(e instanceof Map||t instanceof Map){if(!(e instanceof Map&&t instanceof Map&&e.size===t.size))return!1;for(let[r,n]of e)if(!t.has(r)||!i(n,t.get(r)))return!1;return!0}if(e instanceof Set||t instanceof Set){if(!(e instanceof Set&&t instanceof Set&&e.size===t.size))return!1;for(let r of e)if(!t.has(r))return!1;return!0}let r=Object.keys(e),n=Object.keys(t);return r.length===n.length&&r.every(r=>Object.prototype.hasOwnProperty.call(t,r)&&i(e[r],t[r]))}function f(e){let t=[];for(let r in e)t.push(r);return t}function a(e,t){let r={};for(let n of t)n in e&&(r[n]=e[n]);return r}function o(e,t){let r=new Set(t),n={};for(let[t,i]of Object.entries(e))r.has(t)||(n[t]=i);return n}function s(e){if(!e||0===e.length)return;let t;for(let r of e)r==r&&(void 0===t||r>t)&&(t=r);return t}function u(e,t){if(void 0===t)return e.replace(/\s+$/,"");let r=e.length;for(;r>0&&t.includes(e[r-1]);)r--;return e.slice(0,r)}export{e as a,t as b,r as c,i as d,f as e,a as f,o as g,s as h,u as i};
1
+ function e(e,t=0,r={}){let n,i,f,a,o,s=!0===r.leading,u=!1!==r.trailing,c=void 0!==r.maxWait?Math.max(r.maxWait,t):void 0,l=0,g=t=>{let r=i,n=f;return i=f=void 0,l=t,a=e.apply(n,r),a},y=e=>{if(void 0===o)return!0;let r=e-o;return r>=t||r<0||void 0!==c&&e-l>=c},d=e=>(n=void 0,u&&i?g(e):(i=f=void 0,a)),p=()=>{let e=Date.now();y(e)?d(e):n=setTimeout(p,(e=>{let r=t-(e-o);return void 0!==c?Math.min(r,c-(e-l)):r})(e))},h=function(...e){let r=Date.now(),u=y(r);if(i=e,f=this,o=r,u){if(void 0===n)return l=r,n=setTimeout(p,t),s?g(r):a;if(void 0!==c)return n=setTimeout(p,t),g(r)}return void 0===n&&(n=setTimeout(p,t)),a};return h.cancel=()=>{void 0!==n&&clearTimeout(n),l=0,i=o=f=n=void 0},h.flush=()=>void 0===n?a:d(Date.now()),h}function t(t,r=0,n={}){return e(t,r,{leading:!1!==n.leading,trailing:!1!==n.trailing,maxWait:r})}function r(e){return n(e,new Map)}function n(e,t){if(null===e||"object"!=typeof e)return e;if(t.has(e))return t.get(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){let t=new RegExp(e.source,e.flags);return t.lastIndex=e.lastIndex,t}if(e instanceof ArrayBuffer)return e.slice(0);if(ArrayBuffer.isView(e))return new e.constructor(e.buffer.slice(0),e.byteOffset,e instanceof DataView?e.byteLength:e.length);if(e instanceof Map){let r=new Map;return t.set(e,r),e.forEach((e,i)=>r.set(n(i,t),n(e,t))),r}if(e instanceof Set){let r=new Set;return t.set(e,r),e.forEach(e=>r.add(n(e,t))),r}if(Array.isArray(e)){let r=new e.constructor(e.length);t.set(e,r);for(let[i,f]of Object.entries(e))r[i]=n(f,t);return r}let r=Object.create(Object.getPrototypeOf(e));t.set(e,r);for(let[i,f]of Object.entries(e))r[i]=n(f,t);return r}function i(e,t){if(Object.is(e,t)||e!=e&&t!=t)return!0;if(null===e||null===t||"object"!=typeof e||"object"!=typeof t)return!1;if(e instanceof Date||t instanceof Date)return e instanceof Date&&t instanceof Date&&e.getTime()===t.getTime();if(e instanceof RegExp||t instanceof RegExp)return e instanceof RegExp&&t instanceof RegExp&&e.source===t.source&&e.flags===t.flags;if(Array.isArray(e)||Array.isArray(t))return!(!Array.isArray(e)||!Array.isArray(t)||e.length!==t.length)&&e.every((e,r)=>i(e,t[r]));if(ArrayBuffer.isView(e)||ArrayBuffer.isView(t))return!(!ArrayBuffer.isView(e)||!ArrayBuffer.isView(t)||e.constructor!==t.constructor||e.length!==t.length)&&e.every((e,r)=>Object.is(e,t[r]));if(e instanceof Map||t instanceof Map){if(!(e instanceof Map&&t instanceof Map&&e.size===t.size))return!1;for(let[r,n]of e)if(!t.has(r)||!i(n,t.get(r)))return!1;return!0}if(e instanceof Set||t instanceof Set){if(!(e instanceof Set&&t instanceof Set&&e.size===t.size))return!1;for(let r of e)if(!t.has(r))return!1;return!0}let r=Object.keys(e),n=Object.keys(t);return r.length===n.length&&r.every(r=>Object.prototype.hasOwnProperty.call(t,r)&&i(e[r],t[r]))}function f(e,t){let r={};for(let n of t)n in e&&(r[n]=e[n]);return r}function a(e,t){let r=new Set(t),n={};for(let[t,i]of Object.entries(e))r.has(t)||(n[t]=i);return n}function o(e){if(!e||0===e.length)return;let t;for(let r of e)r==r&&(void 0===t||r>t)&&(t=r);return t}function s(e,t){if(void 0===t)return e.replace(/\s+$/,"");let r=e.length;for(;r>0&&t.includes(e[r-1]);)r--;return e.slice(0,r)}export{e as a,t as b,r as c,i as d,f as e,a as f,o as g,s as h};