claude-code-best 2.5.0 → 2.6.5

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 (614) hide show
  1. package/dist/chunks/AddWorkspaceDirectory-BYyM_V0q.js +1 -0
  2. package/dist/chunks/App-BboadKdn.js +1 -0
  3. package/dist/chunks/ApproveApiKey-BLp4742y.js +1 -0
  4. package/dist/chunks/ApproveApiKey-DiEe4eui.js +1 -0
  5. package/dist/chunks/AssistantSessionChooser-B88DM0Oq.js +1 -0
  6. package/dist/chunks/BackgroundTasksDialog-ByraVuXh.js +2 -0
  7. package/dist/chunks/BypassPermissionsModeDialog-BDvmz12S.js +1 -0
  8. package/dist/chunks/ClaudeInChromeOnboarding-B6XNhFqq.js +1 -0
  9. package/dist/chunks/ClaudeMdExternalIncludesDialog-B4ocUjev.js +1 -0
  10. package/dist/chunks/ClaudeMdExternalIncludesDialog-BNhlq7_K.js +1 -0
  11. package/dist/chunks/ConsoleOAuthFlow-BvaB9b0y.js +1 -0
  12. package/dist/chunks/DesktopHandoff-S-w4bs5T.js +1 -0
  13. package/dist/chunks/DevChannelsDialog-BljR0X9X.js +1 -0
  14. package/dist/chunks/Dialog-DYFGqyDs.js +1 -0
  15. package/dist/chunks/DiffDialog-BhQ2QaLW.js +3 -0
  16. package/dist/chunks/Doctor-BXb0qv6n.js +3 -0
  17. package/dist/chunks/Doctor-C5DYPEGl.js +1 -0
  18. package/dist/chunks/ExitFlow-CSBDxw9H.js +2 -0
  19. package/dist/chunks/Feedback-DwHzc4UT.js +2 -0
  20. package/dist/chunks/Grove-DSXRnXKv.js +11 -0
  21. package/dist/chunks/Grove-DnTo982-.js +1 -0
  22. package/dist/chunks/HybridTransport-CuT3KI5e.js +4 -0
  23. package/dist/chunks/ITermBackend-mokGZVH_.js +1 -0
  24. package/dist/chunks/InProcessTransport-DB52dh4f.js +1 -0
  25. package/dist/chunks/InvalidConfigDialog-Bi4RKYlk.js +1 -0
  26. package/dist/chunks/InvalidSettingsDialog-0zKo4-so.js +1 -0
  27. package/dist/chunks/ListItem-OFARanN7.js +1 -0
  28. package/dist/chunks/MCPConnectionManager-DYGoS1Ht.js +1 -0
  29. package/dist/chunks/McpParsingWarnings-EzgsOoHw.js +1 -0
  30. package/dist/chunks/MessageSelector-DTmUuEKJ.js +3 -0
  31. package/dist/chunks/Messages-DWiKTx5o.js +11 -0
  32. package/dist/chunks/Onboarding-odmthwzz.js +1 -0
  33. package/dist/chunks/OverageCreditUpsell-Cpk_5Lv0.js +1 -0
  34. package/dist/chunks/PermissionDialog-5MlJf7ew.js +1 -0
  35. package/dist/chunks/PluginSettings-eYcWehI8.js +17 -0
  36. package/dist/chunks/PressEnterToContinue-BdA9zDGs.js +1 -0
  37. package/dist/chunks/PromptInputFooterSuggestions-DrrkNOuS.js +1 -0
  38. package/dist/chunks/PromptInputHelpMenu-DMsF4D6d.js +1 -0
  39. package/dist/chunks/QueryEngine-C_KZts4y.js +1 -0
  40. package/dist/chunks/REPL-C6YR0VKU.js +1 -0
  41. package/dist/chunks/REPL-DzHz-LOY.js +97 -0
  42. package/dist/chunks/RemoteCallout-CnpCWRPk.js +1 -0
  43. package/dist/chunks/RemoteSessionManager-OWg_Yccq.js +2 -0
  44. package/dist/chunks/ResumeConversation-BktSnsCm.js +1 -0
  45. package/dist/chunks/SSETransport-BpnapvlK.js +4 -0
  46. package/dist/chunks/SearchBox-DfOmUoaI.js +1 -0
  47. package/dist/chunks/SearchExtraToolsTool-CqFD8vVS.js +1 -0
  48. package/dist/chunks/SentryErrorBoundary-BUirJRWU.js +1 -0
  49. package/dist/chunks/SentryErrorBoundary-C-NlfQZw.js +2 -0
  50. package/dist/chunks/Settings-vfFvcweR.js +2 -0
  51. package/dist/chunks/TeleportProgress-CYXay2ZL.js +1 -0
  52. package/dist/chunks/TeleportRepoMismatchDialog-_zbZTvcJ.js +1 -0
  53. package/dist/chunks/TeleportResumeWrapper-DiHQeZIM.js +1 -0
  54. package/dist/chunks/ThemePicker-BRh027fA.js +1 -0
  55. package/dist/chunks/TmuxBackend-BaX2U7iZ.js +9 -0
  56. package/dist/chunks/TrustDialog-CVbzrv6g.js +1 -0
  57. package/dist/chunks/TungstenTool-C5IqKVr0.js +1 -0
  58. package/dist/chunks/TungstenTool-V-Bwqlx3.js +1 -0
  59. package/dist/chunks/ValidationErrorsList-CdCUgfIl.js +2 -0
  60. package/dist/chunks/WelcomeV2-DCXcYd2x.js +1 -0
  61. package/dist/chunks/WindowsTerminalBackend-BE9NX5IH.js +2 -0
  62. package/dist/chunks/add-dir-ldGd3Ppz.js +1 -0
  63. package/dist/chunks/agentDisplay-CVnAeURF.js +1 -0
  64. package/dist/chunks/agents-C08NzRZx.js +2 -0
  65. package/dist/chunks/agents-DH5fmbVw.js +103 -0
  66. package/dist/chunks/ajv-B_OpU_Uh.js +8 -0
  67. package/dist/chunks/analytics-DqMQntaB.js +1 -0
  68. package/dist/chunks/ant-DJren1Aa.js +1 -0
  69. package/dist/chunks/api-6tcwJlf_.js +1 -0
  70. package/dist/chunks/api-CGOR_Xfl.js +1 -0
  71. package/dist/chunks/asciicast-aoKFhc7C.js +1 -0
  72. package/dist/chunks/asciicast-o5Zg4dJt.js +4 -0
  73. package/dist/chunks/assistant-BlzrMSkM.js +1 -0
  74. package/dist/chunks/assistant-CwbhlCM-.js +1 -0
  75. package/dist/chunks/assistant-aWkDcurV.js +1 -0
  76. package/dist/chunks/attributionHooks-PygdohOh.js +1 -0
  77. package/dist/chunks/attributionTrailer-BpvhXgRP.js +1 -0
  78. package/dist/chunks/auth-CSB2RDKF.js +1 -0
  79. package/dist/chunks/auth-GxZhOvQ1.js +1 -0
  80. package/dist/chunks/autoMode-CWvZs1jO.js +45 -0
  81. package/dist/chunks/autoModeDenials-Cp6VFdsm.js +1 -0
  82. package/dist/chunks/autonomy-BkVcSMCZ.js +19 -0
  83. package/dist/chunks/autonomy-DK42aJYt.js +1 -0
  84. package/dist/chunks/autonomyPanel-Cn4IhXgE.js +1 -0
  85. package/dist/chunks/axios-DLnc2dVy.js +1 -0
  86. package/dist/chunks/axios-DhfaybwJ.js +12 -0
  87. package/dist/chunks/backgroundHousekeeping-BIZTAYho.js +17 -0
  88. package/dist/chunks/backgroundHousekeeping-Csh58CxV.js +1 -0
  89. package/dist/chunks/banner-CVXH2xts.js +2 -0
  90. package/dist/chunks/base64-js-DIVSFswY.js +1 -0
  91. package/dist/chunks/bedrockClient-qi1-JCOK.js +15 -0
  92. package/dist/chunks/bg-DK0E4ZtW.js +9 -0
  93. package/dist/chunks/bg-Dbh5z3Y8.js +1 -0
  94. package/dist/chunks/branch-juox_fko.js +3 -0
  95. package/dist/chunks/break-cache-ByJ7U2Ts.js +8 -0
  96. package/dist/chunks/bridge-DudsCZkh.js +2 -0
  97. package/dist/chunks/bridgeConfig-D4tpc568.js +1 -0
  98. package/dist/chunks/bridgeConfig-lRZfQqmA.js +1 -0
  99. package/dist/chunks/bridgeEnabled-B8_c_Ppq.js +1 -0
  100. package/dist/chunks/bridgeEnabled-D2IykaHE.js +1 -0
  101. package/dist/chunks/bridgeMain-C5RDihlX.js +68 -0
  102. package/dist/chunks/bridgeMain-D7_lg2iJ.js +1 -0
  103. package/dist/chunks/bridgeMessaging-CqNURC4-.js +1 -0
  104. package/dist/chunks/bridgePointer-FvAMj3re.js +1 -0
  105. package/dist/chunks/browser-fLRXxIsQ.js +1 -0
  106. package/dist/chunks/btw-DKlE3Dea.js +1 -0
  107. package/dist/chunks/buddy-DQYgHR63.js +3 -0
  108. package/dist/chunks/bundledMode-kSQejuY4.js +1 -0
  109. package/dist/chunks/bypassPermissionsKillswitch-Bof-UtM-.js +1 -0
  110. package/dist/chunks/caches-B5QZDncQ.js +3 -0
  111. package/dist/chunks/caches-dGk7xsDu.js +1 -0
  112. package/dist/chunks/capacityWake-BXlUpptF.js +1 -0
  113. package/dist/chunks/ccrClient-BaWg4E9-.js +1 -0
  114. package/dist/chunks/ccshareResume-DWLjTF22.js +1 -0
  115. package/dist/chunks/changeDetector-DoLfg8a6.js +1 -0
  116. package/dist/chunks/channelNotification-B7A-9DIl.js +1 -0
  117. package/dist/chunks/channelNotification-DDErroWn.js +1 -0
  118. package/dist/chunks/chokidar-BcI3rIKm.js +1 -0
  119. package/dist/chunks/chokidar-SzksMqYp.js +1 -0
  120. package/dist/chunks/chrome-jMAks7-w.js +1 -0
  121. package/dist/chunks/chromeNativeHost-4U39yLtd.js +1 -0
  122. package/dist/chunks/chunk-DR8-3Aex.js +1 -0
  123. package/dist/chunks/classPrivateFieldSet2-EAQNhHs8.js +1 -0
  124. package/dist/chunks/claudeDesktop-D0S1eq1F.js +1 -0
  125. package/dist/chunks/cleanup-Bg_gFgcj.js +1 -0
  126. package/dist/chunks/clear-OudnCGa7.js +1 -0
  127. package/dist/chunks/cliLaunch-BQa48gsr.js +1 -0
  128. package/dist/chunks/client-CPn1wQyc.js +7 -0
  129. package/dist/chunks/client-DxDmXXTh.js +1 -0
  130. package/dist/chunks/client-_sjL0I7A.js +35 -0
  131. package/dist/chunks/color-DG_R5-hl.js +1 -0
  132. package/dist/chunks/color-convert-ULbeSgNC.js +1 -0
  133. package/dist/chunks/commands-BWIOEBPs.js +1 -0
  134. package/dist/chunks/commitAttribution-BA4fcbHf.js +1 -0
  135. package/dist/chunks/commitAttribution-C22a3OCi.js +2 -0
  136. package/dist/chunks/common-B379wT22.js +1 -0
  137. package/dist/chunks/common-B_BC3eMY.js +1 -0
  138. package/dist/chunks/common-CMCv4N_v.js +1 -0
  139. package/dist/chunks/compact-BWvnb4or.js +3 -0
  140. package/dist/chunks/companion-Bkn2lSLj.js +1 -0
  141. package/dist/chunks/completionCache-DHfUBBMH.js +1 -0
  142. package/dist/chunks/completionCache-DORrtxkS.js +4 -0
  143. package/dist/chunks/computerUseLock-BjoDJH2h.js +1 -0
  144. package/dist/chunks/config-BvpTbJ5p.js +1 -0
  145. package/dist/chunks/config-D-dzD6n-.js +1 -0
  146. package/dist/chunks/connectHeadless-CwsFt-Mh.js +1 -0
  147. package/dist/chunks/constants-41VpZw2G.js +1 -0
  148. package/dist/chunks/context-DzNahdyP.js +1 -0
  149. package/dist/chunks/context-noninteractive-CM1-lUSe.js +1 -0
  150. package/dist/chunks/context-noninteractive-yiyJriiw.js +54 -0
  151. package/dist/chunks/controlMessageCompat-BJhFiS7u.js +1 -0
  152. package/dist/chunks/conversation-DKlz47xf.js +1 -0
  153. package/dist/chunks/conversation-cUxdb8MN.js +1 -0
  154. package/dist/chunks/copy-9k9JPRqW.js +7 -0
  155. package/dist/chunks/createSSHSession-BZf-Loo5.js +6 -0
  156. package/dist/chunks/createSession-BuJcoBAj.js +1 -0
  157. package/dist/chunks/createSession-kiTHYXSL.js +1 -0
  158. package/dist/chunks/cron-DiW7eIPP.js +1 -0
  159. package/dist/chunks/cronJitterConfig-CYP7yrQu.js +6 -0
  160. package/dist/chunks/crossProjectResume-BJisir9Z.js +40 -0
  161. package/dist/chunks/cwd--iizewsn.js +1 -0
  162. package/dist/chunks/cwd-BgpSJxd7.js +1 -0
  163. package/dist/chunks/daemon-VYRit6Aq.js +2 -0
  164. package/dist/chunks/dangerousBackend-BU_PHGR2.js +1 -0
  165. package/dist/chunks/datadog-Bg-zL-i7.js +1 -0
  166. package/dist/chunks/datadog-CVeFkaQu.js +1 -0
  167. package/dist/chunks/debug-DM5ezCBS.js +1 -0
  168. package/dist/chunks/debug-UI3T040K.js +5 -0
  169. package/dist/chunks/debugUtils-BBMFODKH.js +1 -0
  170. package/dist/chunks/defineProperty-80gRi2ZW.js +1 -0
  171. package/dist/chunks/desktop-DpaStjc-.js +1 -0
  172. package/dist/chunks/detached-D300jlhj.js +5 -0
  173. package/dist/chunks/detect-libc-DNuQfUvI.js +1 -0
  174. package/dist/chunks/detectRepository-CBk3S2zv.js +1 -0
  175. package/dist/chunks/detectRepository-DCTvg4p0.js +1 -0
  176. package/dist/chunks/detection-CQsNad64.js +1 -0
  177. package/dist/chunks/detection-DJ-vTbBf.js +1 -0
  178. package/dist/chunks/diff-N_VSBo3Z.js +1 -0
  179. package/dist/chunks/directoryCompletion-DP_4B1GL.js +1 -0
  180. package/dist/chunks/dist-CanSxOZ1.js +5 -0
  181. package/dist/chunks/dist-Cg1a1Exw.js +29 -0
  182. package/dist/chunks/dist-Q7YNoZ0H.js +20 -0
  183. package/dist/chunks/dist-es-4z5T3Jzm.js +1 -0
  184. package/dist/chunks/dist-es-B2jg52tM2.js +1 -0
  185. package/dist/chunks/dist-es-B6OXHQ1S.js +1 -0
  186. package/dist/chunks/dist-es-B8NEy5hc.js +1 -0
  187. package/dist/chunks/dist-es-BVGppqE4.js +1 -0
  188. package/dist/chunks/dist-es-Bcw5GZko.js +1 -0
  189. package/dist/chunks/dist-es-BoIJpncb.js +9 -0
  190. package/dist/chunks/dist-es-Bu_Fshi1.js +1 -0
  191. package/dist/chunks/dist-es-C-1vn4OP2.js +1 -0
  192. package/dist/chunks/dist-es-C41b_0B5.js +1 -0
  193. package/dist/chunks/dist-es-CCZYybbG2.js +1 -0
  194. package/dist/chunks/dist-es-CLK1mey-.js +1 -0
  195. package/dist/chunks/dist-es-CQz2aNf72.js +1 -0
  196. package/dist/chunks/dist-es-CSfI8B8l.js +1 -0
  197. package/dist/chunks/dist-es-CUZBYppo.js +1 -0
  198. package/dist/chunks/dist-es-CZkzHpjF.js +1 -0
  199. package/dist/chunks/dist-es-Cbf0_D8d.js +5 -0
  200. package/dist/chunks/dist-es-ChHe-SVL.js +1 -0
  201. package/dist/chunks/dist-es-ClYOf0My.js +1 -0
  202. package/dist/chunks/dist-es-D-kJbj4A2.js +1 -0
  203. package/dist/chunks/dist-es-D1LN6CJd.js +1 -0
  204. package/dist/chunks/dist-es-DC1sC3ph.js +1 -0
  205. package/dist/chunks/dist-es-DGn8uOwQ2.js +1 -0
  206. package/dist/chunks/dist-es-DK5fTeKM2.js +1 -0
  207. package/dist/chunks/dist-es-DN7otr6F.js +1 -0
  208. package/dist/chunks/dist-es-DPM0mPK5.js +1 -0
  209. package/dist/chunks/dist-es-DqZAh3nG.js +1 -0
  210. package/dist/chunks/dist-es-DuAZyxJ02.js +5 -0
  211. package/dist/chunks/dist-es-HVQrM0oE.js +1 -0
  212. package/dist/chunks/dist-es-OVleIB54.js +1 -0
  213. package/dist/chunks/dist-es-UAs0rdXg.js +1 -0
  214. package/dist/chunks/dist-es-WvMMuHmx2.js +1 -0
  215. package/dist/chunks/dist-es-fjXft-jH.js +1 -0
  216. package/dist/chunks/dist-es-hdN_ShpZ.js +3 -0
  217. package/dist/chunks/dist-es-neiUvMJb.js +1 -0
  218. package/dist/chunks/dist-es-yMYpDtui2.js +1 -0
  219. package/dist/chunks/dist-es-zjcbuB72.js +1 -0
  220. package/dist/chunks/distRoot-CcxmnzqQ.js +1 -0
  221. package/dist/chunks/doctor-CUWjbh1X.js +1 -0
  222. package/dist/chunks/earlyInput-JGJo1zcC.js +1 -0
  223. package/dist/chunks/earlyInput-tRkbxFv2.js +2 -0
  224. package/dist/chunks/effort-loH1TUvE.js +9 -0
  225. package/dist/chunks/entry-D58E-E6Y.js +14 -0
  226. package/dist/chunks/env-chR0gV31.js +1 -0
  227. package/dist/chunks/envLessBridgeConfig-CT8sdmFu.js +1 -0
  228. package/dist/chunks/envLessBridgeConfig-SPEr9oqO.js +1 -0
  229. package/dist/chunks/envUtils-BWeoiL4Y.js +1 -0
  230. package/dist/chunks/escHotkey-Cyz0yyh1.js +259 -0
  231. package/dist/chunks/esm--xjzB1hI.js +1 -0
  232. package/dist/chunks/esm-B2HIF0XY.js +1 -0
  233. package/dist/chunks/esm-BGQPWnJy.js +1 -0
  234. package/dist/chunks/esm-C-1qL9Mn.js +1 -0
  235. package/dist/chunks/esm-C3jcs1DH.js +1 -0
  236. package/dist/chunks/esm-C97WL9nC.js +1 -0
  237. package/dist/chunks/esm-CIL-SKM8.js +1 -0
  238. package/dist/chunks/esm-CJlBxjtx.js +1 -0
  239. package/dist/chunks/esm-CsGLyWmS.js +56 -0
  240. package/dist/chunks/esm-DQHmDm-H.js +1 -0
  241. package/dist/chunks/esm-DcdOXSzi.js +1 -0
  242. package/dist/chunks/esm-DhNYgGTV.js +1 -0
  243. package/dist/chunks/esm-DxPW7qPs.js +1 -0
  244. package/dist/chunks/esm-FBUWr3vI.js +1 -0
  245. package/dist/chunks/esm-QgL6y---.js +10 -0
  246. package/dist/chunks/esm-v0kPjgVS.js +1 -0
  247. package/dist/chunks/esm-vIn-YV_h.js +1 -0
  248. package/dist/chunks/event-streams-BV7ngMXu.js +1 -0
  249. package/dist/chunks/eventLoopStallDetector-Dnh1fc31.js +1 -0
  250. package/dist/chunks/execAsync-BkA6ogic.js +1 -0
  251. package/dist/chunks/execFileNoThrow-CuQN1sz8.js +1 -0
  252. package/dist/chunks/execSyncWrapper-C2XQnFVo.js +1 -0
  253. package/dist/chunks/execa-CGue6Z3n.js +34 -0
  254. package/dist/chunks/executor-4EeD8GNm.js +1561 -0
  255. package/dist/chunks/executor-BHEuNh5F.js +1 -0
  256. package/dist/chunks/exit-D-tuPpbx.js +1 -0
  257. package/dist/chunks/exit-_obETqBv.js +2 -0
  258. package/dist/chunks/export-BIZ_SPXJ.js +2 -0
  259. package/dist/chunks/exportRenderer-CWPSMaqM.js +1 -0
  260. package/dist/chunks/extra-usage-CCMwIa85.js +1 -0
  261. package/dist/chunks/extra-usage-core-BNW4VT7o.js +1 -0
  262. package/dist/chunks/extra-usage-noninteractive-B_WjXO1E.js +1 -0
  263. package/dist/chunks/extra-usage-rdJ7ecEb.js +1 -0
  264. package/dist/chunks/extraUsage-CNMMTNJi.js +1 -0
  265. package/dist/chunks/extractMemories-BrvZVsmM.js +1 -0
  266. package/dist/chunks/fast-CG1v3fRr.js +1 -0
  267. package/dist/chunks/fast-CLKKsx2H.js +1 -0
  268. package/dist/chunks/featureCheck-Cm0YNDXO.js +1 -0
  269. package/dist/chunks/featureCheck-p7OeCYzj.js +1 -0
  270. package/dist/chunks/feedback-CG4mS_-B.js +1 -0
  271. package/dist/chunks/figures-gfT9mM8P.js +1 -0
  272. package/dist/chunks/fileStateCache-C7-TxF8G.js +1 -0
  273. package/dist/chunks/files-DYvAZGxp.js +2 -0
  274. package/dist/chunks/firstPartyEventLogger-Y_jAnHoR.js +1 -0
  275. package/dist/chunks/flushGate-COPcye5f.js +1 -0
  276. package/dist/chunks/foundry-sdk-BFN5VDFQ.js +1 -0
  277. package/dist/chunks/fpsMetrics-DeezdcwV.js +1 -0
  278. package/dist/chunks/fuse-Ch_OAlm3.js +1 -0
  279. package/dist/chunks/gates-CSHuXnUx.js +1 -0
  280. package/dist/chunks/gates-CSKxLmMJ.js +1 -0
  281. package/dist/chunks/gemini-B3uSLiNp.js +1 -0
  282. package/dist/chunks/generateRecap-D7rG3jIm.js +1 -0
  283. package/dist/chunks/generateSessionName-zbqanivg.js +1 -0
  284. package/dist/chunks/genericProcessUtils-BGvcwuPt.js +23 -0
  285. package/dist/chunks/getMachineId-bsd-BMtYGBUL.js +1 -0
  286. package/dist/chunks/getMachineId-darwin-CiLdFH7z.js +2 -0
  287. package/dist/chunks/getMachineId-linux-Cr27rIeY.js +1 -0
  288. package/dist/chunks/getMachineId-unsupported-ceiBLwAN.js +1 -0
  289. package/dist/chunks/getMachineId-win-DFTmsQHq.js +1 -0
  290. package/dist/chunks/git-CN3qtTb_.js +6 -0
  291. package/dist/chunks/git-D23Mzu_K.js +1 -0
  292. package/dist/chunks/githubRepoPathMapping-B04nEUDG.js +1 -0
  293. package/dist/chunks/graceful-fs-Cgc0rjGF.js +2 -0
  294. package/dist/chunks/grok-CDOpos8E.js +1 -0
  295. package/dist/chunks/growthbook-C_EY78Sn.js +1 -0
  296. package/dist/chunks/hash-BRmOQc3c.js +1 -0
  297. package/dist/chunks/heapdump-CpmhJ55b.js +5 -0
  298. package/dist/chunks/help-EHn2neTv.js +1 -0
  299. package/dist/chunks/hooks-BFdX17Za.js +1 -0
  300. package/dist/chunks/hooks-BV6HqbU4.js +79 -0
  301. package/dist/chunks/hostAdapter-_SmFAVNf.js +1 -0
  302. package/dist/chunks/hostGuard-zim_4F9V.js +1 -0
  303. package/dist/chunks/httpAuthSchemes-Wq4XWeLL.js +13 -0
  304. package/dist/chunks/ide-DkN0KdTR.js +2 -0
  305. package/dist/chunks/inboundAttachments-BVUunfAX.js +1 -0
  306. package/dist/chunks/inboundAttachments-DnGQw7Pf.js +1 -0
  307. package/dist/chunks/index.min-BJnb9GQI.js +1 -0
  308. package/dist/chunks/initReplBridge-tPRGPBq7.js +1 -0
  309. package/dist/chunks/insights-Bs9kJDG6.js +822 -0
  310. package/dist/chunks/install-CFX_ph9z.js +1 -0
  311. package/dist/chunks/install-github-app-CvRjY1Wi.js +147 -0
  312. package/dist/chunks/install-slack-app-DjhnVSe0.js +1 -0
  313. package/dist/chunks/instinctParser-DHMa8xa0.js +1 -0
  314. package/dist/chunks/instrumentation-c5zlOWom.js +12 -0
  315. package/dist/chunks/intl-Pse97ORk.js +1 -0
  316. package/dist/chunks/isObject-DaxDnPKm.js +1 -0
  317. package/dist/chunks/isSymbol-Dp3irZaY.js +1 -0
  318. package/dist/chunks/job-3QwLq609.js +2 -0
  319. package/dist/chunks/json-bigint-OxRwRvup.js +8 -0
  320. package/dist/chunks/jsx-runtime-D-D469L8.js +1 -0
  321. package/dist/chunks/jws-2vqRyZtR.js +3 -0
  322. package/dist/chunks/jwtUtils-CpXwh_du.js +1 -0
  323. package/dist/chunks/keybindings-7mDm3UKD.js +2 -0
  324. package/dist/chunks/lang-DyyjY20G.js +1 -0
  325. package/dist/chunks/language-CPRGmY8Q.js +1 -0
  326. package/dist/chunks/language-Cf6bMI4N.js +1 -0
  327. package/dist/chunks/launchAgentsPlatform-CpsMsTqQ.js +1 -0
  328. package/dist/chunks/launchAutofixPr-D9h6YAZY.js +2 -0
  329. package/dist/chunks/launchCommand-Du91jxMC.js +1 -0
  330. package/dist/chunks/launchLocalMemory-DlYQcEQJ.js +3 -0
  331. package/dist/chunks/launchLocalVault-CP0AyPjj.js +3 -0
  332. package/dist/chunks/launchMemoryStores-BHoDFkJ5.js +1 -0
  333. package/dist/chunks/launchOnboarding-CFTNXcnc.js +8 -0
  334. package/dist/chunks/launchSchedule-5KQr6x_A.js +1 -0
  335. package/dist/chunks/launchSkillStore-D0yGuE68.js +1 -0
  336. package/dist/chunks/launchTeleport-DRKnXOwY.js +3 -0
  337. package/dist/chunks/launchVault-XA-zAswX.js +1 -0
  338. package/dist/chunks/lazySchema-2sOku3cX.js +1 -0
  339. package/dist/chunks/lib-B4Q0Nrpb.js +14 -0
  340. package/dist/chunks/lib-Ca3QWJjN.js +2 -0
  341. package/dist/chunks/lib-inCisXen.js +8 -0
  342. package/dist/chunks/loadAgentsDir-DCyiY0MN.js +1 -0
  343. package/dist/chunks/loadAgentsDir-DI1a76pd.js +4601 -0
  344. package/dist/chunks/loadPluginHooks-C0Ei-0E2.js +1 -0
  345. package/dist/chunks/loadSso-sDs471GC.js +1 -0
  346. package/dist/chunks/localSearch-CDOJNc_E.js +1 -0
  347. package/dist/chunks/localSearch-MBx7KzC2.js +1 -0
  348. package/dist/chunks/lockfile-DBwdlC3K.js +1 -0
  349. package/dist/chunks/log-CzsijfHZ.js +1 -0
  350. package/dist/chunks/login-D8UKKaud.js +1 -0
  351. package/dist/chunks/login-nwTOoyxv.js +1 -0
  352. package/dist/chunks/logoV2Utils-DDUoPClc.js +1 -0
  353. package/dist/chunks/logout-B0BjqlGi.js +1 -0
  354. package/dist/chunks/magicDocs-CmUlOWjI.js +57 -0
  355. package/dist/chunks/main-C6be1KFk.js +31 -0
  356. package/dist/chunks/main-CeG_nUsC.js +1108 -0
  357. package/dist/chunks/mappers-CJ8IO1o1.js +1 -0
  358. package/dist/chunks/mcp-CanCqnch.js +2 -0
  359. package/dist/chunks/mcp-Dq0kxZFx.js +6 -0
  360. package/dist/chunks/mcp-zbxZM9BP.js +1 -0
  361. package/dist/chunks/mcpServer-DPHQVYdC.js +1 -0
  362. package/dist/chunks/mcpServer-lIneUZ5p.js +1 -0
  363. package/dist/chunks/memoize-DNnuA2aU.js +1 -0
  364. package/dist/chunks/memoize-DxwLawI2.js +1 -0
  365. package/dist/chunks/memory-BcWBkKV8.js +1 -0
  366. package/dist/chunks/mobile-umu5P0cM.js +2 -0
  367. package/dist/chunks/modalContext-CmSKRyea.js +1 -0
  368. package/dist/chunks/model-DJLzVvcF.js +1 -0
  369. package/dist/chunks/model-H3rtl6eR.js +1 -0
  370. package/dist/chunks/normalization-Cox8C0dP.js +1 -0
  371. package/dist/chunks/oauth-CdZEzMww.js +1 -0
  372. package/dist/chunks/oauth-CmensepG.js +1 -0
  373. package/dist/chunks/observationStore-tvkldXUo.js +4 -0
  374. package/dist/chunks/onChangeAppState-Dxbl8fvk.js +1 -0
  375. package/dist/chunks/open-CDditBQ-.js +1 -0
  376. package/dist/chunks/openai-DkYK4THc.js +10 -0
  377. package/dist/chunks/openaiShared-D5lOejS1.js +16 -0
  378. package/dist/chunks/output-style-XDb9-2Kk.js +1 -0
  379. package/dist/chunks/overageCreditGrant-DLKadMYU.js +1 -0
  380. package/dist/chunks/p-map-9Ud1LOrJ.js +1 -0
  381. package/dist/chunks/p-map-D7WEmnBE.js +1 -0
  382. package/dist/chunks/package-BhL7chzt.js +1 -0
  383. package/dist/chunks/panel-ByW1omJn.js +1 -0
  384. package/dist/chunks/panel-Bz_8td5D.js +1 -0
  385. package/dist/chunks/parseConnectUrl-BS6i9JPo.js +1 -0
  386. package/dist/chunks/parser-CmngCwjB.js +1 -0
  387. package/dist/chunks/parser-SWIZo39J.js +1 -0
  388. package/dist/chunks/passes-BIfuerjL.js +1 -0
  389. package/dist/chunks/path-C4kbwvSH.js +1 -0
  390. package/dist/chunks/paths-BBvuDQl9.js +39 -0
  391. package/dist/chunks/permissions-DXLfdE7b.js +1 -0
  392. package/dist/chunks/permissions-Ps_D01ZB.js +1 -0
  393. package/dist/chunks/permissions-S2EvIRKj.js +3 -0
  394. package/dist/chunks/pipeTransport-DVoIA1uN.js +1 -0
  395. package/dist/chunks/plan--lnWxB3Q.js +1 -0
  396. package/dist/chunks/platform-CuyedWpe.js +2 -0
  397. package/dist/chunks/plist-BO4ZqMZc.js +6 -0
  398. package/dist/chunks/plugin-DWLyrLw4.js +1 -0
  399. package/dist/chunks/pluginAutoupdate-CGXIWBrb.js +1 -0
  400. package/dist/chunks/pluginBlocklist-DJrMdzT0.js +1 -0
  401. package/dist/chunks/pluginCliCommands-C08q9dHk.js +1 -0
  402. package/dist/chunks/pluginFlagging-Dggxke70.js +1 -0
  403. package/dist/chunks/pluginOperations-CNCImIe8.js +2 -0
  404. package/dist/chunks/pluginStartupCheck-BW2fjg2P.js +1 -0
  405. package/dist/chunks/pluginStartupCheck-DpxQPXJE.js +1 -0
  406. package/dist/chunks/plugins-DQ3CRWWO.js +4 -0
  407. package/dist/chunks/policyLimits-BotYrS-v.js +1 -0
  408. package/dist/chunks/pollConfig-DAQ-ives.js +1 -0
  409. package/dist/chunks/poller-Ds0Y6Cir.js +1 -0
  410. package/dist/chunks/poor-DqfrQT61.js +1 -0
  411. package/dist/chunks/poorMode-DEAe3hiK.js +1 -0
  412. package/dist/chunks/poorMode-DzYT47KW.js +1 -0
  413. package/dist/chunks/postCommitAttribution-Ehmwzzuq.js +1 -0
  414. package/dist/chunks/print-GGVp62vj.js +39 -0
  415. package/dist/chunks/privacy-settings-agwqjYJo.js +1 -0
  416. package/dist/chunks/process-CWupreF6.js +1 -0
  417. package/dist/chunks/process-DMKLUQIO.js +1 -0
  418. package/dist/chunks/processBashCommand-DHHN8Ca4.js +1 -0
  419. package/dist/chunks/processSlashCommand-COtIO6Jy.js +6 -0
  420. package/dist/chunks/projectContext-0fpRKUeH.js +1 -0
  421. package/dist/chunks/projectContext-eXMSfgdZ.js +1 -0
  422. package/dist/chunks/prompt-4tea6NJQ.js +54 -0
  423. package/dist/chunks/prompt-CO160cIr.js +1 -0
  424. package/dist/chunks/prompt-CjFAtm3w.js +222 -0
  425. package/dist/chunks/prompt-GY9hlRvI.js +1 -0
  426. package/dist/chunks/promptEditor-EgosPsy-.js +4 -0
  427. package/dist/chunks/protocolHandler-mtPUT9U0.js +13 -0
  428. package/dist/chunks/protocols-CAyQOlkr.js +7 -0
  429. package/dist/chunks/proxy-CfZp-wce.js +99 -0
  430. package/dist/chunks/rate-limit-options-C6SFOHue.js +1 -0
  431. package/dist/chunks/rcDebugLog-CPKZCtR8.js +11 -0
  432. package/dist/chunks/referral-DeDr9zAE.js +1 -0
  433. package/dist/chunks/refresh-D7pdoY_X.js +1 -0
  434. package/dist/chunks/registerProtocol-BZBH8Zgl.js +36 -0
  435. package/dist/chunks/registry-Dz6AbiYP.js +1 -0
  436. package/dist/chunks/release-notes-DiUNOrg9.js +4 -0
  437. package/dist/chunks/releaseNotes-CnhQit0y.js +2 -0
  438. package/dist/chunks/reload-plugins-Dx52GcaG.js +1 -0
  439. package/dist/chunks/remote-env-B67Oo3sI.js +1 -0
  440. package/dist/chunks/remoteBridgeCore-BzSUgPbt.js +1 -0
  441. package/dist/chunks/remoteControlServer-L8smP7Zu.js +3 -0
  442. package/dist/chunks/rename-C4PauyTZ.js +1 -0
  443. package/dist/chunks/renderOptions-BiyC2rj1.js +1 -0
  444. package/dist/chunks/resume-CrSn26xq.js +2 -0
  445. package/dist/chunks/rewind-CXplHgh_.js +1 -0
  446. package/dist/chunks/rollback-DbSpxmJE.js +11 -0
  447. package/dist/chunks/runtimeObserver-YNy3mIb7.js +1 -0
  448. package/dist/chunks/runtimeObserver-nAhH4Wca.js +10 -0
  449. package/dist/chunks/sandbox-adapter-CzwHes1i.js +1 -0
  450. package/dist/chunks/sandbox-toggle-BYqbcI5d.js +1 -0
  451. package/dist/chunks/sanitization-CYp-9DbE.js +1 -0
  452. package/dist/chunks/satisfies-BaHgd_ie.js +1 -0
  453. package/dist/chunks/schemas-BGAvj1T4.js +40 -0
  454. package/dist/chunks/sdk-DEtgRZvI.js +1 -0
  455. package/dist/chunks/sdkHeapDumpMonitor--fevrC5z.js +1 -0
  456. package/dist/chunks/searchExtraTools-CcpdCO6l.js +1 -0
  457. package/dist/chunks/semver-Cq33BYay.js +1 -0
  458. package/dist/chunks/semver-Tw0AFar5.js +1 -0
  459. package/dist/chunks/sentry-BNVxoVLS.js +13 -0
  460. package/dist/chunks/server-C5XZSlto.js +1 -0
  461. package/dist/chunks/server-DzOdtq8A.js +1 -0
  462. package/dist/chunks/serverBanner-WlSYP-f8.js +1 -0
  463. package/dist/chunks/serverLog-DtsUvDiY.js +1 -0
  464. package/dist/chunks/session-BuEmHrqM.js +2 -0
  465. package/dist/chunks/sessionDataUploader-Ctjo1bgR.js +1 -0
  466. package/dist/chunks/sessionDiscovery-Mcsfa0g-.js +1 -0
  467. package/dist/chunks/sessionFileAccessHooks-qnNiGMnE.js +1 -0
  468. package/dist/chunks/sessionManager-Dw72ZUTg.js +1 -0
  469. package/dist/chunks/sessionMemory-CMahwDdW.js +1 -0
  470. package/dist/chunks/sessionMemory-pFSn4HSN.js +1 -0
  471. package/dist/chunks/sessionMemoryUtils-Du5jUl7M.js +1 -0
  472. package/dist/chunks/sessionObserver-DG2zQgfi.js +20 -0
  473. package/dist/chunks/sessionObserver-Je868MC9.js +1 -0
  474. package/dist/chunks/sessionStorage-D3FhAADV.js +1 -0
  475. package/dist/chunks/sessionStoragePortable-BI9q2WcJ.js +3 -0
  476. package/dist/chunks/sessionTitle-zUVSAHO7.js +14 -0
  477. package/dist/chunks/sessionTracing-DoRJ4nSa.js +11 -0
  478. package/dist/chunks/settingsSync-B9bz77E1.js +1 -0
  479. package/dist/chunks/setup-B1JbPepL.js +9 -0
  480. package/dist/chunks/setup-CCOLlRtP.js +1 -0
  481. package/dist/chunks/setup-DWkSjA49.js +2 -0
  482. package/dist/chunks/shadowedRuleDetection-BBR3uEgx.js +1 -0
  483. package/dist/chunks/shellQuote-DgjT8KBA.js +1 -0
  484. package/dist/chunks/sideQuestion-DHW5rgKz.js +20 -0
  485. package/dist/chunks/signin-QEeYpJZw.js +1 -0
  486. package/dist/chunks/sink-DxDOsLa2.js +1 -0
  487. package/dist/chunks/sink-cQOgsnw3.js +1 -0
  488. package/dist/chunks/sinks-BrrTUxkC.js +2 -0
  489. package/dist/chunks/sinks-Djiz_5-Z.js +1 -0
  490. package/dist/chunks/skill-learning-C0nOKZfg.js +5 -0
  491. package/dist/chunks/skillChangeDetector-D8C-uQSQ.js +1 -0
  492. package/dist/chunks/skillGapStore-Czi5jKjJ.js +1 -0
  493. package/dist/chunks/skillGapStore-_YuJP5KI.js +5 -0
  494. package/dist/chunks/skillGenerator-kbaRbpqJ.js +8 -0
  495. package/dist/chunks/skillLearning-3KWrBczS.js +1 -0
  496. package/dist/chunks/skillLearning-DBbdGbk-.js +1 -0
  497. package/dist/chunks/skillPanel-BxDvlPzd.js +28 -0
  498. package/dist/chunks/skillSearchPanel-D-MX6Qgt.js +21 -0
  499. package/dist/chunks/skills-NpEgFkFZ.js +1 -0
  500. package/dist/chunks/slashCommandParsing-Cari0pNg.js +1 -0
  501. package/dist/chunks/sleep-8Eb9j_Ly.js +1 -0
  502. package/dist/chunks/sprites-DD4eIkN7.js +1 -0
  503. package/dist/chunks/src-BIPP3_mo.js +26 -0
  504. package/dist/chunks/src-BJz1KAd_.js +6 -0
  505. package/dist/chunks/src-BRAdBA8A.js +1 -0
  506. package/dist/chunks/src-BRC_BuUP.js +1 -0
  507. package/dist/chunks/src-BaB-bpCj.js +5 -0
  508. package/dist/chunks/src-BlLavFUS.js +7 -0
  509. package/dist/chunks/src-C5yhFG0C.js +19 -0
  510. package/dist/chunks/src-CI_jaaBj.js +2 -0
  511. package/dist/chunks/src-CRsA-Z4y.js +1 -0
  512. package/dist/chunks/src-CYLfL70h.js +1 -0
  513. package/dist/chunks/src-DJXCzwyJ.js +1 -0
  514. package/dist/chunks/src-DJXKJavk.js +1 -0
  515. package/dist/chunks/src-Di342QoJ.js +53 -0
  516. package/dist/chunks/src-DsMd9Q9e.js +2 -0
  517. package/dist/chunks/src-DzH9IdOo.js +1 -0
  518. package/dist/chunks/src-hdbPEvzO.js +9 -0
  519. package/dist/chunks/src-poaoYkuc.js +1 -0
  520. package/dist/chunks/src-x7u_sB6m.js +1 -0
  521. package/dist/chunks/sso-oidc-BX1MlBX0.js +1 -0
  522. package/dist/chunks/startupProfiler-DnXZaX4A.js +3 -0
  523. package/dist/chunks/startupProfiler-SOE--nM9.js +1 -0
  524. package/dist/chunks/state-B2GIOsTB.js +1 -0
  525. package/dist/chunks/state-Ce1HlR-H.js +1 -0
  526. package/dist/chunks/state-sIHsFpDu.js +1 -0
  527. package/dist/chunks/staticRender-Br64h1E1.js +1 -0
  528. package/dist/chunks/stats-xL3NHwhp.js +1 -0
  529. package/dist/chunks/status-B5E70xRv.js +1 -0
  530. package/dist/chunks/statusNoticeHelpers-DcssRhLw.js +1 -0
  531. package/dist/chunks/stdio-BEEzuxaZ.js +1 -0
  532. package/dist/chunks/stdio-D4cT86R0.js +3 -0
  533. package/dist/chunks/stickers-2K05wjSp.js +1 -0
  534. package/dist/chunks/store-DhI7Lcan.js +1 -0
  535. package/dist/chunks/sts-BDFJ-6QE.js +1 -0
  536. package/dist/chunks/subprocessEnv-CggQWZCx.js +1 -0
  537. package/dist/chunks/subprocessEnv-DV6q6o6w.js +1 -0
  538. package/dist/chunks/supports-color-lkzOMQ6u.js +1 -0
  539. package/dist/chunks/systemPromptSections-BcN_XBTx.js +1 -0
  540. package/dist/chunks/systemPromptSections-DB93ZNWP.js +1 -0
  541. package/dist/chunks/systemTheme-dDbitcxB.js +1 -0
  542. package/dist/chunks/tag-BELr-qIa.js +11 -0
  543. package/dist/chunks/tasks-CrdWcSt-.js +1 -0
  544. package/dist/chunks/teamHelpers--3ZyNDlv.js +1 -0
  545. package/dist/chunks/teamHelpers-CUAiXng3.js +1 -0
  546. package/dist/chunks/teammate-DMYOtLTK.js +1 -0
  547. package/dist/chunks/teammateModeSnapshot-C6EWhR0X.js +1 -0
  548. package/dist/chunks/teammateModeSnapshot-DOQMTKbQ.js +1 -0
  549. package/dist/chunks/teleport-LXFOan9C.js +1 -0
  550. package/dist/chunks/templateJobs-8IY2Cgig.js +12 -0
  551. package/dist/chunks/terminalSetup-C4psrmpb.js +1 -0
  552. package/dist/chunks/terminalSetup-Lyg4NbGA.js +33 -0
  553. package/dist/chunks/theme-B8GNnJ_q.js +1 -0
  554. package/dist/chunks/thinkback-DPXwEK3B.js +1 -0
  555. package/dist/chunks/thinkback-DZW3Mcx_.js +1 -0
  556. package/dist/chunks/thinkback-play-BMOE-ceh.js +1 -0
  557. package/dist/chunks/tmux-CvbhsfwG.js +1 -0
  558. package/dist/chunks/toolEventObserver-D0TSHm01.js +1 -0
  559. package/dist/chunks/toolEventObserver-DzLd0MSn.js +1 -0
  560. package/dist/chunks/toolPool-DVOfpjDz.js +1 -0
  561. package/dist/chunks/toolPool-Dq-Vtvrj.js +1 -0
  562. package/dist/chunks/trustedDevice-1iTu4LEm.js +1 -0
  563. package/dist/chunks/trustedDevice-BvYYXfd8.js +1 -0
  564. package/dist/chunks/tui-BVc2q4Xv.js +6 -0
  565. package/dist/chunks/turndown.es-Bv06VjMb.js +69 -0
  566. package/dist/chunks/types-CQ1wrnQ0.js +1 -0
  567. package/dist/chunks/types-Csi32ZXh.js +17 -0
  568. package/dist/chunks/types-RJTEOuIt.js +3 -0
  569. package/dist/chunks/udsClient-BvG_Jip0.js +1 -0
  570. package/dist/chunks/ultrareviewCommand-BTXAN2wP.js +3 -0
  571. package/dist/chunks/undercover-C_44e3oN.js +1 -0
  572. package/dist/chunks/undercover-DvvnEmsX.js +31 -0
  573. package/dist/chunks/up-D-U4wUCe.js +12 -0
  574. package/dist/chunks/updateCCB-C-qfLi0j.js +11 -0
  575. package/dist/chunks/upgrade-CGXa5Dwy.js +1 -0
  576. package/dist/chunks/upgrade-DTBZSxwv.js +1 -0
  577. package/dist/chunks/upload-BF8tf_Eo.js +1 -0
  578. package/dist/chunks/upstreamproxy-DcLeL2XX.js +11 -0
  579. package/dist/chunks/usage-BRYRRgNt.js +1 -0
  580. package/dist/chunks/usage-DvSTXEYY.js +1 -0
  581. package/dist/chunks/useKeybinding-FsOnjW6T.js +1 -0
  582. package/dist/chunks/useMainLoopModel-CwvuTRXn.js +1 -0
  583. package/dist/chunks/useManagePlugins-GmnI9K53.js +1 -0
  584. package/dist/chunks/useMergedTools-Dah5KDMi.js +1 -0
  585. package/dist/chunks/useSearchInput-BV_azHiA.js +1 -0
  586. package/dist/chunks/useSettingsErrors-C-j_Zt7g.js +1 -0
  587. package/dist/chunks/useVoice-DR69NLxp.js +1 -0
  588. package/dist/chunks/util-BpyJ4Bom.js +1 -0
  589. package/dist/chunks/utils-CrZcpypC.js +1 -0
  590. package/dist/chunks/v4-f1i_CNUT.js +1 -0
  591. package/dist/chunks/validatePlugin-vptAYuYu.js +1 -0
  592. package/dist/chunks/vertex-sdk-CSGw3fvU.js +9 -0
  593. package/dist/chunks/vim-DvOw8dfR.js +1 -0
  594. package/dist/chunks/voice-B3BZs53f.js +2 -0
  595. package/dist/chunks/voice-DXiiy8HX.js +8 -0
  596. package/dist/chunks/voiceModeEnabled-DA76xN1Q.js +1 -0
  597. package/dist/chunks/voiceModeEnabled-DIveLYGb.js +1 -0
  598. package/dist/chunks/voiceStreamSTT-_w1VjIOs.js +1 -0
  599. package/dist/chunks/voiceStreamSTT-hpzWd_zl.js +1 -0
  600. package/dist/chunks/which-DqSAIvp2.js +1 -0
  601. package/dist/chunks/windowsPaths-C9CigqoF.js +1 -0
  602. package/dist/chunks/windowsPaths-swxCp7bX.js +2 -0
  603. package/dist/chunks/workSecret-mS2OrpxF.js +1 -0
  604. package/dist/chunks/workerRegistry-2_MZVih1.js +1 -0
  605. package/dist/chunks/worktree-CCuDwRmS.js +1 -0
  606. package/dist/chunks/worktreeModeEnabled-Db6b_Iy_.js +1 -0
  607. package/dist/chunks/worktreeModeEnabled-THQb19xR.js +1 -0
  608. package/dist/chunks/wrapper-BSK0MCQH.js +1 -0
  609. package/dist/chunks/wrapper-D5qL1aQL.js +6 -0
  610. package/dist/chunks/xdg-CBxMmQux.js +1 -0
  611. package/dist/chunks/xml-Dx--sNE1.js +1 -0
  612. package/dist/chunks/zod-DT6hytkp.js +1 -0
  613. package/dist/cli.js +1 -10978
  614. package/package.json +1 -1
@@ -0,0 +1,53 @@
1
+ import{i as e,n as t,o as n,t as r}from"./chunk-DR8-3Aex.js";import{c as i,n as a,s as o,t as s}from"./isObject-DaxDnPKm.js";import{n as c,t as l}from"./defineProperty-80gRi2ZW.js";import{i as u,n as d,r as f,t as p}from"./figures-gfT9mM8P.js";import{n as m,t as h}from"./supports-color-lkzOMQ6u.js";import{t as g}from"./semver-Cq33BYay.js";import{n as _,t as v}from"./isSymbol-Dp3irZaY.js";import{t as y}from"./jsx-runtime-D-D469L8.js";import b from"node:process";import{Stream as x}from"stream";import{closeSync as S,constants as C,openSync as w,readFileSync as T,readSync as E,writeSync as D}from"fs";import O from"node:os";import{Buffer as ee}from"buffer";import{format as te}from"util";import k from"node:tty";import{execFile as ne}from"child_process";import{EventEmitter as re}from"events";import ie from"process";function ae(e,{include:t,exclude:n}={}){let r=e=>{let r=t=>typeof t==`string`?e===t:t.test(e);return t?t.some(r):n?!n.some(r):!0};for(let[t,n]of oe(e.constructor.prototype)){if(n===`constructor`||!r(n))continue;let i=Reflect.getOwnPropertyDescriptor(t,n);i&&typeof i.value==`function`&&(e[n]=e[n].bind(e))}return e}var oe,se=t((()=>{oe=e=>{let t=new Set;do for(let n of Reflect.ownKeys(e))t.add([e,n]);while((e=Reflect.getPrototypeOf(e))&&e!==Object.prototype);return t}}));function ce(){}var le=t((()=>{})),ue,de=t((()=>{o(),ue=function(){return i.Date.now()}}));function fe(e){for(var t=e.length;t--&&pe.test(e.charAt(t)););return t}var pe,A=t((()=>{pe=/\s/}));function me(e){return e&&e.slice(0,fe(e)+1).replace(he,``)}var he,ge=t((()=>{A(),he=/^\s+/}));function j(e){if(typeof e==`number`)return e;if(_(e))return _e;if(a(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=a(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=me(e);var n=ye.test(e);return n||M.test(e)?be(e.slice(2),n?2:8):ve.test(e)?_e:+e}var _e,ve,ye,M,be,xe=t((()=>{ge(),s(),v(),_e=NaN,ve=/^[-+]0x[0-9a-f]+$/i,ye=/^0b[01]+$/i,M=/^0o[0-7]+$/i,be=parseInt}));function Se(e,t,n){var r,i,o,s,c,l,u=0,d=!1,f=!1,p=!0;if(typeof e!=`function`)throw TypeError(Ce);t=j(t)||0,a(n)&&(d=!!n.leading,f=`maxWait`in n,o=f?we(j(n.maxWait)||0,t):o,p=`trailing`in n?!!n.trailing:p);function m(t){var n=r,a=i;return r=i=void 0,u=t,s=e.apply(a,n),s}function h(e){return u=e,c=setTimeout(v,t),d?m(e):s}function g(e){var n=e-l,r=e-u,i=t-n;return f?Te(i,o-r):i}function _(e){var n=e-l,r=e-u;return l===void 0||n>=t||n<0||f&&r>=o}function v(){var e=ue();if(_(e))return y(e);c=setTimeout(v,g(e))}function y(e){return c=void 0,p&&r?m(e):(r=i=void 0,s)}function b(){c!==void 0&&clearTimeout(c),u=0,r=l=i=c=void 0}function x(){return c===void 0?s:y(ue())}function S(){var e=ue(),n=_(e);if(r=arguments,i=this,l=e,n){if(c===void 0)return h(l);if(f)return clearTimeout(c),c=setTimeout(v,t),m(l)}return c===void 0&&(c=setTimeout(v,t)),s}return S.cancel=b,S.flush=x,S}var Ce,we,Te,Ee=t((()=>{s(),de(),xe(),Ce=`Expected a function`,we=Math.max,Te=Math.min}));function De(e,t,n){var r=!0,i=!0;if(typeof e!=`function`)throw TypeError(Oe);return a(n)&&(r=`leading`in n?!!n.leading:r,i=`trailing`in n?!!n.trailing:i),Se(e,t,{leading:r,maxWait:t,trailing:i})}var Oe,ke=t((()=>{Ee(),s(),Oe=`Expected a function`})),Ae=r((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function k(e,t){return typeof e==`object`&&e&&e.key!=null?ee(``+e.key):t.toString(36)}function ne(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function re(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,re(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+k(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),re(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(te,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+k(a,u),c+=re(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+k(a,u++),c+=re(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return re(ne(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function ie(e,t,n){if(e==null)return e;var r=[],i=0;return re(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function ae(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var oe=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},se={map:ie,forEach:function(e,t,n){ie(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ie(e,function(){t++}),t},toArray:function(e){return ie(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=se,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:ae}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,oe)}catch(e){oe(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.5`})),N=r(((e,t)=>{t.exports=Ae()})),je=r((e=>{e.ConcurrentRoot=1,e.ContinuousEventPriority=8,e.DefaultEventPriority=32,e.DiscreteEventPriority=2,e.NoEventPriority=0})),Me=r(((e,t)=>{t.exports=je()})),P,Ne,Pe,F,Fe,Ie,Le,Re,I,ze,Be,Ve,He,Ue=t((()=>{P={Auto:0,FlexStart:1,Center:2,FlexEnd:3,Stretch:4,Baseline:5,SpaceBetween:6,SpaceAround:7,SpaceEvenly:8},Ne={Inherit:0,LTR:1,RTL:2},Pe={Flex:0,None:1,Contents:2},F={Left:0,Top:1,Right:2,Bottom:3,Start:4,End:5,Horizontal:6,Vertical:7,All:8},Fe={None:0,StretchFlexBasis:1,AbsolutePositionWithoutInsetsExcludesPadding:2,AbsolutePercentAgainstInnerSize:4,All:2147483647,Classic:2147483646},Ie={Column:0,ColumnReverse:1,Row:2,RowReverse:3},Le={Column:0,Row:1,All:2},Re={FlexStart:0,Center:1,FlexEnd:2,SpaceBetween:3,SpaceAround:4,SpaceEvenly:5},I={Undefined:0,Exactly:1,AtMost:2},ze={Visible:0,Hidden:1,Scroll:2},Be={Static:0,Relative:1,Absolute:2},Ve={Undefined:0,Point:1,Percent:2,Auto:3},He={NoWrap:0,Wrap:1,WrapReverse:2}}));function We(e){return{unit:Ve.Point,value:e}}function Ge(e){return{unit:Ve.Percent,value:e}}function L(e,t){switch(e.unit){case Ve.Point:return e.value;case Ve.Percent:return isNaN(t)?NaN:e.value*t/100;default:return NaN}}function R(e){return!isNaN(e)}function Ke(e,t){return e===t||e!==e&&t!==t}function qe(){return{direction:Ne.Inherit,flexDirection:Ie.Column,justifyContent:Re.FlexStart,alignItems:P.Stretch,alignSelf:P.Auto,alignContent:P.FlexStart,flexWrap:He.NoWrap,overflow:ze.Visible,display:Pe.Flex,positionType:Be.Relative,flexGrow:0,flexShrink:0,flexBasis:At,margin:Array(9).fill(kt),padding:Array(9).fill(kt),border:Array(9).fill(kt),position:Array(9).fill(kt),gap:[,,,].fill(kt),width:At,height:At,minWidth:kt,minHeight:kt,maxWidth:kt,maxHeight:kt}}function Je(e,t,n,r=!1){let i=e[t];return i.unit===Ve.Undefined&&(i=t===B||t===Mt?e[F.Horizontal]:e[F.Vertical]),i.unit===Ve.Undefined&&(i=e[F.All]),i.unit===Ve.Undefined&&(t===B&&(i=e[F.Start]),t===Mt&&(i=e[F.End])),i.unit===Ve.Undefined?0:i.unit===Ve.Auto?r?NaN:0:L(i,n)}function Ye(e,t){let n=e[t];return n.unit===Ve.Undefined&&(n=t===B||t===Mt?e[F.Horizontal]:e[F.Vertical]),n.unit===Ve.Undefined&&(n=e[F.All]),n.unit===Ve.Undefined&&(t===B&&(n=e[F.Start]),t===Mt&&(n=e[F.End])),n}function Xe(e,t){return Ye(e,t).unit===Ve.Auto}function Ze(e){for(let t=0;t<9;t++)if(e[t].unit===3)return!0;return!1}function Qe(e){for(let t=0;t<9;t++)if(e[t].unit!==0)return!0;return!1}function $e(e,t,n){let r=e[6],i=e[7],a=e[8],o=e[4],s=e[5],c=isNaN(t)?NaN:t/100,l=e[0];l.unit===0&&(l=r),l.unit===0&&(l=a),l.unit===0&&(l=o),n[0]=l.unit===1?l.value:l.unit===2?l.value*c:0,l=e[1],l.unit===0&&(l=i),l.unit===0&&(l=a),n[1]=l.unit===1?l.value:l.unit===2?l.value*c:0,l=e[2],l.unit===0&&(l=r),l.unit===0&&(l=a),l.unit===0&&(l=s),n[2]=l.unit===1?l.value:l.unit===2?l.value*c:0,l=e[3],l.unit===0&&(l=i),l.unit===0&&(l=a),n[3]=l.unit===1?l.value:l.unit===2?l.value*c:0}function et(e){return e===Ie.Row||e===Ie.RowReverse}function tt(e){return e===Ie.RowReverse||e===Ie.ColumnReverse}function nt(e){return et(e)?Ie.Column:Ie.Row}function rt(e){switch(e){case Ie.Row:return B;case Ie.RowReverse:return Mt;case Ie.Column:return jt;case Ie.ColumnReverse:return Nt}}function it(e){switch(e){case Ie.Row:return Mt;case Ie.RowReverse:return B;case Ie.Column:return Nt;case Ie.ColumnReverse:return jt}}function at(){let e={pointScaleFactor:1,errata:Fe.None,useWebDefaults:!1,free(){},isExperimentalFeatureEnabled(){return!1},setExperimentalFeatureEnabled(){},setPointScaleFactor(t){e.pointScaleFactor=t},getErrata(){return e.errata},setErrata(t){e.errata=t},setUseWebDefaults(t){e.useWebDefaults=t}};return e}function ot(e,t,n,r,i,a,o,s,c,l){e._cIn||(e._cIn=new Float64Array(It*8),e._cOut=new Float64Array(It*2)),l&&e._cGen!==Lt&&(e._cN=0,e._cWr=0);let u=e._cWr++%It;e._cN<It&&(e._cN=e._cWr);let d=u*8,f=e._cIn;f[d]=t,f[d+1]=n,f[d+2]=r,f[d+3]=i,f[d+4]=a,f[d+5]=o,f[d+6]=+!!s,f[d+7]=+!!c,e._cOut[u*2]=e.layout.width,e._cOut[u*2+1]=e.layout.height,e._cGen=Lt}function st(e,t){t?(e._lOutW=e.layout.width,e._lOutH=e.layout.height):(e._mOutW=e.layout.width,e._mOutH=e.layout.height)}function ct(){return{visited:Rt,measured:zt,cacheHits:Bt,live:Vt}}function lt(e,t,n,r,i,a,o,s,c=!1,l=!1){Rt++;let u=e.style,d=e.layout,f=e._cGen===Lt&&!s;if(!e.isDirty_||f){if(!e.isDirty_&&e._hasL&&e._lWM===r&&e._lHM===i&&e._lFW===c&&e._lFH===l&&Ke(e._lW,t)&&Ke(e._lH,n)&&Ke(e._lOW,a)&&Ke(e._lOH,o)){Bt++,d.width=e._lOutW,d.height=e._lOutH;return}if(e._cN>0&&(f||!e.isDirty_)){let s=e._cIn;for(let u=0;u<e._cN;u++){let f=u*8;if(s[f+2]===r&&s[f+3]===i&&s[f+6]===+!!c&&s[f+7]===+!!l&&Ke(s[f],t)&&Ke(s[f+1],n)&&Ke(s[f+4],a)&&Ke(s[f+5],o)){d.width=e._cOut[u*2],d.height=e._cOut[u*2+1],Bt++;return}}}if(!e.isDirty_&&!s&&e._hasM&&e._mWM===r&&e._mHM===i&&Ke(e._mW,t)&&Ke(e._mH,n)&&Ke(e._mOW,a)&&Ke(e._mOH,o)){d.width=e._mOutW,d.height=e._mOutH,Bt++;return}}let p=e.isDirty_;s?(e._lW=t,e._lH=n,e._lWM=r,e._lHM=i,e._lOW=a,e._lOH=o,e._lFW=c,e._lFH=l,e._hasL=!0,e.isDirty_=!1,p&&(e._hasM=!1)):(e._mW=t,e._mH=n,e._mWM=r,e._mHM=i,e._mOW=a,e._mOH=o,e._hasM=!0,p&&(e._hasL=!1));let m=d.padding,h=d.border,g=d.margin;e._hasPadding?$e(u.padding,a,m):m[0]=m[1]=m[2]=m[3]=0,e._hasBorder?$e(u.border,a,h):h[0]=h[1]=h[2]=h[3]=0,e._hasMargin?$e(u.margin,a,g):g[0]=g[1]=g[2]=g[3]=0;let _=m[0]+m[2]+h[0]+h[2],v=m[1]+m[3]+h[1]+h[3],y=c?NaN:L(u.width,a),b=l?NaN:L(u.height,o),x=t,S=n,C=r,w=i;if(R(y)&&(x=y,C=I.Exactly),R(b)&&(S=b,w=I.Exactly),x=z(u,!0,x,a,o),S=z(u,!1,S,a,o),e.measureFunc&&e.children.length===0){let d=C===I.Undefined?NaN:Math.max(0,x-_),f=w===I.Undefined?NaN:Math.max(0,S-v);zt++;let m=e.measureFunc(d,C,f,w);e.layout.width=C===I.Exactly?x:z(u,!0,(m.width??0)+_,a,o),e.layout.height=w===I.Exactly?S:z(u,!1,(m.height??0)+v,a,o),st(e,s),ot(e,t,n,r,i,a,o,c,l,p);return}if(e.children.length===0){e.layout.width=C===I.Exactly?x:z(u,!0,_,a,o),e.layout.height=w===I.Exactly?S:z(u,!1,v,a,o),st(e,s),ot(e,t,n,r,i,a,o,c,l,p);return}let T=u.flexDirection,E=nt(T),D=et(T),O=D?x:S,ee=D?S:x,te=D?C:w,k=D?w:C,ne=D?_:v,re=D?v:_,ie=R(O)?Math.max(0,O-ne):NaN,ae=R(ee)?Math.max(0,ee-re):NaN,oe=xt(u,D?Le.Column:Le.Row,ie),se=[],ce=[];Ct(e,se,ce);let le=R(x)?x:NaN,ue=R(S)?S:NaN,de=u.flexWrap!==He.NoWrap,fe=xt(u,D?Le.Row:Le.Column,ae);for(let e of se)e._flexBasis=pt(e,T,ie,ae,k,le,ue);let pe=[];if(!de||!R(ie)||se.length===0){for(let e of se)e._lineIndex=0;pe.push(se)}else{let e=0,t=0;for(let n=0;n<se.length;n++){let r=se[n],i=z(r.style,D,r._flexBasis,le,ue),a=Math.max(0,i)+bt(r,T,le),o=n>e?oe:0;n>e&&t+o+a>ie?(pe.push(se.slice(e,n)),e=n,t=a):t+=o+a,r._lineIndex=pe.length}pe.push(se.slice(e))}let A=pe.length,me=yt(e,se),he=Array(A),ge=Array(A),j=me?Array(A).fill(0):[],_e=0,ve=0;for(let t=0;t<A;t++){let n=pe[t],r=n.length>1?oe*(n.length-1):0,i=r;for(let e of n)i+=e._flexBasis+bt(e,T,le);let c=ie;if(!R(c)){let e=D?a:o,t=L(D?u.minWidth:u.minHeight,e),n=L(D?u.maxWidth:u.maxHeight,e);R(n)&&i>n-ne?c=Math.max(0,n-ne):R(t)&&i<t-ne&&(c=Math.max(0,t-ne))}ht(n,c,i,D,le,ue);let l=0;for(let e of n){let t=e.style,n=t.alignSelf===P.Auto?u.alignItems:t.alignSelf,r=bt(e,E,le),i=NaN,a=I.Undefined,o=L(D?t.height:t.width,D?ue:le),c=D?jt:B,d=D?Nt:Mt,f=e._hasAutoMargin&&(Xe(t.margin,c)||Xe(t.margin,d));R(o)?(i=o,a=I.Exactly):n===P.Stretch&&!f&&!de&&R(ae)&&k===I.Exactly?(i=Math.max(0,ae-r),a=I.Exactly):!de&&R(ae)&&(i=Math.max(0,ae-r),a=I.AtMost),lt(e,D?e._mainSize:i,D?i:e._mainSize,D?I.Exactly:a,D?a:I.Exactly,le,ue,s,D,!D),e._crossSize=D?e.layout.height:e.layout.width,l=Math.max(l,e._crossSize+r)}if(me){let r=0,i=0;for(let t of n){if(_t(e,t)!==P.Baseline)continue;let n=Je(t.style.margin,jt,le),a=Je(t.style.margin,Nt,le),o=vt(t)+n,s=t.layout.height+n+a-o;o>r&&(r=o),s>i&&(i=s)}j[t]=r,r+i>l&&(l=r+i)}let d=rt(T),f=it(T),p=r;for(let e of n){let t=e.layout.margin;p+=e._mainSize+t[d]+t[f]}he[t]=p,ge[t]=l,_e=Math.max(_e,p),ve+=l}let ye=A>1?fe*(A-1):0;ve+=ye;let M=u.overflow===ze.Scroll,be=_e+ne,xe=te===I.Exactly?O:te===I.AtMost&&M?Math.max(Math.min(O,be),ne):de&&A>1&&te===I.AtMost?O:be,Se=ve+re,Ce=k===I.Exactly?ee:k===I.AtMost&&M?Math.max(Math.min(ee,Se),re):Se;if(e.layout.width=z(u,!0,D?xe:Ce,a,o),e.layout.height=z(u,!1,D?Ce:xe,a,o),st(e,s),ot(e,t,n,r,i,a,o,c,l,p),!s)return;let we=(D?e.layout.width:e.layout.height)-ne,Te=(D?e.layout.height:e.layout.width)-re,Ee=rt(T),De=it(T),Oe=D?jt:B,ke=D?Nt:Mt,Ae=tt(T),N=D?e.layout.width:e.layout.height,je=m[Oe]+h[Oe],Me=fe,Ne=Te-ve;if(A===1&&!de&&!me)ge[0]=Te;else{let e=Math.max(0,Ne);switch(u.alignContent){case P.FlexStart:break;case P.Center:je+=Ne/2;break;case P.FlexEnd:je+=Ne;break;case P.Stretch:if(A>0&&e>0){let t=e/A;for(let e=0;e<A;e++)ge[e]+=t}break;case P.SpaceBetween:A>1&&(Me+=e/(A-1));break;case P.SpaceAround:A>0&&(Me+=e/A,je+=e/A/2);break;case P.SpaceEvenly:A>0&&(Me+=e/(A+1),je+=e/(A+1));break;default:break}}let Pe=u.flexWrap===He.WrapReverse,F=D?e.layout.height:e.layout.width,Fe=je;for(let e=0;e<A;e++){let t=pe[e],n=ge[e],r=he[e],i=t.length;if(de||k!==I.Exactly)for(let e of t){let t=e.style,r=t.alignSelf===P.Auto?u.alignItems:t.alignSelf,i=R(L(D?t.height:t.width,D?ue:le)),a=e._hasAutoMargin&&(Xe(t.margin,Oe)||Xe(t.margin,ke));if(r===P.Stretch&&!i&&!a){let t=bt(e,E,le),r=Math.max(0,n-t);e._crossSize!==r&&(lt(e,D?e._mainSize:r,D?r:e._mainSize,I.Exactly,I.Exactly,le,ue,s,D,!D),e._crossSize=r)}}let a=m[Ee]+h[Ee],o=oe,c=0;for(let e of t)e._hasAutoMargin&&(Xe(e.style.margin,Ee)&&c++,Xe(e.style.margin,De)&&c++);let l=we-r,d=Math.max(0,l),f=c>0&&d>0?d/c:0;if(c===0)switch(u.justifyContent){case Re.FlexStart:break;case Re.Center:a+=l/2;break;case Re.FlexEnd:a+=l;break;case Re.SpaceBetween:i>1&&(o+=d/(i-1));break;case Re.SpaceAround:i>0&&(o+=d/i,a+=d/i/2);break;case Re.SpaceEvenly:i>0&&(o+=d/(i+1),a+=d/(i+1));break}let p=Pe?F-Fe-n:Fe,g=a;for(let r of t){let t=r.style.margin,i=r.layout.margin,a=!1,s=!1,c=!1,l=!1,d,m,h,_;r._hasAutoMargin?(a=Xe(t,Ee),s=Xe(t,De),c=Xe(t,Oe),l=Xe(t,ke),d=a?f:i[Ee],m=s?f:i[De],h=c?0:i[Oe],_=l?0:i[ke]):(d=i[Ee],m=i[De],h=i[Oe],_=i[ke]);let v=Ae?N-(g+d)-r._mainSize:g+d,y=r.style.alignSelf===P.Auto?u.alignItems:r.style.alignSelf,b=p+h,x=n-r._crossSize-h-_;if(c&&l)b+=Math.max(0,x)/2;else if(c)b+=Math.max(0,x);else if(!l)switch(y){case P.FlexStart:case P.Stretch:Pe&&(b+=x);break;case P.Center:b+=x/2;break;case P.FlexEnd:Pe||(b+=x);break;case P.Baseline:me&&(b=p+j[e]-vt(r));break;default:break}let S=0,C=0;if(r._hasPosition){let e=L(Ye(r.style.position,B),le),t=L(Ye(r.style.position,Mt),le),n=L(Ye(r.style.position,jt),le),i=L(Ye(r.style.position,Nt),le);S=R(e)?e:R(t)?-t:0,C=R(n)?n:R(i)?-i:0}D?(r.layout.left=v+S,r.layout.top=b+C):(r.layout.left=b+S,r.layout.top=v+C),g+=r._mainSize+d+m+o}Fe+=n+Me}for(let t of ce)ut(e,t,e.layout.width,e.layout.height,m,h)}function ut(e,t,n,r,i,a){let o=t.style,s=Ye(o.position,B),c=Ye(o.position,Mt),l=Ye(o.position,jt),u=Ye(o.position,Nt),d=L(s,n),f=L(c,n),p=L(l,r),m=L(u,r),h=n-a[0]-a[2],g=r-a[1]-a[3],_=L(o.width,h),v=L(o.height,g);!R(_)&&R(d)&&R(f)&&(_=h-d-f),!R(v)&&R(p)&&R(m)&&(v=g-p-m),lt(t,_,v,R(_)?I.Exactly:I.Undefined,R(v)?I.Exactly:I.Undefined,h,g,!0);let y=Je(o.margin,B,n),b=Je(o.margin,jt,n),x=Je(o.margin,Mt,n),S=Je(o.margin,Nt,n),C=e.style.flexDirection,w=tt(C),T=et(C),E=e.style.flexWrap===He.WrapReverse,D=o.alignSelf===P.Auto?e.style.alignItems:o.alignSelf,O;if(R(d))O=a[0]+d+y;else if(R(f))O=n-a[2]-f-t.layout.width-x;else if(T){let r=i[0]+a[0],o=n-i[2]-a[2];O=w?o-t.layout.width-x:dt(e.style.justifyContent,r,o,t.layout.width)+y}else O=ft(D,i[0]+a[0],n-i[2]-a[2],t.layout.width,E)+y;let ee;if(R(p))ee=a[1]+p+b;else if(R(m))ee=r-a[3]-m-t.layout.height-S;else if(T)ee=ft(D,i[1]+a[1],r-i[3]-a[3],t.layout.height,E)+b;else{let n=i[1]+a[1],o=r-i[3]-a[3];ee=w?o-t.layout.height-S:dt(e.style.justifyContent,n,o,t.layout.height)+b}t.layout.left=O,t.layout.top=ee}function dt(e,t,n,r){switch(e){case Re.Center:return t+(n-t-r)/2;case Re.FlexEnd:return n-r;default:return t}}function ft(e,t,n,r,i){switch(e){case P.Center:return t+(n-t-r)/2;case P.FlexEnd:return i?t:n-r;default:return i?n-r:t}}function pt(e,t,n,r,i,a,o){if((e._fbGen===Lt||!e.isDirty_)&&e._fbCrossMode===i&&Ke(e._fbOwnerW,a)&&Ke(e._fbOwnerH,o)&&Ke(e._fbAvailMain,n)&&Ke(e._fbAvailCross,r))return e._fbBasis;let s=e.style,c=et(t),l=L(s.flexBasis,n);if(R(l)){let t=Math.max(0,l);return e._fbBasis=t,e._fbOwnerW=a,e._fbOwnerH=o,e._fbAvailMain=n,e._fbAvailCross=r,e._fbCrossMode=i,e._fbGen=Lt,t}let u=L(c?s.width:s.height,c?a:o);if(R(u)){let t=Math.max(0,u);return e._fbBasis=t,e._fbOwnerW=a,e._fbOwnerH=o,e._fbAvailMain=n,e._fbAvailCross=r,e._fbCrossMode=i,e._fbGen=Lt,t}let d=L(c?s.height:s.width,c?o:a),f=R(d)?I.Exactly:I.Undefined;!R(d)&&R(r)&&(d=r,f=i===I.Exactly&&gt(e)?I.Exactly:I.AtMost);let p=NaN,m=I.Undefined;c&&R(n)&&mt(e)&&(p=n,m=I.AtMost),lt(e,c?p:d,c?d:p,c?m:f,c?f:m,a,o,!1);let h=c?e.layout.width:e.layout.height;return e._fbBasis=h,e._fbOwnerW=a,e._fbOwnerH=o,e._fbAvailMain=n,e._fbAvailCross=r,e._fbCrossMode=i,e._fbGen=Lt,h}function mt(e){if(e.measureFunc)return!0;for(let t of e.children)if(mt(t))return!0;return!1}function ht(e,t,n,r,i,a){let o=e.length,s=Array(o).fill(!1),c=R(t)?t-n:0;for(let n=0;n<o;n++){let o=e[n],l=z(o.style,r,o._flexBasis,i,a);!R(t)||(c>=0?o.style.flexGrow===0:o.style.flexShrink===0)?(o._mainSize=Math.max(0,l),s[n]=!0):o._mainSize=o._flexBasis}let l=Array(o);for(let t=0;t<=o;t++){let t=0,n=0,u=0,d=0;for(let r=0;r<o;r++){let i=e[r];s[r]?t+=i._mainSize-i._flexBasis:(n+=i.style.flexGrow,u+=i.style.flexShrink*i._flexBasis,d++)}if(d===0)break;let f=c-t;if(f>0&&n>0&&n<1){let e=c*n;e<f&&(f=e)}else if(f<0&&u>0){let t=0;for(let n=0;n<o;n++)s[n]||(t+=e[n].style.flexShrink);if(t<1){let e=c*t;e>f&&(f=e)}}let p=0;for(let t=0;t<o;t++){if(s[t])continue;let o=e[t],c=o._flexBasis;f>0&&n>0?c+=f*o.style.flexGrow/n:f<0&&u>0&&(c+=f*(o.style.flexShrink*o._flexBasis)/u),l[t]=c;let d=Math.max(0,z(o.style,r,c,i,a));o._mainSize=d,p+=d-c}if(p===0)break;let m=!1;for(let t=0;t<o;t++){if(s[t])continue;let n=e[t]._mainSize-l[t];(p>0&&n>0||p<0&&n<0)&&(s[t]=!0,m=!0)}if(!m)break}}function gt(e){let t=e.parent;return t?(e.style.alignSelf===P.Auto?t.style.alignItems:e.style.alignSelf)===P.Stretch:!1}function _t(e,t){return t.style.alignSelf===P.Auto?e.style.alignItems:t.style.alignSelf}function vt(e){let t=null;for(let n of e.children){if(n._lineIndex>0)break;if(n.style.positionType!==Be.Absolute&&n.style.display!==Pe.None){if(_t(e,n)===P.Baseline||n.isReferenceBaseline_){t=n;break}t===null&&(t=n)}}return t===null?e.layout.height:vt(t)+t.layout.top}function yt(e,t){if(!et(e.style.flexDirection))return!1;if(e.style.alignItems===P.Baseline)return!0;for(let e of t)if(e.style.alignSelf===P.Baseline)return!0;return!1}function bt(e,t,n){return e._hasMargin?Je(e.style.margin,rt(t),n)+Je(e.style.margin,it(t),n):0}function xt(e,t,n){let r=e.gap[t];r.unit===Ve.Undefined&&(r=e.gap[Le.All]);let i=L(r,n);return R(i)?Math.max(0,i):0}function z(e,t,n,r,i){let a=t?e.minWidth:e.minHeight,o=t?e.maxWidth:e.maxHeight,s=a.unit,c=o.unit;if(s===0&&c===0)return n;let l=t?r:i,u=n;if(c===1)u>o.value&&(u=o.value);else if(c===2){let e=o.value*l/100;e===e&&u>e&&(u=e)}if(s===1)u<a.value&&(u=a.value);else if(s===2){let e=a.value*l/100;e===e&&u<e&&(u=e)}return u}function St(e){for(let t of e.children)t.layout.left=0,t.layout.top=0,t.layout.width=0,t.layout.height=0,t.isDirty_=!0,t._hasL=!1,t._hasM=!1,St(t)}function Ct(e,t,n){for(let r of e.children){let e=r.style.display;e===Pe.None?(r.layout.left=0,r.layout.top=0,r.layout.width=0,r.layout.height=0,St(r)):e===Pe.Contents?(r.layout.left=0,r.layout.top=0,r.layout.width=0,r.layout.height=0,Ct(r,t,n)):r.style.positionType===Be.Absolute?n.push(r):t.push(r)}}function wt(e,t,n,r){if(t===0)return;let i=e.layout,a=i.left,o=i.top,s=i.width,c=i.height,l=n+a,u=r+o,d=e.measureFunc!==null;i.left=Et(a,t,!1,d),i.top=Et(o,t,!1,d);let f=l+s,p=u+c,m=!Tt(s*t),h=!Tt(c*t);i.width=Et(f,t,d&&m,d&&!m)-Et(l,t,!1,d),i.height=Et(p,t,d&&h,d&&!h)-Et(u,t,!1,d);for(let n of e.children)wt(n,t,l,u)}function Tt(e){let t=e-Math.floor(e);return t<1e-4||t>.9999}function Et(e,t,n,r){let i=e*t,a=i-Math.floor(i);return a<0&&(a+=1),i=a<1e-4?Math.floor(i):a>.9999||n?Math.ceil(i):r?Math.floor(i):Math.floor(i)+ +(a>=.4999),i/t}function Dt(e){if(e===void 0)return kt;if(e===`auto`)return At;if(typeof e==`number`)return Number.isFinite(e)?We(e):kt;if(typeof e==`string`&&e.endsWith(`%`))return Ge(parseFloat(e));let t=parseFloat(e);return isNaN(t)?kt:We(t)}function Ot(e){switch(e){case F.Left:case F.Start:return B;case F.Top:return jt;case F.Right:case F.End:return Mt;case F.Bottom:return Nt;default:return B}}var kt,At,B,jt,Mt,Nt,Pt,Ft,It,Lt,Rt,zt,Bt,Vt,Ht,Ut=t((()=>{Ue(),c(),kt={unit:Ve.Undefined,value:NaN},At={unit:Ve.Auto,value:NaN},B=0,jt=1,Mt=2,Nt=3,Pt=class{constructor(e){l(this,`style`,void 0),l(this,`layout`,void 0),l(this,`parent`,void 0),l(this,`children`,void 0),l(this,`measureFunc`,void 0),l(this,`config`,void 0),l(this,`isDirty_`,void 0),l(this,`isReferenceBaseline_`,void 0),l(this,`_flexBasis`,0),l(this,`_mainSize`,0),l(this,`_crossSize`,0),l(this,`_lineIndex`,0),l(this,`_hasAutoMargin`,!1),l(this,`_hasPosition`,!1),l(this,`_hasPadding`,!1),l(this,`_hasBorder`,!1),l(this,`_hasMargin`,!1),l(this,`_lW`,NaN),l(this,`_lH`,NaN),l(this,`_lWM`,0),l(this,`_lHM`,0),l(this,`_lOW`,NaN),l(this,`_lOH`,NaN),l(this,`_lFW`,!1),l(this,`_lFH`,!1),l(this,`_lOutW`,NaN),l(this,`_lOutH`,NaN),l(this,`_hasL`,!1),l(this,`_mW`,NaN),l(this,`_mH`,NaN),l(this,`_mWM`,0),l(this,`_mHM`,0),l(this,`_mOW`,NaN),l(this,`_mOH`,NaN),l(this,`_mOutW`,NaN),l(this,`_mOutH`,NaN),l(this,`_hasM`,!1),l(this,`_fbBasis`,NaN),l(this,`_fbOwnerW`,NaN),l(this,`_fbOwnerH`,NaN),l(this,`_fbAvailMain`,NaN),l(this,`_fbAvailCross`,NaN),l(this,`_fbCrossMode`,0),l(this,`_fbGen`,-1),l(this,`_cIn`,null),l(this,`_cOut`,null),l(this,`_cGen`,-1),l(this,`_cN`,0),l(this,`_cWr`,0),this.style=qe(),this.layout={left:0,top:0,width:0,height:0,border:[0,0,0,0],padding:[0,0,0,0],margin:[0,0,0,0]},this.parent=null,this.children=[],this.measureFunc=null,this.config=e??Ft,this.isDirty_=!0,this.isReferenceBaseline_=!1,Vt++}insertChild(e,t){e.parent=this,this.children.splice(t,0,e),this.markDirty()}removeChild(e){let t=this.children.indexOf(e);t>=0&&(this.children.splice(t,1),e.parent=null,this.markDirty())}getChild(e){return this.children[e]}getChildCount(){return this.children.length}getParent(){return this.parent}free(){this.parent=null,this.children=[],this.measureFunc=null,this._cIn=null,this._cOut=null,Vt--}freeRecursive(){for(let e of this.children)e.freeRecursive();this.free()}reset(){this.style=qe(),this.children=[],this.parent=null,this.measureFunc=null,this.isDirty_=!0,this._hasAutoMargin=!1,this._hasPosition=!1,this._hasPadding=!1,this._hasBorder=!1,this._hasMargin=!1,this._hasL=!1,this._hasM=!1,this._cN=0,this._cWr=0,this._fbBasis=NaN}markDirty(){this.isDirty_=!0,this.parent&&!this.parent.isDirty_&&this.parent.markDirty()}isDirty(){return this.isDirty_}hasNewLayout(){return!0}markLayoutSeen(){}setMeasureFunc(e){this.measureFunc=e,this.markDirty()}unsetMeasureFunc(){this.measureFunc=null,this.markDirty()}getComputedLeft(){return this.layout.left}getComputedTop(){return this.layout.top}getComputedWidth(){return this.layout.width}getComputedHeight(){return this.layout.height}getComputedRight(){let e=this.parent;return e?e.layout.width-this.layout.left-this.layout.width:0}getComputedBottom(){let e=this.parent;return e?e.layout.height-this.layout.top-this.layout.height:0}getComputedLayout(){return{left:this.layout.left,top:this.layout.top,right:this.getComputedRight(),bottom:this.getComputedBottom(),width:this.layout.width,height:this.layout.height}}getComputedBorder(e){return this.layout.border[Ot(e)]}getComputedPadding(e){return this.layout.padding[Ot(e)]}getComputedMargin(e){return this.layout.margin[Ot(e)]}setWidth(e){this.style.width=Dt(e),this.markDirty()}setWidthPercent(e){this.style.width=Ge(e),this.markDirty()}setWidthAuto(){this.style.width=At,this.markDirty()}setHeight(e){this.style.height=Dt(e),this.markDirty()}setHeightPercent(e){this.style.height=Ge(e),this.markDirty()}setHeightAuto(){this.style.height=At,this.markDirty()}setMinWidth(e){this.style.minWidth=Dt(e),this.markDirty()}setMinWidthPercent(e){this.style.minWidth=Ge(e),this.markDirty()}setMinHeight(e){this.style.minHeight=Dt(e),this.markDirty()}setMinHeightPercent(e){this.style.minHeight=Ge(e),this.markDirty()}setMaxWidth(e){this.style.maxWidth=Dt(e),this.markDirty()}setMaxWidthPercent(e){this.style.maxWidth=Ge(e),this.markDirty()}setMaxHeight(e){this.style.maxHeight=Dt(e),this.markDirty()}setMaxHeightPercent(e){this.style.maxHeight=Ge(e),this.markDirty()}setFlexDirection(e){this.style.flexDirection=e,this.markDirty()}setFlexGrow(e){this.style.flexGrow=e??0,this.markDirty()}setFlexShrink(e){this.style.flexShrink=e??0,this.markDirty()}setFlex(e){e===void 0||isNaN(e)?(this.style.flexGrow=0,this.style.flexShrink=0):e>0?(this.style.flexGrow=e,this.style.flexShrink=1,this.style.flexBasis=We(0)):e<0?(this.style.flexGrow=0,this.style.flexShrink=-e):(this.style.flexGrow=0,this.style.flexShrink=0),this.markDirty()}setFlexBasis(e){this.style.flexBasis=Dt(e),this.markDirty()}setFlexBasisPercent(e){this.style.flexBasis=Ge(e),this.markDirty()}setFlexBasisAuto(){this.style.flexBasis=At,this.markDirty()}setFlexWrap(e){this.style.flexWrap=e,this.markDirty()}setAlignItems(e){this.style.alignItems=e,this.markDirty()}setAlignSelf(e){this.style.alignSelf=e,this.markDirty()}setAlignContent(e){this.style.alignContent=e,this.markDirty()}setJustifyContent(e){this.style.justifyContent=e,this.markDirty()}setDisplay(e){this.style.display=e,this.markDirty()}getDisplay(){return this.style.display}setPositionType(e){this.style.positionType=e,this.markDirty()}setPosition(e,t){this.style.position[e]=Dt(t),this._hasPosition=Qe(this.style.position),this.markDirty()}setPositionPercent(e,t){this.style.position[e]=Ge(t),this._hasPosition=!0,this.markDirty()}setPositionAuto(e){this.style.position[e]=At,this._hasPosition=!0,this.markDirty()}setOverflow(e){this.style.overflow=e,this.markDirty()}setDirection(e){this.style.direction=e,this.markDirty()}setBoxSizing(e){}setMargin(e,t){let n=Dt(t);this.style.margin[e]=n,n.unit===Ve.Auto?this._hasAutoMargin=!0:this._hasAutoMargin=Ze(this.style.margin),this._hasMargin=this._hasAutoMargin||Qe(this.style.margin),this.markDirty()}setMarginPercent(e,t){this.style.margin[e]=Ge(t),this._hasAutoMargin=Ze(this.style.margin),this._hasMargin=!0,this.markDirty()}setMarginAuto(e){this.style.margin[e]=At,this._hasAutoMargin=!0,this._hasMargin=!0,this.markDirty()}setPadding(e,t){this.style.padding[e]=Dt(t),this._hasPadding=Qe(this.style.padding),this.markDirty()}setPaddingPercent(e,t){this.style.padding[e]=Ge(t),this._hasPadding=!0,this.markDirty()}setBorder(e,t){this.style.border[e]=t===void 0?kt:We(t),this._hasBorder=Qe(this.style.border),this.markDirty()}setGap(e,t){this.style.gap[e]=Dt(t),this.markDirty()}setGapPercent(e,t){this.style.gap[e]=Ge(t),this.markDirty()}getFlexDirection(){return this.style.flexDirection}getJustifyContent(){return this.style.justifyContent}getAlignItems(){return this.style.alignItems}getAlignSelf(){return this.style.alignSelf}getAlignContent(){return this.style.alignContent}getFlexGrow(){return this.style.flexGrow}getFlexShrink(){return this.style.flexShrink}getFlexBasis(){return this.style.flexBasis}getFlexWrap(){return this.style.flexWrap}getWidth(){return this.style.width}getHeight(){return this.style.height}getOverflow(){return this.style.overflow}getPositionType(){return this.style.positionType}getDirection(){return this.style.direction}copyStyle(e){}setDirtiedFunc(e){}unsetDirtiedFunc(){}setIsReferenceBaseline(e){this.isReferenceBaseline_=e,this.markDirty()}isReferenceBaseline(){return this.isReferenceBaseline_}setAspectRatio(e){}getAspectRatio(){return NaN}setAlwaysFormsContainingBlock(e){}calculateLayout(e,t,n){Rt=0,zt=0,Bt=0,Lt++;let r=e===void 0?NaN:e,i=t===void 0?NaN:t;lt(this,r,i,R(r)?I.Exactly:I.Undefined,R(i)?I.Exactly:I.Undefined,r,i,!0);let a=this.layout.margin,o=L(Ye(this.style.position,B),R(r)?r:0),s=L(Ye(this.style.position,jt),R(r)?r:0);this.layout.left=a[B]+(R(o)?o:0),this.layout.top=a[jt]+(R(s)?s:0),wt(this,this.config.pointScaleFactor,0,0)}},Ft=at(),It=4,Lt=0,Rt=0,zt=0,Bt=0,Vt=0,Ht={Config:{create:at,destroy(){}},Node:{create:e=>new Pt(e),createDefault:()=>new Pt,createWithConfig:e=>new Pt(e),destroy(){}}}}));function Wt(){let e=new Map;for(let[t,n]of Object.entries(Yt)){for(let[t,r]of Object.entries(n))Yt[t]={open:`\u001B[${r[0]}m`,close:`\u001B[${r[1]}m`},n[t]=Yt[t],e.set(r[0],r[1]);Object.defineProperty(Yt,t,{value:n,enumerable:!1})}return Object.defineProperty(Yt,`codes`,{value:e,enumerable:!1}),Yt.color.close=`\x1B[39m`,Yt.bgColor.close=`\x1B[49m`,Yt.color.ansi=Kt(),Yt.color.ansi256=qt(),Yt.color.ansi16m=Jt(),Yt.bgColor.ansi=Kt(Gt),Yt.bgColor.ansi256=qt(Gt),Yt.bgColor.ansi16m=Jt(Gt),Object.defineProperties(Yt,{rgbToAnsi256:{value(e,t,n){return e===t&&t===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(e){let t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(e.toString(16));if(!t)return[0,0,0];let[n]=t;n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=Number.parseInt(n,16);return[r>>16&255,r>>8&255,r&255]},enumerable:!1},hexToAnsi256:{value:e=>Yt.rgbToAnsi256(...Yt.hexToRgb(e)),enumerable:!1},ansi256ToAnsi:{value(e){if(e<8)return 30+e;if(e<16)return 90+(e-8);let t,n,r;if(e>=232)t=((e-232)*10+8)/255,n=t,r=t;else{e-=16;let i=e%36;t=Math.floor(e/36)/5,n=Math.floor(i/6)/5,r=i%6/5}let i=Math.max(t,n,r)*2;if(i===0)return 30;let a=30+(Math.round(r)<<2|Math.round(n)<<1|Math.round(t));return i===2&&(a+=60),a},enumerable:!1},rgbToAnsi:{value:(e,t,n)=>Yt.ansi256ToAnsi(Yt.rgbToAnsi256(e,t,n)),enumerable:!1},hexToAnsi:{value:e=>Yt.ansi256ToAnsi(Yt.hexToAnsi256(e)),enumerable:!1}}),Yt}var Gt,Kt,qt,Jt,Yt,Xt,Zt,Qt,$t=t((()=>{Gt=10,Kt=(e=0)=>t=>`\u001B[${t+e}m`,qt=(e=0)=>t=>`\u001B[${38+e};5;${t}m`,Jt=(e=0)=>(t,n,r)=>`\u001B[${38+e};2;${t};${n};${r}m`,Yt={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}},Object.keys(Yt.modifier),Xt=Object.keys(Yt.color),Zt=Object.keys(Yt.bgColor),[...Xt,...Zt],Qt=Wt()}));function en(e,t=globalThis.Deno?globalThis.Deno.args:b.argv){let n=e.startsWith(`-`)?``:e.length===1?`-`:`--`,r=t.indexOf(n+e),i=t.indexOf(`--`);return r!==-1&&(i===-1||r<i)}function tn(){if(`FORCE_COLOR`in on)return on.FORCE_COLOR===`true`?1:on.FORCE_COLOR===`false`?0:on.FORCE_COLOR.length===0?1:Math.min(Number.parseInt(on.FORCE_COLOR,10),3)}function nn(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function rn(e,{streamIsTTY:t,sniffFlags:n=!0}={}){let r=tn();r!==void 0&&(sn=r);let i=n?sn:r;if(i===0)return 0;if(n){if(en(`color=16m`)||en(`color=full`)||en(`color=truecolor`))return 3;if(en(`color=256`))return 2}if(`TF_BUILD`in on&&`AGENT_NAME`in on)return 1;if(e&&!t&&i===void 0)return 0;let a=i||0;if(on.TERM===`dumb`)return a;if(b.platform===`win32`){let e=O.release().split(`.`);return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if(`CI`in on)return[`GITHUB_ACTIONS`,`GITEA_ACTIONS`,`CIRCLECI`].some(e=>e in on)?3:[`TRAVIS`,`APPVEYOR`,`GITLAB_CI`,`BUILDKITE`,`DRONE`].some(e=>e in on)||on.CI_NAME===`codeship`?1:a;if(`TEAMCITY_VERSION`in on)return+!!/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(on.TEAMCITY_VERSION);if(on.COLORTERM===`truecolor`||on.TERM===`xterm-kitty`||on.TERM===`xterm-ghostty`||on.TERM===`wezterm`)return 3;if(`TERM_PROGRAM`in on){let e=Number.parseInt((on.TERM_PROGRAM_VERSION||``).split(`.`)[0],10);switch(on.TERM_PROGRAM){case`iTerm.app`:return e>=3?3:2;case`Apple_Terminal`:return 2}}return/-256(color)?$/i.test(on.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(on.TERM)||`COLORTERM`in on?1:a}function an(e,t={}){return nn(rn(e,{streamIsTTY:e&&e.isTTY,...t}))}var on,sn,cn,ln=t((()=>{({env:on}=b),en(`no-color`)||en(`no-colors`)||en(`color=false`)||en(`color=never`)?sn=0:(en(`color`)||en(`colors`)||en(`color=true`)||en(`color=always`))&&(sn=1),cn={stdout:an({isTTY:k.isatty(1)}),stderr:an({isTTY:k.isatty(2)})}}));function un(e,t,n){let r=e.indexOf(t);if(r===-1)return e;let i=t.length,a=0,o=``;do o+=e.slice(a,r)+t+n,a=r+i,r=e.indexOf(t,a);while(r!==-1);return o+=e.slice(a),o}function dn(e,t,n,r){let i=0,a=``;do{let o=e[r-1]===`\r`;a+=e.slice(i,o?r-1:r)+t+(o?`\r
2
+ `:`
3
+ `)+n,i=r+1,r=e.indexOf(`
4
+ `,i)}while(r!==-1);return a+=e.slice(i),a}var fn=t((()=>{}));function pn(e){return Cn(e)}var mn,hn,gn,_n,vn,yn,bn,xn,Sn,Cn,wn,Tn,En,Dn,On,V,kn=t((()=>{$t(),ln(),fn(),{stdout:mn,stderr:hn}=cn,gn=Symbol(`GENERATOR`),_n=Symbol(`STYLER`),vn=Symbol(`IS_EMPTY`),yn=[`ansi`,`ansi`,`ansi256`,`ansi16m`],bn=Object.create(null),xn=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw Error("The `level` option should be an integer from 0 to 3");let n=mn?mn.level:0;e.level=t.level===void 0?n:t.level},Sn=class{constructor(e){return Cn(e)}},Cn=e=>{let t=(...e)=>e.join(` `);return xn(t,e),Object.setPrototypeOf(t,pn.prototype),t},Object.setPrototypeOf(pn.prototype,Function.prototype);for(let[e,t]of Object.entries(Qt))bn[e]={get(){let n=Dn(this,En(t.open,t.close,this[_n]),this[vn]);return Object.defineProperty(this,e,{value:n}),n}};bn.visible={get(){let e=Dn(this,this[_n],!0);return Object.defineProperty(this,`visible`,{value:e}),e}},wn=(e,t,n,...r)=>e===`rgb`?t===`ansi16m`?Qt[n].ansi16m(...r):t===`ansi256`?Qt[n].ansi256(Qt.rgbToAnsi256(...r)):Qt[n].ansi(Qt.rgbToAnsi(...r)):e===`hex`?wn(`rgb`,t,n,...Qt.hexToRgb(...r)):Qt[n][e](...r);for(let e of[`rgb`,`hex`,`ansi256`]){bn[e]={get(){let{level:t}=this;return function(...n){let r=En(wn(e,yn[t],`color`,...n),Qt.color.close,this[_n]);return Dn(this,r,this[vn])}}};let t=`bg`+e[0].toUpperCase()+e.slice(1);bn[t]={get(){let{level:t}=this;return function(...n){let r=En(wn(e,yn[t],`bgColor`,...n),Qt.bgColor.close,this[_n]);return Dn(this,r,this[vn])}}}}Tn=Object.defineProperties(()=>{},{...bn,level:{enumerable:!0,get(){return this[gn].level},set(e){this[gn].level=e}}}),En=(e,t,n)=>{let r,i;return n===void 0?(r=e,i=t):(r=n.openAll+e,i=t+n.closeAll),{open:e,close:t,openAll:r,closeAll:i,parent:n}},Dn=(e,t,n)=>{let r=(...e)=>On(r,e.length===1?``+e[0]:e.join(` `));return Object.setPrototypeOf(r,Tn),r[gn]=e,r[_n]=t,r[vn]=n,r},On=(e,t)=>{if(e.level<=0||!t)return e[vn]?``:t;let n=e[_n];if(n===void 0)return t;let{openAll:r,closeAll:i}=n;if(t.includes(`\x1B`))for(;n!==void 0;)t=un(t,n.close,n.open),n=n.parent;let a=t.indexOf(`
5
+ `);return a!==-1&&(t=dn(t,i,r,a)),r+t+i},Object.defineProperties(pn.prototype,bn),V=pn(),pn({level:hn?hn.level:0})}));function An(){return process.env.TERM_PROGRAM===`vscode`&&V.level===2?(V.level=3,!0):!1}function jn(){return process.env.CLAUDE_CODE_TMUX_TRUECOLOR?!1:process.env.TMUX&&V.level>2?(V.level=2,!0):!1}function Mn(e,t){let n=e;return t.inverse&&(n=V.inverse(n)),t.strikethrough&&(n=V.strikethrough(n)),t.underline&&(n=V.underline(n)),t.italic&&(n=V.italic(n)),t.bold&&(n=V.bold(n)),t.dim&&(n=V.dim(n)),t.color&&(n=In(n,t.color,`foreground`)),t.backgroundColor&&(n=In(n,t.backgroundColor,`background`)),n}function Nn(e,t){return t?In(e,t,`foreground`):e}var Pn,Fn,In,Ln=t((()=>{kn(),An(),jn(),Pn=/^rgb\(\s?(\d+),\s?(\d+),\s?(\d+)\s?\)$/,Fn=/^ansi256\(\s?(\d+)\s?\)$/,In=(e,t,n)=>{if(!t)return e;if(t.startsWith(`ansi:`))switch(t.substring(5)){case`black`:return n===`foreground`?V.black(e):V.bgBlack(e);case`red`:return n===`foreground`?V.red(e):V.bgRed(e);case`green`:return n===`foreground`?V.green(e):V.bgGreen(e);case`yellow`:return n===`foreground`?V.yellow(e):V.bgYellow(e);case`blue`:return n===`foreground`?V.blue(e):V.bgBlue(e);case`magenta`:return n===`foreground`?V.magenta(e):V.bgMagenta(e);case`cyan`:return n===`foreground`?V.cyan(e):V.bgCyan(e);case`white`:return n===`foreground`?V.white(e):V.bgWhite(e);case`blackBright`:return n===`foreground`?V.blackBright(e):V.bgBlackBright(e);case`redBright`:return n===`foreground`?V.redBright(e):V.bgRedBright(e);case`greenBright`:return n===`foreground`?V.greenBright(e):V.bgGreenBright(e);case`yellowBright`:return n===`foreground`?V.yellowBright(e):V.bgYellowBright(e);case`blueBright`:return n===`foreground`?V.blueBright(e):V.bgBlueBright(e);case`magentaBright`:return n===`foreground`?V.magentaBright(e):V.bgMagentaBright(e);case`cyanBright`:return n===`foreground`?V.cyanBright(e):V.bgCyanBright(e);case`whiteBright`:return n===`foreground`?V.whiteBright(e):V.bgWhiteBright(e)}if(t.startsWith(`#`))return n===`foreground`?V.hex(t)(e):V.bgHex(t)(e);if(t.startsWith(`ansi256`)){let r=Fn.exec(t);if(!r)return e;let i=Number(r[1]);return n===`foreground`?V.ansi256(i)(e):V.bgAnsi256(i)(e)}if(t.startsWith(`rgb`)){let r=Pn.exec(t);if(!r)return e;let i=Number(r[1]),a=Number(r[2]),o=Number(r[3]);return n===`foreground`?V.rgb(i,a,o)(e):V.bgRgb(i,a,o)(e)}return e}})),Rn,zn=t((()=>{c(),Rn=class{constructor(){l(this,`_didStopImmediatePropagation`,!1)}didStopImmediatePropagation(){return this._didStopImmediatePropagation}stopImmediatePropagation(){this._didStopImmediatePropagation=!0}}})),Bn,Vn=t((()=>{zn(),Bn=class extends re{constructor(){super(),this.setMaxListeners(0)}emit(e,...t){if(e===`error`)return super.emit(e,...t);let n=this.rawListeners(e);if(n.length===0)return!1;let r=t[0]instanceof Rn?t[0]:null;for(let e of n)if(e.apply(this,t),r?.didStopImmediatePropagation())break;return!0}}}));function Hn(e){return e>=48&&e<=126}var Un,Wn,Gn=t((()=>{Un={NUL:0,SOH:1,STX:2,ETX:3,EOT:4,ENQ:5,ACK:6,BEL:7,BS:8,HT:9,LF:10,VT:11,FF:12,CR:13,SO:14,SI:15,DLE:16,DC1:17,DC2:18,DC3:19,DC4:20,NAK:21,SYN:22,ETB:23,CAN:24,EM:25,SUB:26,ESC:27,FS:28,GS:29,RS:30,US:31,DEL:127},Wn={CSI:91,OSC:93,DCS:80,APC:95,PM:94,SOS:88,ST:92}}));function Kn(e){return e>=cr.PARAM_START&&e<=cr.PARAM_END}function qn(e){return e>=cr.INTERMEDIATE_START&&e<=cr.INTERMEDIATE_END}function Jn(e){return e>=cr.FINAL_START&&e<=cr.FINAL_END}function Yn(...e){if(e.length===0)return sr;if(e.length===1)return`${sr}${e[0]}`;let t=e.slice(0,-1),n=e[e.length-1];return`${sr}${t.join(`;`)}${n}`}function Xn(e=1){return e===0?``:Yn(e,`A`)}function Zn(e=1){return e===0?``:Yn(e,`B`)}function Qn(e=1){return e===0?``:Yn(e,`C`)}function $n(e=1){return e===0?``:Yn(e,`D`)}function er(e){return Yn(e,`G`)}function tr(e,t){return Yn(e,t,`H`)}function nr(e,t){let n=``;return e<0?n+=$n(-e):e>0&&(n+=Qn(e)),t<0?n+=Xn(-t):t>0&&(n+=Zn(t)),n}function rr(e){if(e<=0)return``;let t=``;for(let n=0;n<e;n++)t+=hr,n<e-1&&(t+=Xn(1));return t+=pr,t}function ir(e=1){return e===0?``:Yn(e,`S`)}function ar(e=1){return e===0?``:Yn(e,`T`)}function or(e,t){return Yn(e,t,`r`)}var sr,cr,lr,ur,dr,fr,pr,mr,hr,gr,_r,vr,yr,br,xr,Sr,Cr,wr,Tr,Er,Dr=t((()=>{Gn(),sr=`\x1B`+String.fromCharCode(Wn.CSI),cr={PARAM_START:48,PARAM_END:63,INTERMEDIATE_START:32,INTERMEDIATE_END:47,FINAL_START:64,FINAL_END:126},lr={CUU:65,CUD:66,CUF:67,CUB:68,CNL:69,CPL:70,CHA:71,CUP:72,CHT:73,VPA:100,HVP:102,ED:74,EL:75,ECH:88,IL:76,DL:77,ICH:64,DCH:80,SU:83,SD:84,SM:104,RM:108,SGR:109,DSR:110,DECSCUSR:113,DECSTBM:114,SCOSC:115,SCORC:117,CBT:90},ur=[`toEnd`,`toStart`,`all`,`scrollback`],dr=[`toEnd`,`toStart`,`all`],fr=[{style:`block`,blinking:!0},{style:`block`,blinking:!0},{style:`block`,blinking:!1},{style:`underline`,blinking:!0},{style:`underline`,blinking:!1},{style:`bar`,blinking:!0},{style:`bar`,blinking:!1}],pr=Yn(`G`),mr=Yn(`H`),Yn(`s`),Yn(`u`),hr=Yn(2,`K`),gr=Yn(2,`J`),_r=Yn(3,`J`),vr=Yn(`r`),yr=Yn(`200~`),br=Yn(`201~`),xr=Yn(`I`),Sr=Yn(`O`),Cr=Yn(`>1u`),wr=Yn(`<u`),Tr=Yn(`>4;2m`),Er=Yn(`>4m`)}));function Or(e){let t=`ground`,n=``,r=e?.x10Mouse??!1;return{feed(e){let i=kr(e,t,n,!1,r);return t=i.state.state,n=i.state.buffer,i.tokens},flush(){let e=kr(``,t,n,!0,r);return t=e.state.state,n=e.state.buffer,e.tokens},reset(){t=`ground`,n=``},buffer(){return n}}}function kr(e,t,n,r,i){let a=[],o={state:t,buffer:``},s=n+e,c=0,l=0,u=0,d=()=>{if(c>l){let e=s.slice(l,c);e&&a.push({type:`text`,value:e})}l=c},f=e=>{e&&a.push({type:`sequence`,value:e}),o.state=`ground`,l=c};for(;c<s.length;){let e=s.charCodeAt(c);switch(o.state){case`ground`:e===Un.ESC?(d(),u=c,o.state=`escape`,c++):c++;break;case`escape`:e===Wn.CSI?(o.state=`csi`,c++):e===Wn.OSC?(o.state=`osc`,c++):e===Wn.DCS?(o.state=`dcs`,c++):e===Wn.APC?(o.state=`apc`,c++):e===79?(o.state=`ss3`,c++):qn(e)?(o.state=`escapeIntermediate`,c++):Hn(e)?(c++,f(s.slice(u,c))):e===Un.ESC?(f(s.slice(u,c)),u=c,o.state=`escape`,c++):(o.state=`ground`,l=u);break;case`escapeIntermediate`:qn(e)?c++:Hn(e)?(c++,f(s.slice(u,c))):(o.state=`ground`,l=u);break;case`csi`:if(i&&e===77&&c-u===2&&(c+1>=s.length||s.charCodeAt(c+1)>=32)&&(c+2>=s.length||s.charCodeAt(c+2)>=32)&&(c+3>=s.length||s.charCodeAt(c+3)>=32)){c+4<=s.length?(c+=4,f(s.slice(u,c))):c=s.length;break}Jn(e)?(c++,f(s.slice(u,c))):Kn(e)||qn(e)?c++:(o.state=`ground`,l=u);break;case`ss3`:e>=64&&e<=126?(c++,f(s.slice(u,c))):(o.state=`ground`,l=u);break;case`osc`:e===Un.BEL?(c++,f(s.slice(u,c))):e===Un.ESC&&c+1<s.length&&s.charCodeAt(c+1)===Wn.ST?(c+=2,f(s.slice(u,c))):c++;break;case`dcs`:case`apc`:e===Un.BEL?(c++,f(s.slice(u,c))):e===Un.ESC&&c+1<s.length&&s.charCodeAt(c+1)===Wn.ST?(c+=2,f(s.slice(u,c))):c++;break}}if(o.state===`ground`)d();else if(r){let e=s.slice(u);e&&a.push({type:`sequence`,value:e}),o.state=`ground`}else o.buffer=s.slice(u);return{tokens:a,state:o}}var Ar=t((()=>{Gn(),Dr()}));function jr(e){return{kind:`key`,name:``,fn:!1,ctrl:!1,meta:!1,shift:!1,option:!1,super:!1,sequence:e,raw:e,isPasted:!0}}function Mr(e){if(e.startsWith(`\x1B[`)){let t;return(t=Gr.exec(e))?{type:`decrpm`,mode:parseInt(t[1],10),status:parseInt(t[2],10)}:(t=Kr.exec(e))?{type:`da1`,params:Nr(t[1])}:(t=qr.exec(e))?{type:`da2`,params:Nr(t[1])}:(t=Jr.exec(e))?{type:`kittyKeyboard`,flags:parseInt(t[1],10)}:(t=Yr.exec(e))?{type:`cursorPosition`,row:parseInt(t[1],10),col:parseInt(t[2],10)}:null}if(e.startsWith(`\x1B]`)){let t=Xr.exec(e);if(t)return{type:`osc`,code:parseInt(t[1],10),data:t[2]}}if(e.startsWith(`\x1BP`)){let t=Zr.exec(e);if(t)return{type:`xtversion`,name:t[1]}}return null}function Nr(e){return e?e.split(`;`).map(e=>parseInt(e,10)):[]}function Pr(e){return ee.isBuffer(e)?e[0]>127&&e[1]===void 0?(e[0]-=128,`\x1B`+String(e)):String(e):e!==void 0&&typeof e!=`string`?String(e):e||``}function Fr(e,t=``){let n=t===null,r=n?``:Pr(t),i=e._tokenizer??Or({x10Mouse:!0}),a=n?i.flush():i.feed(r),o=[],s=e.mode===`IN_PASTE`,c=e.pasteBuffer;for(let e of a)if(e.type===`sequence`)if(e.value===yr)s=!0,c=``;else if(e.value===br)o.push(jr(c)),s=!1,c=``;else if(s)c+=e.value;else{let t=Mr(e.value);if(t)o.push({kind:`response`,sequence:e.value,response:t});else{let t=Rr(e.value);t?o.push(t):o.push(zr(e.value))}}else if(e.type===`text`)if(s)c+=e.value;else if(/^\[<\d+;\d+;\d+[Mm]$/.test(e.value)||/^\[M[\x60-\x7f][\x20-\uffff]{2}$/.test(e.value)){let t=`\x1B`+e.value,n=Rr(t);o.push(n??zr(t))}else o.push(zr(e.value));return n&&s&&c&&(o.push(jr(c)),s=!1,c=``),[o,{mode:s?`IN_PASTE`:`NORMAL`,incomplete:i.buffer(),pasteBuffer:c,_tokenizer:i}]}function Ir(e){let t=e-1;return{shift:!!(t&1),meta:!!(t&2),ctrl:!!(t&4),super:!!(t&8)}}function Lr(e){switch(e){case 9:return`tab`;case 13:return`return`;case 27:return`escape`;case 32:return`space`;case 127:return`backspace`;case 57399:return`0`;case 57400:return`1`;case 57401:return`2`;case 57402:return`3`;case 57403:return`4`;case 57404:return`5`;case 57405:return`6`;case 57406:return`7`;case 57407:return`8`;case 57408:return`9`;case 57409:return`.`;case 57410:return`/`;case 57411:return`*`;case 57412:return`-`;case 57413:return`+`;case 57414:return`return`;case 57415:return`=`;default:return e>=32&&e<=126?String.fromCharCode(e).toLowerCase():void 0}}function Rr(e){let t=Qr.exec(e);if(!t)return null;let n=parseInt(t[1],10);return n&64?null:{kind:`mouse`,button:n,action:t[4]===`M`?`press`:`release`,col:parseInt(t[2],10),row:parseInt(t[3],10),sequence:e}}function zr(e=``){let t,n={kind:`key`,name:``,fn:!1,ctrl:!1,meta:!1,shift:!1,option:!1,super:!1,sequence:e,raw:e,isPasted:!1};n.sequence=n.sequence||e||n.name;let r;if(r=Ur.exec(e)){let t=parseInt(r[1],10),n=Ir(r[2]?parseInt(r[2],10):1);return{kind:`key`,name:Lr(t),fn:!1,ctrl:n.ctrl,meta:n.meta,shift:n.shift,option:!1,super:n.super,sequence:e,raw:e,isPasted:!1}}if(r=Wr.exec(e)){let t=Ir(parseInt(r[1],10));return{kind:`key`,name:Lr(parseInt(r[2],10)),fn:!1,ctrl:t.ctrl,meta:t.meta,shift:t.shift,option:!1,super:t.super,sequence:e,raw:e,isPasted:!1}}if(r=Qr.exec(e)){let t=parseInt(r[1],10);return(t&67)==64?Br(e,`wheelup`,!1):(t&67)==65?Br(e,`wheeldown`,!1):Br(e,`mouse`,!1)}if(e.length===6&&e.startsWith(`\x1B[M`)){let t=e.charCodeAt(3)-32;return(t&67)==64?Br(e,`wheelup`,!1):(t&67)==65?Br(e,`wheeldown`,!1):Br(e,`mouse`,!1)}if(e===`\r`)n.raw=void 0,n.name=`return`;else if(e===`
6
+ `)n.name=`enter`;else if(e===` `)n.name=`tab`;else if(e===`\b`||e===`\x1B\b`)n.name=`backspace`,n.meta=e.charAt(0)===`\x1B`;else if(e===``||e===`\x1B`)n.name=`backspace`,n.meta=e.charAt(0)===`\x1B`;else if(e===`\x1B`||e===`\x1B\x1B`)n.name=`escape`,n.meta=e.length===2;else if(e===` `||e===`\x1B `)n.name=`space`,n.meta=e.length===2;else if(e===``)n.name=`_`,n.ctrl=!0;else if(e<=``&&e.length===1)n.name=String.fromCharCode(e.charCodeAt(0)+97-1),n.ctrl=!0;else if(e.length===1&&e>=`0`&&e<=`9`)n.name=`number`;else if(e.length===1&&e>=`a`&&e<=`z`)n.name=e;else if(e.length===1&&e>=`A`&&e<=`Z`)n.name=e.toLowerCase(),n.shift=!0;else if(t=Vr.exec(e))n.meta=!0,n.shift=/^[A-Z]$/.test(t[1]);else if(t=Hr.exec(e)){let r=[...e];r[0]===`\x1B`&&r[1]===`\x1B`&&(n.option=!0);let i=[t[1],t[2],t[4],t[6]].filter(Boolean).join(``),a=(t[3]||t[5]||1)-1;n.ctrl=!!(a&4),n.meta=!!(a&2),n.super=!!(a&8),n.shift=!!(a&1),n.code=i,n.name=ei[i],n.shift=ni(i)||n.shift,n.ctrl=ri(i)||n.ctrl}switch(n.raw===`\x1Bb`?(n.meta=!0,n.name=`left`):n.raw===`\x1Bf`&&(n.meta=!0,n.name=`right`),e){case`\x1B[1~`:return Br(e,`home`,!1);case`\x1B[4~`:return Br(e,`end`,!1);case`\x1B[5~`:return Br(e,`pageup`,!1);case`\x1B[6~`:return Br(e,`pagedown`,!1);case`\x1B[1;5D`:return Br(e,`left`,!0);case`\x1B[1;5C`:return Br(e,`right`,!0)}return n}function Br(e,t,n){return{kind:`key`,name:t,ctrl:n,meta:!1,shift:!1,option:!1,super:!1,fn:!1,sequence:e,raw:e,isPasted:!1}}var Vr,Hr,Ur,Wr,Gr,Kr,qr,Jr,Yr,Xr,Zr,Qr,$r,ei,ti,ni,ri,ii=t((()=>{Dr(),Ar(),Vr=/^(?:\x1b)([a-zA-Z0-9])$/,Hr=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,Ur=/^\x1b\[(\d+)(?:;(\d+))?u/,Wr=/^\x1b\[27;(\d+);(\d+)~/,Gr=/^\x1b\[\?(\d+);(\d+)\$y$/,Kr=/^\x1b\[\?([\d;]*)c$/,qr=/^\x1b\[>([\d;]*)c$/,Jr=/^\x1b\[\?(\d+)u$/,Yr=/^\x1b\[\?(\d+);(\d+)R$/,Xr=/^\x1b\](\d+);(.*?)(?:\x07|\x1b\\)$/s,Zr=/^\x1bP>\|(.*?)(?:\x07|\x1b\\)$/s,Qr=/^\x1b\[<(\d+);(\d+);(\d+)([Mm])$/,$r={mode:`NORMAL`,incomplete:``,pasteBuffer:``},ei={OP:`f1`,OQ:`f2`,OR:`f3`,OS:`f4`,Op:`0`,Oq:`1`,Or:`2`,Os:`3`,Ot:`4`,Ou:`5`,Ov:`6`,Ow:`7`,Ox:`8`,Oy:`9`,Oj:`*`,Ok:`+`,Ol:`,`,Om:`-`,On:`.`,Oo:`/`,OM:`return`,"[11~":`f1`,"[12~":`f2`,"[13~":`f3`,"[14~":`f4`,"[[A":`f1`,"[[B":`f2`,"[[C":`f3`,"[[D":`f4`,"[[E":`f5`,"[15~":`f5`,"[17~":`f6`,"[18~":`f7`,"[19~":`f8`,"[20~":`f9`,"[21~":`f10`,"[23~":`f11`,"[24~":`f12`,"[A":`up`,"[B":`down`,"[C":`right`,"[D":`left`,"[E":`clear`,"[F":`end`,"[H":`home`,OA:`up`,OB:`down`,OC:`right`,OD:`left`,OE:`clear`,OF:`end`,OH:`home`,"[1~":`home`,"[2~":`insert`,"[3~":`delete`,"[4~":`end`,"[5~":`pageup`,"[6~":`pagedown`,"[[5~":`pageup`,"[[6~":`pagedown`,"[7~":`home`,"[8~":`end`,"[a":`up`,"[b":`down`,"[c":`right`,"[d":`left`,"[e":`clear`,"[2$":`insert`,"[3$":`delete`,"[5$":`pageup`,"[6$":`pagedown`,"[7$":`home`,"[8$":`end`,Oa:`up`,Ob:`down`,Oc:`right`,Od:`left`,Oe:`clear`,"[2^":`insert`,"[3^":`delete`,"[5^":`pageup`,"[6^":`pagedown`,"[7^":`home`,"[8^":`end`,"[Z":`tab`},ti=[...Object.values(ei).filter(e=>e.length>1),`escape`,`backspace`,`wheelup`,`wheeldown`,`mouse`],ni=e=>[`[a`,`[b`,`[c`,`[d`,`[e`,`[2$`,`[3$`,`[5$`,`[6$`,`[7$`,`[8$`,`[Z`].includes(e),ri=e=>[`Oa`,`Ob`,`Oc`,`Od`,`Oe`,`[2^`,`[3^`,`[5^`,`[6^`,`[7^`,`[8^`].includes(e)}));function ai(e){let t={upArrow:e.name===`up`,downArrow:e.name===`down`,leftArrow:e.name===`left`,rightArrow:e.name===`right`,pageDown:e.name===`pagedown`,pageUp:e.name===`pageup`,wheelUp:e.name===`wheelup`,wheelDown:e.name===`wheeldown`,home:e.name===`home`,end:e.name===`end`,return:e.name===`return`,escape:e.name===`escape`,fn:e.fn,ctrl:e.ctrl,shift:e.shift,tab:e.name===`tab`,backspace:e.name===`backspace`,delete:e.name===`delete`,meta:e.meta||e.name===`escape`||e.option,super:e.super},n=e.ctrl?e.name:e.sequence;n===void 0&&(n=``),e.ctrl&&n===`space`&&(n=` `),e.code&&!e.name&&(n=``),!e.name&&/^\[<\d+;\d+;\d+[Mm]/.test(n)&&(n=``),n.startsWith(`\x1B`)&&(n=n.slice(1));let r=!1;return/^\[\d/.test(n)&&n.endsWith(`u`)&&(n=e.name?e.name===`space`?` `:e.name===`escape`?``:e.name:``,r=!0),n.startsWith(`[27;`)&&n.endsWith(`~`)&&(n=e.name?e.name===`space`?` `:e.name===`escape`?``:e.name:``,r=!0),n.startsWith(`O`)&&n.length===2&&e.name&&e.name.length===1&&(n=e.name,r=!0),!r&&e.name&&ti.includes(e.name)&&(n=``),n.length===1&&typeof n[0]==`string`&&n[0]>=`A`&&n[0]<=`Z`&&(t.shift=!0),[t,n]}var oi,si=t((()=>{ii(),zn(),c(),oi=class extends Rn{constructor(e){super(),l(this,`keypress`,void 0),l(this,`key`,void 0),l(this,`input`,void 0);let[t,n]=ai(e);this.keypress=e,this.key=t,this.input=n}}})),ci,li=t((()=>{zn(),c(),ci=class extends Rn{constructor(e){super(),l(this,`type`,void 0),this.type=e}}})),ui=r((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&k(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&k(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,te=ee.port2;ee.port1.onmessage=D,O=function(){te.postMessage(null)}}else O=function(){_(D,0)};function k(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,k(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),di=r(((e,t)=>{t.exports=ui()})),fi=r(((e,t)=>{t.exports=function(e){function t(e,t,n,r){return new fa(e,t,n,r)}function n(){}function r(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function i(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function a(e){if(i(e)!==e)throw Error(r(188))}function o(e){var t=e.alternate;if(!t){if(t=i(e),t===null)throw Error(r(188));return t===e?e:null}for(var n=e,o=t;;){var s=n.return;if(s===null)break;var c=s.alternate;if(c===null){if(o=s.return,o!==null){n=o;continue}break}if(s.child===c.child){for(c=s.child;c;){if(c===n)return a(s),e;if(c===o)return a(s),t;c=c.sibling}throw Error(r(188))}if(n.return!==o.return)n=s,o=c;else{for(var l=!1,u=s.child;u;){if(u===n){l=!0,n=s,o=c;break}if(u===o){l=!0,o=s,n=c;break}u=u.sibling}if(!l){for(u=c.child;u;){if(u===n){l=!0,n=c,o=s;break}if(u===o){l=!0,o=c,n=s;break}u=u.sibling}if(!l)throw Error(r(189))}}if(n.alternate!==o)throw Error(r(190))}if(n.tag!==3)throw Error(r(188));return n.stateNode.current===n?e:t}function s(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=s(e),t!==null)return t;e=e.sibling}return null}function c(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(e.tag!==4&&(t=c(e),t!==null))return t;e=e.sibling}return null}function l(e){return typeof e!=`object`||!e?null:(e=Ka&&e[Ka]||e[`@@iterator`],typeof e==`function`?e:null)}function u(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===qa?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case Pa:return`Fragment`;case Ia:return`Profiler`;case Fa:return`StrictMode`;case Ba:return`Suspense`;case Va:return`SuspenseList`;case Wa:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case Na:return`Portal`;case Ra:return e.displayName||`Context`;case La:return(e._context.displayName||`Context`)+`.Consumer`;case za:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||``,e=e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case Ha:return t=e.displayName||null,t===null?u(e.type)||`Memo`:t;case Ua:t=e._payload,e=e._init;try{return u(e(t))}catch{}}return null}function d(e){return{current:e}}function f(e){0>mc||(e.current=pc[mc],pc[mc]=null,mc--)}function p(e,t){mc++,pc[mc]=e.current,e.current=t}function m(e){return e>>>=0,e===0?32:31-(_c(e)/vc|0)|0}function h(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function g(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=h(n))):i=h(o):i=h(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=h(n))):i=h(o)):i=h(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function _(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function v(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function y(){var e=xc;return xc<<=1,!(xc&62914560)&&(xc=4194304),e}function b(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function x(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function S(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-gc(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&C(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function C(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-gc(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function w(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-gc(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function T(e,t){var n=t&-t;return n=n&42?1:E(n),(n&(e.suspendedLanes|t))===0?n:0}function E(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function D(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function O(e){if(typeof jc==`function`&&Mc(e),Pc&&typeof Pc.setStrictMode==`function`)try{Pc.setStrictMode(Nc,e)}catch{}}function ee(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}function te(e){if(Rc===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);Rc=t&&t[1]||``,zc=-1<e.stack.indexOf(`
7
+ at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
8
+ `+Rc+e+zc}function k(e,t){if(!e||Bc)return``;Bc=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,`props`,{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,`name`,{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
9
+ `),l=s.split(`
10
+ `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
11
+ `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{Bc=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?te(n):``}function ne(e,t){switch(e.tag){case 26:case 27:case 5:return te(e.type);case 16:return te(`Lazy`);case 13:return e.child!==t&&t!==null?te(`Suspense Fallback`):te(`Suspense`);case 19:return te(`SuspenseList`);case 0:case 15:return k(e.type,!1);case 11:return k(e.type.render,!1);case 1:return k(e.type,!0);case 31:return te(`Activity`);default:return``}}function re(e){try{var t=``,n=null;do t+=ne(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
12
+ Error generating stack: `+e.message+`
13
+ `+e.stack}}function ie(e,t){if(typeof e==`object`&&e){var n=Vc.get(e);return n===void 0?(t={value:e,source:t,stack:re(t)},Vc.set(e,t),t):n}return{value:e,source:t,stack:re(t)}}function ae(e,t){Hc[Uc++]=Gc,Hc[Uc++]=Wc,Wc=e,Gc=t}function oe(e,t,n){Kc[qc++]=Yc,Kc[qc++]=Xc,Kc[qc++]=Jc,Jc=e;var r=Yc;e=Xc;var i=32-gc(r)-1;r&=~(1<<i),n+=1;var a=32-gc(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Yc=1<<32-gc(t)+i|n<<i|r,Xc=a+e}else Yc=1<<a|n<<i|r,Xc=e}function se(e){e.return!==null&&(ae(e,1),oe(e,1,0))}function ce(e){for(;e===Wc;)Wc=Hc[--Uc],Hc[Uc]=null,Gc=Hc[--Uc],Hc[Uc]=null;for(;e===Jc;)Jc=Kc[--qc],Kc[qc]=null,Xc=Kc[--qc],Kc[qc]=null,Yc=Kc[--qc],Kc[qc]=null}function le(e,t){Kc[qc++]=Yc,Kc[qc++]=Xc,Kc[qc++]=Jc,Yc=t.id,Xc=t.overflow,Jc=e}function ue(e,t){p($c,t),p(Qc,e),p(Zc,null),e=$a(t),f(Zc),p(Zc,e)}function de(){f(Zc),f(Qc),f($c)}function fe(e){e.memoizedState!==null&&p(el,e);var t=Zc.current,n=eo(t,e.type);t!==n&&(p(Qc,e),p(Zc,n))}function pe(e){Qc.current===e&&(f(Zc),f(Qc)),el.current===e&&(f(el),fo?jo._currentValue=Ao:jo._currentValue2=Ao)}function A(e){throw ve(ie(Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),al}function me(e,t){if(!ho)throw Error(r(175));Os(e.stateNode,e.type,e.memoizedProps,t,e)||A(e,!0)}function he(e){for(tl=e.return;tl;)switch(tl.tag){case 5:case 31:case 13:il=!1;return;case 27:case 3:il=!0;return;default:tl=tl.return}}function ge(e){if(!ho||e!==tl)return!1;if(!K)return he(e),K=!0,!1;var t=e.tag;if(sc?t!==3&&t!==27&&(t!==5||Ws(e.type)&&!oo(e.type,e.memoizedProps))&&nl&&A(e):t!==3&&(t!==5||Ws(e.type)&&!oo(e.type,e.memoizedProps))&&nl&&A(e),he(e),t===13){if(!ho)throw Error(r(316));if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(r(317));nl=Ns(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(r(317));nl=Ms(e)}else nl=sc&&t===27?vs(e.type,nl):tl?_s(e.stateNode):null;return!0}function j(){ho&&(nl=tl=null,K=!1)}function _e(){var e=rl;return e!==null&&(Lu===null?Lu=e:Lu.push.apply(Lu,e),rl=null),e}function ve(e){rl===null?rl=[e]:rl.push(e)}function ye(e,t,n){fo?(p(ol,t._currentValue),t._currentValue=n):(p(ol,t._currentValue2),t._currentValue2=n)}function M(e){var t=ol.current;fo?e._currentValue=t:e._currentValue2=t,f(ol)}function be(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function xe(e,t,n,i){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),be(o.return,n,e),i||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(r(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),be(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function Se(e,t,n,i){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(r(387));if(s=s.memoizedProps,s!==null){var c=a.type;Fc(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===el.current){if(s=a.alternate,s===null)throw Error(r(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[jo]:e.push(jo))}a=a.return}e!==null&&xe(t,e,n,i),t.flags|=262144}function Ce(e){for(e=e.firstContext;e!==null;){var t=e.context;if(!Fc(fo?t._currentValue:t._currentValue2,e.memoizedValue))return!0;e=e.next}return!1}function we(e){sl=e,cl=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Te(e){return De(sl,e)}function Ee(e,t){return sl===null&&we(e),De(e,t)}function De(e,t){var n=fo?t._currentValue:t._currentValue2;if(t={context:t,memoizedValue:n,next:null},cl===null){if(e===null)throw Error(r(308));cl=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else cl=cl.next=t;return n}function Oe(){return{controller:new ll,data:new Map,refCount:0}}function ke(e){e.refCount--,e.refCount===0&&ul(dl,function(){e.controller.abort()})}function Ae(){}function je(e){e!==ml&&e.next===null&&(ml===null?pl=ml=e:ml=ml.next=e),gl=!0,hl||(hl=!0,Ie())}function Me(e,t){if(!_l&&gl){_l=!0;do for(var n=!1,r=pl;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-gc(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,Fe(r,a))}else a=Z,a=g(r,r===wu?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==uo),!(a&3)||_(r,a)||(n=!0,Fe(r,a));r=r.next}while(n);_l=!1}}function P(){Ne()}function Ne(){gl=hl=!1;var e=0;vl!==0&&xo()&&(e=vl);for(var t=Ec(),n=null,r=pl;r!==null;){var i=r.next,a=Pe(r,t);a===0?(r.next=null,n===null?pl=i:n.next=i,i===null&&(ml=n)):(n=r,(e!==0||a&3)&&(gl=!0)),r=i}Wu!==0&&Wu!==5||Me(e,!1),vl!==0&&(vl=0)}function Pe(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-gc(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=v(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=wu,n=Z,n=g(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==uo),r=e.callbackNode,n===0||e===t&&(Q===2||Q===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&Cc(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||_(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&Cc(r),D(n)){case 2:case 8:n=Oc;break;case 32:n=kc;break;case 268435456:n=Ac;break;default:n=kc}return r=F.bind(null,e),n=Sc(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&Cc(r),e.callbackPriority=2,e.callbackNode=null,2}function F(e,t){if(Wu!==0&&Wu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(ra()&&e.callbackNode!==n)return null;var r=Z;return r=g(e,e===wu?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==uo),r===0?null:(ji(e,r,t),Pe(e,Ec()),e.callbackNode!=null&&e.callbackNode===n?F.bind(null,e):null)}function Fe(e,t){if(ra())return null;ji(e,t,!0)}function Ie(){No?Po(function(){Y&6?Sc(Dc,P):Ne()}):Sc(Dc,P)}function Le(){if(vl===0){var e=xl;e===0&&(e=yc,yc<<=1,!(yc&261888)&&(yc=256)),vl=e}return vl}function Re(e,t){if(yl===null){var n=yl=[];bl=0,xl=Le(),Sl={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return bl++,t.then(I,I),t}function I(){if(--bl===0&&yl!==null){Sl!==null&&(Sl.status=`fulfilled`);var e=yl;yl=null,xl=0,Sl=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function ze(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}function Be(){var e=wl.current;return e===null?wu.pooledCache:e}function Ve(e,t){t===null?p(wl,wl.current):p(wl,t.pool)}function He(){var e=Be();return e===null?null:{parent:fo?fl._currentValue:fl._currentValue2,pool:e}}function Ue(e,t){if(Fc(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Lc.call(t,i)||!Fc(e[i],t[i]))return!1}return!0}function We(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Ge(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Ae,Ae),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ke(e),e;default:if(typeof t.status==`string`)t.then(Ae,Ae);else{if(e=wu,e!==null&&100<e.shellSuspendCounter)throw Error(r(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ke(e),e}throw kl=t,Tl}}function L(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(kl=e,Tl):e}}function R(){if(kl===null)throw Error(r(459));var e=kl;return kl=null,e}function Ke(e){if(e===Tl||e===Dl)throw Error(r(483))}function qe(e){var t=jl;return jl+=1,Al===null&&(Al=[]),Ge(Al,e,t)}function Je(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Ye(e,t){throw t.$$typeof===ja?Error(r(525)):(e=Object.prototype.toString.call(t),Error(r(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Xe(e){function n(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function i(t,r){if(!e)return null;for(;r!==null;)n(t,r),r=r.sibling;return null}function a(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function o(e,t){return e=ma(e,t),e.index=0,e.sibling=null,e}function s(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function c(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function u(e,t,n,r){return t===null||t.tag!==6?(t=va(n,e.mode,r),t.return=e,t):(t=o(t,n),t.return=e,t)}function d(e,t,n,r){var i=n.type;return i===Pa?p(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===Ua&&L(i)===t.type)?(t=o(t,n.props),Je(t,n),t.return=e,t):(t=ga(n.type,n.key,n.props,null,e.mode,r),Je(t,n),t.return=e,t)}function f(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=ba(n,e.mode,r),t.return=e,t):(t=o(t,n.children||[]),t.return=e,t)}function p(e,t,n,r,i){return t===null||t.tag!==7?(t=_a(n,e.mode,r,i),t.return=e,t):(t=o(t,n),t.return=e,t)}function m(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=va(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case Ma:return n=ga(t.type,t.key,t.props,null,e.mode,n),Je(n,t),n.return=e,n;case Na:return t=ba(t,e.mode,n),t.return=e,t;case Ua:return t=L(t),m(e,t,n)}if(Ja(t)||l(t))return t=_a(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return m(e,qe(t),n);if(t.$$typeof===Ra)return m(e,Ee(e,t),n);Ye(e,t)}return null}function h(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?u(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case Ma:return n.key===i?d(e,t,n,r):null;case Na:return n.key===i?f(e,t,n,r):null;case Ua:return n=L(n),h(e,t,n,r)}if(Ja(n)||l(n))return i===null?p(e,t,n,r,null):null;if(typeof n.then==`function`)return h(e,t,qe(n),r);if(n.$$typeof===Ra)return h(e,t,Ee(e,n),r);Ye(e,n)}return null}function g(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,u(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case Ma:return e=e.get(r.key===null?n:r.key)||null,d(t,e,r,i);case Na:return e=e.get(r.key===null?n:r.key)||null,f(t,e,r,i);case Ua:return r=L(r),g(e,t,n,r,i)}if(Ja(r)||l(r))return e=e.get(n)||null,p(t,e,r,i,null);if(typeof r.then==`function`)return g(e,t,n,qe(r),i);if(r.$$typeof===Ra)return g(e,t,n,Ee(t,r),i);Ye(t,r)}return null}function _(t,r,o,c){for(var l=null,u=null,d=r,f=r=0,p=null;d!==null&&f<o.length;f++){d.index>f?(p=d,d=null):p=d.sibling;var _=h(t,d,o[f],c);if(_===null){d===null&&(d=p);break}e&&d&&_.alternate===null&&n(t,d),r=s(_,r,f),u===null?l=_:u.sibling=_,u=_,d=p}if(f===o.length)return i(t,d),K&&ae(t,f),l;if(d===null){for(;f<o.length;f++)d=m(t,o[f],c),d!==null&&(r=s(d,r,f),u===null?l=d:u.sibling=d,u=d);return K&&ae(t,f),l}for(d=a(d);f<o.length;f++)p=g(d,t,f,o[f],c),p!==null&&(e&&p.alternate!==null&&d.delete(p.key===null?f:p.key),r=s(p,r,f),u===null?l=p:u.sibling=p,u=p);return e&&d.forEach(function(e){return n(t,e)}),K&&ae(t,f),l}function v(t,o,c,l){if(c==null)throw Error(r(151));for(var u=null,d=null,f=o,p=o=0,_=null,v=c.next();f!==null&&!v.done;p++,v=c.next()){f.index>p?(_=f,f=null):_=f.sibling;var y=h(t,f,v.value,l);if(y===null){f===null&&(f=_);break}e&&f&&y.alternate===null&&n(t,f),o=s(y,o,p),d===null?u=y:d.sibling=y,d=y,f=_}if(v.done)return i(t,f),K&&ae(t,p),u;if(f===null){for(;!v.done;p++,v=c.next())v=m(t,v.value,l),v!==null&&(o=s(v,o,p),d===null?u=v:d.sibling=v,d=v);return K&&ae(t,p),u}for(f=a(f);!v.done;p++,v=c.next())v=g(f,t,p,v.value,l),v!==null&&(e&&v.alternate!==null&&f.delete(v.key===null?p:v.key),o=s(v,o,p),d===null?u=v:d.sibling=v,d=v);return e&&f.forEach(function(e){return n(t,e)}),K&&ae(t,p),u}function y(e,t,a,s){if(typeof a==`object`&&a&&a.type===Pa&&a.key===null&&(a=a.props.children),typeof a==`object`&&a){switch(a.$$typeof){case Ma:a:{for(var u=a.key;t!==null;){if(t.key===u){if(u=a.type,u===Pa){if(t.tag===7){i(e,t.sibling),s=o(t,a.props.children),s.return=e,e=s;break a}}else if(t.elementType===u||typeof u==`object`&&u&&u.$$typeof===Ua&&L(u)===t.type){i(e,t.sibling),s=o(t,a.props),Je(s,a),s.return=e,e=s;break a}i(e,t);break}else n(e,t);t=t.sibling}a.type===Pa?(s=_a(a.props.children,e.mode,s,a.key),s.return=e,e=s):(s=ga(a.type,a.key,a.props,null,e.mode,s),Je(s,a),s.return=e,e=s)}return c(e);case Na:a:{for(u=a.key;t!==null;){if(t.key===u)if(t.tag===4&&t.stateNode.containerInfo===a.containerInfo&&t.stateNode.implementation===a.implementation){i(e,t.sibling),s=o(t,a.children||[]),s.return=e,e=s;break a}else{i(e,t);break}else n(e,t);t=t.sibling}s=ba(a,e.mode,s),s.return=e,e=s}return c(e);case Ua:return a=L(a),y(e,t,a,s)}if(Ja(a))return _(e,t,a,s);if(l(a)){if(u=l(a),typeof u!=`function`)throw Error(r(150));return a=u.call(a),v(e,t,a,s)}if(typeof a.then==`function`)return y(e,t,qe(a),s);if(a.$$typeof===Ra)return y(e,t,Ee(e,a),s);Ye(e,a)}return typeof a==`string`&&a!==``||typeof a==`number`||typeof a==`bigint`?(a=``+a,t!==null&&t.tag===6?(i(e,t.sibling),s=o(t,a),s.return=e,e=s):(i(e,t),s=va(a,e.mode,s),s.return=e,e=s),c(e)):i(e,t)}return function(e,n,r,i){try{jl=0;var a=y(e,n,r,i);return Al=null,a}catch(n){if(n===Tl||n===Dl)throw n;var o=t(29,n,null,e.mode);return o.lanes=i,o.return=e,o}}}function Ze(){for(var e=Fl,t=Il=Fl=0;t<e;){var n=Pl[t];Pl[t++]=null;var r=Pl[t];Pl[t++]=null;var i=Pl[t];Pl[t++]=null;var a=Pl[t];if(Pl[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&tt(n,i,a)}}function Qe(e,t,n,r){Pl[Fl++]=e,Pl[Fl++]=t,Pl[Fl++]=n,Pl[Fl++]=r,Il|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function $e(e,t,n,r){return Qe(e,t,n,r),nt(e)}function et(e,t){return Qe(e,null,null,t),nt(e)}function tt(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-gc(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function nt(e){if(50<Zu)throw Zu=0,Qu=null,Error(r(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}function rt(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function it(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function at(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function ot(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Y&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=nt(e),tt(e,null,n),t}return Qe(e,r,t,n),nt(e)}function st(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,w(e,n)}}function ct(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function lt(){if(Rl){var e=Sl;if(e!==null)throw e}}function ut(e,t,n,r){Rl=!1;var i=e.updateQueue;Ll=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(Z&f)===f:(r&f)===f){f!==0&&f===xl&&(Rl=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,h=s;f=t;var g=n;switch(h.tag){case 1:if(m=h.payload,typeof m==`function`){d=m.call(g,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=h.payload,f=typeof m==`function`?m.call(g,d,f):m,f==null)break a;d=Aa({},d,f);break a;case 2:Ll=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),ju|=o,e.lanes=o,e.memoizedState=d}}function dt(e,t){if(typeof e!=`function`)throw Error(r(191,e));e.call(t)}function ft(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)dt(n[e],t)}function pt(e,t){e=ku,p(Bl,e),p(zl,t),ku=e|t.baseLanes}function mt(){p(Bl,ku),p(zl,zl.current)}function ht(){ku=Bl.current,f(zl),f(Bl)}function gt(e){var t=e.alternate;p(Ul,Ul.current&1),p(Vl,e),Hl===null&&(t===null||zl.current!==null||t.memoizedState!==null)&&(Hl=e)}function _t(e){p(Ul,Ul.current),p(Vl,e),Hl===null&&(Hl=e)}function vt(e){e.tag===22?(p(Ul,Ul.current),p(Vl,e),Hl===null&&(Hl=e)):yt(e)}function yt(){p(Ul,Ul.current),p(Vl,Vl.current)}function bt(e){f(Vl),Hl===e&&(Hl=null),f(Ul)}function xt(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||ds(n)||fs(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}function z(){throw Error(r(321))}function St(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Fc(e[n],t[n]))return!1;return!0}function Ct(e,t,n,r,i,a){return Wl=a,q=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,G.H=e===null||e.memoizedState===null?tu:nu,Yl=!1,a=n(r,i),Yl=!1,Jl&&(a=Tt(t,n,r,i)),wt(e),a}function wt(e){G.H=eu;var t=Gl!==null&&Gl.next!==null;if(Wl=0,Kl=Gl=q=null,ql=!1,Zl=0,Ql=null,t)throw Error(r(300));e===null||ou||(e=e.dependencies,e!==null&&Ce(e)&&(ou=!0))}function Tt(e,t,n,i){q=e;var a=0;do{if(Jl&&(Ql=null),Zl=0,Jl=!1,25<=a)throw Error(r(301));if(a+=1,Kl=Gl=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}G.H=ru,o=t(n,i)}while(Jl);return o}function Et(){var e=G.H,t=e.useState()[0];return t=typeof t.then==`function`?Mt(t):t,e=e.useState()[0],(Gl===null?null:Gl.memoizedState)!==e&&(q.flags|=1024),t}function Dt(){var e=Xl!==0;return Xl=0,e}function Ot(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function kt(e){if(ql){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}ql=!1}Wl=0,Kl=Gl=q=null,Jl=!1,Zl=Xl=0,Ql=null}function At(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Kl===null?q.memoizedState=Kl=e:Kl=Kl.next=e,Kl}function B(){if(Gl===null){var e=q.alternate;e=e===null?null:e.memoizedState}else e=Gl.next;var t=Kl===null?q.memoizedState:Kl.next;if(t!==null)Kl=t,Gl=e;else{if(e===null)throw q.alternate===null?Error(r(467)):Error(r(310));Gl=e,e={memoizedState:Gl.memoizedState,baseState:Gl.baseState,baseQueue:Gl.baseQueue,queue:Gl.queue,next:null},Kl===null?q.memoizedState=Kl=e:Kl=Kl.next=e}return Kl}function jt(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Mt(e){var t=Zl;return Zl+=1,Ql===null&&(Ql=[]),e=Ge(Ql,e,t),t=q,(Kl===null?t.memoizedState:Kl.next)===null&&(t=t.alternate,G.H=t===null||t.memoizedState===null?tu:nu),e}function Nt(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Mt(e);if(e.$$typeof===Ra)return Te(e)}throw Error(r(438,String(e)))}function Pt(e){var t=null,n=q.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=q.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??(t={data:[],index:0}),n===null&&(n=jt(),q.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=Ga;return t.index++,n}function Ft(e,t){return typeof t==`function`?t(e):t}function It(e){return Lt(B(),Gl,e)}function Lt(e,t,n){var i=e.queue;if(i===null)throw Error(r(311));i.lastRenderedReducer=n;var a=e.baseQueue,o=i.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,i.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(Wl&f)===f:(Z&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===xl&&(d=!0);else if((Wl&p)===p){u=u.next,p===xl&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,q.lanes|=p,ju|=p;f=u.action,Yl&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,q.lanes|=f,ju|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!Fc(o,e.memoizedState)&&(ou=!0,d&&(n=Sl,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,i.lastRenderedState=o}return a===null&&(i.lanes=0),[e.memoizedState,i.dispatch]}function Rt(e){var t=B(),n=t.queue;if(n===null)throw Error(r(311));n.lastRenderedReducer=e;var i=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);Fc(o,t.memoizedState)||(ou=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,i]}function zt(e,t,n){var i=q,a=B(),o=K;if(o){if(n===void 0)throw Error(r(407));n=n()}else n=t();var s=!Fc((Gl||a).memoizedState,n);if(s&&(a.memoizedState=n,ou=!0),a=a.queue,dn(Ht.bind(null,i,a,e),[e]),a.getSnapshot!==t||s||Kl!==null&&Kl.memoizedState.tag&1){if(i.flags|=2048,on(9,{destroy:void 0},Vt.bind(null,i,a,n,t),null),wu===null)throw Error(r(349));o||Wl&127||Bt(i,t,n)}return n}function Bt(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=q.updateQueue,t===null?(t=jt(),q.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Vt(e,t,n,r){t.value=n,t.getSnapshot=r,Ut(t)&&Wt(e)}function Ht(e,t,n){return n(function(){Ut(t)&&Wt(e)})}function Ut(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Fc(e,n)}catch{return!0}}function Wt(e){var t=et(e,2);t!==null&&Ai(t,e,2)}function Gt(e){var t=At();if(typeof e==`function`){var n=e;if(e=n(),Yl){O(!0);try{n()}finally{O(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ft,lastRenderedState:e},t}function Kt(e,t,n,r){return e.baseState=n,Lt(e,Gl,typeof r==`function`?r:Ft)}function qt(e,t,n,i,a){if(Mn(e))throw Error(r(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};G.T===null?o.isTransition=!1:n(!0),i(o),n=t.pending,n===null?(o.next=t.pending=o,Jt(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Jt(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=G.T,o={};G.T=o;try{var s=n(i,r),c=G.S;c!==null&&c(o,s),Yt(e,t,s)}catch(n){Zt(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),G.T=a}}else try{a=n(i,r),Yt(e,t,a)}catch(n){Zt(e,t,n)}}function Yt(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Xt(e,t,n)},function(n){return Zt(e,t,n)}):Xt(e,t,n)}function Xt(e,t,n){t.status=`fulfilled`,t.value=n,Qt(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Jt(e,n)))}function Zt(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Qt(t),t=t.next;while(t!==r)}e.action=null}function Qt(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function $t(e,t){return t}function en(e,t){if(K){var n=wu.formState;if(n!==null){a:{var r=q;if(K){if(nl){var i=hs(nl,il);if(i){nl=_s(i),r=gs(i);break a}}A(r)}r=!1}r&&(t=n[0])}}n=At(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:$t,lastRenderedState:t},n.queue=r,n=kn.bind(null,q,r),r.dispatch=n,r=Gt(!1);var a=jn.bind(null,q,!1,r.queue);return r=At(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=qt.bind(null,q,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function tn(e){return nn(B(),Gl,e)}function nn(e,t,n){if(t=Lt(e,t,$t)[0],e=It(Ft)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Mt(t)}catch(e){throw e===Tl?Dl:e}else r=t;t=B();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(q.flags|=2048,on(9,{destroy:void 0},rn.bind(null,i,n),null)),[r,a,e]}function rn(e,t){e.action=t}function an(e){var t=B(),n=Gl;if(n!==null)return nn(t,n,e);B(),t=t.memoizedState,n=B();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function on(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=q.updateQueue,t===null&&(t=jt(),q.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function sn(){return B().memoizedState}function cn(e,t,n,r){var i=At();q.flags|=e,i.memoizedState=on(1|t,{destroy:void 0},n,r===void 0?null:r)}function ln(e,t,n,r){var i=B();r=r===void 0?null:r;var a=i.memoizedState.inst;Gl!==null&&r!==null&&St(r,Gl.memoizedState.deps)?i.memoizedState=on(t,a,n,r):(q.flags|=e,i.memoizedState=on(1|t,a,n,r))}function un(e,t){cn(8390656,8,e,t)}function dn(e,t){ln(2048,8,e,t)}function fn(e){q.flags|=4;var t=q.updateQueue;if(t===null)t=jt(),q.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function pn(e){var t=B().memoizedState;return fn({ref:t,nextImpl:e}),function(){if(Y&2)throw Error(r(440));return t.impl.apply(void 0,arguments)}}function mn(e,t){return ln(4,2,e,t)}function hn(e,t){return ln(4,4,e,t)}function gn(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function _n(e,t,n){n=n==null?null:n.concat([e]),ln(4,4,gn.bind(null,t,e),n)}function vn(){}function yn(e,t){var n=B();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&St(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function bn(e,t){var n=B();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&St(t,r[1]))return r[0];if(r=e(),Yl){O(!0);try{e()}finally{O(!1)}}return n.memoizedState=[r,t],r}function xn(e,t,n){return n===void 0||Wl&1073741824&&!(Z&261930)?e.memoizedState=t:(e.memoizedState=n,e=ki(),q.lanes|=e,ju|=e,n)}function Sn(e,t,n,r){return Fc(n,t)?n:zl.current===null?!(Wl&42)||Wl&1073741824&&!(Z&261930)?(ou=!0,e.memoizedState=n):(e=ki(),q.lanes|=e,ju|=e,t):(e=xn(e,n,r),Fc(e,t)||(ou=!0),e)}function Cn(e,t,n,r,i){var a=yo();vo(a!==0&&8>a?a:8);var o=G.T,s={};G.T=s,jn(e,!1,t,n);try{var c=i(),l=G.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?An(e,t,ze(c,r),Oi(e)):An(e,t,r,Oi(e))}catch(n){An(e,t,{then:function(){},status:`rejected`,reason:n},Oi())}finally{vo(a),o!==null&&s.types!==null&&(o.types=s.types),G.T=o}}function wn(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:Ao,baseState:Ao,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ft,lastRenderedState:Ao},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ft,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Tn(){return Te(jo)}function En(){return B().memoizedState}function Dn(){return B().memoizedState}function On(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Oi();e=at(n);var r=ot(t,e,n);r!==null&&(Ai(r,t,n),st(r,t,n)),t={cache:Oe()},e.payload=t;return}t=t.return}}function V(e,t,n){var r=Oi();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Mn(e)?Nn(t,n):(n=$e(e,t,n,r),n!==null&&(Ai(n,e,r),Pn(n,t,r)))}function kn(e,t,n){An(e,t,n,Oi())}function An(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Mn(e))Nn(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Fc(s,o))return Qe(e,t,i,0),wu===null&&Ze(),!1}catch{}if(n=$e(e,t,i,r),n!==null)return Ai(n,e,r),Pn(n,t,r),!0}return!1}function jn(e,t,n,i){if(i={lane:2,revertLane:Le(),gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null},Mn(e)){if(t)throw Error(r(479))}else t=$e(e,n,i,2),t!==null&&Ai(t,e,2)}function Mn(e){var t=e.alternate;return e===q||t!==null&&t===q}function Nn(e,t){Jl=ql=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Pn(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,w(e,n)}}function Fn(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:Aa({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}function In(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Ue(n,r)||!Ue(i,a):!0}function Ln(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&iu.enqueueReplaceState(t,t.state,null)}function Rn(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=Aa({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function zn(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Bn(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Vn(e,t,n){return n=at(n),n.tag=3,n.payload={element:null},n.callback=function(){zn(e,t)},n}function Hn(e){return e=at(e),e.tag=3,e}function Un(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Bn(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Bn(t,n,r),typeof i!=`function`&&(Uu===null?Uu=new Set([this]):Uu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Wn(e,t,n,i,a){if(n.flags|=32768,typeof i==`object`&&i&&typeof i.then==`function`){if(t=n.alternate,t!==null&&Se(t,n,a,!0),n=Vl.current,n!==null){switch(n.tag){case 31:case 13:return Hl===null?Hi():n.alternate===null&&Au===0&&(Au=3),n.flags&=-257,n.flags|=65536,n.lanes=a,i===Ol?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([i]):t.add(i),oa(e,i,a)),!1;case 22:return n.flags|=65536,i===Ol?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([i])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([i]):n.add(i)),oa(e,i,a)),!1}throw Error(r(435,n.tag))}return oa(e,i,a),Hi(),!1}if(K)return t=Vl.current,t===null?(i!==al&&(t=Error(r(423),{cause:i}),ve(ie(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,i=ie(i,n),a=Vn(e.stateNode,i,a),ct(e,a),Au!==4&&(Au=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,i!==al&&(e=Error(r(422),{cause:i}),ve(ie(e,n)))),!1;var o=Error(r(520),{cause:i});if(o=ie(o,n),Iu===null?Iu=[o]:Iu.push(o),Au!==4&&(Au=2),t===null)return!0;i=ie(i,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=Vn(n.stateNode,i,e),ct(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(Uu===null||!Uu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Hn(a),Un(a,e,n,i),ct(n,a),!1}n=n.return}while(n!==null);return!1}function Gn(e,t,n,r){t.child=e===null?Nl(t,null,n,r):Ml(t,e.child,n,r)}function Kn(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return we(t),r=Ct(e,t,n,o,a,i),s=Dt(),e!==null&&!ou?(Ot(e,t,i),hr(e,t,i)):(K&&s&&se(t),t.flags|=1,Gn(e,t,r,i),t.child)}function qn(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!pa(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,Jn(e,t,a,r,i)):(e=ga(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!gr(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Ue:n,n(o,r)&&e.ref===t.ref)return hr(e,t,i)}return t.flags|=1,e=ma(a,r),e.ref=t.ref,e.return=t,t.child=e}function Jn(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Ue(a,r)&&e.ref===t.ref)if(ou=!1,t.pendingProps=r=a,gr(e,i))e.flags&131072&&(ou=!0);else return t.lanes=e.lanes,hr(e,t,i)}return nr(e,t,n,r,i)}function Yn(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return Zn(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ve(t,a===null?null:a.cachePool),a===null?mt():pt(t,a),vt(t);else return r=t.lanes=536870912,Zn(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Ve(t,null),mt(),yt(t)):(Ve(t,a.cachePool),pt(t,a),yt(t),t.memoizedState=null);return Gn(e,t,i,n),t.child}function Xn(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Zn(e,t,n,r,i){var a=Be();return a=a===null?null:{parent:fo?fl._currentValue:fl._currentValue2,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Ve(t,null),mt(),vt(t),e!==null&&Se(e,t,r,!0),t.childLanes=i,null}function Qn(e,t){return t=ur({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function $n(e,t,n){return Ml(t,e.child,null,n),e=Qn(t,t.pendingProps),e.flags|=2,bt(t),t.memoizedState=null,e}function er(e,t,n){var i=t.pendingProps,a=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(K){if(i.mode===`hidden`)return e=Qn(t,i),t.lanes=536870912,Xn(null,e);if(_t(t),(e=nl)?(e=Es(e,il),e!==null&&(t.memoizedState={dehydrated:e,treeContext:Jc===null?null:{id:Yc,overflow:Xc},retryLane:536870912,hydrationErrors:null},n=ya(e),n.return=t,t.child=n,tl=t,nl=null)):e=null,e===null)throw A(t);return t.lanes=536870912,null}return Qn(t,i)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(_t(t),a)if(t.flags&256)t.flags&=-257,t=$n(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(r(558));else if(ou||Se(e,t,n,!1),a=(n&e.childLanes)!==0,ou||a){if(i=wu,i!==null&&(s=T(i,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,et(e,s),Ai(i,e,s),au;Hi(),t=$n(e,t,n)}else e=o.treeContext,ho&&(nl=xs(s),tl=t,K=!0,rl=null,il=!1,e!==null&&le(t,e)),t=Qn(t,i),t.flags|=4096;return t}return e=ma(e.child,{mode:i.mode,children:i.children}),e.ref=t.ref,t.child=e,e.return=t,e}function tr(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(r(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function nr(e,t,n,r,i){return we(t),n=Ct(e,t,n,r,void 0,i),r=Dt(),e!==null&&!ou?(Ot(e,t,i),hr(e,t,i)):(K&&r&&se(t),t.flags|=1,Gn(e,t,n,i),t.child)}function rr(e,t,n,r,i,a){return we(t),t.updateQueue=null,n=Tt(t,r,n,i),wt(e),r=Dt(),e!==null&&!ou?(Ot(e,t,a),hr(e,t,a)):(K&&r&&se(t),t.flags|=1,Gn(e,t,n,a),t.child)}function ir(e,t,n,r,i){if(we(t),t.stateNode===null){var a=hc,o=n.contextType;typeof o==`object`&&o&&(a=Te(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=iu,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},rt(t),o=n.contextType,a.context=typeof o==`object`&&o?Te(o):hc,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Fn(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&iu.enqueueReplaceState(a,a.state,null),ut(t,r,a,i),lt(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Rn(n,s);a.props=c;var l=a.context,u=n.contextType;o=hc,typeof u==`object`&&u&&(o=Te(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Ln(t,a,r,o),Ll=!1;var f=t.memoizedState;a.state=f,ut(t,r,a,i),lt(),l=t.memoizedState,s||f!==l||Ll?(typeof d==`function`&&(Fn(t,n,d,r),l=t.memoizedState),(c=Ll||In(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,it(e,t),o=t.memoizedProps,u=Rn(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=hc,typeof l==`object`&&l&&(c=Te(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Ln(t,a,r,c),Ll=!1,f=t.memoizedState,a.state=f,ut(t,r,a,i),lt();var p=t.memoizedState;o!==d||f!==p||Ll||e!==null&&e.dependencies!==null&&Ce(e.dependencies)?(typeof s==`function`&&(Fn(t,n,s,r),p=t.memoizedState),(u=Ll||In(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Ce(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,tr(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Ml(t,e.child,null,i),t.child=Ml(t,null,n,i)):Gn(e,t,n,i),t.memoizedState=a.state,e=t.child):e=hr(e,t,i),e}function ar(e,t,n,r){return j(),t.flags|=256,Gn(e,t,n,r),t.child}function or(e){return{baseLanes:e,cachePool:He()}}function sr(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Pu),e}function cr(e,t,n){var i=t.pendingProps,a=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(Ul.current&2)!=0),s&&(a=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(K){if(a?gt(t):yt(t),(e=nl)?(e=Ds(e,il),e!==null&&(t.memoizedState={dehydrated:e,treeContext:Jc===null?null:{id:Yc,overflow:Xc},retryLane:536870912,hydrationErrors:null},n=ya(e),n.return=t,t.child=n,tl=t,nl=null)):e=null,e===null)throw A(t);return fs(e)?t.lanes=32:t.lanes=536870912,null}var c=i.children;return i=i.fallback,a?(yt(t),a=t.mode,c=ur({mode:`hidden`,children:c},a),i=_a(i,a,n,null),c.return=t,i.return=t,c.sibling=i,t.child=c,i=t.child,i.memoizedState=or(n),i.childLanes=sr(e,s,n),t.memoizedState=su,Xn(null,i)):(gt(t),lr(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(gt(t),t.flags&=-257,t=dr(e,t,n)):t.memoizedState===null?(yt(t),c=i.fallback,a=t.mode,i=ur({mode:`visible`,children:i.children},a),c=_a(c,a,n,null),c.flags|=2,i.return=t,c.return=t,i.sibling=c,t.child=i,Ml(t,e.child,null,n),i=t.child,i.memoizedState=or(n),i.childLanes=sr(e,s,n),t.memoizedState=su,t=Xn(null,i)):(yt(t),t.child=e.child,t.flags|=128,t=null);else if(gt(t),fs(c))s=ps(c).digest,i=Error(r(419)),i.stack=``,i.digest=s,ve({value:i,source:null,stack:null}),t=dr(e,t,n);else if(ou||Se(e,t,n,!1),s=(n&e.childLanes)!==0,ou||s){if(s=wu,s!==null&&(i=T(s,n),i!==0&&i!==l.retryLane))throw l.retryLane=i,et(e,i),Ai(s,e,i),au;ds(c)||Hi(),t=dr(e,t,n)}else ds(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,ho&&(nl=Ss(c),tl=t,K=!0,rl=null,il=!1,e!==null&&le(t,e)),t=lr(t,i.children),t.flags|=4096);return t}return a?(yt(t),c=i.fallback,a=t.mode,l=e.child,o=l.sibling,i=ma(l,{mode:`hidden`,children:i.children}),i.subtreeFlags=l.subtreeFlags&65011712,o===null?(c=_a(c,a,n,null),c.flags|=2):c=ma(o,c),c.return=t,i.return=t,i.sibling=c,t.child=i,Xn(null,i),i=t.child,c=e.child.memoizedState,c===null?c=or(n):(a=c.cachePool,a===null?a=He():(l=fo?fl._currentValue:fl._currentValue2,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),i.memoizedState=c,i.childLanes=sr(e,s,n),t.memoizedState=su,Xn(e.child,i)):(gt(t),n=e.child,e=n.sibling,n=ma(n,{mode:`visible`,children:i.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function lr(e,t){return t=ur({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function ur(e,n){return e=t(22,e,null,n),e.lanes=0,e}function dr(e,t,n){return Ml(t,e.child,null,n),e=lr(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function fr(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),be(e.return,t,n)}function pr(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function mr(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=Ul.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,p(Ul,o),Gn(e,t,r,n),r=K?Gc:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&fr(e,n,t);else if(e.tag===19)fr(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&xt(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),pr(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&xt(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}pr(t,!0,n,null,a,r);break;case`together`:pr(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function hr(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),ju|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Se(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(r(153));if(t.child!==null){for(e=t.child,n=ma(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ma(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function gr(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Ce(e))):!0}function _r(e,t,n){switch(t.tag){case 3:ue(t,t.stateNode.containerInfo),ye(t,fl,e.memoizedState.cache),j();break;case 27:case 5:fe(t);break;case 4:ue(t,t.stateNode.containerInfo);break;case 10:ye(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,_t(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(gt(t),e=hr(e,t,n),e===null?null:e.sibling):cr(e,t,n):(gt(t),t.flags|=128,null);gt(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||(Se(e,t,n,!1),r=(n&t.childLanes)!==0),i){if(r)return mr(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),p(Ul,Ul.current),r)break;return null;case 22:return t.lanes=0,Yn(e,t,n,t.pendingProps);case 24:ye(t,fl,e.memoizedState.cache)}return hr(e,t,n)}function vr(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)ou=!0;else{if(!gr(e,n)&&!(t.flags&128))return ou=!1,_r(e,t,n);ou=!!(e.flags&131072)}else ou=!1,K&&t.flags&1048576&&oe(t,Gc,t.index);switch(t.lanes=0,t.tag){case 16:a:{var i=t.pendingProps;if(e=L(t.elementType),t.type=e,typeof e==`function`)pa(e)?(i=Rn(e,i),t.tag=1,t=ir(null,t,e,i,n)):(t.tag=0,t=nr(null,t,e,i,n));else{if(e!=null){var a=e.$$typeof;if(a===za){t.tag=11,t=Kn(null,t,e,i,n);break a}else if(a===Ha){t.tag=14,t=qn(null,t,e,i,n);break a}}throw t=u(e)||e,Error(r(306,t,``))}}return t;case 0:return nr(e,t,t.type,t.pendingProps,n);case 1:return i=t.type,a=Rn(i,t.pendingProps),ir(e,t,i,a,n);case 3:a:{if(ue(t,t.stateNode.containerInfo),e===null)throw Error(r(387));var o=t.pendingProps;a=t.memoizedState,i=a.element,it(e,t),ut(t,o,null,n);var s=t.memoizedState;if(o=s.cache,ye(t,fl,o),o!==a.cache&&xe(t,[fl],n,!0),lt(),o=s.element,ho&&a.isDehydrated)if(a={element:o,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){t=ar(e,t,o,n);break a}else if(o!==i){i=ie(Error(r(424)),t),ve(i),t=ar(e,t,o,n);break a}else for(ho&&(nl=bs(t.stateNode.containerInfo),tl=t,K=!0,rl=null,il=!0),n=Nl(t,null,o,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(j(),o===i){t=hr(e,t,n);break a}Gn(e,t,o,n)}t=t.child}return t;case 26:if(qs)return tr(e,t),e===null?(n=Xs(t.type,null,t.pendingProps,null))?t.memoizedState=n:K||(t.stateNode=nc(t.type,t.pendingProps,$c.current,t)):t.memoizedState=Xs(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:if(sc)return fe(t),e===null&&sc&&K&&(i=t.stateNode=cc(t.type,t.pendingProps,$c.current,Zc.current,!1),tl=t,il=!0,nl=Cs(t.type,i,nl)),Gn(e,t,t.pendingProps.children,n),tr(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&K&&(Gs(t.type,t.pendingProps,Zc.current),(a=i=nl)&&(i=ws(i,t.type,t.pendingProps,il),i===null?a=!1:(t.stateNode=i,tl=t,nl=ys(i),il=!1,a=!0)),a||A(t)),fe(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,i=o.children,oo(a,o)?i=null:s!==null&&oo(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Ct(e,t,Et,null,null,n),fo?jo._currentValue=a:jo._currentValue2=a),tr(e,t),Gn(e,t,i,n),t.child;case 6:return e===null&&K&&(Ks(t.pendingProps,Zc.current),(e=n=nl)&&(n=Ts(n,t.pendingProps,il),n===null?e=!1:(t.stateNode=n,tl=t,nl=null,e=!0)),e||A(t)),null;case 13:return cr(e,t,n);case 4:return ue(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=Ml(t,null,i,n):Gn(e,t,i,n),t.child;case 11:return Kn(e,t,t.type,t.pendingProps,n);case 7:return Gn(e,t,t.pendingProps,n),t.child;case 8:return Gn(e,t,t.pendingProps.children,n),t.child;case 12:return Gn(e,t,t.pendingProps.children,n),t.child;case 10:return i=t.pendingProps,ye(t,t.type,i.value),Gn(e,t,i.children,n),t.child;case 9:return a=t.type._context,i=t.pendingProps.children,we(t),a=Te(a),i=i(a),t.flags|=1,Gn(e,t,i,n),t.child;case 14:return qn(e,t,t.type,t.pendingProps,n);case 15:return Jn(e,t,t.type,t.pendingProps,n);case 19:return mr(e,t,n);case 31:return er(e,t,n);case 22:return Yn(e,t,n,t.pendingProps);case 24:return we(t),i=Te(fl),e===null?(a=Be(),a===null&&(a=wu,o=Oe(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:i,cache:a},rt(t),ye(t,fl,a)):((e.lanes&n)!==0&&(it(e,t),ut(t,null,null,n),lt()),a=e.memoizedState,o=t.memoizedState,a.parent===i?(i=o.cache,ye(t,fl,i),i!==a.cache&&xe(t,[fl],n,!0)):(a={parent:i,cache:i},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),ye(t,fl,i))),Gn(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(r(156,t.tag))}function yr(e){e.flags|=4}function br(e){mo&&(e.flags|=8)}function xr(e,t){if(e!==null&&e.child===t.child)return!1;if(t.flags&16)return!0;for(e=t.child;e!==null;){if(e.flags&8218||e.subtreeFlags&8218)return!0;e=e.sibling}return!1}function Sr(e,t,n,r){if(po)for(n=t.child;n!==null;){if(n.tag===5||n.tag===6)io(e,n.stateNode);else if(!(n.tag===4||sc&&n.tag===27)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}else if(mo)for(var i=t.child;i!==null;){if(i.tag===5){var a=i.stateNode;n&&r&&(a=ls(a,i.type,i.memoizedProps)),io(e,a)}else if(i.tag===6)a=i.stateNode,n&&r&&(a=us(a,i.memoizedProps)),io(e,a);else if(i.tag!==4){if(i.tag===22&&i.memoizedState!==null)a=i.child,a!==null&&(a.return=i),Sr(e,i,!0,!0);else if(i.child!==null){i.child.return=i,i=i.child;continue}}if(i===t)break;for(;i.sibling===null;){if(i.return===null||i.return===t)return;i=i.return}i.sibling.return=i.return,i=i.sibling}}function Cr(e,t,n,r){var i=!1;if(mo)for(var a=t.child;a!==null;){if(a.tag===5){var o=a.stateNode;n&&r&&(o=ls(o,a.type,a.memoizedProps)),os(e,o)}else if(a.tag===6)o=a.stateNode,n&&r&&(o=us(o,a.memoizedProps)),os(e,o);else if(a.tag!==4){if(a.tag===22&&a.memoizedState!==null)i=a.child,i!==null&&(i.return=a),Cr(e,a,!0,!0),i=!0;else if(a.child!==null){a.child.return=a,a=a.child;continue}}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return i;a=a.return}a.sibling.return=a.return,a=a.sibling}return i}function wr(e,t){if(mo&&xr(e,t)){e=t.stateNode;var n=e.containerInfo,r=as();Cr(r,t,!1,!1),e.pendingChildren=r,yr(t),ss(n,r)}}function Tr(e,t,n,r){if(po)e.memoizedProps!==r&&yr(t);else if(mo){var i=e.stateNode,a=e.memoizedProps;if((e=xr(e,t))||a!==r){var o=Zc.current;a=is(i,n,a,r,!e,null),a===i?t.stateNode=i:(br(t),ao(a,n,r,o)&&yr(t),t.stateNode=a,e&&Sr(a,t,!1,!1))}else t.stateNode=i}}function Er(e,t,n,r,i){if(e.mode&32&&(n===null?Co(t,r):wo(t,n,r))){if(e.flags|=16777216,(i&335544128)===i||To(t,r))if(Eo(e.stateNode,t,r))e.flags|=8192;else if(zi())e.flags|=8192;else throw kl=Ol,El}else e.flags&=-16777217}function Dr(e,t){if(ic(t)){if(e.flags|=16777216,!ac(t))if(zi())e.flags|=8192;else throw kl=Ol,El}else e.flags&=-16777217}function Or(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:y(),e.lanes|=t,Fu|=t)}function kr(e,t){if(!K)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ar(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function jr(e,t,n){var i=t.pendingProps;switch(ce(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ar(t),null;case 1:return Ar(t),null;case 3:return n=t.stateNode,i=null,e!==null&&(i=e.memoizedState.cache),t.memoizedState.cache!==i&&(t.flags|=2048),M(fl),de(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(ge(t)?yr(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,_e())),wr(e,t),Ar(t),null;case 26:if(qs){var a=t.type,o=t.memoizedState;return e===null?(yr(t),o===null?(Ar(t),Er(t,a,null,i,n)):(Ar(t),Dr(t,o))):o?o===e.memoizedState?(Ar(t),t.flags&=-16777217):(yr(t),Ar(t),Dr(t,o)):(o=e.memoizedProps,po?o!==i&&yr(t):Tr(e,t,a,i),Ar(t),Er(t,a,o,i,n)),null}case 27:if(sc){if(pe(t),n=$c.current,a=t.type,e!==null&&t.stateNode!=null)po?e.memoizedProps!==i&&yr(t):Tr(e,t,a,i);else{if(!i){if(t.stateNode===null)throw Error(r(166));return Ar(t),null}e=Zc.current,ge(t)?me(t,e):(e=cc(a,i,n,e,!0),t.stateNode=e,yr(t))}return Ar(t),null}case 5:if(pe(t),a=t.type,e!==null&&t.stateNode!=null)Tr(e,t,a,i);else{if(!i){if(t.stateNode===null)throw Error(r(166));return Ar(t),null}if(o=Zc.current,ge(t))me(t,o),Rs(t.stateNode,a,i,o)&&(t.flags|=64);else{var s=ro(a,i,$c.current,o,t);br(t),Sr(s,t,!1,!1),t.stateNode=s,ao(s,a,i,o)&&yr(t)}}return Ar(t),Er(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)n=e.memoizedProps,po?n!==i&&yr(t):mo&&(n===i?t.stateNode=e.stateNode:(e=$c.current,n=Zc.current,br(t),t.stateNode=so(i,e,n,t)));else{if(typeof i!=`string`&&t.stateNode===null)throw Error(r(166));if(e=$c.current,n=Zc.current,ge(t)){if(!ho)throw Error(r(176));if(e=t.stateNode,n=t.memoizedProps,i=null,a=tl,a!==null)switch(a.tag){case 27:case 5:i=a.memoizedProps}ks(e,n,t,i)||A(t,!0)}else br(t),t.stateNode=so(i,e,n,t)}return Ar(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(i=ge(t),n!==null){if(e===null){if(!i)throw Error(r(318));if(!ho)throw Error(r(556));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(r(557));As(e,t)}else j(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ar(t),e=!1}else n=_e(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(bt(t),t):(bt(t),null);if(t.flags&128)throw Error(r(558))}return Ar(t),null;case 13:if(i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=ge(t),i!==null&&i.dehydrated!==null){if(e===null){if(!a)throw Error(r(318));if(!ho)throw Error(r(344));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(r(317));js(a,t)}else j(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ar(t),a=!1}else a=_e(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(bt(t),t):(bt(t),null)}return bt(t),t.flags&128?(t.lanes=n,t):(n=i!==null,e=e!==null&&e.memoizedState!==null,n&&(i=t.child,a=null,i.alternate!==null&&i.alternate.memoizedState!==null&&i.alternate.memoizedState.cachePool!==null&&(a=i.alternate.memoizedState.cachePool.pool),o=null,i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(o=i.memoizedState.cachePool.pool),o!==a&&(i.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Or(t,t.updateQueue),Ar(t),null);case 4:return de(),wr(e,t),e===null&&_o(t.stateNode.containerInfo),Ar(t),null;case 10:return M(t.type),Ar(t),null;case 19:if(f(Ul),i=t.memoizedState,i===null)return Ar(t),null;if(a=(t.flags&128)!=0,o=i.rendering,o===null)if(a)kr(i,!1);else{if(Au!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=xt(e),o!==null){for(t.flags|=128,kr(i,!1),e=o.updateQueue,t.updateQueue=e,Or(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ha(n,e),n=n.sibling;return p(Ul,Ul.current&1|2),K&&ae(t,i.treeForkCount),t.child}e=e.sibling}i.tail!==null&&Ec()>Vu&&(t.flags|=128,a=!0,kr(i,!1),t.lanes=4194304)}else{if(!a)if(e=xt(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Or(t,e),kr(i,!0),i.tail===null&&i.tailMode===`hidden`&&!o.alternate&&!K)return Ar(t),null}else 2*Ec()-i.renderingStartTime>Vu&&n!==536870912&&(t.flags|=128,a=!0,kr(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(e=i.last,e===null?t.child=o:e.sibling=o,i.last=o)}return i.tail===null?(Ar(t),null):(e=i.tail,i.rendering=e,i.tail=e.sibling,i.renderingStartTime=Ec(),e.sibling=null,n=Ul.current,p(Ul,a?n&1|2:n&1),K&&ae(t,i.treeForkCount),e);case 22:case 23:return bt(t),ht(),i=t.memoizedState!==null,e===null?i&&(t.flags|=8192):e.memoizedState!==null!==i&&(t.flags|=8192),i?n&536870912&&!(t.flags&128)&&(Ar(t),t.subtreeFlags&6&&(t.flags|=8192)):Ar(t),n=t.updateQueue,n!==null&&Or(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),i=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(i=t.memoizedState.cachePool.pool),i!==n&&(t.flags|=2048),e!==null&&f(wl),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),M(fl),Ar(t),null;case 25:return null;case 30:return null}throw Error(r(156,t.tag))}function Mr(e,t){switch(ce(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return M(fl),de(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return pe(t),null;case 31:if(t.memoizedState!==null){if(bt(t),t.alternate===null)throw Error(r(340));j()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(bt(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(r(340));j()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return f(Ul),null;case 4:return de(),null;case 10:return M(t.type),null;case 22:case 23:return bt(t),ht(),e!==null&&f(wl),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return M(fl),null;case 25:return null;default:return null}}function Nr(e,t){switch(ce(t),t.tag){case 3:M(fl),de();break;case 26:case 27:case 5:pe(t);break;case 4:de();break;case 31:t.memoizedState!==null&&bt(t);break;case 13:bt(t);break;case 19:f(Ul);break;case 10:M(t.type);break;case 22:case 23:bt(t),ht(),e!==null&&f(wl);break;case 24:M(fl)}}function Pr(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){U(t,t.return,e)}}function Fr(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){U(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){U(t,t.return,e)}}function Ir(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{ft(t,n)}catch(t){U(e,e.return,t)}}}function Lr(e,t,n){n.props=Rn(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){U(e,t,n)}}function Rr(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=Qa(e.stateNode);break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){U(e,t,n)}}function zr(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){U(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){U(e,t,n)}else n.current=null}function Br(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{Ko(r,t,n,e)}catch(t){U(e,e.return,t)}}function Vr(e,t,n){try{qo(e.stateNode,e.type,n,t,e)}catch(t){U(e,e.return,t)}}function Hr(e){return e.tag===5||e.tag===3||(qs?e.tag===26:!1)||(sc?e.tag===27&&fc(e.type):!1)||e.tag===4}function Ur(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Hr(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(sc&&e.tag===27&&fc(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Wr(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?Yo(n,e,t):Wo(n,e);else if(r!==4&&(sc&&r===27&&fc(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Wr(e,t,n),e=e.sibling;e!==null;)Wr(e,t,n),e=e.sibling}function Gr(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?Jo(n,e,t):Uo(n,e);else if(r!==4&&(sc&&r===27&&fc(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Gr(e,t,n),e=e.sibling;e!==null;)Gr(e,t,n),e=e.sibling}function Kr(e,t,n){e=e.containerInfo;try{cs(e,n)}catch(e){U(t,t.return,e)}}function qr(e){var t=e.stateNode,n=e.memoizedProps;try{lc(e.type,n,t,e)}catch(t){U(e,e.return,t)}}function Jr(e,t){for(to(e.containerInfo),fu=t;fu!==null;)if(e=fu,t=e.child,e.subtreeFlags&1028&&t!==null)t.return=e,fu=t;else for(;fu!==null;){e=fu;var n=e.alternate;switch(t=e.flags,e.tag){case 0:if(t&4&&(t=e.updateQueue,t=t===null?null:t.events,t!==null))for(var i=0;i<t.length;i++){var a=t[i];a.ref.impl=a.nextImpl}break;case 11:case 15:break;case 1:if(t&1024&&n!==null){t=void 0,i=e,a=n.memoizedProps,n=n.memoizedState;var o=i.stateNode;try{var s=Rn(i.type,a);t=o.getSnapshotBeforeUpdate(s,n),o.__reactInternalSnapshotBeforeUpdate=t}catch(e){U(i,i.return,e)}}break;case 3:t&1024&&po&&rs(e.stateNode.containerInfo);break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(t&1024)throw Error(r(163))}if(t=e.sibling,t!==null){t.return=e.return,fu=t;break}fu=e.return}}function Yr(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:si(e,n),r&4&&Pr(5,n);break;case 1:if(si(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){U(n,n.return,e)}else{var i=Rn(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){U(n,n.return,e)}}r&64&&Ir(n),r&512&&Rr(n,n.return);break;case 3:if(si(e,n),r&64&&(r=n.updateQueue,r!==null)){if(e=null,n.child!==null)switch(n.child.tag){case 27:case 5:e=Qa(n.child.stateNode);break;case 1:e=n.child.stateNode}try{ft(r,e)}catch(e){U(n,n.return,e)}}break;case 27:sc&&t===null&&r&4&&qr(n);case 26:case 5:if(si(e,n),t===null){if(r&4)Br(n);else if(r&64){e=n.type,t=n.memoizedProps,i=n.stateNode;try{Ps(i,e,t,n)}catch(e){U(n,n.return,e)}}}r&512&&Rr(n,n.return);break;case 12:si(e,n);break;case 31:si(e,n),r&4&&$r(e,n);break;case 13:si(e,n),r&4&&ei(e,n),r&64&&(r=n.memoizedState,r!==null&&(r=r.dehydrated,r!==null&&(n=la.bind(null,n),ms(r,n))));break;case 22:if(r=n.memoizedState!==null||cu,!r){t=t!==null&&t.memoizedState!==null||lu,i=cu;var a=lu;cu=r,(lu=t)&&!a?li(e,n,(n.subtreeFlags&8772)!=0):si(e,n),cu=i,lu=a}break;case 30:break;default:si(e,n)}}function Xr(e){var t=e.alternate;t!==null&&(e.alternate=null,Xr(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&So(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Zr(e,t,n){for(n=n.child;n!==null;)Qr(e,t,n),n=n.sibling}function Qr(e,t,n){if(Pc&&typeof Pc.onCommitFiberUnmount==`function`)try{Pc.onCommitFiberUnmount(Nc,n)}catch{}switch(n.tag){case 26:if(qs){lu||zr(n,t),Zr(e,t,n),n.memoizedState?Qs(n.memoizedState):n.stateNode&&tc(n.stateNode);break}case 27:if(sc){lu||zr(n,t);var r=pu,i=J;fc(n.type)&&(pu=n.stateNode,J=!1),Zr(e,t,n),uc(n.stateNode),pu=r,J=i;break}case 5:lu||zr(n,t);case 6:if(po){if(r=pu,i=J,pu=null,Zr(e,t,n),pu=r,J=i,pu!==null)if(J)try{Zo(pu,n.stateNode)}catch(e){U(n,t,e)}else try{Xo(pu,n.stateNode)}catch(e){U(n,t,e)}}else Zr(e,t,n);break;case 18:po&&pu!==null&&(J?Vs(pu,n.stateNode):Bs(pu,n.stateNode));break;case 4:po?(r=pu,i=J,pu=n.stateNode.containerInfo,J=!0,Zr(e,t,n),pu=r,J=i):(mo&&Kr(n.stateNode,n,as()),Zr(e,t,n));break;case 0:case 11:case 14:case 15:Fr(2,n,t),lu||Fr(4,n,t),Zr(e,t,n);break;case 1:lu||(zr(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Lr(n,t,r)),Zr(e,t,n);break;case 21:Zr(e,t,n);break;case 22:lu=(r=lu)||n.memoizedState!==null,Zr(e,t,n),lu=r;break;default:Zr(e,t,n)}}function $r(e,t){if(ho&&t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Is(e)}catch(e){U(t,t.return,e)}}}function ei(e,t){if(ho&&t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Ls(e)}catch(e){U(t,t.return,e)}}function ti(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new du),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new du),t;default:throw Error(r(435,e.tag))}}function ni(e,t){var n=ti(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=ua.bind(null,e,t);t.then(r,r)}})}function ri(e,t){var n=t.deletions;if(n!==null)for(var i=0;i<n.length;i++){var a=n[i],o=e,s=t;if(po){var c=s;a:for(;c!==null;){switch(c.tag){case 27:if(sc){if(fc(c.type)){pu=c.stateNode,J=!1;break a}break}case 5:pu=c.stateNode,J=!1;break a;case 3:case 4:pu=c.stateNode.containerInfo,J=!0;break a}c=c.return}if(pu===null)throw Error(r(160));Qr(o,s,a),pu=null,J=!1}else Qr(o,s,a);o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)ii(t,e),t=t.sibling}function ii(e,t){var n=e.alternate,i=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ri(t,e),ai(e),i&4&&(Fr(3,e,e.return),Pr(3,e),Fr(5,e,e.return));break;case 1:ri(t,e),ai(e),i&512&&(lu||n===null||zr(n,n.return)),i&64&&cu&&(e=e.updateQueue,e!==null&&(i=e.callbacks,i!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?i:n.concat(i))));break;case 26:if(qs){var a=mu;if(ri(t,e),ai(e),i&512&&(lu||n===null||zr(n,n.return)),i&4){i=n===null?null:n.memoizedState;var o=e.memoizedState;n===null?o===null?e.stateNode===null?e.stateNode=$s(a,e.type,e.memoizedProps,e):ec(a,e.type,e.stateNode):e.stateNode=Zs(a,o,e.memoizedProps):i===o?o===null&&e.stateNode!==null&&Vr(e,e.memoizedProps,n.memoizedProps):(i===null?n.stateNode!==null&&tc(n.stateNode):Qs(i),o===null?ec(a,e.type,e.stateNode):Zs(a,o,e.memoizedProps))}break}case 27:if(sc){ri(t,e),ai(e),i&512&&(lu||n===null||zr(n,n.return)),n!==null&&i&4&&Vr(e,e.memoizedProps,n.memoizedProps);break}case 5:if(ri(t,e),ai(e),i&512&&(lu||n===null||zr(n,n.return)),po){if(e.flags&32){a=e.stateNode;try{Qo(a)}catch(t){U(e,e.return,t)}}i&4&&e.stateNode!=null&&(a=e.memoizedProps,Vr(e,a,n===null?a:n.memoizedProps)),i&1024&&(uu=!0)}else mo&&e.alternate!==null&&(e.alternate.stateNode=e.stateNode);break;case 6:if(ri(t,e),ai(e),i&4&&po){if(e.stateNode===null)throw Error(r(162));i=e.memoizedProps,n=n===null?i:n.memoizedProps,a=e.stateNode;try{Go(a,n,i)}catch(t){U(e,e.return,t)}}break;case 3:if(qs?(rc(),a=mu,mu=Ys(t.containerInfo),ri(t,e),mu=a):ri(t,e),ai(e),i&4){if(po&&ho&&n!==null&&n.memoizedState.isDehydrated)try{Fs(t.containerInfo)}catch(t){U(e,e.return,t)}if(mo){i=t.containerInfo,n=t.pendingChildren;try{cs(i,n)}catch(t){U(e,e.return,t)}}}uu&&(uu=!1,oi(e));break;case 4:qs?(n=mu,mu=Ys(e.stateNode.containerInfo),ri(t,e),ai(e),mu=n):(ri(t,e),ai(e)),i&4&&mo&&Kr(e.stateNode,e,e.stateNode.pendingChildren);break;case 12:ri(t,e),ai(e);break;case 31:ri(t,e),ai(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,ni(e,i)));break;case 13:ri(t,e),ai(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(zu=Ec()),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,ni(e,i)));break;case 22:a=e.memoizedState!==null;var s=n!==null&&n.memoizedState!==null,c=cu,l=lu;if(cu=c||a,lu=l||s,ri(t,e),lu=l,cu=c,ai(e),i&8192&&(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||s||cu||lu||ci(e)),po)){a:if(n=null,po)for(t=e;;){if(t.tag===5||qs&&t.tag===26){if(n===null){s=n=t;try{o=s.stateNode,a?$o(o):ts(s.stateNode,s.memoizedProps)}catch(e){U(s,s.return,e)}}}else if(t.tag===6){if(n===null){s=t;try{var u=s.stateNode;a?es(u):ns(u,s.memoizedProps)}catch(e){U(s,s.return,e)}}}else if(t.tag===18){if(n===null){s=t;try{var d=s.stateNode;a?Hs(d):Us(s.stateNode)}catch(e){U(s,s.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}}i&4&&(i=e.updateQueue,i!==null&&(n=i.retryQueue,n!==null&&(i.retryQueue=null,ni(e,n))));break;case 19:ri(t,e),ai(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,ni(e,i)));break;case 30:break;case 21:break;default:ri(t,e),ai(e)}}function ai(e){var t=e.flags;if(t&2){try{for(var n,i=e.return;i!==null;){if(Hr(i)){n=i;break}i=i.return}if(po){if(n==null)throw Error(r(160));switch(n.tag){case 27:if(sc){var a=n.stateNode;Gr(e,Ur(e),a);break}case 5:var o=n.stateNode;n.flags&32&&(Qo(o),n.flags&=-33),Gr(e,Ur(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Wr(e,Ur(e),s);break;default:throw Error(r(161))}}}catch(t){U(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function oi(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;oi(t),t.tag===5&&t.flags&1024&&Mo(t.stateNode),e=e.sibling}}function si(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Yr(e,t.alternate,t),t=t.sibling}function ci(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Fr(4,t,t.return),ci(t);break;case 1:zr(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Lr(t,t.return,n),ci(t);break;case 27:sc&&uc(t.stateNode);case 26:case 5:zr(t,t.return),ci(t);break;case 22:t.memoizedState===null&&ci(t);break;case 30:ci(t);break;default:ci(t)}e=e.sibling}}function li(e,t,n){for(n=n&&(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:li(i,a,n),Pr(4,a);break;case 1:if(li(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){U(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)dt(c[i],s)}catch(e){U(r,r.return,e)}}n&&o&64&&Ir(a),Rr(a,a.return);break;case 27:sc&&qr(a);case 26:case 5:li(i,a,n),n&&r===null&&o&4&&Br(a),Rr(a,a.return);break;case 12:li(i,a,n);break;case 31:li(i,a,n),n&&o&4&&$r(i,a);break;case 13:li(i,a,n),n&&o&4&&ei(i,a);break;case 22:a.memoizedState===null&&li(i,a,n),Rr(a,a.return);break;case 30:break;default:li(i,a,n)}t=t.sibling}}function ui(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&ke(n))}function fi(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ke(e))}function pi(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)H(e,t,n,r),t=t.sibling}function H(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:pi(e,t,n,r),i&2048&&Pr(9,t);break;case 1:pi(e,t,n,r);break;case 3:pi(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ke(e)));break;case 12:if(i&2048){pi(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){U(t,t.return,e)}}else pi(e,t,n,r);break;case 31:pi(e,t,n,r);break;case 13:pi(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?pi(e,t,n,r):(a._visibility|=2,mi(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?pi(e,t,n,r):hi(e,t),i&2048&&ui(o,t);break;case 24:pi(e,t,n,r),i&2048&&fi(t.alternate,t);break;default:pi(e,t,n,r)}}function mi(e,t,n,r,i){for(i=i&&((t.subtreeFlags&10256)!=0||!1),t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:mi(a,o,s,c,i),Pr(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,mi(a,o,s,c,i)):u._visibility&2?mi(a,o,s,c,i):hi(a,o),i&&l&2048&&ui(o.alternate,o);break;case 24:mi(a,o,s,c,i),i&&l&2048&&fi(o.alternate,o);break;default:mi(a,o,s,c,i)}t=t.sibling}}function hi(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:hi(n,r),i&2048&&ui(r.alternate,r);break;case 24:hi(n,r),i&2048&&fi(r.alternate,r);break;default:hi(n,r)}t=t.sibling}}function gi(e,t,n){if(e.subtreeFlags&hu)for(e=e.child;e!==null;)_i(e,t,n),e=e.sibling}function _i(e,t,n){switch(e.tag){case 26:if(gi(e,t,n),e.flags&hu)if(e.memoizedState!==null)oc(n,mu,e.memoizedState,e.memoizedProps);else{var r=e.stateNode,i=e.type;e=e.memoizedProps,((t&335544128)===t||To(i,e))&&Oo(n,r,i,e)}break;case 5:gi(e,t,n),e.flags&hu&&(r=e.stateNode,i=e.type,e=e.memoizedProps,((t&335544128)===t||To(i,e))&&Oo(n,r,i,e));break;case 3:case 4:qs?(r=mu,mu=Ys(e.stateNode.containerInfo),gi(e,t,n),mu=r):gi(e,t,n);break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=hu,hu=16777216,gi(e,t,n),hu=r):gi(e,t,n));break;default:gi(e,t,n)}}function vi(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function yi(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];fu=r,Si(r,e)}vi(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)bi(e),e=e.sibling}function bi(e){switch(e.tag){case 0:case 11:case 15:yi(e),e.flags&2048&&Fr(9,e,e.return);break;case 3:yi(e);break;case 12:yi(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,xi(e)):yi(e);break;default:yi(e)}}function xi(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];fu=r,Si(r,e)}vi(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Fr(8,t,t.return),xi(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,xi(t));break;default:xi(t)}e=e.sibling}}function Si(e,t){for(;fu!==null;){var n=fu;switch(n.tag){case 0:case 11:case 15:Fr(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:ke(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,fu=r;else a:for(n=e;fu!==null;){r=fu;var i=r.sibling,a=r.return;if(Xr(r),r===n){fu=null;break a}if(i!==null){i.return=a,fu=i;break a}fu=a}}}function Ci(e){var t=go(e);if(t!=null){if(typeof t.memoizedProps[`data-testname`]!=`string`)throw Error(r(364));return t}if(e=Io(e),e===null)throw Error(r(362));return e.stateNode.current}function wi(e,t){var n=e.tag;switch(t.$$typeof){case _u:if(e.type===t.value)return!0;break;case vu:a:{for(t=t.value,e=[e,0],n=0;n<e.length;){var i=e[n++],a=i.tag,o=e[n++],s=t[o];if(a!==5&&a!==26&&a!==27||!zo(i)){for(;s!=null&&wi(i,s);)o++,s=t[o];if(o===t.length){t=!0;break a}else for(i=i.child;i!==null;)e.push(i,o),i=i.sibling}}t=!1}return t;case yu:if((n===5||n===26||n===27)&&Bo(e.stateNode,t.value))return!0;break;case xu:if((n===5||n===6||n===26||n===27)&&(e=Ro(e),e!==null&&0<=e.indexOf(t.value)))return!0;break;case bu:if((n===5||n===26||n===27)&&(e=e.memoizedProps[`data-testname`],typeof e==`string`&&e.toLowerCase()===t.value.toLowerCase()))return!0;break;default:throw Error(r(365))}return!1}function Ti(e){switch(e.$$typeof){case _u:return`<`+(u(e.value)||`Unknown`)+`>`;case vu:return`:has(`+(Ti(e)||``)+`)`;case yu:return`[role="`+e.value+`"]`;case xu:return`"`+e.value+`"`;case bu:return`[data-testname="`+e.value+`"]`;default:throw Error(r(365))}}function Ei(e,t){var n=[];e=[e,0];for(var r=0;r<e.length;){var i=e[r++],a=i.tag,o=e[r++],s=t[o];if(a!==5&&a!==26&&a!==27||!zo(i)){for(;s!=null&&wi(i,s);)o++,s=t[o];if(o===t.length)n.push(i);else for(i=i.child;i!==null;)e.push(i,o),i=i.sibling}}return n}function Di(e,t){if(!Fo)throw Error(r(363));e=Ci(e),e=Ei(e,t),t=[],e=Array.from(e);for(var n=0;n<e.length;){var i=e[n++],a=i.tag;if(a===5||a===26||a===27)zo(i)||t.push(i.stateNode);else for(i=i.child;i!==null;)e.push(i),i=i.sibling}return t}function Oi(){return Y&2&&Z!==0?Z&-Z:G.T===null?bo():Le()}function ki(){if(Pu===0)if(!(Z&536870912)||K){var e=bc;bc<<=1,!(bc&3932160)&&(bc=262144),Pu=e}else Pu=536870912;return e=Vl.current,e!==null&&(e.flags|=32),Pu}function Ai(e,t,n){(e===wu&&(Q===2||Q===9)||e.cancelPendingCommit!==null)&&(Li(e,0),Pi(e,Z,Pu,!1)),x(e,n),(!(Y&2)||e!==wu)&&(e===wu&&(!(Y&2)&&(Mu|=n),Au===4&&Pi(e,Z,Pu,!1)),je(e))}function ji(e,t,n){if(Y&6)throw Error(r(327));var i=!n&&(t&127)==0&&(t&e.expiredLanes)===0||_(e,t),a=i?Gi(e,t):Ui(e,t,!0),o=i;do{if(a===0){Du&&!i&&Pi(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!Ni(n)){a=Ui(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=Iu;var l=ho&&c.current.memoizedState.isDehydrated;if(l&&(Li(c,s).flags|=256),s=Ui(c,s,!1),s!==2){if(Ou&&!l){c.errorRecoveryDisabledLanes|=o,Mu|=o,a=4;break a}o=Lu,Lu=a,o!==null&&(Lu===null?Lu=o:Lu.push.apply(Lu,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Li(e,0),Pi(e,t,0,!0);break}a:{switch(i=e,o=a,o){case 0:case 1:throw Error(r(345));case 4:if((t&4194048)!==t)break;case 6:Pi(i,t,Pu,!Eu);break a;case 2:Lu=null;break;case 3:case 5:break;default:throw Error(r(329))}if((t&62914560)===t&&(a=zu+300-Ec(),10<a)){if(Pi(i,t,Pu,!Eu),g(i,0,!0)!==0)break a;qu=t,i.timeoutHandle=co(Mi.bind(null,i,n,Lu,Hu,Ru,t,Pu,Mu,Fu,Eu,o,`Throttled`,-0,0),a);break a}Mi(i,n,Lu,Hu,Ru,t,Pu,Mu,Fu,Eu,o,null,-0,0)}}break}while(1);je(e)}function Mi(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=uo,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d=Do(),_i(t,a,d);var m=(a&62914560)===a?zu-Ec():(a&4194048)===a?Bu-Ec():0;if(m=ko(d,m),m!==null){qu=a,e.cancelPendingCommit=m(Qi.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),Pi(e,a,o,!l);return}}Qi(e,t,a,n,r,i,o,s,c)}function Ni(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!Fc(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Pi(e,t,n,r){t&=~Nu,t&=~Mu,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-gc(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&C(e,n,t)}function Fi(){return Y&6?!0:(Me(0,!1),!1)}function Ii(){if(X!==null){if(Q===0)var e=X.return;else e=X,cl=sl=null,kt(e),Al=null,jl=0,e=X;for(;e!==null;)Nr(e.alternate,e),e=e.return;X=null}}function Li(e,t){var n=e.timeoutHandle;n!==uo&&(e.timeoutHandle=uo,lo(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),qu=0,Ii(),wu=e,X=n=ma(e.current,null),Z=t,Q=0,Tu=null,Eu=!1,Du=_(e,t),Ou=!1,Fu=Pu=Nu=Mu=ju=Au=0,Lu=Iu=null,Ru=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-gc(r),a=1<<i;t|=e[i],r&=~a}return ku=t,Ze(),n}function Ri(e,t){q=null,G.H=eu,t===Tl||t===Dl?(t=R(),Q=3):t===El?(t=R(),Q=4):Q=t===au?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Tu=t,X===null&&(Au=1,zn(e,ie(t,e.current)))}function zi(){var e=Vl.current;return e===null?!0:(Z&4194048)===Z?Hl===null:(Z&62914560)===Z||Z&536870912?e===Hl:!1}function Bi(){var e=G.H;return G.H=eu,e===null?eu:e}function Vi(){var e=G.A;return G.A=gu,e}function Hi(){Au=4,Eu||(Z&4194048)!==Z&&Vl.current!==null||(Du=!0),!(ju&134217727)&&!(Mu&134217727)||wu===null||Pi(wu,Z,Pu,!1)}function Ui(e,t,n){var r=Y;Y|=2;var i=Bi(),a=Vi();(wu!==e||Z!==t)&&(Hu=null,Li(e,t)),t=!1;var o=Au;a:do try{if(Q!==0&&X!==null){var s=X,c=Tu;switch(Q){case 8:Ii(),o=6;break a;case 3:case 2:case 9:case 6:Vl.current===null&&(t=!0);var l=Q;if(Q=0,Tu=null,Yi(e,s,c,l),n&&Du){o=0;break a}break;default:l=Q,Q=0,Tu=null,Yi(e,s,c,l)}}Wi(),o=Au;break}catch(t){Ri(e,t)}while(1);return t&&e.shellSuspendCounter++,cl=sl=null,Y=r,G.H=i,G.A=a,X===null&&(wu=null,Z=0,Ze()),o}function Wi(){for(;X!==null;)qi(X)}function Gi(e,t){var n=Y;Y|=2;var i=Bi(),a=Vi();wu!==e||Z!==t?(Hu=null,Vu=Ec()+500,Li(e,t)):Du=_(e,t);a:do try{if(Q!==0&&X!==null){t=X;var o=Tu;b:switch(Q){case 1:Q=0,Tu=null,Yi(e,t,o,1);break;case 2:case 9:if(We(o)){Q=0,Tu=null,Ji(t);break}t=function(){Q!==2&&Q!==9||wu!==e||(Q=7),je(e)},o.then(t,t);break a;case 3:Q=7;break a;case 4:Q=5;break a;case 7:We(o)?(Q=0,Tu=null,Ji(t)):(Q=0,Tu=null,Yi(e,t,o,7));break;case 5:var s=null;switch(X.tag){case 26:s=X.memoizedState;case 5:case 27:var c=X,l=c.type,u=c.pendingProps;if(s?ac(s):Eo(c.stateNode,l,u)){Q=0,Tu=null;var d=c.sibling;if(d!==null)X=d;else{var f=c.return;f===null?X=null:(X=f,Xi(f))}break b}}Q=0,Tu=null,Yi(e,t,o,5);break;case 6:Q=0,Tu=null,Yi(e,t,o,6);break;case 8:Ii(),Au=6;break a;default:throw Error(r(462))}}Ki();break}catch(t){Ri(e,t)}while(1);return cl=sl=null,G.H=i,G.A=a,Y=n,X===null?(wu=null,Z=0,Ze(),Au):0}function Ki(){for(;X!==null&&!wc();)qi(X)}function qi(e){var t=vr(e.alternate,e,ku);e.memoizedProps=e.pendingProps,t===null?Xi(e):X=t}function Ji(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=rr(n,t,t.pendingProps,t.type,void 0,Z);break;case 11:t=rr(n,t,t.pendingProps,t.type.render,t.ref,Z);break;case 5:kt(t);default:Nr(n,t),t=X=ha(t,ku),t=vr(n,t,ku)}e.memoizedProps=e.pendingProps,t===null?Xi(e):X=t}function Yi(e,t,n,r){cl=sl=null,kt(t),Al=null,jl=0;var i=t.return;try{if(Wn(e,i,t,n,Z)){Au=1,zn(e,ie(n,e.current)),X=null;return}}catch(t){if(i!==null)throw X=i,t;Au=1,zn(e,ie(n,e.current)),X=null;return}t.flags&32768?(K||r===1?e=!0:Du||Z&536870912?e=!1:(Eu=e=!0,(r===2||r===9||r===3||r===6)&&(r=Vl.current,r!==null&&r.tag===13&&(r.flags|=16384))),Zi(t,e)):Xi(t)}function Xi(e){var t=e;do{if(t.flags&32768){Zi(t,Eu);return}e=t.return;var n=jr(t.alternate,t,ku);if(n!==null){X=n;return}if(t=t.sibling,t!==null){X=t;return}X=t=e}while(t!==null);Au===0&&(Au=5)}function Zi(e,t){do{var n=Mr(e.alternate,e);if(n!==null){n.flags&=32767,X=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){X=e;return}X=e=n}while(e!==null);Au=6,X=null}function Qi(e,t,n,i,a,o,s,c,l){e.cancelPendingCommit=null;do ra();while(Wu!==0);if(Y&6)throw Error(r(327));if(t!==null){if(t===e.current)throw Error(r(177));if(o=t.lanes|t.childLanes,o|=Il,S(e,n,o,s,c,l),e===wu&&(X=wu=null,Z=0),Ku=t,Gu=e,qu=n,Ju=o,Yu=a,Xu=i,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,da(kc,function(){return ia(),null})):(e.callbackNode=null,e.callbackPriority=0),i=(t.flags&13878)!=0,t.subtreeFlags&13878||i){i=G.T,G.T=null,a=yo(),vo(2),s=Y,Y|=4;try{Jr(e,t,n)}finally{Y=s,vo(a),G.T=i}}Wu=1,$i(),ea(),ta()}}function $i(){if(Wu===1){Wu=0;var e=Gu,t=Ku,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=G.T,G.T=null;var r=yo();vo(2);var i=Y;Y|=4;try{ii(t,e),no(e.containerInfo)}finally{Y=i,vo(r),G.T=n}}e.current=t,Wu=2}}function ea(){if(Wu===2){Wu=0;var e=Gu,t=Ku,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=G.T,G.T=null;var r=yo();vo(2);var i=Y;Y|=4;try{Yr(e,t.alternate,t)}finally{Y=i,vo(r),G.T=n}}Wu=3}}function ta(){if(Wu===4||Wu===3){Wu=0,Tc();var e=Gu,t=Ku,n=qu,r=Xu;t.subtreeFlags&10256||t.flags&10256?Wu=5:(Wu=0,Ku=Gu=null,na(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(Uu=null),D(n),t=t.stateNode,Pc&&typeof Pc.onCommitFiberRoot==`function`)try{Pc.onCommitFiberRoot(Nc,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=G.T,i=yo(),vo(2),G.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{G.T=t,vo(i)}}qu&3&&ra(),je(e),i=e.pendingLanes,n&261930&&i&42?e===Qu?Zu++:(Zu=0,Qu=e):Zu=0,ho&&zs(),Me(0,!1)}}function na(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ke(t)))}function ra(){return $i(),ea(),ta(),ia()}function ia(){if(Wu!==5)return!1;var e=Gu,t=Ju;Ju=0;var n=D(qu),i=32>n?32:n;n=G.T;var a=yo();try{vo(i),G.T=null,i=Yu,Yu=null;var o=Gu,s=qu;if(Wu=0,Ku=Gu=null,qu=0,Y&6)throw Error(r(331));var c=Y;if(Y|=4,bi(o.current),H(o,o.current,s,i),Y=c,Me(0,!1),Pc&&typeof Pc.onPostCommitFiberRoot==`function`)try{Pc.onPostCommitFiberRoot(Nc,o)}catch{}return!0}finally{vo(a),G.T=n,na(e,t)}}function aa(e,t,n){t=ie(n,t),t=Vn(e.stateNode,t,2),e=ot(e,t,2),e!==null&&(x(e,2),je(e))}function U(e,t,n){if(e.tag===3)aa(e,e,n);else for(;t!==null;){if(t.tag===3){aa(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(Uu===null||!Uu.has(r))){e=ie(n,e),n=Hn(2),r=ot(t,n,2),r!==null&&(Un(n,r,t,e),x(r,2),je(r));break}}t=t.return}}function oa(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Cu;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Ou=!0,i.add(n),e=sa.bind(null,e,t,n),t.then(e,e))}function sa(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,wu===e&&(Z&n)===n&&(Au===4||Au===3&&(Z&62914560)===Z&&300>Ec()-zu?!(Y&2)&&Li(e,0):Nu|=n,Fu===Z&&(Fu=0)),je(e)}function ca(e,t){t===0&&(t=y()),e=et(e,t),e!==null&&(x(e,t),je(e))}function la(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),ca(e,n)}function ua(e,t){var n=0;switch(e.tag){case 31:case 13:var i=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:i=e.stateNode;break;case 22:i=e.stateNode._retryCache;break;default:throw Error(r(314))}i!==null&&i.delete(t),ca(e,n)}function da(e,t){return Sc(e,t)}function fa(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function pa(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ma(e,n){var r=e.alternate;return r===null?(r=t(e.tag,n,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=n,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&65011712,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,n=e.dependencies,r.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r.refCleanup=e.refCleanup,r}function ha(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function ga(e,n,i,a,o,s){var c=0;if(a=e,typeof e==`function`)pa(e)&&(c=1);else if(typeof e==`string`)c=qs&&sc?Js(e,i,Zc.current)?26:dc(e)?27:5:qs?Js(e,i,Zc.current)?26:5:sc&&dc(e)?27:5;else a:switch(e){case Wa:return e=t(31,i,n,o),e.elementType=Wa,e.lanes=s,e;case Pa:return _a(i.children,o,s,n);case Fa:c=8,o|=24;break;case Ia:return e=t(12,i,n,o|2),e.elementType=Ia,e.lanes=s,e;case Ba:return e=t(13,i,n,o),e.elementType=Ba,e.lanes=s,e;case Va:return e=t(19,i,n,o),e.elementType=Va,e.lanes=s,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case Ra:c=10;break a;case La:c=9;break a;case za:c=11;break a;case Ha:c=14;break a;case Ua:c=16,a=null;break a}c=29,i=Error(r(130,e===null?`null`:typeof e,``)),a=null}return n=t(c,i,n,o),n.elementType=e,n.type=a,n.lanes=s,n}function _a(e,n,r,i){return e=t(7,e,i,n),e.lanes=r,e}function va(e,n,r){return e=t(6,e,null,n),e.lanes=r,e}function ya(e){var n=t(18,null,null,0);return n.stateNode=e,n}function ba(e,n,r){return n=t(4,e.children===null?[]:e.children,e.key,n),n.lanes=r,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}function xa(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=uo,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=b(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=b(0),this.hiddenUpdates=b(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function Sa(e,n,r,i,a,o,s,c,l,u,d,f){return e=new xa(e,n,r,s,l,u,d,f,c),n=1,!0===o&&(n|=24),o=t(3,null,null,n),e.current=o,o.stateNode=e,n=Oe(),n.refCount++,e.pooledCache=n,n.refCount++,o.memoizedState={element:i,isDehydrated:r,cache:n},rt(o),e}function Ca(e){return e?(e=hc,e):hc}function wa(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(r(188)):(e=Object.keys(e).join(`,`),Error(r(268,e)));return e=o(t),e=e===null?null:s(e),e===null?null:Qa(e.stateNode)}function Ta(e,t,n,r,i,a){i=Ca(i),r.context===null?r.context=i:r.pendingContext=i,r=at(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=ot(e,r,t),n!==null&&(Ai(n,e,t),st(n,e,t))}function Ea(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Da(e,t){Ea(e,t),(e=e.alternate)&&Ea(e,t)}var W={},Oa=N(),ka=di(),Aa=Object.assign,ja=Symbol.for(`react.element`),Ma=Symbol.for(`react.transitional.element`),Na=Symbol.for(`react.portal`),Pa=Symbol.for(`react.fragment`),Fa=Symbol.for(`react.strict_mode`),Ia=Symbol.for(`react.profiler`),La=Symbol.for(`react.consumer`),Ra=Symbol.for(`react.context`),za=Symbol.for(`react.forward_ref`),Ba=Symbol.for(`react.suspense`),Va=Symbol.for(`react.suspense_list`),Ha=Symbol.for(`react.memo`),Ua=Symbol.for(`react.lazy`),Wa=Symbol.for(`react.activity`),Ga=Symbol.for(`react.memo_cache_sentinel`),Ka=Symbol.iterator,qa=Symbol.for(`react.client.reference`),Ja=Array.isArray,G=Oa.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ya=e.rendererVersion,Xa=e.rendererPackageName,Za=e.extraDevToolsConfig,Qa=e.getPublicInstance,$a=e.getRootHostContext,eo=e.getChildHostContext,to=e.prepareForCommit,no=e.resetAfterCommit,ro=e.createInstance;e.cloneMutableInstance;var io=e.appendInitialChild,ao=e.finalizeInitialChildren,oo=e.shouldSetTextContent,so=e.createTextInstance;e.cloneMutableTextInstance;var co=e.scheduleTimeout,lo=e.cancelTimeout,uo=e.noTimeout,fo=e.isPrimaryRenderer;e.warnsIfNotActing;var po=e.supportsMutation,mo=e.supportsPersistence,ho=e.supportsHydration,go=e.getInstanceFromNode;e.beforeActiveInstanceBlur;var _o=e.preparePortalMount;e.prepareScopeUpdate,e.getInstanceFromScope;var vo=e.setCurrentUpdatePriority,yo=e.getCurrentUpdatePriority,bo=e.resolveUpdatePriority;e.trackSchedulerEvent,e.resolveEventType,e.resolveEventTimeStamp;var xo=e.shouldAttemptEagerTransition,So=e.detachDeletedInstance;e.requestPostPaintCallback;var Co=e.maySuspendCommit,wo=e.maySuspendCommitOnUpdate,To=e.maySuspendCommitInSyncRender,Eo=e.preloadInstance,Do=e.startSuspendingCommit,Oo=e.suspendInstance;e.suspendOnActiveViewTransition;var ko=e.waitForCommitToBeReady;e.getSuspendedCommitReason;var Ao=e.NotPendingTransition,jo=e.HostTransitionContext,Mo=e.resetFormInstance;e.bindToConsole;var No=e.supportsMicrotasks,Po=e.scheduleMicrotask,Fo=e.supportsTestSelectors,Io=e.findFiberRoot,Lo=e.getBoundingRect,Ro=e.getTextContent,zo=e.isHiddenSubtree,Bo=e.matchAccessibilityRole,Vo=e.setFocusIfFocusable,Ho=e.setupIntersectionObserver,Uo=e.appendChild,Wo=e.appendChildToContainer,Go=e.commitTextUpdate,Ko=e.commitMount,qo=e.commitUpdate,Jo=e.insertBefore,Yo=e.insertInContainerBefore,Xo=e.removeChild,Zo=e.removeChildFromContainer,Qo=e.resetTextContent,$o=e.hideInstance,es=e.hideTextInstance,ts=e.unhideInstance,ns=e.unhideTextInstance;e.cancelViewTransitionName,e.cancelRootViewTransitionName,e.restoreRootViewTransitionName,e.cloneRootViewTransitionContainer,e.removeRootViewTransitionClone,e.measureClonedInstance,e.hasInstanceChanged,e.hasInstanceAffectedParent,e.startViewTransition,e.startGestureTransition,e.stopViewTransition,e.getCurrentGestureOffset,e.createViewTransitionInstance;var rs=e.clearContainer;e.createFragmentInstance,e.updateFragmentInstanceFiber,e.commitNewChildToFragmentInstance,e.deleteChildFromFragmentInstance;var is=e.cloneInstance,as=e.createContainerChildSet,os=e.appendChildToContainerChildSet,ss=e.finalizeContainerChildren,cs=e.replaceContainerChildren,ls=e.cloneHiddenInstance,us=e.cloneHiddenTextInstance,ds=e.isSuspenseInstancePending,fs=e.isSuspenseInstanceFallback,ps=e.getSuspenseInstanceFallbackErrorDetails,ms=e.registerSuspenseInstanceRetry,hs=e.canHydrateFormStateMarker,gs=e.isFormStateMarkerMatching,_s=e.getNextHydratableSibling,vs=e.getNextHydratableSiblingAfterSingleton,ys=e.getFirstHydratableChild,bs=e.getFirstHydratableChildWithinContainer,xs=e.getFirstHydratableChildWithinActivityInstance,Ss=e.getFirstHydratableChildWithinSuspenseInstance,Cs=e.getFirstHydratableChildWithinSingleton,ws=e.canHydrateInstance,Ts=e.canHydrateTextInstance,Es=e.canHydrateActivityInstance,Ds=e.canHydrateSuspenseInstance,Os=e.hydrateInstance,ks=e.hydrateTextInstance,As=e.hydrateActivityInstance,js=e.hydrateSuspenseInstance,Ms=e.getNextHydratableInstanceAfterActivityInstance,Ns=e.getNextHydratableInstanceAfterSuspenseInstance,Ps=e.commitHydratedInstance,Fs=e.commitHydratedContainer,Is=e.commitHydratedActivityInstance,Ls=e.commitHydratedSuspenseInstance,Rs=e.finalizeHydratedChildren,zs=e.flushHydrationEvents;e.clearActivityBoundary;var Bs=e.clearSuspenseBoundary;e.clearActivityBoundaryFromContainer;var Vs=e.clearSuspenseBoundaryFromContainer,Hs=e.hideDehydratedBoundary,Us=e.unhideDehydratedBoundary,Ws=e.shouldDeleteUnhydratedTailInstances;e.diffHydratedPropsForDevWarnings,e.diffHydratedTextForDevWarnings,e.describeHydratableInstanceForDevWarnings;var Gs=e.validateHydratableInstance,Ks=e.validateHydratableTextInstance,qs=e.supportsResources,Js=e.isHostHoistableType,Ys=e.getHoistableRoot,Xs=e.getResource,Zs=e.acquireResource,Qs=e.releaseResource,$s=e.hydrateHoistable,ec=e.mountHoistable,tc=e.unmountHoistable,nc=e.createHoistableInstance,rc=e.prepareToCommitHoistables,ic=e.mayResourceSuspendCommit,ac=e.preloadResource,oc=e.suspendResource,sc=e.supportsSingletons,cc=e.resolveSingletonInstance,lc=e.acquireSingletonInstance,uc=e.releaseSingletonInstance,dc=e.isHostSingletonType,fc=e.isSingletonScope,pc=[],mc=-1,hc={},gc=Math.clz32?Math.clz32:m,_c=Math.log,vc=Math.LN2,yc=256,bc=262144,xc=4194304,Sc=ka.unstable_scheduleCallback,Cc=ka.unstable_cancelCallback,wc=ka.unstable_shouldYield,Tc=ka.unstable_requestPaint,Ec=ka.unstable_now,Dc=ka.unstable_ImmediatePriority,Oc=ka.unstable_UserBlockingPriority,kc=ka.unstable_NormalPriority,Ac=ka.unstable_IdlePriority,jc=ka.log,Mc=ka.unstable_setDisableYieldValue,Nc=null,Pc=null,Fc=typeof Object.is==`function`?Object.is:ee,Ic=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Lc=Object.prototype.hasOwnProperty,Rc,zc,Bc=!1,Vc=new WeakMap,Hc=[],Uc=0,Wc=null,Gc=0,Kc=[],qc=0,Jc=null,Yc=1,Xc=``,Zc=d(null),Qc=d(null),$c=d(null),el=d(null),tl=null,nl=null,K=!1,rl=null,il=!1,al=Error(r(519)),ol=d(null),sl=null,cl=null,ll=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},ul=ka.unstable_scheduleCallback,dl=ka.unstable_NormalPriority,fl={$$typeof:Ra,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0},pl=null,ml=null,hl=!1,gl=!1,_l=!1,vl=0,yl=null,bl=0,xl=0,Sl=null,Cl=G.S;G.S=function(e,t){Bu=Ec(),typeof t==`object`&&t&&typeof t.then==`function`&&Re(e,t),Cl!==null&&Cl(e,t)};var wl=d(null),Tl=Error(r(460)),El=Error(r(474)),Dl=Error(r(542)),Ol={then:function(){}},kl=null,Al=null,jl=0,Ml=Xe(!0),Nl=Xe(!1),Pl=[],Fl=0,Il=0,Ll=!1,Rl=!1,zl=d(null),Bl=d(0),Vl=d(null),Hl=null,Ul=d(0),Wl=0,q=null,Gl=null,Kl=null,ql=!1,Jl=!1,Yl=!1,Xl=0,Zl=0,Ql=null,$l=0,eu={readContext:Te,use:Nt,useCallback:z,useContext:z,useEffect:z,useImperativeHandle:z,useLayoutEffect:z,useInsertionEffect:z,useMemo:z,useReducer:z,useRef:z,useState:z,useDebugValue:z,useDeferredValue:z,useTransition:z,useSyncExternalStore:z,useId:z,useHostTransitionStatus:z,useFormState:z,useActionState:z,useOptimistic:z,useMemoCache:z,useCacheRefresh:z};eu.useEffectEvent=z;var tu={readContext:Te,use:Nt,useCallback:function(e,t){return At().memoizedState=[e,t===void 0?null:t],e},useContext:Te,useEffect:un,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),cn(4194308,4,gn.bind(null,t,e),n)},useLayoutEffect:function(e,t){return cn(4194308,4,e,t)},useInsertionEffect:function(e,t){cn(4,2,e,t)},useMemo:function(e,t){var n=At();t=t===void 0?null:t;var r=e();if(Yl){O(!0);try{e()}finally{O(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=At();if(n!==void 0){var i=n(t);if(Yl){O(!0);try{n(t)}finally{O(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=V.bind(null,q,e),[r.memoizedState,e]},useRef:function(e){var t=At();return e={current:e},t.memoizedState=e},useState:function(e){e=Gt(e);var t=e.queue,n=kn.bind(null,q,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:vn,useDeferredValue:function(e,t){return xn(At(),e,t)},useTransition:function(){var e=Gt(!1);return e=Cn.bind(null,q,e.queue,!0,!1),At().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var i=q,a=At();if(K){if(n===void 0)throw Error(r(407));n=n()}else{if(n=t(),wu===null)throw Error(r(349));Z&127||Bt(i,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,un(Ht.bind(null,i,o,e),[e]),i.flags|=2048,on(9,{destroy:void 0},Vt.bind(null,i,o,n,t),null),n},useId:function(){var e=At(),t=wu.identifierPrefix;if(K){var n=Xc,r=Yc;n=(r&~(1<<32-gc(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=Xl++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=$l++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Tn,useFormState:en,useActionState:en,useOptimistic:function(e){var t=At();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=jn.bind(null,q,!0,n),n.dispatch=t,[e,t]},useMemoCache:Pt,useCacheRefresh:function(){return At().memoizedState=On.bind(null,q)},useEffectEvent:function(e){var t=At(),n={impl:e};return t.memoizedState=n,function(){if(Y&2)throw Error(r(440));return n.impl.apply(void 0,arguments)}}},nu={readContext:Te,use:Nt,useCallback:yn,useContext:Te,useEffect:dn,useImperativeHandle:_n,useInsertionEffect:mn,useLayoutEffect:hn,useMemo:bn,useReducer:It,useRef:sn,useState:function(){return It(Ft)},useDebugValue:vn,useDeferredValue:function(e,t){return Sn(B(),Gl.memoizedState,e,t)},useTransition:function(){var e=It(Ft)[0],t=B().memoizedState;return[typeof e==`boolean`?e:Mt(e),t]},useSyncExternalStore:zt,useId:En,useHostTransitionStatus:Tn,useFormState:tn,useActionState:tn,useOptimistic:function(e,t){return Kt(B(),Gl,e,t)},useMemoCache:Pt,useCacheRefresh:Dn};nu.useEffectEvent=pn;var ru={readContext:Te,use:Nt,useCallback:yn,useContext:Te,useEffect:dn,useImperativeHandle:_n,useInsertionEffect:mn,useLayoutEffect:hn,useMemo:bn,useReducer:Rt,useRef:sn,useState:function(){return Rt(Ft)},useDebugValue:vn,useDeferredValue:function(e,t){var n=B();return Gl===null?xn(n,e,t):Sn(n,Gl.memoizedState,e,t)},useTransition:function(){var e=Rt(Ft)[0],t=B().memoizedState;return[typeof e==`boolean`?e:Mt(e),t]},useSyncExternalStore:zt,useId:En,useHostTransitionStatus:Tn,useFormState:an,useActionState:an,useOptimistic:function(e,t){var n=B();return Gl===null?(n.baseState=e,[e,n.queue.dispatch]):Kt(n,Gl,e,t)},useMemoCache:Pt,useCacheRefresh:Dn};ru.useEffectEvent=pn;var iu={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Oi(),i=at(r);i.payload=t,n!=null&&(i.callback=n),t=ot(e,i,r),t!==null&&(Ai(t,e,r),st(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Oi(),i=at(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=ot(e,i,r),t!==null&&(Ai(t,e,r),st(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Oi(),r=at(n);r.tag=2,t!=null&&(r.callback=t),t=ot(e,r,n),t!==null&&(Ai(t,e,n),st(t,e,n))}},au=Error(r(461)),ou=!1,su={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null},cu=!1,lu=!1,uu=!1,du=typeof WeakSet==`function`?WeakSet:Set,fu=null,pu=null,J=!1,mu=null,hu=8192,gu={getCacheForType:function(e){var t=Te(fl),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Te(fl).controller.signal}},_u=0,vu=1,yu=2,bu=3,xu=4;if(typeof Symbol==`function`&&Symbol.for){var Su=Symbol.for;_u=Su(`selector.component`),vu=Su(`selector.has_pseudo_class`),yu=Su(`selector.role`),bu=Su(`selector.test_id`),xu=Su(`selector.text`)}var Cu=typeof WeakMap==`function`?WeakMap:Map,Y=0,wu=null,X=null,Z=0,Q=0,Tu=null,Eu=!1,Du=!1,Ou=!1,ku=0,Au=0,ju=0,Mu=0,Nu=0,Pu=0,Fu=0,Iu=null,Lu=null,Ru=!1,zu=0,Bu=0,Vu=1/0,Hu=null,Uu=null,Wu=0,Gu=null,Ku=null,qu=0,Ju=0,Yu=null,Xu=null,Zu=0,Qu=null;return W.attemptContinuousHydration=function(e){if(e.tag===13||e.tag===31){var t=et(e,67108864);t!==null&&Ai(t,e,67108864),Da(e,67108864)}},W.attemptHydrationAtCurrentPriority=function(e){if(e.tag===13||e.tag===31){var t=Oi();t=E(t);var n=et(e,t);n!==null&&Ai(n,e,t),Da(e,t)}},W.attemptSynchronousHydration=function(e){switch(e.tag){case 3:if(e=e.stateNode,e.current.memoizedState.isDehydrated){var t=h(e.pendingLanes);if(t!==0){for(e.pendingLanes|=2,e.entangledLanes|=2;t;){var n=1<<31-gc(t);e.entanglements[1]|=n,t&=~n}je(e),!(Y&6)&&(Vu=Ec()+500,Me(0,!1))}}break;case 31:case 13:t=et(e,2),t!==null&&Ai(t,e,2),Fi(),Da(e,2)}},W.batchedUpdates=function(e,t){return e(t)},W.createComponentSelector=function(e){return{$$typeof:_u,value:e}},W.createContainer=function(e,t,n,r,i,a,o,s,c,l){return Sa(e,t,!1,null,n,r,a,null,o,s,c,l)},W.createHasPseudoClassSelector=function(e){return{$$typeof:vu,value:e}},W.createHydrationContainer=function(e,t,n,r,i,a,o,s,c,l,u,d,f,p){return e=Sa(n,r,!0,e,i,a,s,p,c,l,u,d),e.context=Ca(null),n=e.current,r=Oi(),r=E(r),i=at(r),i.callback=t??null,ot(n,i,r),t=r,e.current.lanes=t,x(e,t),je(e),e},W.createPortal=function(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Na,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}},W.createRoleSelector=function(e){return{$$typeof:yu,value:e}},W.createTestNameSelector=function(e){return{$$typeof:bu,value:e}},W.createTextSelector=function(e){return{$$typeof:xu,value:e}},W.defaultOnCaughtError=function(e){console.error(e)},W.defaultOnRecoverableError=function(e){Ic(e)},W.defaultOnUncaughtError=function(e){Ic(e)},W.deferredUpdates=function(e){var t=G.T,n=yo();try{return vo(32),G.T=null,e()}finally{vo(n),G.T=t}},W.discreteUpdates=function(e,t,n,r,i){var a=G.T,o=yo();try{return vo(2),G.T=null,e(t,n,r,i)}finally{vo(o),G.T=a,Y===0&&(Vu=Ec()+500)}},W.findAllNodes=Di,W.findBoundingRects=function(e,t){if(!Fo)throw Error(r(363));t=Di(e,t),e=[];for(var n=0;n<t.length;n++)e.push(Lo(t[n]));for(t=e.length-1;0<t;t--){n=e[t];for(var i=n.x,a=i+n.width,o=n.y,s=o+n.height,c=t-1;0<=c;c--)if(t!==c){var l=e[c],u=l.x,d=u+l.width,f=l.y,p=f+l.height;if(i>=u&&o>=f&&a<=d&&s<=p){e.splice(t,1);break}else if(!(i!==u||n.width!==l.width||p<o||f>s)){f>o&&(l.height+=f-o,l.y=o),p<s&&(l.height=s-f),e.splice(t,1);break}else if(!(o!==f||n.height!==l.height||d<i||u>a)){u>i&&(l.width+=u-i,l.x=i),d<a&&(l.width=a-u),e.splice(t,1);break}}}return e},W.findHostInstance=wa,W.findHostInstanceWithNoPortals=function(e){return e=o(e),e=e===null?null:c(e),e===null?null:Qa(e.stateNode)},W.findHostInstanceWithWarning=function(e){return wa(e)},W.flushPassiveEffects=ra,W.flushSyncFromReconciler=function(e){var t=Y;Y|=1;var n=G.T,r=yo();try{if(vo(2),G.T=null,e)return e()}finally{vo(r),G.T=n,Y=t,!(Y&6)&&Me(0,!1)}},W.flushSyncWork=Fi,W.focusWithin=function(e,t){if(!Fo)throw Error(r(363));for(e=Ci(e),t=Ei(e,t),t=Array.from(t),e=0;e<t.length;){var n=t[e++],i=n.tag;if(!zo(n)){if((i===5||i===26||i===27)&&Vo(n.stateNode))return!0;for(n=n.child;n!==null;)t.push(n),n=n.sibling}}return!1},W.getFindAllNodesFailureDescription=function(e,t){if(!Fo)throw Error(r(363));var n=0,i=[];e=[Ci(e),0];for(var a=0;a<e.length;){var o=e[a++],s=o.tag,c=e[a++],l=t[c];if((s!==5&&s!==26&&s!==27||!zo(o))&&(wi(o,l)&&(i.push(Ti(l)),c++,c>n&&(n=c)),c<t.length))for(o=o.child;o!==null;)e.push(o,c),o=o.sibling}if(n<t.length){for(e=[];n<t.length;n++)e.push(Ti(t[n]));return`findAllNodes was able to match part of the selector:
14
+ `+(i.join(` > `)+`
15
+
16
+ No matching component was found for:
17
+ `)+e.join(` > `)}return null},W.getPublicRootInstance=function(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 27:case 5:return Qa(e.child.stateNode);default:return e.child.stateNode}},W.injectIntoDevTools=function(){var e={bundleType:0,version:Ya,rendererPackageName:Xa,currentDispatcherRef:G,reconcilerVersion:`19.2.0`};if(Za!==null&&(e.rendererConfig=Za),typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`)e=!1;else{var t=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(t.isDisabled||!t.supportsFiber)e=!0;else{try{Nc=t.inject(e),Pc=t}catch{}e=!!t.checkDCE}}return e},W.isAlreadyRendering=function(){return(Y&6)!=0},W.observeVisibleRects=function(e,t,n,i){if(!Fo)throw Error(r(363));e=Di(e,t);var a=Ho(e,n,i).disconnect;return{disconnect:function(){a()}}},W.shouldError=function(){return null},W.shouldSuspend=function(){return!1},W.startHostTransition=function(e,t,i,a){if(e.tag!==5)throw Error(r(476));var o=wn(e).queue;Cn(e,o,t,Ao,i===null?n:function(){var t=wn(e);return t.next===null&&(t=e.alternate.memoizedState),An(e,t.next.queue,{},Oi()),i(a)})},W.updateContainer=function(e,t,n,r){var i=t.current,a=Oi();return Ta(i,a,e,t,n,r),a},W.updateContainerSync=function(e,t,n,r){return Ta(t.current,2,e,t,n,r),2},W},t.exports.default=t.exports,Object.defineProperty(t.exports,`__esModule`,{value:!0})})),pi=r(((e,t)=>{t.exports=fi()})),H,mi,hi,gi,_i,vi,yi,bi,xi,Si,Ci=t((()=>{H={All:`all`,Horizontal:`horizontal`,Vertical:`vertical`,Left:`left`,Right:`right`,Top:`top`,Bottom:`bottom`,Start:`start`,End:`end`},mi={All:`all`,Column:`column`,Row:`row`},hi={Flex:`flex`,None:`none`},gi={Row:`row`,RowReverse:`row-reverse`,Column:`column`,ColumnReverse:`column-reverse`},_i={Auto:`auto`,Stretch:`stretch`,FlexStart:`flex-start`,Center:`center`,FlexEnd:`flex-end`},vi={FlexStart:`flex-start`,Center:`center`,FlexEnd:`flex-end`,SpaceBetween:`space-between`,SpaceAround:`space-around`,SpaceEvenly:`space-evenly`},yi={NoWrap:`nowrap`,Wrap:`wrap`,WrapReverse:`wrap-reverse`},bi={Relative:`relative`,Absolute:`absolute`},xi={Visible:`visible`,Hidden:`hidden`,Scroll:`scroll`},Si={Undefined:`undefined`,Exactly:`exactly`,AtMost:`at-most`}}));function wi(){return new Di(Ht.Node.create())}var Ti,Ei,Di,Oi=t((()=>{Ut(),Ci(),c(),Ti={all:F.All,horizontal:F.Horizontal,vertical:F.Vertical,left:F.Left,right:F.Right,top:F.Top,bottom:F.Bottom,start:F.Start,end:F.End},Ei={all:Le.All,column:Le.Column,row:Le.Row},Di=class e{constructor(e){l(this,`yoga`,void 0),this.yoga=e}insertChild(e,t){this.yoga.insertChild(e.yoga,t)}removeChild(e){this.yoga.removeChild(e.yoga)}getChildCount(){return this.yoga.getChildCount()}getParent(){let t=this.yoga.getParent();return t?new e(t):null}calculateLayout(e,t){this.yoga.calculateLayout(e,void 0,Ne.LTR)}setMeasureFunc(e){this.yoga.setMeasureFunc((t,n)=>e(t,n===I.Exactly?Si.Exactly:n===I.AtMost?Si.AtMost:Si.Undefined))}unsetMeasureFunc(){this.yoga.unsetMeasureFunc()}markDirty(){this.yoga.markDirty()}getComputedLeft(){return this.yoga.getComputedLeft()}getComputedTop(){return this.yoga.getComputedTop()}getComputedWidth(){return this.yoga.getComputedWidth()}getComputedHeight(){return this.yoga.getComputedHeight()}getComputedBorder(e){return this.yoga.getComputedBorder(Ti[e])}getComputedPadding(e){return this.yoga.getComputedPadding(Ti[e])}setWidth(e){this.yoga.setWidth(e)}setWidthPercent(e){this.yoga.setWidthPercent(e)}setWidthAuto(){this.yoga.setWidthAuto()}setHeight(e){this.yoga.setHeight(e)}setHeightPercent(e){this.yoga.setHeightPercent(e)}setHeightAuto(){this.yoga.setHeightAuto()}setMinWidth(e){this.yoga.setMinWidth(e)}setMinWidthPercent(e){this.yoga.setMinWidthPercent(e)}setMinHeight(e){this.yoga.setMinHeight(e)}setMinHeightPercent(e){this.yoga.setMinHeightPercent(e)}setMaxWidth(e){this.yoga.setMaxWidth(e)}setMaxWidthPercent(e){this.yoga.setMaxWidthPercent(e)}setMaxHeight(e){this.yoga.setMaxHeight(e)}setMaxHeightPercent(e){this.yoga.setMaxHeightPercent(e)}setFlexDirection(e){let t={row:Ie.Row,"row-reverse":Ie.RowReverse,column:Ie.Column,"column-reverse":Ie.ColumnReverse};this.yoga.setFlexDirection(t[e])}setFlexGrow(e){this.yoga.setFlexGrow(e)}setFlexShrink(e){this.yoga.setFlexShrink(e)}setFlexBasis(e){this.yoga.setFlexBasis(e)}setFlexBasisPercent(e){this.yoga.setFlexBasisPercent(e)}setFlexWrap(e){let t={nowrap:He.NoWrap,wrap:He.Wrap,"wrap-reverse":He.WrapReverse};this.yoga.setFlexWrap(t[e])}setAlignItems(e){let t={auto:P.Auto,stretch:P.Stretch,"flex-start":P.FlexStart,center:P.Center,"flex-end":P.FlexEnd};this.yoga.setAlignItems(t[e])}setAlignSelf(e){let t={auto:P.Auto,stretch:P.Stretch,"flex-start":P.FlexStart,center:P.Center,"flex-end":P.FlexEnd};this.yoga.setAlignSelf(t[e])}setJustifyContent(e){let t={"flex-start":Re.FlexStart,center:Re.Center,"flex-end":Re.FlexEnd,"space-between":Re.SpaceBetween,"space-around":Re.SpaceAround,"space-evenly":Re.SpaceEvenly};this.yoga.setJustifyContent(t[e])}setDisplay(e){this.yoga.setDisplay(e===`flex`?Pe.Flex:Pe.None)}getDisplay(){return this.yoga.getDisplay()===Pe.None?hi.None:hi.Flex}setPositionType(e){this.yoga.setPositionType(e===`absolute`?Be.Absolute:Be.Relative)}setPosition(e,t){this.yoga.setPosition(Ti[e],t)}setPositionPercent(e,t){this.yoga.setPositionPercent(Ti[e],t)}setOverflow(e){let t={visible:ze.Visible,hidden:ze.Hidden,scroll:ze.Scroll};this.yoga.setOverflow(t[e])}setMargin(e,t){this.yoga.setMargin(Ti[e],t)}setPadding(e,t){this.yoga.setPadding(Ti[e],t)}setBorder(e,t){this.yoga.setBorder(Ti[e],t)}setGap(e,t){this.yoga.setGap(Ei[e],t)}free(){this.yoga.free()}freeRecursive(){this.yoga.freeRecursive()}}}));function ki(){return wi()}var Ai=t((()=>{Oi()})),ji,Mi=t((()=>{ji=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g})),Ni,Pi,Fi,Ii,Li,Ri=t((()=>{Ni=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],Pi=[12288,12288,65281,65376,65504,65510],Fi=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],Ii=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],Li=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141]})),zi,Bi=t((()=>{zi=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;for(;n<=r;){let i=Math.floor((n+r)/2),a=i*2;if(t<e[a])r=i-1;else if(t>e[a+1])n=i+1;else return!0}return!1}}));function Vi(e){let t=e[0],n=e[1];for(let r=0;r<e.length;r+=2){let i=e[r],a=e[r+1];if(Ji>=i&&Ji<=a)return[i,a];a-i>n-t&&(t=i,n=a)}return[t,n]}var Hi,Ui,Wi,Gi,Ki,qi,Ji,Yi,Xi,Zi,Qi,$i,ea=t((()=>{Ri(),Bi(),Hi=Ni[0],Ui=Ni.at(-1),Wi=Pi[0],Gi=Pi.at(-1),Fi[0],Fi.at(-1),Ii[0],Ii.at(-1),Ki=Li[0],qi=Li.at(-1),Ji=19968,[Yi,Xi]=Vi(Li),Zi=e=>e<Hi||e>Ui?!1:zi(Ni,e),Qi=e=>e<Wi||e>Gi?!1:zi(Pi,e),$i=e=>e>=Yi&&e<=Xi?!0:e<Ki||e>qi?!1:zi(Li,e)}));function ta(e){if(!Number.isSafeInteger(e))throw TypeError(`Expected a code point, got \`${typeof e}\`.`)}function na(e,{ambiguousAsWide:t=!1}={}){return ta(e),Qi(e)||$i(e)||t&&Zi(e)?2:1}var ra=t((()=>{ea()}));function ia({onlyFirst:e=!1}={}){return RegExp(`(?:\\u001B\\][\\s\\S]*?(?:\\u0007|\\u001B\\u005C|\\u009C))|[\\u001B\\u009B][[\\]()#;?]*(?:\\d{1,4}(?:[;:]\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]`,e?void 0:`g`)}var aa=t((()=>{}));function U(e){if(typeof e!=`string`)throw TypeError(`Expected a \`string\`, got \`${typeof e}\``);return!e.includes(`\x1B`)&&!e.includes(`›`)?e:e.replace(oa,``)}var oa,sa=t((()=>{aa(),oa=ia()}));function ca(){return la||(la=new Intl.Segmenter(void 0,{granularity:`grapheme`})),la}var la,ua=t((()=>{la=null}));function da(e){if(typeof e!=`string`||e.length===0)return 0;let t=!0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);if(r>=127||r===27){t=!1;break}}if(t){let t=0;for(let n=0;n<e.length;n++)e.charCodeAt(n)>31&&t++;return t}if(e.includes(`\x1B`)&&(e=U(e),e.length===0))return 0;if(!fa(e)){let t=0;for(let n of e){let e=n.codePointAt(0);ma(e)||(t+=na(e,{ambiguousAsWide:!1}))}return t}let n=0;for(let{segment:t}of ca().segment(e)){if(ha.lastIndex=0,ha.test(t)){n+=pa(t);continue}for(let e of t){let t=e.codePointAt(0);if(!ma(t)){n+=na(t,{ambiguousAsWide:!1});break}}}return n}function fa(e){for(let t of e){let e=t.codePointAt(0);if(e>=127744&&e<=129791||e>=9728&&e<=10175||e>=127462&&e<=127487||e>=65024&&e<=65039||e===8205)return!0}return!1}function pa(e){let t=e.codePointAt(0);if(t>=127462&&t<=127487){let t=0;for(let n of e)t++;return t===1?1:2}return e.length===2&&e.codePointAt(1)===65039&&(t>=48&&t<=57||t===35||t===42)?1:2}function ma(e){if(e>=32&&e<127)return!1;if(e>=160&&e<768)return e===173;if(e<=31||e>=127&&e<=159||e>=8203&&e<=8205||e===65279||e>=8288&&e<=8292||e>=65024&&e<=65039||e>=917760&&e<=917999||e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071)return!0;if(e>=2304&&e<=3407){let t=e&127;if(t<=3||t>=58&&t<=79||t>=81&&t<=87||t>=98&&t<=99)return!0}return e===3633||e>=3636&&e<=3642||e>=3655&&e<=3662||e===3761||e>=3764&&e<=3772||e>=3784&&e<=3789||e>=1536&&e<=1541||e===1757||e===1807||e===2274||e>=55296&&e<=57343||e>=917504&&e<=917631}var ha,ga,_a,va,ya=t((()=>{Mi(),ra(),sa(),ua(),ha=ji(),ga=typeof Bun<`u`&&typeof Bun.stringWidth==`function`?Bun.stringWidth:null,_a={ambiguousIsNarrow:!0},va=ga?e=>ga(e,_a):da}));function ba(e){let t=xa.get(e);if(t!==void 0)return t;let n=va(e);return xa.size>=Sa&&xa.clear(),xa.set(e,n),n}var xa,Sa,Ca=t((()=>{ya(),xa=new Map,Sa=4096}));function wa(e,t){if(e.length===0)return{width:0,height:0};let n=t<=0||!Number.isFinite(t),r=0,i=0,a=0;for(;a<=e.length;){let o=e.indexOf(`
18
+ `,a),s=ba(o===-1?e.substring(a):e.substring(a,o));if(i=Math.max(i,s),n?r++:r+=s===0?1:Math.ceil(s/t),o===-1)break;a=o+1}return{width:i,height:r}}var Ta=t((()=>{Ca()}));function Ea(e,t,n){let r=Oa.get(e);r?r.push(t):Oa.set(e,[t]),n&&(ka=!0)}function Da(){let e=ka;return ka=!1,e}var W,Oa,ka,Aa=t((()=>{W=new WeakMap,Oa=new WeakMap,ka=!1}));function ja(e,t={},n,r=[]){let i=e.textStyles?{...t,...e.textStyles}:t;for(let t of e.childNodes)if(t!==void 0){if(t.nodeName===`#text`)t.nodeValue.length>0&&r.push({text:t.nodeValue,styles:i,hyperlink:n});else if(t.nodeName===`ink-text`||t.nodeName===`ink-virtual-text`)ja(t,i,n,r);else if(t.nodeName===`ink-link`){let e=t.attributes.href;ja(t,i,e||n,r)}}return r}function Ma(e){let t=``;for(let n of e.childNodes)n!==void 0&&(n.nodeName===`#text`?t+=n.nodeValue:(n.nodeName===`ink-text`||n.nodeName===`ink-virtual-text`||n.nodeName===`ink-link`)&&(t+=Ma(n)));return t}var Na=t((()=>{}));function Pa(e,t=Fa){if(!e.includes(` `))return e;let n=Or(),r=n.feed(e);r.push(...n.flush());let i=``,a=0;for(let e of r)if(e.type===`sequence`)i+=e.value;else{let n=e.value.split(/(\t|\n)/);for(let e of n)if(e===` `){let e=t-a%t;i+=` `.repeat(e),a+=e}else e===`
19
+ `?(i+=e,a=0):(i+=e,a+=va(e))}return i}var Fa,Ia=t((()=>{ya(),Ar(),Fa=8}));function La(){let e=new Map;for(let[t,n]of Object.entries(Ha)){for(let[t,r]of Object.entries(n))Ha[t]={open:`\u001B[${r[0]}m`,close:`\u001B[${r[1]}m`},n[t]=Ha[t],e.set(r[0],r[1]);Object.defineProperty(Ha,t,{value:n,enumerable:!1})}return Object.defineProperty(Ha,`codes`,{value:e,enumerable:!1}),Ha.color.close=`\x1B[39m`,Ha.bgColor.close=`\x1B[49m`,Ha.color.ansi=za(),Ha.color.ansi256=Ba(),Ha.color.ansi16m=Va(),Ha.bgColor.ansi=za(Ra),Ha.bgColor.ansi256=Ba(Ra),Ha.bgColor.ansi16m=Va(Ra),Object.defineProperties(Ha,{rgbToAnsi256:{value(e,t,n){return e===t&&t===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(t/255*5)+Math.round(n/255*5)},enumerable:!1},hexToRgb:{value(e){let t=/[a-f\d]{6}|[a-f\d]{3}/i.exec(e.toString(16));if(!t)return[0,0,0];let[n]=t;n.length===3&&(n=[...n].map(e=>e+e).join(``));let r=Number.parseInt(n,16);return[r>>16&255,r>>8&255,r&255]},enumerable:!1},hexToAnsi256:{value:e=>Ha.rgbToAnsi256(...Ha.hexToRgb(e)),enumerable:!1},ansi256ToAnsi:{value(e){if(e<8)return 30+e;if(e<16)return 90+(e-8);let t,n,r;if(e>=232)t=((e-232)*10+8)/255,n=t,r=t;else{e-=16;let i=e%36;t=Math.floor(e/36)/5,n=Math.floor(i/6)/5,r=i%6/5}let i=Math.max(t,n,r)*2;if(i===0)return 30;let a=30+(Math.round(r)<<2|Math.round(n)<<1|Math.round(t));return i===2&&(a+=60),a},enumerable:!1},rgbToAnsi:{value:(e,t,n)=>Ha.ansi256ToAnsi(Ha.rgbToAnsi256(e,t,n)),enumerable:!1},hexToAnsi:{value:e=>Ha.ansi256ToAnsi(Ha.hexToAnsi256(e)),enumerable:!1}}),Ha}var Ra,za,Ba,Va,Ha,Ua,Wa,Ga,Ka=t((()=>{Ra=10,za=(e=0)=>t=>`\u001B[${t+e}m`,Ba=(e=0)=>t=>`\u001B[${38+e};5;${t}m`,Va=(e=0)=>(t,n,r)=>`\u001B[${38+e};2;${t};${n};${r}m`,Ha={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}},Object.keys(Ha.modifier),Ua=Object.keys(Ha.color),Wa=Object.keys(Ha.bgColor),[...Ua,...Wa],Ga=La()})),qa,Ja,G,Ya,Xa,Za,Qa,$a,eo,to,no,ro,io,ao,oo,so,co,lo,uo=t((()=>{qa=`\x07`,Ja=`\x1B`,G=`\\`,Ya=`[`,Xa=`]`,Za=`œ`,Qa=qa.charCodeAt(0),$a=Ja.charCodeAt(0),eo=G.charCodeAt(0),to=Ya.charCodeAt(0),no=Xa.charCodeAt(0),ro=Za.charCodeAt(0),io=new Set([$a,155]),ao=`${Ja}${Xa}8;`,oo=ao.split(``).map(e=>e.charCodeAt(0)),so=`${Ja}${Xa}8;;${qa}`,co=`${Ja}${Xa}8;;${Ja}${G}`,lo=`${Ja}${Xa}8;;${Za}`}));function fo(e){if(ho.has(e))return e;if(go.has(e))return go.get(e);if(e.startsWith(ao))return e.endsWith(`\x1B\\`)?co:e.endsWith(`œ`)?lo:so;if(e=e.slice(2),e.startsWith(`38`))return Ga.color.close;if(e.startsWith(`48`))return Ga.bgColor.close;let t=Ga.codes.get(parseInt(e,10));return t?Ga.color.ansi(t):Ga.reset.open}function po(e){return[...new Set(e.map(e=>e.code))].join(``)}function mo(e){return e.code===Ga.bold.open||e.code===Ga.dim.open}var ho,go,_o=t((()=>{Ka(),uo(),ho=new Set,go=new Map;for(let[e,t]of Ga.codes)ho.add(Ga.color.ansi(t)),go.set(Ga.color.ansi(e),Ga.color.ansi(t))}));function vo(e){return yo([],e)}function yo(e,t){let n=[...e];for(let e of t)e.code===Ga.reset.open?n=[]:ho.has(e.code)?n=n.filter(t=>t.endCode!==e.code):mo(e)?n.find(t=>t.code===e.code&&t.endCode===e.endCode)||n.push(e):(n=n.filter(t=>t.endCode!==e.endCode),n.push(e));return n}var bo=t((()=>{Ka(),_o()}));function xo(e){return vo(e).reverse().map(e=>({...e,code:e.endCode}))}var So=t((()=>{bo()}));function Co(e,t){let n=new Set(t.map(e=>e.endCode)),r=new Set(t.map(e=>e.code)),i=new Set(e.map(e=>e.code));return[...xo(e.filter(e=>mo(e)?!r.has(e.code):!n.has(e.endCode))),...t.filter(e=>!i.has(e.code))]}var wo=t((()=>{_o(),So()}));function To(e){let t=[],n=[];for(let r of e)r.type===`ansi`?t=yo(t,[r]):r.type===`char`&&n.push({...r,styles:[...t]});return n}var Eo=t((()=>{_o(),wo(),bo()}));function Do(e){return Number.isInteger(e)?Qi(e)||$i(e):!1}var Oo=t((()=>{ra()}));function ko(e,t){return!!(Do(t)||e.includes(`️`)||t>=127462&&t<=127487)}function Ao(e,t){e=e.slice(t);for(let t=1;t<oo.length;t++)if(e.charCodeAt(t)!==oo[t])return;let n=e.indexOf(`;`,ao.length);if(n===-1)return;let r=Mo(e,n+1);if(r!==-1)return e.slice(0,r+1)}function jo(e,t){e=e.slice(t);let n=Mo(e,2);if(n!==-1)return e.slice(0,n+1)}function Mo(e,t){for(let n=t;n<e.length;n++){let t=e.charCodeAt(n);if(t===Qa||t===ro)return n;if(t===$a&&n+1<e.length&&e.charCodeAt(n+1)===eo)return n+1}return-1}function No(e){for(let t=2;t<e.length;t++){let n=e.charCodeAt(t);if(n===109)return t;if(n!==59&&!(n>=48&&n<=57))break}return-1}function Po(e,t){e=e.slice(t);let n=No(e);if(n!==-1)return e.slice(0,n+1)}function Fo(e){if(!e.includes(`;`))return[e];let t=e.slice(2,-1).split(`;`),n=[];for(let e=0;e<t.length;e++){let r=t[e];if(r===`38`||r===`48`){if(e+2<t.length&&t[e+1]===`5`){n.push(t.slice(e,e+3).join(`;`)),e+=2;continue}else if(e+4<t.length&&t[e+1]===`2`){n.push(t.slice(e,e+5).join(`;`)),e+=4;continue}}n.push(r)}return n.map(e=>`\x1b[${e}m`)}function Io(e,t=1/0){let n=[],r=0,i=0;for(let{segment:a,index:o}of Lo.segment(e)){if(o<i)continue;let s=a.codePointAt(0);if(io.has(s)){let t,r=e.codePointAt(o+1);if(r===no)t=Ao(e,o),t?n.push({type:`ansi`,code:t,endCode:fo(t)}):(t=jo(e,o),t&&n.push({type:`control`,code:t}));else if(r===to&&(t=Po(e,o),t)){let e=Fo(t);for(let t of e)n.push({type:`ansi`,code:t,endCode:fo(t)})}if(t){i=o+t.length;continue}}let c=ko(a,s);if(n.push({type:`char`,value:a,fullWidth:c}),r+=c?2:1,r>=t)break}return n}var Lo,Ro=t((()=>{Oo(),_o(),uo(),Lo=new Intl.Segmenter(void 0,{granularity:`grapheme`})})),zo=t((()=>{_o(),wo(),bo(),Eo(),Ro(),So()}));function Bo(e){return e.code===e.endCode}function Vo(e){return e.filter(e=>!Bo(e))}function Ho(e,t,n){let r=Io(e),i=[],a=0,o=``,s=!1;for(let e of r){let r=e.type===`ansi`?0:e.type===`char`?e.fullWidth?2:va(e.value):0;if(n!==void 0&&a>=n&&(e.type===`ansi`||r>0||!s))break;if(e.type===`ansi`)i.push(e),s&&(o+=e.code);else{if(!s&&a>=t){if(t>0&&r===0)continue;s=!0,i=Vo(vo(i)),o=po(i)}s&&(o+=e.value),a+=r}}let c=Vo(vo(i));return o+=po(xo(c)),o}var Uo=t((()=>{zo(),ya()}));function Wo(e){if(e.length>50)return!1;if($o.test(e))return!0;if(e.includes(`‍`)){let t=e.match(es);return t!==null&&t.length>=2}return!1}function Go(e){return e.replace(Zo,``)}function Ko(e){return Xo.test(e)}function qo(e,t){let n=0;if(e.length>1)for(let r of e.slice(1))r>=`＀`&&r<=`￯`&&(n+=na(r.codePointAt(0),t));return n}function Jo(e,t={}){if(typeof e!=`string`||e.length===0)return 0;let{ambiguousIsNarrow:n=!0,countAnsiEscapeCodes:r=!1}=t,i=e;if(!r&&(i.includes(`\x1B`)||i.includes(`›`))&&(i=U(i)),i.length===0)return 0;if(/^[\u0020-\u007E]*$/.test(i))return i.length;let a=0,o={ambiguousAsWide:!n};for(let{segment:e}of Yo.segment(i)){if(Ko(e))continue;if(Qo.test(e)||Wo(e)){a+=2;continue}let t=Go(e).codePointAt(0);a+=na(t,o),a+=qo(e,o)}return a}var Yo,Xo,Zo,Qo,$o,es,ts=t((()=>{sa(),ra(),Yo=new Intl.Segmenter,Xo=RegExp(`^(?:\\p{Default_Ignorable_Code_Point}|\\p{Control}|\\p{Format}|\\p{Mark}|\\p{Surrogate})+$`,`v`),Zo=RegExp(`^[\\p{Default_Ignorable_Code_Point}\\p{Control}\\p{Format}\\p{Mark}\\p{Surrogate}]+`,`v`),Qo=RegExp(`^\\p{RGI_Emoji}$`,`v`),$o=/^[\d#*]\u20E3$/,es=/\p{Extended_Pictographic}/gu}));function ns(e,t,n){return String(e).normalize().replaceAll(`\r
20
+ `,`
21
+ `).split(`
22
+ `).map(e=>Ws(Us(e),t,n)).join(`
23
+ `)}var rs,is,as,os,ss,cs,ls,us,ds,fs,ps,ms,hs,gs,_s,vs,ys,bs,xs,Ss,Cs,ws,Ts,Es,Ds,Os,ks,As,js,Ms,Ns,Ps,Fs,Is,Ls,Rs,zs,Bs,Vs,Hs,Us,Ws,Gs=t((()=>{ts(),sa(),Ka(),rs=`\x1B`,is=`›`,as=new Set([rs,is]),os=`\x07`,ss=`[`,cs=`]`,ls=`m`,us=0,ds=39,fs=49,ps=59,ms=38,hs=48,gs=58,_s=5,vs=2,ys=`${cs}8;;`,bs=RegExp(`^\\u001B(?:\\${ss}(?<sgr>[0-9;]*)${ls}|${ys}(?<uri>[^\\u0007\\u001B]*)(?:\\u0007|\\u001B\\\\))`),xs=RegExp(`^\\u009B(?<sgr>[0-9;]*)${ls}`),Ss=new Set(Ga.codes.values()),Ss.delete(us),Cs=new Intl.Segmenter,ws=e=>Array.from(Cs.segment(e),({segment:e})=>e),Ts=8,Es=e=>`${rs}${ss}${e}${ls}`,Ds=e=>`${rs}${ys}${e}${os}`,Os=e=>{let t=e.split(`;`).map(e=>e===``?us:Number.parseInt(e,10)),n=[];for(let e=0;e<t.length;e++){let r=t[e];if(Number.isFinite(r)){if(r===ms||r===hs||r===gs){if(e+1>=t.length)break;let i=t[e+1];if(i===_s&&Number.isFinite(t[e+2])){n.push([r,i,t[e+2]]),e+=2;continue}let a=t[e+2],o=t[e+3],s=t[e+4];if(i===vs&&Number.isFinite(a)&&Number.isFinite(o)&&Number.isFinite(s)){n.push([r,i,a,o,s]),e+=4;continue}break}n.push([r])}}return n},ks=(e,t)=>{let n=e.findIndex(e=>e.family===t);n!==-1&&e.splice(n,1)},As=(e,t)=>{ks(e,t.family),e.push(t)},js=(e,t)=>{for(let n=e.length-1;n>=0;n--){let r=e[n];r.family.startsWith(`modifier-`)&&r.close===t&&e.splice(n,1)}},Ms=(e,t)=>{if(e>=30&&e<=37||e>=90&&e<=97||e===ms&&t.length>1)return{family:`foreground`,open:t.join(`;`),close:ds};if(e>=40&&e<=47||e>=100&&e<=107||e===hs&&t.length>1)return{family:`background`,open:t.join(`;`),close:fs};if(e===gs&&t.length>1)return{family:`underlineColor`,open:t.join(`;`),close:ps}},Ns=(e,t)=>e===us?(t.length=0,!0):e===ds?(ks(t,`foreground`),!0):e===fs?(ks(t,`background`),!0):e===ps?(ks(t,`underlineColor`),!0):Ss.has(e)?(js(t,e),!0):!1,Ps=(e,t)=>{let[n]=e;if(Ns(n,t))return;let r=Ms(n,e);if(r){As(t,r);return}let i=Ga.codes.get(n);i!==void 0&&i!==us&&As(t,{family:`modifier-${n}`,open:e.join(`;`),close:i})},Fs=(e,t)=>{for(let n of Os(e))Ps(n,t)},Is=(e,t)=>{for(let n of Os(e)){let[e]=n;Ns(e,t)}},Ls=(e,t)=>{let n=e;for(;n.length>0;){if(n.startsWith(rs)&&n[1]!==`\\`){let e=bs.exec(n);if(!e)break;e.groups.sgr!==void 0&&Is(e.groups.sgr,t),n=n.slice(e[0].length);continue}if(n.startsWith(is)){let e=xs.exec(n);if(!e||e.groups.sgr===void 0)break;Is(e.groups.sgr,t),n=n.slice(e[0].length);continue}break}},Rs=e=>[...e].reverse().map(e=>Es(e.close)).join(``),zs=e=>e.map(e=>Es(e.open)).join(``),Bs=e=>e.split(` `).map(e=>Jo(e)),Vs=(e,t,n)=>{let r=ws(t),i=!1,a=!1,o=Jo(U(e.at(-1)));for(let[t,s]of r.entries()){let c=Jo(s);if(o+c<=n?e[e.length-1]+=s:(e.push(s),o=0),as.has(s)&&!(a&&s===rs&&r[t+1]===`\\`)&&(i=!0,a=r.slice(t+1,t+1+ys.length).join(``)===ys),i){a?(s===os||s===`\\`&&t>0&&r[t-1]===rs)&&(i=!1,a=!1):s===ls&&(i=!1);continue}o+=c,o===n&&t<r.length-1&&(e.push(``),o=0)}!o&&e.at(-1).length>0&&e.length>1&&(e[e.length-2]+=e.pop())},Hs=e=>{let t=e.split(` `),n=t.length;for(;n>0&&!(Jo(t[n-1])>0);)n--;return n===t.length?e:t.slice(0,n).join(` `)+t.slice(n).join(``)},Us=e=>{if(!e.includes(` `))return e;let t=e.split(` `),n=0,r=``;for(let[e,i]of t.entries())if(r+=i,n+=Jo(i),e<t.length-1){let e=Ts-n%Ts;r+=` `.repeat(e),n+=e}return r},Ws=(e,t,n={})=>{if(n.trim!==!1&&e.trim()===``)return``;let r=``,i,a=[],o=Bs(e),s=[``];for(let[r,i]of e.split(` `).entries()){n.trim!==!1&&(s[s.length-1]=s.at(-1).trimStart());let e=Jo(s.at(-1));if(r!==0&&(e>=t&&(n.wordWrap===!1||n.trim===!1)&&(s.push(``),e=0),(e>0||n.trim===!1)&&(s[s.length-1]+=` `,e++)),n.hard&&n.wordWrap!==!1&&o[r]>t){let n=t-e,a=1+Math.floor((o[r]-n-1)/t);Math.floor((o[r]-1)/t)<a&&s.push(``),Vs(s,i,t);continue}if(e+o[r]>t&&e>0&&o[r]>0){if(n.wordWrap===!1&&e<t){Vs(s,i,t);continue}s.push(``)}if(e+o[r]>t&&n.wordWrap===!1){Vs(s,i,t);continue}s[s.length-1]+=i}n.trim!==!1&&(s=s.map(e=>Hs(e)));let c=s.join(`
24
+ `),l=ws(c),u=0;for(let[e,t]of l.entries()){if(r+=t,t===rs&&l[e+1]!==`\\`){let{groups:e}=bs.exec(c.slice(u))||{groups:{}};e.sgr===void 0?e.uri!==void 0&&(i=e.uri.length===0?void 0:e.uri):Fs(e.sgr,a)}else if(t===is){let{groups:e}=xs.exec(c.slice(u))||{groups:{}};e.sgr!==void 0&&Fs(e.sgr,a)}if(l[e+1]===`
25
+ `)i&&(r+=Ds(``)),r+=Rs(a);else if(t===`
26
+ `){let e=[...a];Ls(c.slice(u+1),e),r+=zs(e),i&&(r+=Ds(i))}u+=t.length}return r}})),Ks,qs=t((()=>{Gs(),Ks=(typeof Bun<`u`&&typeof Bun.wrapAnsi==`function`?Bun.wrapAnsi:null)??ns}));function Js(e,t,n){let r=Ho(e,t,n);return va(r)>n-t?Ho(e,t,n-1):r}function Ys(e,t,n){if(t<1)return``;if(t===1)return Zs;let r=va(e);if(r<=t)return e;if(n===`start`)return Zs+Js(e,r-t+1,r);if(n===`middle`){let n=Math.floor(t/2);return Js(e,0,n)+Zs+Js(e,r-(t-n)+1,r)}return Js(e,0,t-1)+Zs}function Xs(e,t,n){if(n===`wrap`)return Ks(e,t,{trim:!1,hard:!0});if(n===`wrap-trim`)return Ks(e,t,{trim:!0,hard:!0});if(n.startsWith(`truncate`)){let r=`end`;return n===`truncate-middle`&&(r=`middle`),n===`truncate-start`&&(r=`start`),Ys(e,t,r)}return e}var Zs,Qs=t((()=>{Uo(),ya(),qs(),Zs=`…`}));function $s(e,t,n=!1){if(t.nodeName===`#text`)return;let r=t,i=n||r.style.position===`absolute`,a=W.get(r);a&&(Ea(e,a,i),W.delete(r));for(let t of r.childNodes)$s(e,t,i)}function ec(e,t){return tc(e,t)}function tc(e,t){if(e===t)return!0;if(e===void 0||t===void 0)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(e[r]!==t[r])return!1;return!0}function nc(e){return e.nodeName!==`#text`}function rc(e,t){let n=[];return r(e,0),n;function r(e,i){let a=e.yogaNode;if(!a||a.getDisplay()===hi.None)return;let o=i+a.getComputedTop(),s=a.getComputedHeight();if(!(t<o||t>=o+s)){e.debugOwnerChain&&(n=e.debugOwnerChain);for(let t of e.childNodes)nc(t)&&r(t,o)}}}var ic,ac,oc,sc,cc,lc,uc,dc,fc,pc,mc,hc,gc,_c,vc=t((()=>{Ai(),Ci(),Ta(),Aa(),Na(),Ia(),Qs(),ic=e=>{let t={nodeName:e,style:{},attributes:{},childNodes:[],parentNode:void 0,yogaNode:e!==`ink-virtual-text`&&e!==`ink-link`&&e!==`ink-progress`?ki():void 0,dirty:!1};return e===`ink-text`?t.yogaNode?.setMeasureFunc(fc.bind(null,t)):e===`ink-raw-ansi`&&t.yogaNode?.setMeasureFunc(pc.bind(null,t)),t},ac=(e,t)=>{t.parentNode&&sc(t.parentNode,t),t.parentNode=e,e.childNodes.push(t),t.yogaNode&&e.yogaNode?.insertChild(t.yogaNode,e.yogaNode.getChildCount()),mc(e)},oc=(e,t,n)=>{t.parentNode&&sc(t.parentNode,t),t.parentNode=e;let r=e.childNodes.indexOf(n);if(r>=0){let n=0;if(t.yogaNode&&e.yogaNode)for(let t=0;t<r;t++)e.childNodes[t]?.yogaNode&&n++;e.childNodes.splice(r,0,t),t.yogaNode&&e.yogaNode&&e.yogaNode.insertChild(t.yogaNode,n),mc(e);return}e.childNodes.push(t),t.yogaNode&&e.yogaNode?.insertChild(t.yogaNode,e.yogaNode.getChildCount()),mc(e)},sc=(e,t)=>{t.yogaNode&&t.parentNode?.yogaNode?.removeChild(t.yogaNode),$s(e,t),t.parentNode=void 0;let n=e.childNodes.indexOf(t);n>=0&&e.childNodes.splice(n,1),mc(e)},cc=(e,t,n)=>{t!==`children`&&e.attributes[t]!==n&&(e.attributes[t]=n,mc(e))},lc=(e,t)=>{ec(e.style,t)||(e.style=t,mc(e))},uc=(e,t)=>{tc(e.textStyles,t)||(e.textStyles=t,mc(e))},dc=e=>{let t={nodeName:`#text`,nodeValue:e,yogaNode:void 0,parentNode:void 0,style:{}};return gc(t,e),t},fc=function(e,t,n){let r=Pa(e.nodeName===`#text`?e.nodeValue:Ma(e)),i=wa(r,t);return i.width<=t||i.width>=1&&t>0&&t<1?i:r.includes(`
27
+ `)&&n===Si.Undefined?wa(r,Math.max(t,i.width)):wa(Xs(r,t,e.style?.textWrap??`wrap`),t)},pc=function(e){return{width:e.attributes.rawWidth,height:e.attributes.rawHeight}},mc=e=>{let t=e,n=!1;for(;t;)t.nodeName!==`#text`&&(t.dirty=!0,!n&&(t.nodeName===`ink-text`||t.nodeName===`ink-raw-ansi`)&&t.yogaNode&&(t.yogaNode.markDirty(),n=!0)),t=t.parentNode},hc=e=>{let t=e;for(;t?.parentNode;)t=t.parentNode;t&&t.nodeName!==`#text`&&t.onRender?.()},gc=(e,t)=>{typeof t!=`string`&&(t=String(t)),e.nodeValue!==t&&(e.nodeValue=t,mc(e))},_c=e=>{if(`childNodes`in e)for(let t of e.childNodes)_c(t);e.yogaNode=void 0}})),yc,bc,xc=t((()=>{yc={keydown:{bubble:`onKeyDown`,capture:`onKeyDownCapture`},focus:{bubble:`onFocus`,capture:`onFocusCapture`},blur:{bubble:`onBlur`,capture:`onBlurCapture`},paste:{bubble:`onPaste`,capture:`onPasteCapture`},resize:{bubble:`onResize`},click:{bubble:`onClick`},mousedown:{bubble:`onMouseDown`},mouseup:{bubble:`onMouseUp`},mousedrag:{bubble:`onMouseDrag`}},bc=new Set([`onKeyDown`,`onKeyDownCapture`,`onFocus`,`onFocusCapture`,`onBlur`,`onBlurCapture`,`onPaste`,`onPasteCapture`,`onResize`,`onClick`,`onMouseDown`,`onMouseUp`,`onMouseDrag`,`onMouseEnter`,`onMouseLeave`])}));function Sc(e,t,n){let r=e._eventHandlers;if(!r)return;let i=yc[t];if(!i)return;let a=n?i.capture:i.bubble;if(a)return r[a]}function Cc(e,t){let n=[],r=e;for(;r;){let i=r===e,a=Sc(r,t.type,!0),o=Sc(r,t.type,!1);a&&n.unshift({node:r,handler:a,phase:i?`at_target`:`capturing`}),o&&(t.bubbles||i)&&n.push({node:r,handler:o,phase:i?`at_target`:`bubbling`}),r=r.parentNode}return n}function wc(e,t){let n;for(let{node:r,handler:i,phase:a}of e){if(t._isImmediatePropagationStopped()||t._isPropagationStopped()&&r!==n)break;t._setEventPhase(a),t._setCurrentTarget(r),t._prepareForTarget(r);try{i(t)}catch(e){Dc(e)}n=r}}function Tc(e){switch(e){case`keydown`:case`keyup`:case`click`:case`focus`:case`blur`:case`paste`:return Ec.DiscreteEventPriority;case`resize`:case`scroll`:case`mousemove`:return Ec.ContinuousEventPriority;default:return Ec.DefaultEventPriority}}var Ec,Dc,Oc,kc=t((()=>{Ec=Me(),xc(),c(),Dc=e=>{console.error(e)},Oc=class{constructor(){l(this,`currentEvent`,null),l(this,`currentUpdatePriority`,Ec.DefaultEventPriority),l(this,`discreteUpdates`,null)}resolveEventPriority(){return this.currentUpdatePriority===0?this.currentEvent?Tc(this.currentEvent.type):Ec.DefaultEventPriority:this.currentUpdatePriority}dispatch(e,t){let n=this.currentEvent;this.currentEvent=t;try{return t._setTarget(e),wc(Cc(e,t),t),t._setEventPhase(`none`),t._setCurrentTarget(null),!t.defaultPrevented}finally{this.currentEvent=n}}dispatchDiscrete(e,t){return this.discreteUpdates?this.discreteUpdates((e,t)=>this.dispatch(e,t),e,t,void 0,void 0):this.dispatch(e,t)}dispatchContinuous(e,t){let n=this.currentUpdatePriority;try{return this.currentUpdatePriority=Ec.ContinuousEventPriority,this.dispatch(e,t)}finally{this.currentUpdatePriority=n}}}})),Ac,jc=t((()=>{zn(),c(),Ac=class extends Rn{constructor(e,t){super(),l(this,`type`,void 0),l(this,`timeStamp`,void 0),l(this,`bubbles`,void 0),l(this,`cancelable`,void 0),l(this,`_target`,null),l(this,`_currentTarget`,null),l(this,`_eventPhase`,`none`),l(this,`_propagationStopped`,!1),l(this,`_defaultPrevented`,!1),this.type=e,this.timeStamp=performance.now(),this.bubbles=t?.bubbles??!0,this.cancelable=t?.cancelable??!0}get target(){return this._target}get currentTarget(){return this._currentTarget}get eventPhase(){return this._eventPhase}get defaultPrevented(){return this._defaultPrevented}stopPropagation(){this._propagationStopped=!0}stopImmediatePropagation(){super.stopImmediatePropagation(),this._propagationStopped=!0}preventDefault(){this.cancelable&&(this._defaultPrevented=!0)}_setTarget(e){this._target=e}_setCurrentTarget(e){this._currentTarget=e}_setEventPhase(e){this._eventPhase=e}_isPropagationStopped(){return this._propagationStopped}_isImmediatePropagationStopped(){return this.didStopImmediatePropagation()}_prepareForTarget(e){}}})),Mc,Nc=t((()=>{jc(),c(),Mc=class extends Ac{constructor(e,t=null){super(e,{bubbles:!0,cancelable:!1}),l(this,`relatedTarget`,void 0),this.relatedTarget=t}}}));function Pc(e){let t=[];return Fc(e,t),t}function Fc(e,t){let n=e.attributes.tabIndex;typeof n==`number`&&n>=0&&t.push(e);for(let n of e.childNodes)n.nodeName!==`#text`&&Fc(n,t)}function Ic(e,t){let n=e;for(;n;){if(n===t)return!0;n=n.parentNode}return!1}function Lc(e){let t=e;for(;t;){if(t.focusManager)return t;t=t.parentNode}throw Error(`Node is not in a tree with a FocusManager`)}function Rc(e){return Lc(e).focusManager}var zc,Bc,Vc=t((()=>{Nc(),c(),zc=32,Bc=class{constructor(e){l(this,`activeElement`,null),l(this,`dispatchFocusEvent`,void 0),l(this,`enabled`,!0),l(this,`focusStack`,[]),this.dispatchFocusEvent=e}focus(e){if(e===this.activeElement||!this.enabled)return;let t=this.activeElement;if(t){let n=this.focusStack.indexOf(t);n!==-1&&this.focusStack.splice(n,1),this.focusStack.push(t),this.focusStack.length>zc&&this.focusStack.shift(),this.dispatchFocusEvent(t,new Mc(`blur`,e))}this.activeElement=e,this.dispatchFocusEvent(e,new Mc(`focus`,t))}blur(){if(!this.activeElement)return;let e=this.activeElement;this.activeElement=null,this.dispatchFocusEvent(e,new Mc(`blur`,null))}handleNodeRemoved(e,t){if(this.focusStack=this.focusStack.filter(n=>n!==e&&Ic(n,t)),!this.activeElement||this.activeElement!==e&&Ic(this.activeElement,t))return;let n=this.activeElement;for(this.activeElement=null,this.dispatchFocusEvent(n,new Mc(`blur`,null));this.focusStack.length>0;){let e=this.focusStack.pop();if(Ic(e,t)){this.activeElement=e,this.dispatchFocusEvent(e,new Mc(`focus`,n));return}}}handleAutoFocus(e){this.focus(e)}handleClickFocus(e){typeof e.attributes.tabIndex==`number`&&this.focus(e)}enable(){this.enabled=!0}disable(){this.enabled=!1}focusNext(e){this.moveFocus(1,e)}focusPrevious(e){this.moveFocus(-1,e)}moveFocus(e,t){if(!this.enabled)return;let n=Pc(t);if(n.length===0)return;let r=this.activeElement?n.indexOf(this.activeElement):-1,i=n[r===-1?e===1?0:n.length-1:(r+e+n.length)%n.length];i&&this.focus(i)}}}));function Hc(e,t,n){typeof n==`string`?e.setPositionPercent(t,Number.parseInt(n,10)):typeof n==`number`?e.setPosition(t,n):e.setPosition(t,NaN)}var Uc,Wc,Gc,Kc,qc,Jc,Yc,Xc,Zc,Qc,$c=t((()=>{Ci(),Uc=(e,t)=>{`position`in t&&e.setPositionType(t.position===`absolute`?bi.Absolute:bi.Relative),`top`in t&&Hc(e,`top`,t.top),`bottom`in t&&Hc(e,`bottom`,t.bottom),`left`in t&&Hc(e,`left`,t.left),`right`in t&&Hc(e,`right`,t.right)},Wc=(e,t)=>{let n=t.overflowY??t.overflow,r=t.overflowX??t.overflow;n===`scroll`||r===`scroll`?e.setOverflow(xi.Scroll):n===`hidden`||r===`hidden`?e.setOverflow(xi.Hidden):(`overflow`in t||`overflowX`in t||`overflowY`in t)&&e.setOverflow(xi.Visible)},Gc=(e,t)=>{`margin`in t&&e.setMargin(H.All,t.margin??0),`marginX`in t&&e.setMargin(H.Horizontal,t.marginX??0),`marginY`in t&&e.setMargin(H.Vertical,t.marginY??0),`marginLeft`in t&&e.setMargin(H.Start,t.marginLeft||0),`marginRight`in t&&e.setMargin(H.End,t.marginRight||0),`marginTop`in t&&e.setMargin(H.Top,t.marginTop||0),`marginBottom`in t&&e.setMargin(H.Bottom,t.marginBottom||0)},Kc=(e,t)=>{`padding`in t&&e.setPadding(H.All,t.padding??0),`paddingX`in t&&e.setPadding(H.Horizontal,t.paddingX??0),`paddingY`in t&&e.setPadding(H.Vertical,t.paddingY??0),`paddingLeft`in t&&e.setPadding(H.Left,t.paddingLeft||0),`paddingRight`in t&&e.setPadding(H.Right,t.paddingRight||0),`paddingTop`in t&&e.setPadding(H.Top,t.paddingTop||0),`paddingBottom`in t&&e.setPadding(H.Bottom,t.paddingBottom||0)},qc=(e,t)=>{`flexGrow`in t&&e.setFlexGrow(t.flexGrow??0),`flexShrink`in t&&e.setFlexShrink(typeof t.flexShrink==`number`?t.flexShrink:1),`flexWrap`in t&&(t.flexWrap===`nowrap`&&e.setFlexWrap(yi.NoWrap),t.flexWrap===`wrap`&&e.setFlexWrap(yi.Wrap),t.flexWrap===`wrap-reverse`&&e.setFlexWrap(yi.WrapReverse)),`flexDirection`in t&&(t.flexDirection===`row`&&e.setFlexDirection(gi.Row),t.flexDirection===`row-reverse`&&e.setFlexDirection(gi.RowReverse),t.flexDirection===`column`&&e.setFlexDirection(gi.Column),t.flexDirection===`column-reverse`&&e.setFlexDirection(gi.ColumnReverse)),`flexBasis`in t&&(typeof t.flexBasis==`number`?e.setFlexBasis(t.flexBasis):typeof t.flexBasis==`string`?e.setFlexBasisPercent(Number.parseInt(t.flexBasis,10)):e.setFlexBasis(NaN)),`alignItems`in t&&((t.alignItems===`stretch`||!t.alignItems)&&e.setAlignItems(_i.Stretch),t.alignItems===`flex-start`&&e.setAlignItems(_i.FlexStart),t.alignItems===`center`&&e.setAlignItems(_i.Center),t.alignItems===`flex-end`&&e.setAlignItems(_i.FlexEnd)),`alignSelf`in t&&((t.alignSelf===`auto`||!t.alignSelf)&&e.setAlignSelf(_i.Auto),t.alignSelf===`flex-start`&&e.setAlignSelf(_i.FlexStart),t.alignSelf===`center`&&e.setAlignSelf(_i.Center),t.alignSelf===`flex-end`&&e.setAlignSelf(_i.FlexEnd)),`justifyContent`in t&&((t.justifyContent===`flex-start`||!t.justifyContent)&&e.setJustifyContent(vi.FlexStart),t.justifyContent===`center`&&e.setJustifyContent(vi.Center),t.justifyContent===`flex-end`&&e.setJustifyContent(vi.FlexEnd),t.justifyContent===`space-between`&&e.setJustifyContent(vi.SpaceBetween),t.justifyContent===`space-around`&&e.setJustifyContent(vi.SpaceAround),t.justifyContent===`space-evenly`&&e.setJustifyContent(vi.SpaceEvenly))},Jc=(e,t)=>{`width`in t&&(typeof t.width==`number`?e.setWidth(t.width):typeof t.width==`string`?e.setWidthPercent(Number.parseInt(t.width,10)):e.setWidthAuto()),`height`in t&&(typeof t.height==`number`?e.setHeight(t.height):typeof t.height==`string`?e.setHeightPercent(Number.parseInt(t.height,10)):e.setHeightAuto()),`minWidth`in t&&(typeof t.minWidth==`string`?e.setMinWidthPercent(Number.parseInt(t.minWidth,10)):e.setMinWidth(t.minWidth??0)),`minHeight`in t&&(typeof t.minHeight==`string`?e.setMinHeightPercent(Number.parseInt(t.minHeight,10)):e.setMinHeight(t.minHeight??0)),`maxWidth`in t&&(typeof t.maxWidth==`string`?e.setMaxWidthPercent(Number.parseInt(t.maxWidth,10)):e.setMaxWidth(t.maxWidth??0)),`maxHeight`in t&&(typeof t.maxHeight==`string`?e.setMaxHeightPercent(Number.parseInt(t.maxHeight,10)):e.setMaxHeight(t.maxHeight??0))},Yc=(e,t)=>{`display`in t&&e.setDisplay(t.display===`flex`?hi.Flex:hi.None)},Xc=(e,t,n)=>{let r=n??t;if(`borderStyle`in t){let n=+!!t.borderStyle;e.setBorder(H.Top,r.borderTop===!1?0:n),e.setBorder(H.Bottom,r.borderBottom===!1?0:n),e.setBorder(H.Left,r.borderLeft===!1?0:n),e.setBorder(H.Right,r.borderRight===!1?0:n)}else `borderTop`in t&&t.borderTop!==void 0&&e.setBorder(H.Top,t.borderTop===!1?0:1),`borderBottom`in t&&t.borderBottom!==void 0&&e.setBorder(H.Bottom,t.borderBottom===!1?0:1),`borderLeft`in t&&t.borderLeft!==void 0&&e.setBorder(H.Left,t.borderLeft===!1?0:1),`borderRight`in t&&t.borderRight!==void 0&&e.setBorder(H.Right,t.borderRight===!1?0:1)},Zc=(e,t)=>{`gap`in t&&e.setGap(mi.All,t.gap??0),`columnGap`in t&&e.setGap(mi.Column,t.columnGap??0),`rowGap`in t&&e.setGap(mi.Row,t.rowGap??0)},Qc=(e,t={},n)=>{Uc(e,t),Wc(e,t),Gc(e,t),Kc(e,t),qc(e,t),Jc(e,t),Yc(e,t),Xc(e,t,n),Zc(e,t)}}));function el(e,t,n){e._eventHandlers||(e._eventHandlers={}),e._eventHandlers[t]=n}function tl(e,t,n){if(t!==`children`){if(t===`style`){lc(e,n),e.yogaNode&&Qc(e.yogaNode,n);return}if(t===`textStyles`){e.textStyles=n;return}if(bc.has(t)){el(e,t,n);return}cc(e,t,n)}}function nl(e){let t=[],n=new Set,r=e;for(let e=0;r&&e<50&&!n.has(r);e++){n.add(r);let e=r.elementType,i=typeof e==`function`?e.displayName||e.name:typeof e==`string`?void 0:e?.displayName||e?.name;i&&i!==t[t.length-1]&&t.push(i),r=r._debugOwner??r.return}return t}function K(){return fl===void 0&&(fl=process.env.CLAUDE_CODE_DEBUG_REPAINTS===`1`),fl}function rl(e){console.warn(`[ink-commit] ${e}`)}function il(e){xl=e}function al(){return xl}function ol(){Cl=performance.now()}function sl(){return Sl}function cl(){xl=0,Sl=0,Cl=0}var ll,ul,dl,fl,pl,ml,hl,gl,_l,vl,yl,bl,xl,Sl,Cl,wl,Tl=t((()=>{ll=n(pi(),1),Ut(),vc(),kc(),xc(),Vc(),Ci(),$c(),ul=(e,t)=>{if(e===t)return;if(!e)return t;let n={},r=!1;for(let i of Object.keys(e))(!t||!Object.hasOwn(t,i))&&(n[i]=void 0,r=!0);if(t)for(let i of Object.keys(t))t[i]!==e[i]&&(n[i]=t[i],r=!0);return r?n:void 0},dl=e=>{let t=e.yogaNode;t&&(t.unsetMeasureFunc(),_c(e),t.freeRecursive())},pl=new Oc,ml=process.env.CLAUDE_CODE_COMMIT_LOG,hl=0,gl=0,_l=0,vl=0,yl=0,bl=0,xl=0,Sl=0,Cl=0,wl=(0,ll.default)({getRootHostContext:()=>({isInsideText:!1}),prepareForCommit:()=>(ml&&(bl=performance.now()),null),preparePortalMount:()=>null,clearContainer:()=>!1,resetAfterCommit(e){if(Sl=Cl>0?performance.now()-Cl:0,Cl=0,ml){let e=performance.now();hl++;let t=_l>0?e-_l:0;t>vl&&(vl=t),_l=e;let n=bl>0?e-bl:0;(t>30||n>20||yl>50)&&rl(`${e.toFixed(1)} gap=${t.toFixed(1)}ms reconcile=${n.toFixed(1)}ms creates=${yl}`),yl=0,e-gl>1e3&&(rl(`${e.toFixed(1)} commits=${hl}/s maxGap=${vl.toFixed(1)}ms`),hl=0,vl=0,gl=e)}let t=ml?performance.now():0;if(typeof e.onComputeLayout==`function`&&e.onComputeLayout(),ml){let e=performance.now()-t;if(e>20){let n=ct();rl(`${t.toFixed(1)} SLOW_YOGA ${e.toFixed(1)}ms visited=${n.visited} measured=${n.measured} hits=${n.cacheHits} live=${n.live}`)}}let n=ml?performance.now():0;if(e.onRender?.(),ml){let e=performance.now()-n;e>10&&rl(`${n.toFixed(1)} SLOW_PAINT ${e.toFixed(1)}ms`)}},getChildHostContext(e,t){let n=e.isInsideText,r=t===`ink-text`||t===`ink-virtual-text`||t===`ink-link`;return n===r?e:{isInsideText:r}},shouldSetTextContent:()=>!1,createInstance(e,t,n,r,i){if(r.isInsideText&&e===`ink-box`)throw Error(`<Box> can't be nested inside <Text> component`);let a=ic(e===`ink-text`&&r.isInsideText?`ink-virtual-text`:e);ml&&yl++;for(let[e,n]of Object.entries(t))tl(a,e,n);return K()&&(a.debugOwnerChain=nl(i)),a},createTextInstance(e,t,n){if(!n.isInsideText)throw Error(`Text string "${e}" must be rendered inside <Text> component`);return dc(e)},resetTextContent(){},hideTextInstance(e){gc(e,``)},unhideTextInstance(e,t){gc(e,t)},getPublicInstance:e=>e,hideInstance(e){e.isHidden=!0,e.yogaNode?.setDisplay(hi.None),mc(e)},unhideInstance(e){e.isHidden=!1,e.yogaNode?.setDisplay(hi.Flex),mc(e)},appendInitialChild:ac,appendChild:ac,insertBefore:oc,finalizeInitialChildren(e,t,n){return n.autoFocus===!0},commitMount(e){Rc(e).handleAutoFocus(e)},isPrimaryRenderer:!0,supportsMutation:!0,supportsPersistence:!1,supportsHydration:!1,scheduleTimeout:setTimeout,cancelTimeout:clearTimeout,noTimeout:-1,getCurrentUpdatePriority:()=>pl.currentUpdatePriority,beforeActiveInstanceBlur(){},afterActiveInstanceBlur(){},detachDeletedInstance(){},getInstanceFromNode:()=>null,prepareScopeUpdate(){},getInstanceFromScope:()=>null,appendChildToContainer:ac,insertInContainerBefore:oc,removeChildFromContainer(e,t){sc(e,t),dl(t),Rc(e).handleNodeRemoved(t,e)},commitUpdate(e,t,n,r){let i=ul(n,r),a=ul(n.style,r.style);if(i)for(let[t,n]of Object.entries(i)){if(t===`style`){lc(e,n);continue}if(t===`textStyles`){uc(e,n);continue}if(bc.has(t)){el(e,t,n);continue}cc(e,t,n)}a&&e.yogaNode&&Qc(e.yogaNode,a,r.style)},commitTextUpdate(e,t,n){gc(e,n)},removeChild(e,t){if(sc(e,t),dl(t),t.nodeName!==`#text`){let n=Lc(e);n.focusManager.handleNodeRemoved(t,n)}},maySuspendCommit(){return!1},preloadInstance(){return!0},startSuspendingCommit(){},suspendInstance(){},waitForCommitToBeReady(){return null},NotPendingTransition:null,HostTransitionContext:{$$typeof:Symbol.for(`react.context`),_currentValue:null},setCurrentUpdatePriority(e){pl.currentUpdatePriority=e},resolveUpdatePriority(){return pl.resolveEventPriority()},resetFormInstance(){},requestPostPaintCallback(){},shouldAttemptEagerTransition(){return!1},trackSchedulerEvent(){},resolveEventType(){return pl.currentEvent?.type??null},resolveEventTimeStamp(){return pl.currentEvent?.timeStamp??-1.1}}),pl.discreteUpdates=wl.discreteUpdates.bind(wl)}));function El(e,t){let n=Math.min(e.x,t.x),r=Math.min(e.y,t.y),i=Math.max(e.x+e.width,t.x+t.width),a=Math.max(e.y+e.height,t.y+t.height);return{x:n,y:r,width:i-n,height:a-r}}function Dl(e,t,n){return t!==void 0&&e<t?t:n!==void 0&&e>n?n:e}var Ol=t((()=>{})),kl=t((()=>{}));function Al(e,t){e!==void 0&&(Number.isInteger(e)||`${t}${e}`)}var jl=t((()=>{kl()}));function Ml(e){for(let t of e)if(pu.has(t.endCode))return!0;return!1}function Nl(){let e=new Int32Array(128);return e.fill(-1),e[32]=mu,e}function Pl(e,t,n){return e<<gu|t<<_u|n}function Fl(e,t){let n=t<<1;return e.cells[n]===0&&e.cells[n|1]===0}function Il(e,t,n){return t<0||n<0||t>=e.width||n>=e.height?!0:Fl(e,n*e.width+t)}function Ll(e,t){return e.hyperlinkPool.intern(t)}function Rl(e,t,n,r,i){Al(e,`createScreen width`),Al(t,`createScreen height`),(!Number.isInteger(e)||e<0)&&(e=Math.max(0,Math.floor(e)||0)),(!Number.isInteger(t)||t<0)&&(t=Math.max(0,Math.floor(t)||0));let a=e*t,o=new ArrayBuffer(a<<3),s=new Int32Array(o),c=new BigInt64Array(o);return{width:e,height:t,cells:s,cells64:c,charPool:r,hyperlinkPool:i,emptyStyleId:n.none,damage:void 0,noSelect:new Uint8Array(a),softWrap:new Int32Array(t)}}function zl(e,t,n){Al(t,`resetScreen width`),Al(n,`resetScreen height`),(!Number.isInteger(t)||t<0)&&(t=Math.max(0,Math.floor(t)||0)),(!Number.isInteger(n)||n<0)&&(n=Math.max(0,Math.floor(n)||0));let r=t*n;if(e.cells64.length<r){let t=new ArrayBuffer(r<<3);e.cells=new Int32Array(t),e.cells64=new BigInt64Array(t),e.noSelect=new Uint8Array(r)}e.softWrap.length<n&&(e.softWrap=new Int32Array(n)),e.cells64.fill(bu,0,r),e.noSelect.fill(0,0,r),e.softWrap.fill(0,0,n),e.width=t,e.height=n,e.damage=void 0}function Bl(e,t,n){let r=e.charPool,i=e.hyperlinkPool;if(r===t&&i===n)return;let a=e.width*e.height,o=e.cells;for(let e=0;e<a<<1;e+=2){let a=o[e];o[e]=t.intern(r.get(a));let s=o[e+1],c=s>>>_u&vu;if(c!==0){let t=i.get(c),r=n.intern(t),a=s>>>gu,l=s&yu;o[e+1]=Pl(a,r,l)}}e.charPool=t,e.hyperlinkPool=n}function Vl(e,t,n){if(!(t<0||n<0||t>=e.width||n>=e.height))return Hl(e,n*e.width+t)}function Hl(e,t){let n=t<<1,r=e.cells[n+1],i=r>>>_u&vu;return{char:e.charPool.get(e.cells[n]),styleId:r>>>gu,width:r&yu,hyperlink:i===0?void 0:e.hyperlinkPool.get(i)}}function Ul(e,t,n,r,i){let a=r<<1,o=e[a];if(o===1)return;let s=e[a+1];if(o===0&&!(s&262140)){let e=s>>>gu;if(e===0||e===i)return}let c=s>>>_u&vu;return{char:t.get(o),styleId:s>>>gu,width:s&yu,hyperlink:c===0?void 0:n.get(c)}}function Wl(e,t,n){let r=t|1,i=e.cells[r];n.char=e.charPool.get(e.cells[t]),n.styleId=i>>>gu,n.width=i&yu;let a=i>>>_u&vu;n.hyperlink=a===0?void 0:e.hyperlinkPool.get(a)}function q(e,t,n){if(t<0||n<0||t>=e.width||n>=e.height)return;let r=n*e.width+t<<1;return e.charPool.get(e.cells[r])}function Gl(e,t,n,r){if(t<0||n<0||t>=e.width||n>=e.height)return;let i=n*e.width+t<<1,a=e.cells,o=a[i+1]&yu;if(o===J.Wide&&r.width!==J.Wide&&t+1<e.width){let t=i+2;(a[t+1]&yu)===J.SpacerTail&&(a[t]=mu,a[t+1]=Pl(e.emptyStyleId,0,J.Narrow))}let s=-1;if(o===J.SpacerTail&&r.width!==J.SpacerTail&&t>0){let n=i-2;(a[n+1]&yu)===J.Wide&&(a[n]=mu,a[n+1]=Pl(e.emptyStyleId,0,J.Narrow),s=t-1)}a[i]=ql(e,r.char),a[i+1]=Pl(r.styleId,Ll(e,r.hyperlink),r.width);let c=s>=0?Math.min(t,s):t,l=e.damage;if(l){let e=l.x+l.width,r=l.y+l.height;c<l.x?(l.width+=l.x-c,l.x=c):t>=e&&(l.width=t-l.x+1),n<l.y?(l.height+=l.y-n,l.y=n):n>=r&&(l.height=n-l.y+1)}else e.damage={x:c,y:n,width:t-c+1,height:1};if(r.width===J.Wide){let n=t+1;if(n<e.width){let t=i+2;if((a[t+1]&yu)===J.Wide){let r=t+2;n+1<e.width&&(a[r+1]&yu)===J.SpacerTail&&(a[r]=mu,a[r+1]=Pl(e.emptyStyleId,0,J.Narrow))}a[t]=hu,a[t+1]=Pl(e.emptyStyleId,0,J.SpacerTail);let r=e.damage;r&&n>=r.x+r.width&&(r.width=n-r.x+1)}}}function Kl(e,t,n,r){if(t<0||n<0||t>=e.width||n>=e.height)return;let i=n*e.width+t<<1,a=e.cells,o=a[i+1],s=o&yu;if(s===J.SpacerTail||s===J.SpacerHead)return;let c=o>>>_u&vu;a[i+1]=Pl(r,c,s);let l=e.damage;l?e.damage=El(l,{x:t,y:n,width:1,height:1}):e.damage={x:t,y:n,width:1,height:1}}function ql(e,t){return e.charPool.intern(t)}function Jl(e,t,n,r,i,a){if(n=Math.max(0,n),r=Math.max(0,r),n>=i||r>=a)return;let o=i-n,s=t.width<<1,c=e.width<<1,l=o<<1,u=t.cells,d=e.cells,f=t.noSelect,p=e.noSelect;if(e.softWrap.set(t.softWrap.subarray(r,a),r),n===0&&i===t.width&&t.width===e.width){let e=r*s,n=(a-r)*s;d.set(u.subarray(e,e+n),e);let i=r*t.width,o=(a-r)*t.width;p.set(f.subarray(i,i+o),i)}else{let i=r*s+(n<<1),m=r*c+(n<<1),h=r*t.width+n,g=r*e.width+n;for(let n=r;n<a;n++)d.set(u.subarray(i,i+l),m),p.set(f.subarray(h,h+o),g),i+=s,m+=c,h+=t.width,g+=e.width}let m={x:n,y:r,width:o,height:a-r};if(e.damage?e.damage=El(e.damage,m):e.damage=m,i<e.width){let n=r*t.width+(i-1)<<1,o=r*e.width+i<<1,l=!1;for(let t=r;t<a;t++)(u[n+1]&yu)===J.Wide&&(d[o]=hu,d[o+1]=Pl(e.emptyStyleId,0,J.SpacerTail),l=!0),n+=s,o+=c;l&&e.damage&&e.damage.x+e.damage.width===i&&(e.damage={...e.damage,width:e.damage.width+1})}}function Yl(e,t,n,r){if(r===0||t<0||n>=e.height||t>n)return;let i=e.width,a=e.cells64,o=e.noSelect,s=e.softWrap;if(Math.abs(r)>n-t){a.fill(bu,t*i,(n+1)*i),o.fill(0,t*i,(n+1)*i),s.fill(0,t,n+1);return}r>0?(a.copyWithin(t*i,(t+r)*i,(n+1)*i),o.copyWithin(t*i,(t+r)*i,(n+1)*i),s.copyWithin(t,t+r,n+1),a.fill(bu,(n-r+1)*i,(n+1)*i),o.fill(0,(n-r+1)*i,(n+1)*i),s.fill(0,n-r+1,n+1)):(a.copyWithin((t-r)*i,t*i,(n+r+1)*i),o.copyWithin((t-r)*i,t*i,(n+r+1)*i),s.copyWithin(t-r,t,n+r+1),a.fill(bu,t*i,(t-r)*i),o.fill(0,t*i,(t-r)*i),s.fill(0,t,t-r))}function Xl(e){for(let t of e){let e=t.code;if(e.length<5||!e.startsWith(Su))continue;let n=e.match(xu);if(n)return n[1]||null}return null}function Zl(e){return e.filter(e=>!e.code.startsWith(Su)||!xu.test(e.code))}function Ql(e,t,n){let r=e.width,i=t.width,a=e.height,o=t.height,s;r===0&&a===0?s={x:0,y:0,width:i,height:o}:t.damage?(s=t.damage,e.damage&&(s=El(s,e.damage))):s=e.damage?e.damage:{x:0,y:0,width:0,height:0},a>o&&(s=El(s,{x:0,y:o,width:r,height:a-o})),r>i&&(s=El(s,{x:i,y:0,width:r-i,height:a}));let c=Math.max(a,o),l=Math.max(r,i),u=Math.min(s.y+s.height,c),d=Math.min(s.x+s.width,l);return r===i?ru(e,t,s.x,d,s.y,u,n):iu(e,t,s.x,d,s.y,u,n)}function $l(e,t,n,r){for(let i=0;i<r;i++,n+=2){let r=n|1;if(e[n]!==t[n]||e[r]!==t[r])return i}return r}function eu(e,t,n,r,i,a,o,s,c,l,u){let d=o;for(;d<s;){let o=$l(e,t,i,s-d);if(d+=o,i+=o<<1,d>=s)break;if(Wl(n,i,c),Wl(r,i,l),u(d,a,c,l))return!0;d++,i+=2}return!1}function tu(e,t,n,r,i,a,o){for(let s=r;s<i;s++,t+=2)if(Wl(e,t,a),o(s,n,a,void 0))return!0;return!1}function nu(e,t,n,r,i,a,o,s){for(let c=i;c<a;c++,n+=2)if(!(e[n]===0&&e[n|1]===0)&&(Wl(t,n,o),s(c,r,void 0,o)))return!0;return!1}function ru(e,t,n,r,i,a,o){let s=e.cells,c=t.cells,l=e.width,u=e.height,d=t.height,f=l<<1,p={char:` `,styleId:0,width:J.Narrow,hyperlink:void 0},m={char:` `,styleId:0,width:J.Narrow,hyperlink:void 0},h=Math.min(r,l),g=i*l+n<<1;for(let r=i;r<a;r++){let i=r<u,a=r<d;if(i&&a){if(eu(s,c,e,t,g,r,n,h,p,m,o))return!0}else if(i){if(tu(e,g,r,n,h,p,o))return!0}else if(a&&nu(c,t,g,r,n,h,m,o))return!0;g+=f}return!1}function iu(e,t,n,r,i,a,o){let s=e.width,c=t.width,l=e.cells,u=t.cells,d={char:` `,styleId:0,width:J.Narrow,hyperlink:void 0},f={char:` `,styleId:0,width:J.Narrow,hyperlink:void 0},p=s<<1,m=c<<1,h=i*s+n<<1,g=i*c+n<<1;for(let _=i;_<a;_++){let i=_<e.height,a=_<t.height,v=i?Math.min(r,s):n,y=a?Math.min(r,c):n,b=Math.min(v,y),x=h,S=g;for(let r=n;r<b;r++){if(l[x]===u[S]&&l[x+1]===u[S+1]){x+=2,S+=2;continue}if(Wl(e,x,d),Wl(t,S,f),x+=2,S+=2,o(r,_,d,f))return!0}if(v>b){x=h+(b-n<<1);for(let t=b;t<v;t++)if(Wl(e,x,d),x+=2,o(t,_,d,void 0))return!0}if(y>b){S=g+(b-n<<1);for(let e=b;e<y;e++){if(u[S]===0&&u[S|1]===0){S+=2;continue}if(Wl(t,S,f),S+=2,o(e,_,void 0,f))return!0}}h+=p,g+=m}return!1}function au(e,t,n,r,i){let a=Math.min(t+r,e.width),o=Math.min(n+i,e.height),s=e.noSelect,c=e.width;for(let e=Math.max(0,n);e<o;e++){let n=e*c;s.fill(1,n+Math.max(0,t),n+a)}}var ou,su,cu,lu,uu,du,fu,pu,J,mu,hu,gu,_u,vu,yu,bu,xu,Su,Cu=t((()=>{zo(),Ol(),Gn(),jl(),c(),ou=class{constructor(){l(this,`strings`,[` `,``]),l(this,`stringMap`,new Map([[` `,0],[``,1]])),l(this,`ascii`,Nl())}intern(e){if(e.length===1){let t=e.charCodeAt(0);if(t<128){let n=this.ascii[t];if(n!==-1)return n;let r=this.strings.length;return this.strings.push(e),this.ascii[t]=r,r}}let t=this.stringMap.get(e);if(t!==void 0)return t;let n=this.strings.length;return this.strings.push(e),this.stringMap.set(e,n),n}get(e){return this.strings[e]??` `}},su=class{constructor(){l(this,`strings`,[``]),l(this,`stringMap`,new Map)}intern(e){if(!e)return 0;let t=this.stringMap.get(e);return t===void 0&&(t=this.strings.length,this.strings.push(e),this.stringMap.set(e,t)),t}get(e){return e===0?void 0:this.strings[e]}},cu={type:`ansi`,code:`\x1B[7m`,endCode:`\x1B[27m`},lu={type:`ansi`,code:`\x1B[1m`,endCode:`\x1B[22m`},uu={type:`ansi`,code:`\x1B[4m`,endCode:`\x1B[24m`},du={type:`ansi`,code:`\x1B[33m`,endCode:`\x1B[39m`},fu=class e{constructor(){l(this,`ids`,new Map),l(this,`styles`,[]),l(this,`transitionCache`,new Map),l(this,`none`,void 0),l(this,`inverseCache`,new Map),l(this,`currentMatchCache`,new Map),l(this,`selectionBgCode`,null),l(this,`selectionBgCache`,new Map),this.none=this.intern([])}evictCacheIfNeeded(){if(this.transitionCache.size>e.CACHE_MAX){let t=this.transitionCache.keys();for(let n=0;n<this.transitionCache.size-e.CACHE_MAX;n++){let e=t.next().value;e!==void 0&&this.transitionCache.delete(e)}}if(this.inverseCache.size>e.CACHE_MAX){let t=this.inverseCache.keys();for(let n=0;n<this.inverseCache.size-e.CACHE_MAX;n++){let e=t.next().value;e!==void 0&&this.inverseCache.delete(e)}}if(this.currentMatchCache.size>e.CACHE_MAX){let t=this.currentMatchCache.keys();for(let n=0;n<this.currentMatchCache.size-e.CACHE_MAX;n++){let e=t.next().value;e!==void 0&&this.currentMatchCache.delete(e)}}}intern(e){let t=e.length===0?``:e.map(e=>e.code).join(`\0`),n=this.ids.get(t);if(n===void 0){let r=this.styles.length;this.styles.push(e.length===0?[]:e),n=r<<1|(e.length>0&&Ml(e)?1:0),this.ids.set(t,n),this.evictCacheIfNeeded()}return n}get(e){return this.styles[e>>>1]??[]}transition(e,t){if(e===t)return``;let n=e*1048576+t,r=this.transitionCache.get(n);return r===void 0&&(r=po(Co(this.get(e),this.get(t))),this.transitionCache.set(n,r)),r}withInverse(e){let t=this.inverseCache.get(e);if(t===void 0){let n=this.get(e);t=n.some(e=>e.endCode===`\x1B[27m`)?e:this.intern([...n,cu]),this.inverseCache.set(e,t)}return t}withCurrentMatch(e){let t=this.currentMatchCache.get(e);if(t===void 0){let n=this.get(e),r=n.filter(e=>e.endCode!==`\x1B[39m`&&e.endCode!==`\x1B[49m`);r.push(du),n.some(e=>e.endCode===`\x1B[27m`)||r.push(cu),n.some(e=>e.endCode===`\x1B[22m`)||r.push(lu),n.some(e=>e.endCode===`\x1B[24m`)||r.push(uu),t=this.intern(r),this.currentMatchCache.set(e,t)}return t}setSelectionBg(e){this.selectionBgCode?.code!==e?.code&&(this.selectionBgCode=e,this.selectionBgCache.clear())}withSelectionBg(e){let t=this.selectionBgCode;if(t===null)return this.withInverse(e);let n=this.selectionBgCache.get(e);if(n===void 0){let r=this.get(e).filter(e=>e.endCode!==`\x1B[49m`&&e.endCode!==`\x1B[27m`);r.push(t),n=this.intern(r),this.selectionBgCache.set(e,n)}return n}},l(fu,`CACHE_MAX`,1e3),pu=new Set([`\x1B[49m`,`\x1B[27m`,`\x1B[24m`,`\x1B[29m`,`\x1B[55m`]),J=function(e){return e[e.Narrow=0]=`Narrow`,e[e.Wide=1]=`Wide`,e[e.SpacerTail=2]=`SpacerTail`,e[e.SpacerHead=3]=`SpacerHead`,e}({}),mu=0,hu=1,gu=17,_u=2,vu=32767,yu=3,bu=0n,xu=RegExp(`^\x1B\\]8;;([^\x07]*)\x07$`),Su=`\x1B]8;`}));function Y(){return{anchor:null,focus:null,isDragging:!1,anchorSpan:null,scrolledOffAbove:[],scrolledOffBelow:[],scrolledOffAboveSW:[],scrolledOffBelowSW:[],lastPressHadAlt:!1}}function wu(e,t,n){e.anchor={col:t,row:n},e.focus=null,e.isDragging=!0,e.anchorSpan=null,e.scrolledOffAbove=[],e.scrolledOffBelow=[],e.scrolledOffAboveSW=[],e.scrolledOffBelowSW=[],e.virtualAnchorRow=void 0,e.virtualFocusRow=void 0,e.lastPressHadAlt=!1}function X(e,t,n){e.isDragging&&(!e.focus&&e.anchor&&e.anchor.col===t&&e.anchor.row===n||(e.focus={col:t,row:n}))}function Z(e){e.isDragging=!1}function Q(e){e.anchor=null,e.focus=null,e.isDragging=!1,e.anchorSpan=null,e.scrolledOffAbove=[],e.scrolledOffBelow=[],e.scrolledOffAboveSW=[],e.scrolledOffBelowSW=[],e.virtualAnchorRow=void 0,e.virtualFocusRow=void 0,e.lastPressHadAlt=!1}function Tu(e){return e===` `||e===``?0:Wu.test(e)?1:2}function Eu(e,t,n){if(n<0||n>=e.height)return null;let r=e.width,i=e.noSelect,a=n*r,o=t;if(o>0){let t=Vl(e,o,n);t&&t.width===J.SpacerTail&&--o}if(o<0||o>=r||i[a+o]===1)return null;let s=Vl(e,o,n);if(!s)return null;let c=Tu(s.char),l=o;for(;l>0;){let t=l-1;if(i[a+t]===1)break;let r=Vl(e,t,n);if(!r)break;if(r.width===J.SpacerTail){if(t===0||i[a+t-1]===1)break;let r=Vl(e,t-1,n);if(!r||Tu(r.char)!==c)break;l=t-1;continue}if(Tu(r.char)!==c)break;l=t}let u=o;for(;u<r-1;){let t=u+1;if(i[a+t]===1)break;let r=Vl(e,t,n);if(!r)break;if(r.width===J.SpacerTail){u=t;continue}if(Tu(r.char)!==c)break;u=t}return{lo:l,hi:u}}function Du(e,t){return e.row===t.row?e.col===t.col?0:e.col<t.col?-1:1:e.row<t.row?-1:1}function Ou(e,t,n,r){let i=Eu(t,n,r);if(!i)return;let a={col:i.lo,row:r},o={col:i.hi,row:r};e.anchor=a,e.focus=o,e.isDragging=!0,e.anchorSpan={lo:a,hi:o,kind:`word`}}function ku(e){if(e.length!==1)return!1;let t=e.charCodeAt(0);return t>=33&&t<=126&&!Gu.has(e)}function Au(e,t,n){if(n<0||n>=e.height)return;let r=e.width,i=e.noSelect,a=n*r,o=t;if(o>0){let t=Vl(e,o,n);t&&t.width===J.SpacerTail&&--o}if(o<0||o>=r||i[a+o]===1)return;let s=Vl(e,o,n);if(!s||!ku(s.char))return;let c=o;for(;c>0;){let t=c-1;if(i[a+t]===1)break;let r=Vl(e,t,n);if(!r||r.width!==J.Narrow||!ku(r.char))break;c=t}let l=o;for(;l<r-1;){let t=l+1;if(i[a+t]===1)break;let r=Vl(e,t,n);if(!r||r.width!==J.Narrow||!ku(r.char))break;l=t}let u=``;for(let t=c;t<=l;t++)u+=Vl(e,t,n).char;let d=o-c,f=/(?:https?|file):\/\//g,p=-1,m=u.length;for(let e;e=f.exec(u);){if(e.index>d){m=e.index;break}p=e.index}if(p<0)return;let h=u.slice(p,m),g={")":`(`,"]":`[`,"}":`{`};for(;h.length>0;){let e=h.at(-1);if(`.,;:!?`.includes(e)){h=h.slice(0,-1);continue}let t=g[e];if(!t)break;let n=0,r=0;for(let i=0;i<h.length;i++){let a=h.charAt(i);a===t?n++:a===e&&r++}if(r>n)h=h.slice(0,-1);else break}if(!(d>=p+h.length))return h}function ju(e,t,n){if(n<0||n>=t.height)return;let r={col:0,row:n},i={col:t.width-1,row:n};e.anchor=r,e.focus=i,e.isDragging=!0,e.anchorSpan={lo:r,hi:i,kind:`line`}}function Mu(e,t,n,r){if(!e.isDragging||!e.anchorSpan)return;let i=e.anchorSpan,a,o;if(i.kind===`word`){let e=Eu(t,n,r);a={col:e?e.lo:n,row:r},o={col:e?e.hi:n,row:r}}else{let e=Dl(r,0,t.height-1);a={col:0,row:e},o={col:t.width-1,row:e}}Du(o,i.lo)<0?(e.anchor=i.hi,e.focus=a):Du(a,i.hi)>0?(e.anchor=i.lo,e.focus=o):(e.anchor=i.lo,e.focus=i.hi)}function Nu(e,t,n){e.focus&&(e.anchorSpan=null,e.focus={col:t,row:n},e.virtualFocusRow=void 0)}function Pu(e,t,n,r,i){if(!e.anchor||!e.focus)return;let a=(e.virtualAnchorRow??e.anchor.row)+t,o=(e.virtualFocusRow??e.focus.row)+t;if(a<n&&o<n||a>r&&o>r){Q(e);return}let s=Math.min(e.virtualAnchorRow??e.anchor.row,e.virtualFocusRow??e.focus.row),c=Math.max(e.virtualAnchorRow??e.anchor.row,e.virtualFocusRow??e.focus.row),l=Math.max(0,n-s),u=Math.max(0,c-r),d=Math.max(0,n-Math.min(a,o)),f=Math.max(0,Math.max(a,o)-r);if(d<l){let t=l-d;e.scrolledOffAbove.length-=t,e.scrolledOffAboveSW.length=e.scrolledOffAbove.length}if(f<u){let t=u-f;e.scrolledOffBelow.splice(0,t),e.scrolledOffBelowSW.splice(0,t)}e.scrolledOffAbove.length>d&&(e.scrolledOffAbove=d>0?e.scrolledOffAbove.slice(-d):[],e.scrolledOffAboveSW=d>0?e.scrolledOffAboveSW.slice(-d):[]),e.scrolledOffBelow.length>f&&(e.scrolledOffBelow=e.scrolledOffBelow.slice(0,f),e.scrolledOffBelowSW=e.scrolledOffBelowSW.slice(0,f));let p=(e,t)=>t<n?{col:0,row:n}:t>r?{col:i-1,row:r}:{col:e.col,row:t};if(e.anchor=p(e.anchor,a),e.focus=p(e.focus,o),e.virtualAnchorRow=a<n||a>r?a:void 0,e.virtualFocusRow=o<n||o>r?o:void 0,e.anchorSpan){let a=e=>{let a=e.row+t;return a<n?{col:0,row:n}:a>r?{col:i-1,row:r}:{col:e.col,row:a}};e.anchorSpan={lo:a(e.anchorSpan.lo),hi:a(e.anchorSpan.hi),kind:e.anchorSpan.kind}}}function Fu(e,t,n,r){if(!e.anchor)return;let i=(e.virtualAnchorRow??e.anchor.row)+t;if(e.anchor={col:e.anchor.col,row:Dl(i,n,r)},e.virtualAnchorRow=i<n||i>r?i:void 0,e.anchorSpan){let i=e=>({col:e.col,row:Dl(e.row+t,n,r)});e.anchorSpan={lo:i(e.anchorSpan.lo),hi:i(e.anchorSpan.hi),kind:e.anchorSpan.kind}}}function Iu(e,t,n,r){if(!e.anchor)return!1;let i=(e.virtualAnchorRow??e.anchor.row)+t,a=e.focus?(e.virtualFocusRow??e.focus.row)+t:void 0;if(i<n&&a!==void 0&&a<n)return Q(e),!0;if(e.anchor={col:e.anchor.col,row:Dl(i,n,r)},e.focus&&a!==void 0&&(e.focus={col:e.focus.col,row:Dl(a,n,r)}),e.virtualAnchorRow=i<n||i>r?i:void 0,e.virtualFocusRow=a!==void 0&&(a<n||a>r)?a:void 0,e.anchorSpan){let i=e=>({col:e.col,row:Dl(e.row+t,n,r)});e.anchorSpan={lo:i(e.anchorSpan.lo),hi:i(e.anchorSpan.hi),kind:e.anchorSpan.kind}}return!1}function Lu(e){return e.anchor!==null&&e.focus!==null}function Ru(e){return!e.anchor||!e.focus?null:Du(e.anchor,e.focus)<=0?{start:e.anchor,end:e.focus}:{start:e.focus,end:e.anchor}}function zu(e,t,n,r){let i=e.noSelect,a=t*e.width,o=t+1<e.height?e.softWrap[t+1]:0,s=o>0?Math.min(r,o-1):r,c=``;for(let r=n;r<=s;r++){if(i[a+r]===1)continue;let n=Vl(e,r,t);n&&(n.width===J.SpacerTail||n.width===J.SpacerHead||(c+=n.char))}return o>0?c:c.replace(/\s+$/,``)}function Bu(e,t,n){n&&e.length>0?e[e.length-1]+=t:e.push(t)}function Vu(e,t){let n=Ru(e);if(!n)return``;let{start:r,end:i}=n,a=t.softWrap,o=[];for(let t=0;t<e.scrolledOffAbove.length;t++)Bu(o,e.scrolledOffAbove[t],e.scrolledOffAboveSW[t]);for(let e=r.row;e<=i.row;e++){let n=e===r.row?r.col:0,s=e===i.row?i.col:t.width-1;Bu(o,zu(t,e,n,s),a[e]>0)}for(let t=0;t<e.scrolledOffBelow.length;t++)Bu(o,e.scrolledOffBelow[t],e.scrolledOffBelowSW[t]);return o.join(`
28
+ `)}function Hu(e,t,n,r,i){let a=Ru(e);if(!a||n>r)return;let{start:o,end:s}=a,c=Math.max(n,o.row),l=Math.min(r,s.row);if(c>l)return;let u=t.width,d=t.softWrap,f=[],p=[];for(let e=c;e<=l;e++){let n=e===o.row?o.col:0,r=e===s.row?s.col:u-1;f.push(zu(t,e,n,r)),p.push(d[e]>0)}i===`above`?(e.scrolledOffAbove.push(...f),e.scrolledOffAboveSW.push(...p),e.anchor&&e.anchor.row===o.row&&c===o.row&&(e.anchor={col:0,row:e.anchor.row},e.anchorSpan&&(e.anchorSpan={kind:e.anchorSpan.kind,lo:{col:0,row:e.anchorSpan.lo.row},hi:{col:u-1,row:e.anchorSpan.hi.row}}))):(e.scrolledOffBelow.unshift(...f),e.scrolledOffBelowSW.unshift(...p),e.anchor&&e.anchor.row===s.row&&l===s.row&&(e.anchor={col:u-1,row:e.anchor.row},e.anchorSpan&&(e.anchorSpan={kind:e.anchorSpan.kind,lo:{col:0,row:e.anchorSpan.lo.row},hi:{col:u-1,row:e.anchorSpan.hi.row}})))}function Uu(e,t,n){let r=Ru(t);if(!r)return;let{start:i,end:a}=r,o=e.width,s=e.noSelect;for(let t=i.row;t<=a.row&&t<e.height;t++){let r=t===i.row?i.col:0,c=t===a.row?Math.min(a.col,o-1):o-1,l=t*o;for(let i=r;i<=c;i++){let r=l+i;if(s[r]===1)continue;let a=Hl(e,r);Kl(e,i,t,n.withSelectionBg(a.styleId))}}}var Wu,Gu,Ku=t((()=>{Ol(),Cu(),Wu=/[\p{L}\p{N}_/.\-+~\\]/u,Gu=new Set([...`<>"'\` `])}));function qu(){return process.platform===`win32`&&!!process.env.WT_SESSION}function Ju(){return!!(process.env.TERM_PROGRAM===`mintty`||process.platform===`win32`&&process.env.MSYSTEM)}function Yu(){return!!(qu()||process.platform===`win32`&&process.env.TERM_PROGRAM===`vscode`&&process.env.TERM_PROGRAM_VERSION||Ju())}function Xu(){return process.platform===`win32`?Yu()?gr+_r+mr:gr+Zu:gr+_r+mr}var Zu,Qu=t((()=>{Dr(),Zu=Yn(0,`f`),Xu()}));function $u(e){return Yn(`?${e}h`)}function ed(e){return Yn(`?${e}l`)}var td,nd,rd,id,ad,od,sd,cd,ld,ud,dd,fd,pd,md=t((()=>{Dr(),td={CURSOR_VISIBLE:25,ALT_SCREEN:47,ALT_SCREEN_CLEAR:1049,MOUSE_NORMAL:1e3,MOUSE_BUTTON:1002,MOUSE_ANY:1003,MOUSE_SGR:1006,FOCUS_EVENTS:1004,BRACKETED_PASTE:2004,SYNCHRONIZED_UPDATE:2026},nd=$u(td.SYNCHRONIZED_UPDATE),rd=ed(td.SYNCHRONIZED_UPDATE),id=$u(td.BRACKETED_PASTE),ad=ed(td.BRACKETED_PASTE),od=$u(td.FOCUS_EVENTS),sd=ed(td.FOCUS_EVENTS),cd=$u(td.CURSOR_VISIBLE),ld=ed(td.CURSOR_VISIBLE),ud=$u(td.ALT_SCREEN_CLEAR),dd=ed(td.ALT_SCREEN_CLEAR),fd=$u(td.MOUSE_NORMAL)+$u(td.MOUSE_BUTTON)+$u(td.MOUSE_ANY)+$u(td.MOUSE_SGR),pd=ed(td.MOUSE_SGR)+ed(td.MOUSE_ANY)+ed(td.MOUSE_BUTTON)+ed(td.MOUSE_NORMAL)}));function hd(e,t,n={}){return new Promise(r=>{let{input:i,timeout:a}=n,o=ne(e,t,{timeout:a},(e,t,n)=>{r({code:+!!e,stdout:t??``,stderr:n??``})});i&&o.stdin&&(o.stdin.write(i),o.stdin.end())})}function gd(...e){let t=process.env.TERM_PROGRAM===`kitty`?Md:`\x07`;return`${jd}${e.join(`;`)}${t}`}function _d(e){return process.env.TMUX?`\x1bPtmux;${e.replaceAll(`\x1B`,`\x1B\x1B`)}\x1b\\`:process.env.STY?`\x1bP${e}\x1b\\`:e}function vd(){return process.platform===`darwin`&&!process.env.SSH_CONNECTION?`native`:process.env.TMUX?`tmux-buffer`:`osc52`}function yd(e){return`Ptmux;${e.replaceAll(`\x1B`,`\x1B\x1B`)}${Md}`}async function bd(e){if(!process.env.TMUX)return!1;let{code:t}=await hd(`tmux`,process.env.LC_TERMINAL===`iTerm2`?[`load-buffer`,`-`]:[`load-buffer`,`-w`,`-`],{input:e,useCwd:!1,timeout:2e3});return t===0}async function xd(e){let t=ee.from(e,`utf8`).toString(`base64`),n=gd(Pd.CLIPBOARD,`c`,t);return process.env.SSH_CONNECTION||Sd(e),await bd(e)?yd(`]52;c;${t}`):n}function Sd(e){let t={input:e,useCwd:!1,timeout:2e3};switch(process.platform){case`darwin`:hd(`pbcopy`,[],t);return;case`linux`:if(Nd===null)return;if(Nd===`wl-copy`){hd(`wl-copy`,[],t);return}if(Nd===`xclip`){hd(`xclip`,[`-selection`,`clipboard`],t);return}if(Nd===`xsel`){hd(`xsel`,[`--clipboard`,`--input`],t);return}hd(`wl-copy`,[],t).then(e=>{if(e.code===0){Nd=`wl-copy`;return}hd(`xclip`,[`-selection`,`clipboard`],t).then(e=>{if(e.code===0){Nd=`xclip`;return}hd(`xsel`,[`--clipboard`,`--input`],t).then(e=>{Nd=e.code===0?`xsel`:null})})});return;case`win32`:hd(`clip`,[],t);return}}function Cd(e){let t=e.indexOf(`;`),n=t>=0?e.slice(0,t):e,r=t>=0?e.slice(t+1):``,i=parseInt(n,10);if(i===Pd.SET_TITLE_AND_ICON)return{type:`title`,action:{type:`both`,title:r}};if(i===Pd.SET_ICON)return{type:`title`,action:{type:`iconName`,name:r}};if(i===Pd.SET_TITLE)return{type:`title`,action:{type:`windowTitle`,title:r}};if(i===Pd.HYPERLINK){let e=r.split(`;`),t=e[0]??``,n=e.slice(1).join(`;`);if(n===``)return{type:`link`,action:{type:`end`}};let i={};if(t)for(let e of t.split(`:`)){let t=e.indexOf(`=`);t>=0&&(i[e.slice(0,t)]=e.slice(t+1))}return{type:`link`,action:{type:`start`,url:n,params:Object.keys(i).length>0?i:void 0}}}return i===Pd.TAB_STATUS?{type:`tabStatus`,action:Td(r)}:{type:`unknown`,sequence:`\x1b]${e}`}}function wd(e){let t=e.match(/^#([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/i);if(t)return{type:`rgb`,r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)};let n=e.match(/^rgb:([0-9a-f]{1,4})\/([0-9a-f]{1,4})\/([0-9a-f]{1,4})$/i);if(n){let e=e=>Math.round(parseInt(e,16)/(16**e.length-1)*255);return{type:`rgb`,r:e(n[1]),g:e(n[2]),b:e(n[3])}}return null}function Td(e){let t={};for(let[n,r]of Ed(e))switch(n){case`indicator`:t.indicator=r===``?null:wd(r);break;case`status`:t.status=r===``?null:r;break;case`status-color`:t.statusColor=r===``?null:wd(r);break}return t}function*Ed(e){let t=``,n=``,r=!1,i=!1;for(let a of e)i?(r?n+=a:t+=a,i=!1):a===`\\`?i=!0:a===`;`?(yield[t,n],t=``,n=``,r=!1):a===`=`&&!r?r=!0:r?n+=a:t+=a;(t||r)&&(yield[t,n])}function Dd(e,t){if(!e)return Fd;let n={id:Od(e),...t},r=Object.entries(n).map(([e,t])=>`${e}=${t}`).join(`:`);return gd(Pd.HYPERLINK,r,e)}function Od(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n)|0;return(t>>>0).toString(36)}function kd(){return process.env.USER_TYPE===`ant`}function Ad(e){let t=[],n=e=>e.type===`rgb`?`#${[e.r,e.g,e.b].map(e=>e.toString(16).padStart(2,`0`)).join(``)}`:``;return`indicator`in e&&t.push(`indicator=${e.indicator?n(e.indicator):``}`),`status`in e&&t.push(`status=${e.status?.replaceAll(`\\`,`\\\\`).replaceAll(`;`,`\\;`)??``}`),`statusColor`in e&&t.push(`status-color=${e.statusColor?n(e.statusColor):``}`),gd(Pd.TAB_STATUS,t.join(`;`))}var jd,Md,Nd,Pd,Fd,Id,Ld,Rd,zd,Bd,Vd=t((()=>{Gn(),jd=`\x1B`+String.fromCharCode(Wn.OSC),Md=`\x1B\\`,Pd={SET_TITLE_AND_ICON:0,SET_ICON:1,SET_TITLE:2,SET_COLOR:4,SET_CWD:7,HYPERLINK:8,ITERM2:9,SET_FG_COLOR:10,SET_BG_COLOR:11,SET_CURSOR_COLOR:12,CLIPBOARD:52,KITTY:99,RESET_COLOR:104,RESET_FG_COLOR:110,RESET_BG_COLOR:111,RESET_CURSOR_COLOR:112,SEMANTIC_PROMPT:133,GHOSTTY:777,TAB_STATUS:21337},Fd=gd(Pd.HYPERLINK,``,``),Id={NOTIFY:0,BADGE:2,PROGRESS:4},Ld={CLEAR:0,SET:1,ERROR:2,INDETERMINATE:3},Rd=`${jd}${Pd.ITERM2};${Id.PROGRESS};${Ld.CLEAR};`,zd=`${jd}${Pd.SET_TITLE_AND_ICON};`,Bd=gd(Pd.TAB_STATUS,`indicator=;status=;status-color=`)}));function Hd(){if(!process.stdout.isTTY||process.env.WT_SESSION)return!1;if(process.env.ConEmuANSI||process.env.ConEmuPID||process.env.ConEmuTask)return!0;let e=(0,Yd.coerce)(process.env.TERM_PROGRAM_VERSION);return e?process.env.TERM_PROGRAM===`ghostty`?(0,Yd.gte)(e.version,`1.2.0`):process.env.TERM_PROGRAM===`iTerm.app`?(0,Yd.gte)(e.version,`3.6.6`):!1:!1}function Ud(){if(process.env.TMUX)return!1;let e=process.env.TERM_PROGRAM,t=process.env.TERM;if(e===`iTerm.app`||e===`WezTerm`||e===`WarpTerminal`||e===`ghostty`||e===`contour`||e===`vscode`||e===`alacritty`||t?.includes(`kitty`)||process.env.KITTY_WINDOW_ID||t===`xterm-ghostty`||t?.startsWith(`foot`)||t?.includes(`alacritty`)||process.env.ZED_TERM||process.env.WT_SESSION)return!0;let n=process.env.VTE_VERSION;return!!(n&&parseInt(n,10)>=6800)}function Wd(e){Xd===void 0&&(Xd=e)}function Gd(){return process.env.TERM_PROGRAM===`vscode`?!0:Xd?.startsWith(`xterm.js`)??!1}function Kd(){return Zd.includes(process.env.TERM_PROGRAM??``)}function qd(){return process.platform===`win32`||!!process.env.WT_SESSION}function Jd(e,t,n=!1){if(t.length===0)return;let r=!n,i=r?nd:``;for(let e of t)switch(e.type){case`stdout`:i+=e.content;break;case`clear`:e.count>0&&(i+=rr(e.count));break;case`clearTerminal`:i+=Xu();break;case`cursorHide`:i+=ld;break;case`cursorShow`:i+=cd;break;case`cursorMove`:i+=nr(e.x,e.y);break;case`cursorTo`:i+=er(e.col);break;case`carriageReturn`:i+=`\r`;break;case`hyperlink`:i+=Dd(e.uri);break;case`styleStr`:i+=e.str;break}r&&(i+=rd),e.stdout.write(i)}var Yd,Xd,Zd,Qd,$d=t((()=>{Yd=g(),Qu(),Dr(),md(),Vd(),Zd=[`iTerm.app`,`kitty`,`WezTerm`,`ghostty`,`tmux`,`windows-terminal`],Qd=Ud()}));function ef(e){af=e?`focused`:`blurred`;for(let e of sf)e();if(!e){for(let e of of)e();of.clear()}}function tf(){return af!==`blurred`}function nf(){return af}function rf(e){return sf.add(e),()=>{sf.delete(e)}}var af,of,sf,cf=t((()=>{af=`unknown`,of=new Set,sf=new Set}));function lf(){return{request:Yn(`>0q`),match:e=>e.type===`xtversion`}}var uf,df,ff=t((()=>{Dr(),Vd(),c(),uf=Yn(`c`),df=class{constructor(e){l(this,`queue`,[]),this.stdout=e}send(e){return new Promise(t=>{this.queue.push({kind:`query`,match:e.match,resolve:e=>t(e)}),this.stdout.write(e.request)})}flush(){return new Promise(e=>{this.queue.push({kind:`sentinel`,resolve:e}),this.stdout.write(uf)})}onResponse(e){let t=this.queue.findIndex(t=>t.kind===`query`&&t.match(e));if(t!==-1){let[n]=this.queue.splice(t,1);n?.kind===`query`&&n.resolve(e);return}if(e.type===`da1`){let e=this.queue.findIndex(e=>e.kind===`sentinel`);if(e===-1)return;for(let t of this.queue.splice(0,e+1))t.kind===`query`?t.resolve(void 0):t.resolve()}}}})),pf,mf,hf=t((()=>{pf=n(N(),1),mf=(0,pf.createContext)({exit(){}}),mf.displayName=`InternalAppContext`})),gf=t((()=>{}));function _f({children:e}){let t=(0,vf.useSyncExternalStore)(rf,tf),n=(0,vf.useSyncExternalStore)(rf,nf),r=(0,vf.useMemo)(()=>({isTerminalFocused:t,terminalFocusState:n}),[t,n]);return(0,yf.jsx)(bf.Provider,{value:r,children:e})}var vf,yf,bf,xf=t((()=>{vf=n(N(),1),cf(),yf=y(),bf=(0,vf.createContext)({isTerminalFocused:!0,terminalFocusState:`unknown`}),bf.displayName=`TerminalFocusContext`}));function Sf(){let{isTerminalFocused:e}=(0,Cf.useContext)(bf);return e}var Cf,wf=t((()=>{Cf=n(N(),1),xf()}));function Tf(e){let t=new Map,n=null,r=e,i=0,a=0;function o(){a=Date.now()-i;for(let e of t.keys())e()}function s(){[...t.values()].some(Boolean)?(n&&(clearInterval(n),n=null),i===0&&(i=Date.now()),n=setInterval(o,r)):n&&(clearInterval(n),n=null)}return{subscribe(e,n){return t.set(e,n),s(),()=>{t.delete(e),s()}},now(){return i===0&&(i=Date.now()),n&&a?a:Date.now()-i},setTickInterval(e){e!==r&&(r=e,s())}}}function Ef({children:e}){let[t]=(0,Df.useState)(()=>Tf(16)),n=Sf();return(0,Df.useEffect)(()=>{t.setTickInterval(n?16:Af)},[t,n]),(0,Of.jsx)(kf.Provider,{value:t,children:e})}var Df,Of,kf,Af,jf=t((()=>{Df=n(N(),1),gf(),wf(),Of=y(),kf=(0,Df.createContext)(null),Af=32})),Mf,Nf,Pf=t((()=>{Mf=n(N(),1),Nf=(0,Mf.createContext)(()=>{})})),Ff,If=t((()=>{Ff=(e,t=2)=>e.replace(/^\t+/gm,e=>` `.repeat(e.length*t))})),Lf,Rf,zf=t((()=>{If(),Lf=(e,t)=>{let n=[],r=e-t,i=e+t;for(let e=r;e<=i;e++)n.push(e);return n},Rf=(e,t,n={})=>{if(typeof e!=`string`)throw TypeError(`Source code is missing.`);if(!t||t<1)throw TypeError("Line number must start from `1`.");let r=Ff(e).split(/\r?\n/);if(!(t>r.length))return Lf(t,n.around??3).filter(e=>r[e-1]!==void 0).map(e=>({line:e,value:r[e-1]}))}})),Bf=r(((e,t)=>{var n=/[|\\{}()[\]^$+*?.-]/g;t.exports=e=>{if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(n,`\\$&`)}})),Vf=r(((t,n)=>{var r=Bf(),i=typeof process==`object`&&process&&typeof process.cwd==`function`?process.cwd():`.`,a=[].concat(e(`module`).builtinModules,`bootstrap_node`,`node`).map(e=>RegExp(`(?:\\((?:node:)?${e}(?:\\.js)?:\\d+:\\d+\\)$|^\\s*at (?:node:)?${e}(?:\\.js)?:\\d+:\\d+$)`));a.push(/\((?:node:)?internal\/[^:]+:\d+:\d+\)$/,/\s*at (?:node:)?internal\/[^:]+:\d+:\d+$/,/\/\.node-spawn-wrap-\w+-\w+\/node:\d+:\d+\)?$/);var o=class e{constructor(t){t={ignoredPackages:[],...t},`internals`in t||(t.internals=e.nodeInternals()),`cwd`in t||(t.cwd=i),this._cwd=t.cwd.replace(/\\/g,`/`),this._internals=[].concat(t.internals,c(t.ignoredPackages)),this._wrapCallSite=t.wrapCallSite||!1}static nodeInternals(){return[...a]}clean(e,t=0){t=` `.repeat(t),Array.isArray(e)||(e=e.split(`
29
+ `)),!/^\s*at /.test(e[0])&&/^\s*at /.test(e[1])&&(e=e.slice(1));let n=!1,r=null,i=[];return e.forEach(e=>{if(e=e.replace(/\\/g,`/`),this._internals.some(t=>t.test(e)))return;let t=/^\s*at /.test(e);n?e=e.trimEnd().replace(/^(\s+)at /,`$1`):(e=e.trim(),t&&(e=e.slice(3))),e=e.replace(`${this._cwd}/`,``),e&&(t?(r&&(i.push(r),r=null),i.push(e)):(n=!0,r=e))}),i.map(e=>`${t}${e}\n`).join(``)}captureString(e,t=this.captureString){typeof e==`function`&&(t=e,e=1/0);let{stackTraceLimit:n}=Error;e&&(Error.stackTraceLimit=e);let r={};Error.captureStackTrace(r,t);let{stack:i}=r;return Error.stackTraceLimit=n,this.clean(i)}capture(e,t=this.capture){typeof e==`function`&&(t=e,e=1/0);let{prepareStackTrace:n,stackTraceLimit:r}=Error;Error.prepareStackTrace=(e,t)=>this._wrapCallSite?t.map(this._wrapCallSite):t,e&&(Error.stackTraceLimit=e);let i={};Error.captureStackTrace(i,t);let{stack:a}=i;return Object.assign(Error,{prepareStackTrace:n,stackTraceLimit:r}),a}at(e=this.at){let[t]=this.capture(1,e);if(!t)return{};let n={line:t.getLineNumber(),column:t.getColumnNumber()};s(n,t.getFileName(),this._cwd),t.isConstructor()&&Object.defineProperty(n,`constructor`,{value:!0,configurable:!0}),t.isEval()&&(n.evalOrigin=t.getEvalOrigin()),t.isNative()&&(n.native=!0);let r;try{r=t.getTypeName()}catch{}r&&r!==`Object`&&r!==`[object Object]`&&(n.type=r);let i=t.getFunctionName();i&&(n.function=i);let a=t.getMethodName();return a&&i!==a&&(n.method=a),n}parseLine(e){let t=e&&e.match(l);if(!t)return null;let n=t[1]===`new`,r=t[2],i=t[3],a=t[4],o=Number(t[5]),c=Number(t[6]),d=t[7],f=t[8],p=t[9],m=t[10]===`native`,h=t[11]===`)`,g,_={};if(f&&(_.line=Number(f)),p&&(_.column=Number(p)),h&&d){let e=0;for(let t=d.length-1;t>0;t--)if(d.charAt(t)===`)`)e++;else if(d.charAt(t)===`(`&&d.charAt(t-1)===` `&&(e--,e===-1&&d.charAt(t-1)===` `)){let e=d.slice(0,t-1);d=d.slice(t+1),r+=` (${e}`;break}}if(r){let e=r.match(u);e&&(r=e[1],g=e[2])}return s(_,d,this._cwd),n&&Object.defineProperty(_,`constructor`,{value:!0,configurable:!0}),i&&(_.evalOrigin=i,_.evalLine=o,_.evalColumn=c,_.evalFile=a&&a.replace(/\\/g,`/`)),m&&(_.native=!0),r&&(_.function=r),g&&r!==g&&(_.method=g),_}};function s(e,t,n){t&&(t=t.replace(/\\/g,`/`),t.startsWith(`${n}/`)&&(t=t.slice(n.length+1)),e.file=t)}function c(e){if(e.length===0)return[];let t=e.map(e=>r(e));return RegExp(`[\/\\\\]node_modules[\/\\\\](?:${t.join(`|`)})[\/\\\\][^:]+:\\d+:\\d+`)}var l=RegExp(`^(?:\\s*at )?(?:(new) )?(?:(.*?) \\()?(?:eval at ([^ ]+) \\((.+?):(\\d+):(\\d+)\\), )?(?:(.+?):(\\d+):(\\d+)|(native))(\\)?)$`),u=/^(.*?) \[as (.*?)\]$/;n.exports=o}));function Hf({children:e,flexWrap:t=`nowrap`,flexDirection:n=`row`,flexGrow:r=0,flexShrink:i=1,ref:a,tabIndex:o,autoFocus:s,onClick:c,onFocus:l,onFocusCapture:u,onBlur:d,onBlurCapture:f,onMouseEnter:p,onMouseLeave:m,onKeyDown:h,onKeyDownCapture:g,..._}){return Al(_.margin,`margin`),Al(_.marginX,`marginX`),Al(_.marginY,`marginY`),Al(_.marginTop,`marginTop`),Al(_.marginBottom,`marginBottom`),Al(_.marginLeft,`marginLeft`),Al(_.marginRight,`marginRight`),Al(_.padding,`padding`),Al(_.paddingX,`paddingX`),Al(_.paddingY,`paddingY`),Al(_.paddingTop,`paddingTop`),Al(_.paddingBottom,`paddingBottom`),Al(_.paddingLeft,`paddingLeft`),Al(_.paddingRight,`paddingRight`),Al(_.gap,`gap`),Al(_.columnGap,`columnGap`),Al(_.rowGap,`rowGap`),(0,Uf.jsx)(`ink-box`,{ref:a,tabIndex:o,autoFocus:s,onClick:c,onFocus:l,onFocusCapture:u,onBlur:d,onBlurCapture:f,onMouseEnter:p,onMouseLeave:m,onKeyDown:h,onKeyDownCapture:g,style:{flexWrap:t,flexDirection:n,flexGrow:r,flexShrink:i,..._,overflowX:_.overflowX??_.overflow??`visible`,overflowY:_.overflowY??_.overflow??`visible`},children:e})}var Uf,Wf=t((()=>{N(),jl(),Uf=y()}));function Gf({color:e,backgroundColor:t,bold:n,dim:r,italic:i=!1,underline:a=!1,strikethrough:o=!1,inverse:s=!1,wrap:c=`wrap`,children:l}){if(l==null)return null;let u={...e&&{color:e},...t&&{backgroundColor:t},...r&&{dim:r},...n&&{bold:n},...i&&{italic:i},...a&&{underline:a},...o&&{strikethrough:o},...s&&{inverse:s}};return(0,Kf.jsx)(`ink-text`,{style:qf[c],textStyles:u,children:l})}var Kf,qf,Jf=t((()=>{N(),Kf=y(),qf={wrap:{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`wrap`},"wrap-trim":{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`wrap-trim`},end:{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`end`},middle:{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`middle`},"truncate-end":{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`truncate-end`},truncate:{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`truncate`},"truncate-middle":{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`truncate-middle`},"truncate-start":{flexGrow:0,flexShrink:1,flexDirection:`row`,textWrap:`truncate-start`}}}));function Yf(){return ep??(ep=new Zf.default({cwd:process.cwd(),internals:Zf.default.nodeInternals()}))}function Xf({error:e}){let t=e.stack?e.stack.split(`
30
+ `).slice(1):void 0,n=t?Yf().parseLine(t[0]):void 0,r=$f(n?.file),i,a=0;if(r&&n?.line)try{if(i=Rf(T(r,`utf8`),n.line),i)for(let{line:e}of i)a=Math.max(a,String(e).length)}catch{}return(0,Qf.jsxs)(Hf,{flexDirection:`column`,padding:1,children:[(0,Qf.jsxs)(Hf,{children:[(0,Qf.jsxs)(Gf,{backgroundColor:`ansi:red`,color:`ansi:white`,children:[` `,`ERROR`,` `]}),(0,Qf.jsxs)(Gf,{children:[` `,e.message]})]}),n&&r&&(0,Qf.jsx)(Hf,{marginTop:1,children:(0,Qf.jsxs)(Gf,{dim:!0,children:[r,`:`,n.line,`:`,n.column]})}),n&&i&&(0,Qf.jsx)(Hf,{marginTop:1,flexDirection:`column`,children:i.map(({line:e,value:t})=>(0,Qf.jsxs)(Hf,{children:[(0,Qf.jsx)(Hf,{width:a+1,children:(0,Qf.jsxs)(Gf,{dim:e!==n.line,backgroundColor:e===n.line?`ansi:red`:void 0,color:e===n.line?`ansi:white`:void 0,children:[String(e).padStart(a,` `),`:`]})}),(0,Qf.jsx)(Gf,{backgroundColor:e===n.line?`ansi:red`:void 0,color:e===n.line?`ansi:white`:void 0,children:` `+t},e)]},e))}),e.stack&&(0,Qf.jsx)(Hf,{marginTop:1,flexDirection:`column`,children:e.stack.split(`
31
+ `).slice(1).map(e=>{let t=Yf().parseLine(e);return t?(0,Qf.jsxs)(Hf,{children:[(0,Qf.jsx)(Gf,{dim:!0,children:`- `}),(0,Qf.jsx)(Gf,{bold:!0,children:t.function}),(0,Qf.jsxs)(Gf,{dim:!0,children:[` `,`(`,$f(t.file)??``,`:`,t.line,`:`,t.column,`)`]})]},e):(0,Qf.jsxs)(Hf,{children:[(0,Qf.jsx)(Gf,{dim:!0,children:`- `}),(0,Qf.jsx)(Gf,{bold:!0,children:e})]},e)})})]})}var Zf,Qf,$f,ep,tp=t((()=>{zf(),N(),Zf=n(Vf(),1),Wf(),Jf(),Qf=y(),$f=e=>e?.replace(`file://${process.cwd()}/`,``)})),np,rp,ip=t((()=>{np=n(N(),1),Vn(),rp=(0,np.createContext)({stdin:process.stdin,internal_eventEmitter:new Bn,setRawMode(){},isRawModeSupported:!1,internal_exitOnCtrlC:!0,internal_querier:null}),rp.displayName=`InternalStdinContext`})),ap,op,sp=t((()=>{ap=n(N(),1),op=(0,ap.createContext)(null)}));function cp(e){return e===`1`||e===`true`}function lp(e,t,n,r){t.some(e=>e.kind===`key`||e.kind===`mouse`&&!(e.button&32&&(e.button&3)==3))&&pp.updateLastInteractionTime();for(let n of t){if(n.kind===`response`){e.querier.onResponse(n.response);continue}if(n.kind===`mouse`){up(e,n);continue}let t=n.sequence;if(t===xr){e.handleTerminalFocus(!0);let t=new ci(`terminalfocus`);e.internal_eventEmitter.emit(`terminalfocus`,t);continue}if(t===Sr){e.handleTerminalFocus(!1),e.props.selection.isDragging&&(Z(e.props.selection),e.props.onSelectionChange());let t=new ci(`terminalblur`);e.internal_eventEmitter.emit(`terminalblur`,t);continue}if(tf()||ef(!0),n.name===`z`&&n.ctrl&&mp){e.handleSuspend();continue}e.handleInput(t);let r=new oi(n);e.internal_eventEmitter.emit(`input`,r),e.props.dispatchKeyboardEvent(n)}}function up(e,t){if(pp.isMouseClicksDisabled())return;let n=e.props.selection,r=t.col-1,i=t.row-1,a=t.button&3;if(t.action===`press`){if(t.button&32&&a===3){if(n.isDragging&&(Z(n),e.props.onSelectionChange()),r===e.lastHoverCol&&i===e.lastHoverRow)return;e.lastHoverCol=r,e.lastHoverRow=i,e.props.onHoverAt(r,i);return}if(a!==0){e.clickCount=0;return}if(t.button&32){e.props.onSelectionDrag(r,i);return}n.isDragging&&(Z(n),e.props.onSelectionChange());let o=Date.now();if(e.clickCount=o-e.lastClickTime<gp&&Math.abs(r-e.lastClickCol)<=_p&&Math.abs(i-e.lastClickRow)<=_p?e.clickCount+1:1,e.lastClickTime=o,e.lastClickCol=r,e.lastClickRow=i,e.clickCount>=2){e.pendingHyperlinkTimer&&(clearTimeout(e.pendingHyperlinkTimer),e.pendingHyperlinkTimer=null);let t=e.clickCount===2?2:3;e.props.onMultiClick(r,i,t);return}wu(n,r,i),n.lastPressHadAlt=(t.button&8)!=0,e.props.onSelectionChange();return}if(a!==0){if(!n.isDragging)return;Z(n),e.props.onSelectionChange();return}if(Z(n),!Lu(n)&&n.anchor&&!e.props.onClickAt(r,i)){let t=e.props.getHyperlinkAt(r,i);t&&process.env.TERM_PROGRAM!==`vscode`&&!Gd()&&(e.pendingHyperlinkTimer&&clearTimeout(e.pendingHyperlinkTimer),e.pendingHyperlinkTimer=setTimeout((e,t)=>{e.pendingHyperlinkTimer=null,e.props.onOpenHyperlink(t)},gp,e,t))}e.props.onSelectionChange()}var dp,fp,pp,mp,hp,gp,_p,vp,yp=t((()=>{dp=n(N(),1),fp=y(),c(),Vn(),si(),li(),ii(),Tl(),Ku(),$d(),cf(),ff(),Dr(),md(),hf(),jf(),Pf(),tp(),ip(),xf(),sp(),pp={updateLastInteractionTime:()=>{},stopCapturingEarlyInput:()=>{},isMouseClicksDisabled:()=>!1,logError:e=>console.error(e),logForDebugging:(e,t)=>{}},mp=process.platform!==`win32`,hp=5e3,gp=500,_p=1,vp=class extends dp.PureComponent{constructor(...e){super(...e),l(this,`state`,{error:void 0}),l(this,`rawModeEnabledCount`,0),l(this,`internal_eventEmitter`,new Bn),l(this,`keyParseState`,$r),l(this,`incompleteEscapeTimer`,null),l(this,`NORMAL_TIMEOUT`,50),l(this,`PASTE_TIMEOUT`,500),l(this,`querier`,new df(this.props.stdout)),l(this,`lastClickTime`,0),l(this,`lastClickCol`,-1),l(this,`lastClickRow`,-1),l(this,`clickCount`,0),l(this,`pendingHyperlinkTimer`,null),l(this,`lastHoverCol`,-1),l(this,`lastHoverRow`,-1),l(this,`lastStdinTime`,Date.now()),l(this,`handleSetRawMode`,e=>{let{stdin:t}=this.props;if(!this.isRawModeSupported())throw t===process.stdin?Error(`Raw mode is not supported on the current process.stdin, which Ink uses as input stream by default.
32
+ Read about how to prevent this error on https://github.com/vadimdemedes/ink/#israwmodesupported`):Error(`Raw mode is not supported on the stdin provided to Ink.
33
+ Read about how to prevent this error on https://github.com/vadimdemedes/ink/#israwmodesupported`);if(t.setEncoding(`utf8`),e){if(this.rawModeEnabledCount===0){pp.stopCapturingEarlyInput();let e=t.listeners(`readable`);for(let n of e)n!==this.handleReadable&&t.removeListener(`readable`,n);t.ref(),t.setRawMode(!0),t.addListener(`readable`,this.handleReadable),this.props.stdout.write(id),this.props.stdout.write(od),Kd()&&(this.props.stdout.write(Cr),this.props.stdout.write(Tr)),setImmediate(()=>{Promise.all([this.querier.send(lf()),this.querier.flush()]).then(([e])=>{e?(Wd(e.name),pp.logForDebugging(`XTVERSION: terminal identified as "${e.name}"`)):pp.logForDebugging(`XTVERSION: no reply (terminal ignored query)`)})})}this.rawModeEnabledCount++;return}if(--this.rawModeEnabledCount===0){let e=this.internal_eventEmitter.listenerCount(`input`);if(e>0){this.rawModeEnabledCount=e;return}this.props.stdout.write(Er),this.props.stdout.write(wr),this.props.stdout.write(sd),this.props.stdout.write(ad),t.setRawMode(!1),t.removeListener(`readable`,this.handleReadable),t.unref()}}),l(this,`flushIncomplete`,()=>{if(this.incompleteEscapeTimer=null,this.keyParseState.incomplete){if(this.props.stdin.readableLength>0){this.incompleteEscapeTimer=setTimeout(this.flushIncomplete,this.NORMAL_TIMEOUT);return}this.processInput(null)}}),l(this,`processInput`,e=>{let[t,n]=Fr(this.keyParseState,e);this.keyParseState=n,t.length>0&&wl.discreteUpdates(lp,this,t,void 0,void 0),this.keyParseState.incomplete&&(this.incompleteEscapeTimer&&clearTimeout(this.incompleteEscapeTimer),this.incompleteEscapeTimer=setTimeout(this.flushIncomplete,this.keyParseState.mode===`IN_PASTE`?this.PASTE_TIMEOUT:this.NORMAL_TIMEOUT))}),l(this,`handleReadable`,()=>{let e=Date.now();e-this.lastStdinTime>hp&&this.props.onStdinResume?.(),this.lastStdinTime=e;try{let e;for(;(e=this.props.stdin.read())!==null;)this.processInput(e)}catch(e){pp.logError(e);let{stdin:t}=this.props;this.rawModeEnabledCount>0&&!t.listeners(`readable`).includes(this.handleReadable)&&(pp.logForDebugging(`handleReadable: re-attaching stdin readable listener after error recovery`,{level:`warn`}),t.addListener(`readable`,this.handleReadable))}}),l(this,`handleInput`,e=>{e===``&&this.props.exitOnCtrlC&&this.handleExit()}),l(this,`handleExit`,e=>{this.isRawModeSupported()&&this.handleSetRawMode(!1),this.props.onExit(e)}),l(this,`handleTerminalFocus`,e=>{ef(e)}),l(this,`handleSuspend`,()=>{if(!this.isRawModeSupported())return;let e=this.rawModeEnabledCount;for(;this.rawModeEnabledCount>0;)this.handleSetRawMode(!1);this.props.stdout.isTTY&&this.props.stdout.write(cd+sd+pd),this.internal_eventEmitter.emit(`suspend`);let t=()=>{for(let t=0;t<e;t++)this.isRawModeSupported()&&this.handleSetRawMode(!0);this.props.stdout.isTTY&&(cp(process.env.CLAUDE_CODE_ACCESSIBILITY)||this.props.stdout.write(ld),this.props.stdout.write(od)),this.internal_eventEmitter.emit(`resume`),process.removeListener(`SIGCONT`,t)};process.on(`SIGCONT`,t),process.kill(process.pid,`SIGSTOP`)})}static getDerivedStateFromError(e){return{error:{message:e.message,stack:e.stack}}}isRawModeSupported(){return this.props.stdin.isTTY}render(){return(0,fp.jsx)(op.Provider,{value:{columns:this.props.terminalColumns,rows:this.props.terminalRows},children:(0,fp.jsx)(mf.Provider,{value:{exit:this.handleExit},children:(0,fp.jsx)(rp.Provider,{value:{stdin:this.props.stdin,setRawMode:this.handleSetRawMode,isRawModeSupported:this.isRawModeSupported(),internal_exitOnCtrlC:this.props.exitOnCtrlC,internal_eventEmitter:this.internal_eventEmitter,internal_querier:this.querier},children:(0,fp.jsx)(_f,{children:(0,fp.jsx)(Ef,{children:(0,fp.jsx)(Nf.Provider,{value:this.props.onCursorDeclaration??(()=>{}),children:this.state.error?(0,fp.jsx)(Xf,{error:this.state.error}):this.props.children})})})})})})}componentDidMount(){this.props.stdout.isTTY&&!cp(process.env.CLAUDE_CODE_ACCESSIBILITY)&&this.props.stdout.write(ld)}componentWillUnmount(){if(this.props.stdout.isTTY&&this.props.stdout.write(cd),this.incompleteEscapeTimer&&(clearTimeout(this.incompleteEscapeTimer),this.incompleteEscapeTimer=null),this.pendingHyperlinkTimer&&(clearTimeout(this.pendingHyperlinkTimer),this.pendingHyperlinkTimer=null),this.isRawModeSupported())this.handleSetRawMode(!1);else try{this.props.stdin.unref()}catch{}}componentDidCatch(e){this.handleExit(e)}},l(vp,`displayName`,`InternalApp`)}));function bp(e){let t=e.sequence??``,n=e.name??``;if(e.ctrl)return n;if(t.length===1){let e=t.charCodeAt(0);if(e>=32&&e!==127)return t}return n||t}var xp,Sp=t((()=>{jc(),c(),xp=class extends Ac{constructor(e){super(`keydown`,{bubbles:!0,cancelable:!0}),l(this,`key`,void 0),l(this,`ctrl`,void 0),l(this,`shift`,void 0),l(this,`meta`,void 0),l(this,`superKey`,void 0),l(this,`fn`,void 0),this.key=bp(e),this.ctrl=e.ctrl,this.shift=e.shift,this.meta=e.meta||e.option,this.superKey=e.super,this.fn=e.fn}}}));function Cp(e,t,n,r,i){return{screen:Rl(0,0,n,r,i),viewport:{width:t,height:e},cursor:{x:0,y:0,visible:!0}}}var wp=t((()=>{Cu()})),Tp,Ep=t((()=>{zn(),c(),Tp=class extends Rn{constructor(e,t,n){super(),l(this,`col`,void 0),l(this,`row`,void 0),l(this,`localCol`,0),l(this,`localRow`,0),l(this,`cellIsBlank`,void 0),this.col=e,this.row=t,this.cellIsBlank=n}}}));function Dp(e,t,n){let r=W.get(e);if(!r||t<r.x||t>=r.x+r.width||n<r.y||n>=r.y+r.height)return null;for(let r=e.childNodes.length-1;r>=0;r--){let i=e.childNodes[r];if(i.nodeName===`#text`)continue;let a=Dp(i,t,n);if(a)return a}return e}function Op(e,t,n,r=!1){let i=Dp(e,t,n)??void 0;if(!i)return!1;if(e.focusManager){let t=i;for(;t;){if(typeof t.attributes.tabIndex==`number`){e.focusManager.handleClickFocus(t);break}t=t.parentNode}}let a=new Tp(t,n,r),o=!1;for(;i;){let e=i._eventHandlers?.onClick;if(e){o=!0;let r=W.get(i);if(r&&(a.localCol=t-r.x,a.localRow=n-r.y),e(a),a.didStopImmediatePropagation())return!0}i=i.parentNode}return o}function kp(e,t,n,r){let i=new Set,a=Dp(e,t,n)??void 0;for(;a;){let e=a._eventHandlers;(e?.onMouseEnter||e?.onMouseLeave)&&i.add(a),a=a.parentNode}for(let e of r)i.has(e)||(r.delete(e),e.parentNode&&e._eventHandlers?.onMouseLeave?.());for(let e of i)r.has(e)||(r.add(e),e._eventHandlers?.onMouseEnter?.())}var Ap=t((()=>{Ep(),Aa()})),jp,Mp=t((()=>{jp=new Map}));function Np(e,t,n){return t===n?t:(e.push({type:`hyperlink`,uri:n??``}),n)}function Pp(e,t,n,r){let i=t.transition(n,r);return i.length>0&&e.push({type:`styleStr`,str:i}),r}function Fp(e,t){let n=``;for(let r=0;r<e.width;r++)n+=q(e,r,t)??` `;return n.trimEnd()}function Ip(e,t,n,r){let i=new Kp({x:0,y:0},e.viewport.width);return Lp(i,e,n),[{type:`clearTerminal`,reason:t,debug:r},...i.diff]}function Lp(e,t,n){Rp(e,t,0,t.screen.height,n)}function Rp(e,t,n,r,i){let a=i.none,o,s=-1,{width:c,cells:l,charPool:u,hyperlinkPool:d}=t.screen,f=n*c;for(let t=n;t<r;t+=1){if(e.cursor.y<t){let n=t-e.cursor.y;e.txn(e=>{let t=Array(1+n);t[0]=Up;for(let e=0;e<n;e++)t[1+e]=Wp;return[t,{dx:-e.x,dy:n}]})}s=-1;for(let n=0;n<c;n+=1,f+=1){let r=Ul(l,u,d,f,s);if(!r)continue;Bp(e,n,t);let c=r.hyperlink;o=Np(e.diff,o,c),zp(e,r,i.transition(a,r.styleId))&&(a=r.styleId,s=r.styleId)}a=Pp(e.diff,i,a,i.none),o=Np(e.diff,o,void 0),e.txn(e=>[[Up,Wp],{dx:-e.x,dy:1}])}return Pp(e.diff,i,a,i.none),Np(e.diff,o,void 0),e}function zp(e,t,n){let r=t.width===J.Wide?2:1,i=e.cursor.x,a=e.viewportWidth;if(r===2&&i<a){let e=t.char.length>2?a:a+1;if(i+2>=e)return!1}let o=e.diff;n.length>0&&o.push({type:`styleStr`,str:n});let s=r===2&&Vp(t.char);return s&&i+1<a&&(o.push({type:`cursorTo`,col:i+2}),o.push({type:`stdout`,content:` `}),o.push({type:`cursorTo`,col:i+1})),o.push({type:`stdout`,content:t.char}),s&&o.push({type:`cursorTo`,col:i+r+1}),i>=a?(e.cursor.x=r,e.cursor.y++):e.cursor.x=i+r,!0}function Bp(e,t,n){e.txn(r=>{let i=t-r.x,a=n-r.y;return r.x>=e.viewportWidth||a!==0?[[Up,{type:`cursorMove`,x:t,y:a}],{dx:i,dy:a}]:[[{type:`cursorMove`,x:i,y:a}],{dx:i,dy:a}]})}function Vp(e){let t=e.codePointAt(0);if(t===void 0)return!1;if(t>=129648&&t<=129791||t>=129792&&t<=130047)return!0;if(e.length>=2){for(let t=0;t<e.length;t++)if(e.charCodeAt(t)===65039)return!0}return!1}var Hp,Up,Wp,Gp,Kp,qp=t((()=>{zo(),c(),Cu(),Dr(),Vd(),Hp=e=>{},Up={type:`carriageReturn`},Wp={type:`stdout`,content:`
34
+ `},Gp=class{constructor(e){l(this,`state`,void 0),this.options=e,this.state={previousOutput:``}}renderPreviousOutput_DEPRECATED(e){return this.options.isTTY?this.getRenderOpsForDone(e):[Wp]}reset(){this.state.previousOutput=``}renderFullFrame(e){let{screen:t}=e,n=[],r=[],i;for(let e=0;e<t.height;e++){let a=``;for(let n=0;n<t.width;n++){let o=Vl(t,n,e);if(o&&o.width!==J.SpacerTail){o.hyperlink!==i&&(i!==void 0&&(a+=Fd),o.hyperlink!==void 0&&(a+=Dd(o.hyperlink)),i=o.hyperlink);let e=this.options.stylePool.get(o.styleId),t=Co(r,e);t.length>0&&(a+=po(t),r=e),a+=o.char}}i!==void 0&&(a+=Fd,i=void 0);let o=Co(r,[]);o.length>0&&(a+=po(o),r=[]),n.push(a.trimEnd())}return n.length===0?[]:[{type:`stdout`,content:n.join(`
35
+ `)}]}getRenderOpsForDone(e){return this.state.previousOutput=``,e.cursor.visible?[]:[{type:`cursorShow`}]}render(e,t,n=!1,r=!0){if(!this.options.isTTY)return this.renderFullFrame(t);let i=performance.now(),a=this.options.stylePool;if(t.viewport.height<e.viewport.height||e.viewport.width!==0&&t.viewport.width!==e.viewport.width)return Ip(t,`resize`,a);let o=[];if(n&&t.scrollHint&&r){let{top:n,bottom:r,delta:i}=t.scrollHint;n>=0&&r<e.screen.height&&r<t.screen.height&&(Yl(e.screen,n,r,i),o=[{type:`stdout`,content:or(n+1,r+1)+(i>0?ir(i):ar(-i))+vr+mr}])}let s=e.cursor.y>=e.screen.height,c=t.screen.height>e.screen.height,l=s&&e.screen.height>=e.viewport.height,u=t.screen.height<e.screen.height,d=t.screen.height<=e.viewport.height;if(l&&d&&u)return Hp(`Full reset (shrink->below): prevHeight=${e.screen.height}, nextHeight=${t.screen.height}, viewport=${e.viewport.height}`),Ip(t,`offscreen`,a);if(e.screen.height>=e.viewport.height&&e.screen.height>0&&s&&!c){let n=e.screen.height-e.viewport.height+1,r=-1;if(Ql(e.screen,t.screen,(e,t)=>{if(t<n)return r=t,!0}),r>=0){let n=Fp(e.screen,r),i=Fp(t.screen,r);return Ip(t,`offscreen`,a,{triggerY:r,prevLine:n,nextLine:i})}}let f=new Kp(e.cursor,t.viewport.width),p=Math.max(t.screen.height,1)-Math.max(e.screen.height,1),m=p<0,h=p>0;if(m){let n=e.screen.height-t.screen.height;if(n>e.viewport.height)return Ip(t,`offscreen`,this.options.stylePool);f.txn(e=>[[{type:`clear`,count:n},{type:`cursorMove`,x:0,y:-1}],{dx:-e.x,dy:-n}])}let g=+!!l,_=h?Math.max(0,e.screen.height-e.viewport.height+g):Math.max(e.screen.height,t.screen.height)-t.viewport.height+g,v=a.none,y,b=!1,x=-1;if(Ql(e.screen,t.screen,(n,r,i,o)=>{if(!(h&&r>=e.screen.height)&&!(o&&(o.width===J.SpacerTail||o.width===J.SpacerHead))&&!(i&&(i.width===J.SpacerTail||i.width===J.SpacerHead)&&!o)&&!(o&&Il(t.screen,n,r)&&!i)){if(r<_)return b=!0,x=r,!0;if(Bp(f,n,r),o){let e=o.hyperlink;y=Np(f.diff,y,e),zp(f,o,a.transition(v,o.styleId))&&(v=o.styleId)}else if(i){let e=v,t=y;v=a.none,y=void 0,f.txn(()=>{let n=[];return Pp(n,a,e,a.none),Np(n,t,void 0),n.push({type:`stdout`,content:` `}),[n,{dx:1,dy:0}]})}}}),b)return Ip(t,`offscreen`,a,{triggerY:x,prevLine:Fp(e.screen,x),nextLine:Fp(t.screen,x)});v=Pp(f.diff,a,v,a.none),y=Np(f.diff,y,void 0),h&&Rp(f,t,e.screen.height,t.screen.height,a),n||(t.cursor.y>=t.screen.height?f.txn(e=>{let n=t.cursor.y-e.y;if(n>0){let t=Array(1+n);t[0]=Up;for(let e=0;e<n;e++)t[1+e]=Wp;return[t,{dx:-e.x,dy:n}]}let r=t.cursor.y-e.y;if(r!==0||e.x!==t.cursor.x){let n=[Up];return n.push({type:`cursorMove`,x:t.cursor.x,y:r}),[n,{dx:t.cursor.x-e.x,dy:r}]}return[[],{dx:0,dy:0}]}):Bp(f,t.cursor.x,t.cursor.y));let S=performance.now()-i;if(S>50){let e=t.screen.damage,n=e?`${e.width}x${e.height} at (${e.x},${e.y})`:`none`;Hp(`Slow render: ${S.toFixed(1)}ms, screen: ${t.screen.height}x${t.screen.width}, damage: ${n}, changes: ${f.diff.length}`)}return o.length>0?[...o,...f.diff]:f.diff}},Kp=class{constructor(e,t){l(this,`cursor`,void 0),l(this,`diff`,[]),this.viewportWidth=t,this.cursor={...e}}txn(e){let[t,n]=e(this.cursor);for(let e of t)this.diff.push(e);this.cursor.x+=n.dx,this.cursor.y+=n.dy}}}));function Jp(e){if(e.length<=1)return e;let t=[],n=0;for(let r of e){let e=r.type;if(e===`stdout`){if(r.content===``)continue}else if(e===`cursorMove`){if(r.x===0&&r.y===0)continue}else if(e===`clear`&&r.count===0)continue;if(n>0){let i=n-1,a=t[i],o=a.type;if(e===`cursorMove`&&o===`cursorMove`){t[i]={type:`cursorMove`,x:a.x+r.x,y:a.y+r.y};continue}if(e===`cursorTo`&&o===`cursorTo`){t[i]=r;continue}if(e===`styleStr`&&o===`styleStr`){t[i]={type:`styleStr`,str:a.str+r.str};continue}if(e===`hyperlink`&&o===`hyperlink`&&r.uri===a.uri)continue;if(e===`cursorShow`&&o===`cursorHide`||e===`cursorHide`&&o===`cursorShow`){t.pop(),n--;continue}}t.push(r),n++}return t}var Yp=t((()=>{}));function Xp(){return function(e){var t={R:`13k,1a,2,3,3,2+1j,ch+16,a+1,5+2,2+n,5,a,4,6+16,4+3,h+1b,4mo,179q,2+9,2+11,2i9+7y,2+68,4,3+4,5+13,4+3,2+4k,3+29,8+cf,1t+7z,w+17,3+3m,1t+3z,16o1+5r,8+30,8+mc,29+1r,29+4v,75+73`,EN:`1c+9,3d+1,6,187+9,513,4+5,7+9,sf+j,175h+9,qw+q,161f+1d,4xt+a,25i+9`,ES:`17,2,6dp+1,f+1,av,16vr,mx+1,4o,2`,ET:`z+2,3h+3,b+1,ym,3e+1,2o,p4+1,8,6u,7c,g6,1wc,1n9+4,30+1b,2n,6d,qhx+1,h0m,a+1,49+2,63+1,4+1,6bb+3,12jj`,AN:`16o+5,2j+9,2+1,35,ed,1ff2+9,87+u`,CS:`18,2+1,b,2u,12k,55v,l,17v0,2,3,53,2+1,b`,B:`a,3,f+2,2v,690`,S:`9,2,k`,WS:`c,k,4f4,1vk+a,u,1j,335`,ON:`x+1,4+4,h+5,r+5,r+3,z,5+3,2+1,2+1,5,2+2,3+4,o,w,ci+1,8+d,3+d,6+8,2+g,39+1,9,6+1,2,33,b8,3+1,3c+1,7+1,5r,b,7h+3,sa+5,2,3i+6,jg+3,ur+9,2v,ij+1,9g+9,7+a,8m,4+1,49+x,14u,2+2,c+2,e+2,e+2,e+1,i+n,e+e,2+p,u+2,e+2,36+1,2+3,2+1,b,2+2,6+5,2,2,2,h+1,5+4,6+3,3+f,16+2,5+3l,3+81,1y+p,2+40,q+a,m+13,2r+ch,2+9e,75+hf,3+v,2+2w,6e+5,f+6,75+2a,1a+p,2+2g,d+5x,r+b,6+3,4+o,g,6+1,6+2,2k+1,4,2j,5h+z,1m+1,1e+f,t+2,1f+e,d+3,4o+3,2s+1,w,535+1r,h3l+1i,93+2,2s,b+1,3l+x,2v,4g+3,21+3,kz+1,g5v+1,5a,j+9,n+v,2,3,2+8,2+1,3+2,2,3,46+1,4+4,h+5,r+5,r+a,3h+2,4+6,b+4,78,1r+24,4+c,4,1hb,ey+6,103+j,16j+c,1ux+7,5+g,fsh,jdq+1t,4,57+2e,p1,1m,1m,1m,1m,4kt+1,7j+17,5+2r,d+e,3+e,2+e,2+10,m+4,w,1n+5,1q,4z+5,4b+rb,9+c,4+c,4+37,d+2g,8+b,l+b,5+1j,9+9,7+13,9+t,3+1,27+3c,2+29,2+3q,d+d,3+4,4+2,6+6,a+o,8+6,a+2,e+6,16+42,2+1i`,BN:`0+8,6+d,2s+5,2+p,e,4m9,1kt+2,2b+5,5+5,17q9+v,7k,6p+8,6+1,119d+3,440+7,96s+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+1,1ekf+75,6p+2rz,1ben+1,1ekf+1,1ekf+1`,NSM:`lc+33,7o+6,7c+18,2,2+1,2+1,2,21+a,1d+k,h,2u+6,3+5,3+1,2+3,10,v+q,2k+a,1n+8,a,p+3,2+8,2+2,2+4,18+2,3c+e,2+v,1k,2,5+7,5,4+6,b+1,u,1n,5+3,9,l+1,r,3+1,1m,5+1,5+1,3+2,4,v+1,4,c+1,1m,5+4,2+1,5,l+1,n+5,2,1n,3,2+3,9,8+1,c+1,v,1q,d,1f,4,1m+2,6+2,2+3,8+1,c+1,u,1n,g+1,l+1,t+1,1m+1,5+3,9,l+1,u,21,8+2,2,2j,3+6,d+7,2r,3+8,c+5,23+1,s,2,2,1k+d,2+4,2+1,6+a,2+z,a,2v+3,2+5,2+1,3+1,q+1,5+2,h+3,e,3+1,7,g,jk+2,qb+2,u+2,u+1,v+1,1t+1,2+6,9,3+a,a,1a+2,3c+1,z,3b+2,5+1,a,7+2,64+1,3,1n,2+6,2,2,3+7,7+9,3,1d+g,1s+3,1d,2+4,2,6,15+8,d+1,x+3,3+1,2+2,1l,2+1,4,2+2,1n+7,3+1,49+2,2+c,2+6,5,7,4+1,5j+1l,2+4,k1+w,2db+2,3y,2p+v,ff+3,30+1,n9x+3,2+9,x+1,29+1,7l,4,5,q+1,6,48+1,r+h,e,13+7,q+a,1b+2,1d,3+3,3+1,14,1w+5,3+1,3+1,d,9,1c,1g,2+2,3+1,6+1,2,17+1,9,6n,3,5,fn5,ki+f,h+f,r2,6b,46+4,1af+2,2+1,6+3,15+2,5,4m+1,fy+3,as+1,4a+a,4x,1j+e,1l+2,1e+3,3+1,1y+2,11+4,2+7,1r,d+1,1h+8,b+3,3,2o+2,3,2+1,7,4h,4+7,m+1,1m+1,4,12+6,4+4,5g+7,3+2,2,o,2d+5,2,5+1,2+1,6n+3,7+1,2+1,s+1,2e+7,3,2+1,2z,2,3+5,2,2u+2,3+3,2+4,78+8,2+1,75+1,2,5,41+3,3+1,5,x+5,3+1,15+5,3+3,9,a+5,3+2,1b+c,2+1,bb+6,2+5,2d+l,3+6,2+1,2+1,3f+5,4,2+1,2+6,2,21+1,4,2,9o+1,f0c+4,1o+6,t5,1s+3,2a,f5l+1,43t+2,i+7,3+6,v+3,45+2,1j0+1i,5+1d,9,f,n+4,2+e,11t+6,2+g,3+6,2+1,2+4,7a+6,c6+3,15t+6,32+6,gzhy+6n`,AL:`16w,3,2,e+1b,z+2,2+2s,g+1,8+1,b+m,2+t,s+2i,c+e,4h+f,1d+1e,1bwe+dp,3+3z,x+c,2+1,35+3y,2rm+z,5+7,b+5,dt+l,c+u,17nl+27,1t+27,4x+6n,3+d`,LRO:`6ct`,RLO:`6cu`,LRE:`6cq`,RLE:`6cr`,PDF:`6cs`,LRI:`6ee`,RLI:`6ef`,FSI:`6eg`,PDI:`6eh`},n={},r={};n.L=1,r[1]=`L`,Object.keys(t).forEach(function(e,t){n[e]=1<<t+1,r[n[e]]=e}),Object.freeze(n);var i=n.LRI|n.RLI|n.FSI,a=n.L|n.R|n.AL,o=n.B|n.S|n.WS|n.ON|n.FSI|n.LRI|n.RLI|n.PDI,s=n.BN|n.RLE|n.LRE|n.RLO|n.LRO|n.PDF,c=n.S|n.WS|n.B|i|n.PDI|s,l=null;function u(){if(!l){l=new Map;var e=function(e){if(t.hasOwnProperty(e)){var r=0;t[e].split(`,`).forEach(function(t){var i=t.split(`+`),a=i[0],o=i[1];a=parseInt(a,36),o=o?parseInt(o,36):0,l.set(r+=a,n[e]);for(var s=0;s<o;s++)l.set(++r,n[e])})}};for(var r in t)e(r)}}function d(e){return u(),l.get(e.codePointAt(0))||n.L}function f(e){return r[d(e)]}var p={pairs:`14>1,1e>2,u>2,2wt>1,1>1,1ge>1,1wp>1,1j>1,f>1,hm>1,1>1,u>1,u6>1,1>1,+5,28>1,w>1,1>1,+3,b8>1,1>1,+3,1>3,-1>-1,3>1,1>1,+2,1s>1,1>1,x>1,th>1,1>1,+2,db>1,1>1,+3,3>1,1>1,+2,14qm>1,1>1,+1,4q>1,1e>2,u>2,2>1,+1`,canonical:`6f1>-6dx,6dy>-6dx,6ec>-6ed,6ee>-6ed,6ww>2jj,-2ji>2jj,14r4>-1e7l,1e7m>-1e7l,1e7m>-1e5c,1e5d>-1e5b,1e5c>-14qx,14qy>-14qx,14vn>-1ecg,1ech>-1ecg,1edu>-1ecg,1eci>-1ecg,1eda>-1ecg,1eci>-1ecg,1eci>-168q,168r>-168q,168s>-14ye,14yf>-14ye`};function m(e,t){var n=36,r=0,i=new Map,a=t&&new Map,o;return e.split(`,`).forEach(function e(s){if(s.indexOf(`+`)!==-1)for(var c=+s;c--;)e(o);else{o=s;var l=s.split(`>`),u=l[0],d=l[1];u=String.fromCodePoint(r+=parseInt(u,n)),d=String.fromCodePoint(r+=parseInt(d,n)),i.set(u,d),t&&a.set(d,u)}}),{map:i,reverseMap:a}}var h,g,_;function v(){if(!h){var e=m(p.pairs,!0),t=e.map,n=e.reverseMap;h=t,g=n,_=m(p.canonical,!1).map}}function y(e){return v(),h.get(e)||null}function b(e){return v(),g.get(e)||null}function x(e){return v(),_.get(e)||null}var S=n.L,C=n.R,w=n.EN,T=n.ES,E=n.ET,D=n.AN,O=n.CS,ee=n.B,te=n.S,k=n.ON,ne=n.BN,re=n.NSM,ie=n.AL,ae=n.LRO,oe=n.RLO,se=n.LRE,ce=n.RLE,le=n.PDF,ue=n.LRI,de=n.RLI,fe=n.FSI,pe=n.PDI;function A(e,t){for(var n=125,r=new Uint32Array(e.length),l=0;l<e.length;l++)r[l]=d(e[l]);var u=new Map;function f(e,t){var n=r[e];r[e]=t,u.set(n,u.get(n)-1),n&o&&u.set(o,u.get(o)-1),u.set(t,(u.get(t)||0)+1),t&o&&u.set(o,(u.get(o)||0)+1)}for(var p=new Uint8Array(e.length),m=new Map,h=[],g=null,_=0;_<e.length;_++)g||h.push(g={start:_,end:e.length-1,level:t===`rtl`?1:t===`ltr`?0:en(_,!1)}),r[_]&ee&&(g.end=_,g=null);for(var v=ce|se|oe|ae|i|pe|le|ee,A=function(e){return e+(e&1?1:2)},me=function(e){return e+(e&1?2:1)},he=0;he<h.length;he++){g=h[he];var ge=[{_level:g.level,_override:0,_isolate:0}],j=void 0,_e=0,ve=0,ye=0;u.clear();for(var M=g.start;M<=g.end;M++){var be=r[M];if(j=ge[ge.length-1],u.set(be,(u.get(be)||0)+1),be&o&&u.set(o,(u.get(o)||0)+1),be&v)if(be&(ce|se)){p[M]=j._level;var xe=(be===ce?me:A)(j._level);xe<=n&&!_e&&!ve?ge.push({_level:xe,_override:0,_isolate:0}):_e||ve++}else if(be&(oe|ae)){p[M]=j._level;var Se=(be===oe?me:A)(j._level);Se<=n&&!_e&&!ve?ge.push({_level:Se,_override:be&oe?C:S,_isolate:0}):_e||ve++}else if(be&i){be&fe&&(be=en(M+1,!0)===1?de:ue),p[M]=j._level,j._override&&f(M,j._override);var Ce=(be===de?me:A)(j._level);Ce<=n&&_e===0&&ve===0?(ye++,ge.push({_level:Ce,_override:0,_isolate:1,_isolInitIndex:M})):_e++}else if(be&pe){if(_e>0)_e--;else if(ye>0){for(ve=0;!ge[ge.length-1]._isolate;)ge.pop();var we=ge[ge.length-1]._isolInitIndex;we!=null&&(m.set(we,M),m.set(M,we)),ge.pop(),ye--}j=ge[ge.length-1],p[M]=j._level,j._override&&f(M,j._override)}else be&le?(_e===0&&(ve>0?ve--:!j._isolate&&ge.length>1&&(ge.pop(),j=ge[ge.length-1])),p[M]=j._level):be&ee&&(p[M]=g.level);else p[M]=j._level,j._override&&be!==ne&&f(M,j._override)}for(var Te=[],Ee=null,De=g.start;De<=g.end;De++){var Oe=r[De];if(!(Oe&s)){var ke=p[De],Ae=Oe&i,N=Oe===pe;Ee&&ke===Ee._level?(Ee._end=De,Ee._endsWithIsolInit=Ae):Te.push(Ee={_start:De,_end:De,_level:ke,_startsWithPDI:N,_endsWithIsolInit:Ae})}}for(var je=[],Me=0;Me<Te.length;Me++){var P=Te[Me];if(!P._startsWithPDI||P._startsWithPDI&&!m.has(P._start)){for(var Ne=[Ee=P],Pe=void 0;Ee&&Ee._endsWithIsolInit&&(Pe=m.get(Ee._end))!=null;)for(var F=Me+1;F<Te.length;F++)if(Te[F]._start===Pe){Ne.push(Ee=Te[F]);break}for(var Fe=[],Ie=0;Ie<Ne.length;Ie++)for(var Le=Ne[Ie],Re=Le._start;Re<=Le._end;Re++)Fe.push(Re);for(var I=p[Fe[0]],ze=g.level,Be=Fe[0]-1;Be>=0;Be--)if(!(r[Be]&s)){ze=p[Be];break}var Ve=Fe[Fe.length-1],He=p[Ve],Ue=g.level;if(!(r[Ve]&i)){for(var We=Ve+1;We<=g.end;We++)if(!(r[We]&s)){Ue=p[We];break}}je.push({_seqIndices:Fe,_sosType:Math.max(ze,I)%2?C:S,_eosType:Math.max(Ue,He)%2?C:S})}}for(var Ge=0;Ge<je.length;Ge++){var L=je[Ge],R=L._seqIndices,Ke=L._sosType,qe=L._eosType,Je=p[R[0]]&1?C:S;if(u.get(re))for(var Ye=0;Ye<R.length;Ye++){var Xe=R[Ye];if(r[Xe]&re){for(var Ze=Ke,Qe=Ye-1;Qe>=0;Qe--)if(!(r[R[Qe]]&s)){Ze=r[R[Qe]];break}f(Xe,Ze&(i|pe)?k:Ze)}}if(u.get(w))for(var $e=0;$e<R.length;$e++){var et=R[$e];if(r[et]&w)for(var tt=$e-1;tt>=-1;tt--){var nt=tt===-1?Ke:r[R[tt]];if(nt&a){nt===ie&&f(et,D);break}}}if(u.get(ie))for(var rt=0;rt<R.length;rt++){var it=R[rt];r[it]&ie&&f(it,C)}if(u.get(T)||u.get(O))for(var at=1;at<R.length-1;at++){var ot=R[at];if(r[ot]&(T|O)){for(var st=0,ct=0,lt=at-1;lt>=0&&(st=r[R[lt]],st&s);lt--);for(var ut=at+1;ut<R.length&&(ct=r[R[ut]],ct&s);ut++);st===ct&&(r[ot]===T?st===w:st&(w|D))&&f(ot,st)}}if(u.get(w)){for(var dt=0;dt<R.length;dt++)if(r[R[dt]]&w){for(var ft=dt-1;ft>=0&&r[R[ft]]&(E|s);ft--)f(R[ft],w);for(dt++;dt<R.length&&r[R[dt]]&(E|s|w);dt++)r[R[dt]]!==w&&f(R[dt],w)}}if(u.get(E)||u.get(T)||u.get(O))for(var pt=0;pt<R.length;pt++){var mt=R[pt];if(r[mt]&(E|T|O)){f(mt,k);for(var ht=pt-1;ht>=0&&r[R[ht]]&s;ht--)f(R[ht],k);for(var gt=pt+1;gt<R.length&&r[R[gt]]&s;gt++)f(R[gt],k)}}if(u.get(w))for(var _t=0,vt=Ke;_t<R.length;_t++){var yt=R[_t],bt=r[yt];bt&w?vt===S&&f(yt,S):bt&a&&(vt=bt)}if(u.get(o)){for(var xt=C|w|D,z=xt|S,St=[],Ct=[],wt=0;wt<R.length;wt++)if(r[R[wt]]&o){var Tt=e[R[wt]],Et=void 0;if(y(Tt)!==null)if(Ct.length<63)Ct.push({char:Tt,seqIndex:wt});else break;else if((Et=b(Tt))!==null)for(var Dt=Ct.length-1;Dt>=0;Dt--){var Ot=Ct[Dt].char;if(Ot===Et||Ot===b(x(Tt))||y(x(Ot))===Tt){St.push([Ct[Dt].seqIndex,wt]),Ct.length=Dt;break}}}St.sort(function(e,t){return e[0]-t[0]});for(var kt=0;kt<St.length;kt++){for(var At=St[kt],B=At[0],jt=At[1],Mt=!1,Nt=0,Pt=B+1;Pt<jt;Pt++){var Ft=R[Pt];if(r[Ft]&z){Mt=!0;var It=r[Ft]&xt?C:S;if(It===Je){Nt=It;break}}}if(Mt&&!Nt){Nt=Ke;for(var Lt=B-1;Lt>=0;Lt--){var Rt=R[Lt];if(r[Rt]&z){var zt=r[Rt]&xt?C:S;Nt=zt===Je?Je:zt;break}}}if(Nt){if(r[R[B]]=r[R[jt]]=Nt,Nt!==Je){for(var Bt=B+1;Bt<R.length;Bt++)if(!(r[R[Bt]]&s)){d(e[R[Bt]])&re&&(r[R[Bt]]=Nt);break}}if(Nt!==Je){for(var Vt=jt+1;Vt<R.length;Vt++)if(!(r[R[Vt]]&s)){d(e[R[Vt]])&re&&(r[R[Vt]]=Nt);break}}}}for(var Ht=0;Ht<R.length;Ht++)if(r[R[Ht]]&o){for(var Ut=Ht,Wt=Ht,Gt=Ke,Kt=Ht-1;Kt>=0;Kt--)if(r[R[Kt]]&s)Ut=Kt;else{Gt=r[R[Kt]]&xt?C:S;break}for(var qt=qe,Jt=Ht+1;Jt<R.length;Jt++)if(r[R[Jt]]&(o|s))Wt=Jt;else{qt=r[R[Jt]]&xt?C:S;break}for(var Yt=Ut;Yt<=Wt;Yt++)r[R[Yt]]=Gt===qt?Gt:Je;Ht=Wt}}}for(var Xt=g.start;Xt<=g.end;Xt++){var Zt=p[Xt],Qt=r[Xt];if(Zt&1?Qt&(S|w|D)&&p[Xt]++:Qt&C?p[Xt]++:Qt&(D|w)&&(p[Xt]+=2),Qt&s&&(p[Xt]=Xt===0?g.level:p[Xt-1]),Xt===g.end||d(e[Xt])&(te|ee))for(var $t=Xt;$t>=0&&d(e[$t])&c;$t--)p[$t]=g.level}}return{levels:p,paragraphs:h};function en(t,n){for(var a=t;a<e.length;a++){var o=r[a];if(o&(C|ie))return 1;if(o&(ee|S)||n&&o===pe)return 0;if(o&i){var s=tn(a);a=s===-1?e.length:s}}return 0}function tn(t){for(var n=1,a=t+1;a<e.length;a++){var o=r[a];if(o&ee)break;if(o&pe){if(--n===0)return a}else o&i&&n++}return-1}}var me=`14>1,j>2,t>2,u>2,1a>g,2v3>1,1>1,1ge>1,1wd>1,b>1,1j>1,f>1,ai>3,-2>3,+1,8>1k0,-1jq>1y7,-1y6>1hf,-1he>1h6,-1h5>1ha,-1h8>1qi,-1pu>1,6>3u,-3s>7,6>1,1>1,f>1,1>1,+2,3>1,1>1,+13,4>1,1>1,6>1eo,-1ee>1,3>1mg,-1me>1mk,-1mj>1mi,-1mg>1mi,-1md>1,1>1,+2,1>10k,-103>1,1>1,4>1,5>1,1>1,+10,3>1,1>8,-7>8,+1,-6>7,+1,a>1,1>1,u>1,u6>1,1>1,+5,26>1,1>1,2>1,2>2,8>1,7>1,4>1,1>1,+5,b8>1,1>1,+3,1>3,-2>1,2>1,1>1,+2,c>1,3>1,1>1,+2,h>1,3>1,a>1,1>1,2>1,3>1,1>1,d>1,f>1,3>1,1a>1,1>1,6>1,7>1,13>1,k>1,1>1,+19,4>1,1>1,+2,2>1,1>1,+18,m>1,a>1,1>1,lk>1,1>1,4>1,2>1,f>1,3>1,1>1,+3,db>1,1>1,+3,3>1,1>1,+2,14qm>1,1>1,+1,6>1,4j>1,j>2,t>2,u>2,2>1,+1`,he;function ge(){if(!he){var e=m(me,!0),t=e.map;e.reverseMap.forEach(function(e,n){t.set(n,e)}),he=t}}function j(e){return ge(),he.get(e)||null}function _e(e,t,n,r){var i=e.length;n=Math.max(0,n==null?0:+n),r=Math.min(i-1,r==null?i-1:+r);for(var a=new Map,o=n;o<=r;o++)if(t[o]&1){var s=j(e[o]);s!==null&&a.set(o,s)}return a}function ve(e,t,n,r){var i=e.length;n=Math.max(0,n==null?0:+n),r=Math.min(i-1,r==null?i-1:+r);var a=[];return t.paragraphs.forEach(function(i){var o=Math.max(n,i.start),s=Math.min(r,i.end);if(o<s){for(var l=t.levels.slice(o,s+1),u=s;u>=o&&d(e[u])&c;u--)l[u]=i.level;for(var f=i.level,p=1/0,m=0;m<l.length;m++){var h=l[m];h>f&&(f=h),h<p&&(p=h|1)}for(var g=f;g>=p;g--)for(var _=0;_<l.length;_++)if(l[_]>=g){for(var v=_;_+1<l.length&&l[_+1]>=g;)_++;_>v&&a.push([v+o,_+o])}}}),a}function ye(e,t,n,r){var i=M(e,t,n,r),a=[].concat(e);return i.forEach(function(n,r){a[r]=(t.levels[n]&1?j(e[n]):null)||e[n]}),a.join(``)}function M(e,t,n,r){for(var i=ve(e,t,n,r),a=[],o=0;o<e.length;o++)a[o]=o;return i.forEach(function(e){for(var t=e[0],n=e[1],r=a.slice(t,n+1),i=r.length;i--;)a[n-i]=r[i]}),a}return e.closingToOpeningBracket=b,e.getBidiCharType=d,e.getBidiCharTypeName=f,e.getCanonicalBracket=x,e.getEmbeddingLevels=A,e.getMirroredCharacter=j,e.getMirroredCharactersMap=_e,e.getReorderSegments=ve,e.getReorderedIndices=M,e.getReorderedString=ye,e.openingToClosingBracket=y,Object.defineProperty(e,`__esModule`,{value:!0}),e}({})}var Zp=t((()=>{}));function Qp(){return am===void 0&&(am=process.platform===`win32`||typeof process.env.WT_SESSION==`string`||process.env.TERM_PROGRAM===`vscode`),am}function $p(){return im||(im=Xp()),im}function em(e){if(!Qp()||e.length===0)return e;let t=e.map(e=>e.value).join(``);if(!rm(t))return e;let{levels:n}=$p().getEmbeddingLevels(t,`auto`),r=[],i=0;for(let t=0;t<e.length;t++)r.push(n[i]),i+=e[t].value.length;let a=[...e],o=Math.max(...r);for(let e=o;e>=1;e--){let t=0;for(;t<a.length;)if(r[t]>=e){let n=t+1;for(;n<a.length&&r[n]>=e;)n++;tm(a,t,n-1),nm(r,t,n-1),t=n}else t++}return a}function tm(e,t,n){for(;t<n;){let r=e[t];e[t]=e[n],e[n]=r,t++,n--}}function nm(e,t,n){for(;t<n;){let r=e[t];e[t]=e[n],e[n]=r,t++,n--}}function rm(e){return/[\u0590-\u05FF\uFB1D-\uFB4F\u0600-\u06FF\u0750-\u077F\u08A0-\u08FF\uFB50-\uFDFF\uFE70-\uFEFF\u0780-\u07BF\u0700-\u074F]/u.test(e)}var im,am,om=t((()=>{Zp()}));function sm(e){let t=0,n=0;for(;n<=e.length;){let r=e.indexOf(`
36
+ `,n),i=r===-1?e.substring(n):e.substring(n,r);if(t=Math.max(t,ba(i)),r===-1)break;n=r+1}return t}var cm=t((()=>{Ca()}));function lm(e,t){return e?{x1:um(e.x1,t.x1),x2:dm(e.x2,t.x2),y1:um(e.y1,t.y1),y2:dm(e.y2,t.y2)}:t}function um(e,t){return e===void 0?t:t===void 0?e:Math.max(e,t)}function dm(e,t){return e===void 0?t:t===void 0?e:Math.min(e,t)}function fm(e,t){if(e===t)return!0;let n=e.length;if(n!==t.length)return!1;if(n===0)return!0;for(let r=0;r<n;r++)if(e[r].code!==t[r].code)return!1;return!0}function pm(e,t){let n=e.length;if(n===0)return[];let r=[],i=[],a=e[0].styles;for(let o=0;o<n;o++){let n=e[o],s=n.styles;i.length>0&&!fm(s,a)&&(mm(i.join(``),a,t,r),i.length=0),i.push(n.value),a=s}return i.length>0&&mm(i.join(``),a,t,r),r}function mm(e,t,n,r){let i=Xl(t)??void 0,a=i!==void 0||t.some(e=>e.code.length>=Su.length&&e.code.startsWith(Su))?Zl(t):t,o=n.intern(a);for(let{segment:t}of ca().segment(e))r.push({value:t,width:va(t),styleId:o,hyperlink:i})}function hm(e,t,n,r,i,a,o){let s=o.get(t);s||(s=em(pm(To(Io(t)),a)),o.set(t,s));let c=n;for(let t=0;t<s.length;t++){let n=s[t],o=n.value.codePointAt(0);if(o!==void 0&&o<=31){if(o===9){let t=8-c%8;for(let n=0;n<t&&c<i;n++)Gl(e,c,r,{char:` `,styleId:a.none,width:J.Narrow,hyperlink:void 0}),c++}else if(o===27){let e=s[t+1]?.value,n=e?.codePointAt(0);if(e===`(`||e===`)`||e===`*`||e===`+`)t+=2;else if(e===`[`)for(t++;t<s.length-1;){t++;let e=s[t]?.value.codePointAt(0);if(e!==void 0&&e>=64&&e<=126)break}else if(e===`]`||e===`P`||e===`_`||e===`^`||e===`X`)for(t++;t<s.length-1;){t++;let e=s[t]?.value;if(e===`\x07`)break;if(e===`\x1B`&&s[t+1]?.value===`\\`){t++;break}}else n!==void 0&&n>=48&&n<=126&&t++}continue}let l=n.width;if(l===0)continue;let u=l>=2;if(u&&c+2>i){Gl(e,c,r,{char:` `,styleId:a.none,width:J.SpacerHead,hyperlink:void 0}),c++;continue}Gl(e,c,r,{char:n.value,styleId:n.styleId,width:u?J.Wide:J.Narrow,hyperlink:n.hyperlink}),c+=u?2:1}return c}var gm,_m,vm=t((()=>{zo(),ua(),Uo(),c(),om(),Ol(),Cu(),ya(),cm(),gm=e=>{},_m=class{constructor(e){l(this,`width`,void 0),l(this,`height`,void 0),l(this,`stylePool`,void 0),l(this,`screen`,void 0),l(this,`operations`,[]),l(this,`charCache`,new Map);let{width:t,height:n,stylePool:r,screen:i}=e;this.width=t,this.height=n,this.stylePool=r,this.screen=i,zl(i,t,n)}reset(e,t,n){this.width=e,this.height=t,this.screen=n,this.operations.length=0,zl(n,e,t),this.charCache.size>16384&&this.charCache.clear()}blit(e,t,n,r,i){this.operations.push({type:`blit`,src:e,x:t,y:n,width:r,height:i})}shift(e,t,n){this.operations.push({type:`shift`,top:e,bottom:t,n})}clear(e,t){this.operations.push({type:`clear`,region:e,fromAbsolute:t})}noSelect(e){this.operations.push({type:`noSelect`,region:e})}write(e,t,n,r){n&&this.operations.push({type:`write`,x:e,y:t,text:n,softWrap:r})}clip(e){this.operations.push({type:`clip`,clip:e})}unclip(){this.operations.push({type:`unclip`})}get(){let e=this.screen,t=this.width,n=this.height,r=0,i=0,a=[];for(let r of this.operations){if(r.type!==`clear`)continue;let{x:i,y:o,width:s,height:c}=r.region,l=Math.max(0,i),u=Math.max(0,o),d=Math.min(i+s,t),f=Math.min(o+c,n);if(l>=d||u>=f)continue;let p={x:l,y:u,width:d-l,height:f-u};e.damage=e.damage?El(e.damage,p):p,r.fromAbsolute&&a.push(p)}let o=[];for(let s of this.operations)switch(s.type){case`clear`:continue;case`clip`:o.push(lm(o.at(-1),s.clip));continue;case`unclip`:o.pop();continue;case`blit`:{let{src:i,x:c,y:l,width:u,height:d}=s,f=o.at(-1),p=Math.max(c,f?.x1??0),m=Math.max(l,f?.y1??0),h=Math.min(l+d,n,i.height,f?.y2??1/0),g=Math.min(c+u,t,i.width,f?.x2??1/0);if(p>=g||m>=h)continue;if(a.length===0){Jl(e,i,p,m,g,h),r+=(h-m)*(g-p);continue}let _=m;for(let t=m;t<=h;t++)(t<h&&a.some(e=>t>=e.y&&t<e.y+e.height&&p>=e.x&&g<=e.x+e.width)||t===h)&&(t>_&&(Jl(e,i,p,_,g,t),r+=(t-_)*(g-p)),_=t+1);continue}case`shift`:Yl(e,s.top,s.bottom,s.n);continue;case`write`:{let{text:r,softWrap:a}=s,{x:c,y:l}=s,u=r.split(`
37
+ `),d=0,f=0,p=o.at(-1);if(p){let e=typeof p?.x1==`number`&&typeof p?.x2==`number`,t=typeof p?.y1==`number`&&typeof p?.y2==`number`;if(e){let e=sm(r);if(c+e<=p.x1||c>=p.x2)continue}if(t){let e=u.length;if(l+e<=p.y1||l>=p.y2)continue}if(e&&(u=u.map(e=>{let t=c<p.x1?p.x1-c:0,n=va(e),r=c+n>p.x2?p.x2-c:n,i=Ho(e,t,r);return va(i)>r-t&&(i=Ho(e,t,r-1)),i}),c<p.x1&&(c=p.x1)),t){let e=l<p.y1?p.y1-l:0,t=u.length,n=l+t>p.y2?p.y2-l:t;a&&e>0&&a[e]===!0&&(f=c+va(u[e-1])),u=u.slice(e,n),d=e,l<p.y1&&(l=p.y1)}}let m=e.softWrap,h=0;for(let r of u){let o=l+h;if(o>=n)break;let s=hm(e,r,c,o,t,this.stylePool,this.charCache);i+=s-c,a&&(m[o]=a[d+h]===!0?f:0,f=s),h++}continue}}for(let t of this.operations)if(t.type===`noSelect`){let{x:n,y:r,width:i,height:a}=t.region;au(e,n,r,i,a)}let s=r+i;return s>1e3&&i>r&&gm(`High write ratio: blit=${r}, write=${i} (${(i/s*100).toFixed(1)}% writes), screen=${n}x${t}`),e}}}));function ym(e,t=1,n={}){let{indent:r=` `,includeEmptyLines:i=!1}=n;if(typeof e!=`string`)throw TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof e}\``);if(typeof t!=`number`)throw TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof t}\``);if(t<0)throw RangeError(`Expected \`count\` to be at least 0, got \`${t}\``);if(typeof r!=`string`)throw TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof r}\``);if(t===0)return e;let a=i?/^/gm:/^(?!\s*$)/gm;return e.replace(a,r.repeat(t))}var bm=t((()=>{})),xm,Sm=t((()=>{Ci(),xm=e=>e.getComputedWidth()-e.getComputedPadding(H.Left)-e.getComputedPadding(H.Right)-e.getComputedBorder(H.Left)-e.getComputedBorder(H.Right)})),Cm,wm,Tm,Em,Dm,Om,km,Am,jm,Mm=t((()=>{Cm={topLeft:`┌`,top:`─`,topRight:`┐`,right:`│`,bottomRight:`┘`,bottom:`─`,bottomLeft:`└`,left:`│`},wm={topLeft:`╔`,top:`═`,topRight:`╗`,right:`║`,bottomRight:`╝`,bottom:`═`,bottomLeft:`╚`,left:`║`},Tm={topLeft:`╭`,top:`─`,topRight:`╮`,right:`│`,bottomRight:`╯`,bottom:`─`,bottomLeft:`╰`,left:`│`},Em={topLeft:`┏`,top:`━`,topRight:`┓`,right:`┃`,bottomRight:`┛`,bottom:`━`,bottomLeft:`┗`,left:`┃`},Dm={topLeft:`╓`,top:`─`,topRight:`╖`,right:`║`,bottomRight:`╜`,bottom:`─`,bottomLeft:`╙`,left:`║`},Om={topLeft:`╒`,top:`═`,topRight:`╕`,right:`│`,bottomRight:`╛`,bottom:`═`,bottomLeft:`╘`,left:`│`},km={topLeft:`+`,top:`-`,topRight:`+`,right:`|`,bottomRight:`+`,bottom:`-`,bottomLeft:`+`,left:`|`},Am={topLeft:`↘`,top:`↓`,topRight:`↙`,right:`←`,bottomRight:`↖`,bottom:`↑`,bottomLeft:`↗`,left:`→`},jm={single:Cm,double:wm,round:Tm,bold:Em,singleDouble:Dm,doubleSingle:Om,classic:km,arrow:Am}})),Nm,Pm=t((()=>{Mm(),Nm=jm}));function Fm(e,t,n,r=0,i){let a=va(t),o=e.length;if(a>=o-2)return[``,t.substring(0,o),``];let s;return s=n===`center`?Math.floor((o-a)/2):n===`start`?r+1:o-a-r-1,s=Math.max(1,Math.min(s,o-a-1)),[e.substring(0,1)+i.repeat(s-1),t,i.repeat(o-s-a-1)+e.substring(o-1)]}function Im(e,t,n){let r=Nn(e,t);return n&&(r=V.dim(r)),r}var Lm,Rm,zm=t((()=>{kn(),Pm(),Ln(),ya(),Lm={dashed:{top:`╌`,left:`╎`,right:`╎`,bottom:`╌`,topLeft:` `,topRight:` `,bottomLeft:` `,bottomRight:` `}},Rm=(e,t,n,r)=>{if(n.style.borderStyle){let i=Math.floor(n.yogaNode.getComputedWidth()),a=Math.floor(n.yogaNode.getComputedHeight()),o=typeof n.style.borderStyle==`string`?Lm[n.style.borderStyle]??Nm[n.style.borderStyle]:n.style.borderStyle,s=n.style.borderTopColor??n.style.borderColor,c=n.style.borderBottomColor??n.style.borderColor,l=n.style.borderLeftColor??n.style.borderColor,u=n.style.borderRightColor??n.style.borderColor,d=n.style.borderTopDimColor??n.style.borderDimColor,f=n.style.borderBottomDimColor??n.style.borderDimColor,p=n.style.borderLeftDimColor??n.style.borderDimColor,m=n.style.borderRightDimColor??n.style.borderDimColor,h=n.style.borderTop!==!1,g=n.style.borderBottom!==!1,_=n.style.borderLeft!==!1,v=n.style.borderRight!==!1,y=Math.max(0,i-+!!_-!!v),b=h?(_?o.topLeft:``)+o.top.repeat(y)+(v?o.topRight:``):``,x;if(h&&n.style.borderText?.position===`top`){let[e,t,r]=Fm(b,n.style.borderText.content,n.style.borderText.align,n.style.borderText.offset,o.top);x=Im(e,s,d)+t+Im(r,s,d)}else h&&(x=Im(b,s,d));let S=a;h&&--S,g&&--S,S=Math.max(0,S);let C=(Nn(o.left,l)+`
38
+ `).repeat(S);p&&(C=V.dim(C));let w=(Nn(o.right,u)+`
39
+ `).repeat(S);m&&(w=V.dim(w));let T=g?(_?o.bottomLeft:``)+o.bottom.repeat(y)+(v?o.bottomRight:``):``,E;if(g&&n.style.borderText?.position===`bottom`){let[e,t,r]=Fm(T,n.style.borderText.content,n.style.borderText.align,n.style.borderText.offset,o.bottom);E=Im(e,c,f)+t+Im(r,c,f)}else g&&(E=Im(T,c,f));let D=+!!h;x&&r.write(e,t,x),_&&r.write(e,t+D,C),v&&r.write(e+i-1,t+D,w),E&&r.write(e,t+a-1,E)}}}));function Bm(){return process.env.TERM_PROGRAM===`vscode`||Gd()}function Vm(){ch=!1}function Hm(){return ch}function Um(){lh=null,uh=dh,dh=[]}function Wm(){return lh}function Gm(){fh=null}function Km(){return fh}function qm(){let e=ph;return ph=null,e}function Jm(e,t,n){let r=t>0?1:-1,i=Math.abs(t),a=0;i>yh&&(a+=r*(i-yh),i=yh);let o=i<=hh?i:i<gh?_h:vh;a+=r*o;let s=i-o,c=Math.max(1,n-1),l=Math.abs(a);return l>c?(e.pendingScrollDelta=r*(s+(l-c)),r*c):(e.pendingScrollDelta=s>0?r*s:void 0,a)}function Ym(e,t,n){let r=Math.abs(t),i=Math.max(1,n-1),a=Math.min(i,Math.max(mh,r*3>>2));if(r<=a)return e.pendingScrollDelta=void 0,t;let o=t>0?a:-a;return e.pendingScrollDelta=t-o,o}function Xm(e,t){return`${bh}8;;${t}${xh}${e}${bh}8;;${xh}`}function Zm(e){let t=[];for(let n=0;n<e.length;n++){let r=e[n].text.length;for(let e=0;e<r;e++)t.push(n)}return t}function Qm(e,t,n,r,i=!1){let a=e.split(`
40
+ `),o=[],s=0;for(let e=0;e<a.length;e++){let c=a[e];if(i&&c.length>0){let e=/\s/.test(c[0]);if(s<r.length&&/\s/.test(r[s])&&!e)for(;s<r.length&&/\s/.test(r[s]);)s++}let l=``,u=0,d=n[s]??0;for(let e=0;e<c.length;e++){let r=n[s]??d;if(r!==d){let n=c.slice(u,e),i=t[d];if(i){let e=Mn(n,i.styles);i.hyperlink&&(e=Xm(e,i.hyperlink)),l+=e}else l+=n;u=e,d=r}s++}let f=c.slice(u),p=t[d];if(p){let e=Mn(f,p.styles);p.hyperlink&&(e=Xm(e,p.hyperlink)),l+=e}else l+=f;if(o.push(l),s<r.length&&r[s]===`
41
+ `&&s++,i&&e<a.length-1){let t=a[e+1],n=t.length>0?t[0]:null;for(;s<r.length&&/\s/.test(r[s])&&!(n!==null&&r[s]===n);)s++}}return o.join(`
42
+ `)}function $m(e,t,n){if(n!==`wrap`&&n!==`wrap-trim`)return{wrapped:Xs(e,t,n),softWrap:void 0};let r=e.split(`
43
+ `),i=[],a=[];for(let e of r){let r=Xs(e,t,n).split(`
44
+ `);for(let e=0;e<r.length;e++)i.push(r[e]),a.push(e>0)}return{wrapped:i.join(`
45
+ `),softWrap:a}}function eh(e,t,n){let r=e.childNodes[0]?.yogaNode;if(r){let e=r.getComputedLeft(),i=r.getComputedTop();t=`
46
+ `.repeat(i)+ym(t,e),n&&i>0&&n.unshift(...Array(i).fill(!1))}return t}function th(e,t,{offsetX:n=0,offsetY:r=0,prevScreen:i,skipSelfBlit:a=!1,inheritedBackgroundColor:o}){let{yogaNode:s}=e;if(s){if(s.getDisplay()===hi.None){if(e.dirty){let n=W.get(e);n&&(t.clear({x:Math.floor(n.x),y:Math.floor(n.y),width:Math.floor(n.width),height:Math.floor(n.height)}),sh(e),ch=!0)}return}let c=n+s.getComputedLeft(),l=s.getComputedTop(),u=r+l,d=s.getComputedWidth(),f=s.getComputedHeight();u<0&&e.style.position===`absolute`&&(u=0);let p=W.get(e);if(!e.dirty&&!a&&e.pendingScrollDelta===void 0&&p&&p.x===c&&p.y===u&&p.width===d&&p.height===f&&i){let n=Math.floor(c),r=Math.floor(u),a=Math.floor(d),o=Math.floor(f);t.blit(i,n,r,a,o),e.style.position===`absolute`&&dh.push(p),ah(e,t,i,n,r,a,o);return}let m=p!==void 0&&(p.x!==c||p.y!==u||p.width!==d||p.height!==f);m&&(ch=!0),p&&(e.dirty||m)&&t.clear({x:Math.floor(p.x),y:Math.floor(p.y),width:Math.floor(p.width),height:Math.floor(p.height)},e.style.position===`absolute`);let h=Oa.get(e),g=h!==void 0;if(g){ch=!0;for(let e of h)t.clear({x:Math.floor(e.x),y:Math.floor(e.y),width:Math.floor(e.width),height:Math.floor(e.height)});Oa.delete(e)}if(f===0&&ih(e,s)){W.set(e,{x:c,y:u,width:d,height:f,top:l}),e.dirty=!1;return}if(e.nodeName===`ink-raw-ansi`){let n=e.attributes.rawText;n&&t.write(c,u,n)}else if(e.nodeName===`ink-text`){let n=ja(e,o?{backgroundColor:o}:void 0),r=n.map(e=>e.text).join(``);if(r.length>0){let i=Math.min(xm(s),t.width-c),a=e.style.textWrap??`wrap`,o=sm(r)>i,l,d;if(o&&n.length===1){let e=n[0],t=$m(r,i,a);d=t.softWrap,l=t.wrapped.split(`
47
+ `).map(t=>{let n=Mn(t,e.styles);return e.hyperlink&&(n=Xm(n,e.hyperlink)),n}).join(`
48
+ `)}else if(o){let e=$m(r,i,a);d=e.softWrap;let t=Zm(n);l=Qm(e.wrapped,n,t,r,a===`wrap-trim`)}else l=n.map(e=>{let t=Mn(e.text,e.styles);return e.hyperlink&&(t=Xm(t,e.hyperlink)),t}).join(``);l=eh(e,l,d),t.write(c,u,l,d)}}else if(e.nodeName===`ink-box`){let n=e.style.backgroundColor??o;if(e.style.noSelect){let n=Math.floor(c),r=e.style.noSelect===`from-left-edge`;t.noSelect({x:r?0:n,y:Math.floor(u),width:r?n+Math.floor(d):Math.floor(d),height:Math.floor(f)})}let r=e.style.overflowX??e.style.overflow,a=e.style.overflowY??e.style.overflow,l=r===`hidden`||r===`scroll`,h=a===`hidden`||a===`scroll`,_=a===`scroll`,v=l||h,y,b;if(v){let e=l?c+s.getComputedBorder(H.Left):void 0,n=l?c+s.getComputedWidth()-s.getComputedBorder(H.Right):void 0;y=h?u+s.getComputedBorder(H.Top):void 0,b=h?u+s.getComputedHeight()-s.getComputedBorder(H.Bottom):void 0,t.clip({x1:e,x2:n,y1:y,y2:b})}if(_){let r=s.getComputedPadding(H.Top),a=Math.max(0,(b??u+f)-(y??u)-r-s.getComputedPadding(H.Bottom)),o=e.childNodes.find(e=>e.yogaNode),l=o?.yogaNode,h=l?.getComputedHeight()??0,_=e.scrollHeight??h,v=e.scrollViewportHeight??a;e.scrollHeight=h,e.scrollViewportHeight=a,e.scrollViewportTop=(y??u)+r;let x=Math.max(0,h-a);if(e.scrollAnchor){let t=e.scrollAnchor.el.yogaNode?.getComputedTop();t!=null&&(e.scrollTop=t+e.scrollAnchor.offset,e.pendingScrollDelta=void 0),e.scrollAnchor=void 0}let S=e.scrollTop??0,C=e.stickyScroll??!!e.attributes.stickyScroll,w=Math.max(0,_-v);(C||h>=_&&S>=w)&&(e.pendingScrollDelta??0)>=0&&(e.scrollTop=x,e.pendingScrollDelta=void 0,e.stickyScroll===!1&&S>=w&&(e.stickyScroll=!0));let T=(e.scrollTop??0)-S;if(T>0){let t=e.scrollViewportTop??0;ph={delta:T,viewportTop:t,viewportBottom:t+a-1}}let E=e.scrollTop??0,D=e.pendingScrollDelta,O=e.scrollClampMin,ee=e.scrollClampMax,te=O!==void 0&&ee!==void 0;if(D!==void 0&&D!==0){let t=te&&(D<0&&E<O||D>0&&E>ee)?Math.min(4,a>>3):a;E+=Bm()?Jm(e,D,t):Ym(e,D,t)}else D===0&&(e.pendingScrollDelta=void 0);let k=Math.max(0,Math.min(E,x)),ne=te?Math.max(O,Math.min(k,ee)):k;if(e.scrollTop=k,k!==E&&(e.pendingScrollDelta=void 0),e.pendingScrollDelta!==void 0&&(fh=e),k=ne,o&&l){let e=c+l.getComputedLeft(),s=u+l.getComputedTop()-k,h=W.get(o),_=null;if(h&&h.y!==s){let e=h.y-s,t=Math.floor(u+l.getComputedTop()),n=t+a-1;p?.y===u&&p.height===f&&a>0&&Math.abs(e)<a?(_={top:t,bottom:n,delta:e},lh=_):ch=!0}let v=l.getComputedHeight(),x=v-(h?.height??v),S=!_||x===0||_.delta>0&&x===_.delta;if(S||(lh=null),_&&i&&S){let{top:l,bottom:f,delta:p}=_,m=Math.floor(d);t.blit(i,Math.floor(c),l,m,f-l+1),t.shift(l,f,p);let h=p>0?f-p+1:l,v=p>0?f:l-p-1;t.clear({x:Math.floor(c),y:h,width:m,height:v-h+1}),t.clip({x1:void 0,x2:void 0,y1:h,y2:v+1});let b=o.dirty?new Set(o.childNodes.filter(e=>e.dirty)):null;if(oh(o,t,e,s,g,void 0,h-s,v+1-s,n,!0),t.unclip(),b){let i=h-s,l=v+1-s,d=` `.repeat(m),f=0;for(let m of o.childNodes){let o=m,h=b.has(m);if(!h&&f===0&&W.has(o))continue;let g=o.yogaNode;if(!g)continue;let _=g.getComputedTop(),v=g.getComputedHeight(),x=_+v;if(h){let e=W.get(o);f+=v-(e?e.height:0)}if(x<=k||_>=k+a||_>=i&&x<=l)continue;let S=Math.floor(s+_);if(!h){let e=W.get(o);if(e&&Math.floor(e.y)-p===S)continue}let C=Math.min(Math.floor(s+x),Math.floor((y??u)+r+a));if(S<C){let r=Array(C-S).fill(d).join(`
49
+ `);t.write(Math.floor(c),S,r),t.clip({x1:void 0,x2:void 0,y1:S,y2:C}),th(o,t,{offsetX:e,offsetY:s,prevScreen:void 0,inheritedBackgroundColor:n}),t.unclip()}}}let x=uh.length?` `.repeat(m):``;for(let r of uh){if(r.y>=f+1||r.y+r.height<=l)continue;let i=Math.max(l,Math.floor(r.y)-p),a=Math.min(f+1,Math.floor(r.y+r.height)-p);if(i>=h&&a<=v+1||i>=a)continue;let u=Array(a-i).fill(x).join(`
50
+ `);t.write(Math.floor(c),i,u),t.clip({x1:void 0,x2:void 0,y1:i,y2:a}),oh(o,t,e,s,g,void 0,i-s,a-s,n,!0),t.unclip()}}else{let r=h&&h.y!==s;r&&y!==void 0&&b!==void 0&&t.clear({x:Math.floor(c),y:Math.floor(y),width:Math.floor(d),height:Math.floor(b-y)}),oh(o,t,e,s,g,r||m?void 0:i,k,k+a,n)}W.set(o,{x:e,y:s,width:l.getComputedWidth(),height:l.getComputedHeight()}),o.dirty=!1}}else{let r=e.style.backgroundColor;if(r||e.style.opaque){let e=s.getComputedBorder(H.Left),n=s.getComputedBorder(H.Right),i=s.getComputedBorder(H.Top),a=s.getComputedBorder(H.Bottom),o=Math.floor(d)-e-n,l=Math.floor(f)-i-a;if(o>0&&l>0){let n=` `.repeat(o),a=r?Mn(n,{backgroundColor:r}):n,s=Array(l).fill(a).join(`
51
+ `);t.write(c+e,u+i,s)}}nh(e,t,c,u,g,r||e.style.opaque?void 0:i,n)}v&&t.unclip(),Rm(c,u,e,t)}else e.nodeName===`ink-root`&&nh(e,t,c,u,g,i,o);let _={x:c,y:u,width:d,height:f,top:l};W.set(e,_),e.style.position===`absolute`&&dh.push(_),e.dirty=!1}}function nh(e,t,n,r,i,a,o){let s=!1,c=!1;for(let l of e.childNodes){let e=l,u=e.dirty,d=e.style.position===`absolute`;th(e,t,{offsetX:n,offsetY:r,prevScreen:i||s?void 0:a,skipSelfBlit:c&&d&&!e.style.opaque&&e.style.backgroundColor===void 0,inheritedBackgroundColor:o}),u&&!s&&(!rh(e)||d?s=!0:c=!0)}}function rh(e){let t=e.style.overflowX??e.style.overflow,n=e.style.overflowY??e.style.overflow;return(t===`hidden`||t===`scroll`)&&(n===`hidden`||n===`scroll`)}function ih(e,t){let n=e.parentNode;if(!n)return!1;let r=t.getComputedTop(),i=n.childNodes,a=i.indexOf(e);for(let e=a+1;e<i.length;e++){let t=i[e].yogaNode;if(t)return t.getComputedTop()===r}for(let e=a-1;e>=0;e--){let t=i[e].yogaNode;if(t)return t.getComputedTop()===r}return!1}function ah(e,t,n,r,i,a,o){let s=r+a,c=i+o;for(let l of e.childNodes){if(l.nodeName===`#text`)continue;let e=l;if(e.style.position===`absolute`){let a=W.get(e);if(a){dh.push(a);let e=Math.floor(a.x),o=Math.floor(a.y),l=Math.floor(a.width),u=Math.floor(a.height);(e<r||o<i||e+l>s||o+u>c)&&t.blit(n,e,o,l,u)}}ah(e,t,n,r,i,a,o)}}function oh(e,t,n,r,i,a,o,s,c,l=!1){let u=!1,d=0;for(let f of e.childNodes){let e=f,p=e.yogaNode;if(p){let t=W.get(e),n,r;if(t?.top!==void 0&&!e.dirty&&d===0?(n=t.top,r=t.height):(n=p.getComputedTop(),r=p.getComputedHeight(),e.dirty&&(d+=r-(t?t.height:0)),t&&(t.top=n)),n+r<=o||n>=s){l||sh(e);continue}}let m=e.dirty;th(e,t,{offsetX:n,offsetY:r,prevScreen:i||u?void 0:a,inheritedBackgroundColor:c}),m&&(u=!0)}}function sh(e){W.delete(e);for(let t of e.childNodes)t.nodeName!==`#text`&&sh(t)}var ch,lh,uh,dh,fh,ph,mh,hh,gh,_h,vh,yh,bh,xh,Sh=t((()=>{bm(),Ln(),Sm(),Ci(),Aa(),zm(),Na(),$d(),cm(),Qs(),ch=!1,lh=null,uh=[],dh=[],fh=null,ph=null,mh=4,hh=5,gh=12,_h=2,vh=3,yh=30,bh=`\x1B]`,xh=`\x07`}));function Ch(e,t){let n=t.toLowerCase();if(!n)return[];let r=n.length,i=e.width,a=e.height,o=e.noSelect,s=[],c=performance.now();for(let t=0;t<a;t++){let a=t*i,c=``,l=[],u=[];for(let t=0;t<i;t++){let n=a+t,r=Hl(e,n);if(r.width===J.SpacerTail||r.width===J.SpacerHead||o[n]===1)continue;let i=r.char.toLowerCase(),s=l.length;for(let e=0;e<i.length;e++)u.push(s);c+=i,l.push(t)}let d=c.indexOf(n);for(;d>=0;){let e=u[d],i=u[d+r-1],a=l[e],o=l[i]+1;s.push({row:t,col:a,len:o-a}),d=c.indexOf(n,d+r)}}return Th.scan+=performance.now()-c,s}function wh(e,t,n,r,i){if(i<0||i>=n.length)return!1;let a=n[i],o=a.row+r;if(o<0||o>=e.height)return!1;let s=e=>t.withCurrentMatch(e),c=o*e.width;for(let t=a.col;t<a.col+a.len;t++){if(t<0||t>=e.width)continue;let n=Hl(e,c+t);Kl(e,t,o,s(n.styleId))}return!0}var Th,Eh=t((()=>{Me(),vc(),vm(),Tl(),Sh(),Cu(),Th={reconcile:0,yoga:0,paint:0,scan:0,calls:0}}));function Dh(e,t){let n;return r=>{let{frontFrame:i,backFrame:a,isTTY:o,terminalWidth:s,terminalRows:c}=r,l=i.screen,u=a.screen,d=u.charPool,f=u.hyperlinkPool,p=e.yogaNode?.getComputedHeight(),m=e.yogaNode?.getComputedWidth(),h=p===void 0||!Number.isFinite(p)||p<0,g=m===void 0||!Number.isFinite(m)||m<0;if(!e.yogaNode||h||g)return e.yogaNode&&(h||g)&&Oh(`Invalid yoga dimensions: width=${m}, height=${p}, childNodes=${e.childNodes.length}, terminalWidth=${s}, terminalRows=${c}`),{screen:Rl(s,0,t,d,f),viewport:{width:s,height:c},cursor:{x:0,y:0,visible:!0}};let _=Math.floor(e.yogaNode.getComputedWidth()),v=Math.floor(e.yogaNode.getComputedHeight()),y=r.altScreen?c:v;r.altScreen&&v>c&&Oh(`alt-screen: yoga height ${v} > terminalRows ${c} — something is rendering outside <AlternateScreen>. Overflow clipped.`,{level:`warn`});let b=u??Rl(_,y,t,d,f);n?n.reset(_,y,b):n=new _m({width:_,height:y,stylePool:t,screen:b}),Vm(),Um(),Gm();let x=Da();th(e,n,{prevScreen:x||r.prevFrameContaminated?void 0:l});let S=n.get(),C=Km();return C&&mc(C),{scrollHint:r.altScreen?Wm():null,scrollDrainPending:C!==null,screen:S,viewport:{width:s,height:r.altScreen?c+1:c},cursor:{x:0,y:r.altScreen?Math.max(0,Math.min(b.height,c)-1):b.height,visible:!o||b.height===0}}}}var Oh,kh=t((()=>{vc(),Aa(),vm(),Sh(),Cu(),Oh=(e,t)=>{}}));function Ah(e,t,n){if(!t)return!1;let r=t.toLowerCase(),i=r.length,a=e.width,o=e.noSelect,s=e.height,c=!1;for(let t=0;t<s;t++){let s=t*a,l=``,u=[],d=[];for(let t=0;t<a;t++){let n=s+t,r=Hl(e,n);if(r.width===J.SpacerTail||r.width===J.SpacerHead||o[n]===1)continue;let i=r.char.toLowerCase(),a=u.length;for(let e=0;e<i.length;e++)d.push(a);l+=i,u.push(t)}let f=l.indexOf(r);for(;f>=0;){c=!0;let a=d[f],o=d[f+i-1];for(let r=a;r<=o;r++){let i=u[r],a=Hl(e,s+i);Kl(e,i,t,n.withInverse(a.styleId))}f=l.indexOf(r,f+i)}}return c}var jh=t((()=>{Cu()}));function Mh(){let e=(0,Nh.useContext)(Ph);if(!e)throw Error(`useTerminalNotification must be used within TerminalWriteProvider`);let t=(0,Nh.useCallback)(({message:t,title:n})=>{let r=n?`${n}:\n${t}`:t;e(_d(gd(Pd.ITERM2,`\n\n${r}`)))},[e]),n=(0,Nh.useCallback)(({message:t,title:n,id:r})=>{e(_d(gd(Pd.KITTY,`i=${r}:d=0:p=title`,n))),e(_d(gd(Pd.KITTY,`i=${r}:p=body`,t))),e(_d(gd(Pd.KITTY,`i=${r}:d=1:a=focus`,``)))},[e]),r=(0,Nh.useCallback)(({message:t,title:n})=>{e(_d(gd(Pd.GHOSTTY,`notify`,n,t)))},[e]),i=(0,Nh.useCallback)(()=>{e(`\x07`)},[e]),a=(0,Nh.useCallback)((t,n)=>{if(!Hd())return;if(!t){e(_d(gd(Pd.ITERM2,Id.PROGRESS,Ld.CLEAR,``)));return}let r=Math.max(0,Math.min(100,Math.round(n??0)));switch(t){case`completed`:e(_d(gd(Pd.ITERM2,Id.PROGRESS,Ld.CLEAR,``)));break;case`error`:e(_d(gd(Pd.ITERM2,Id.PROGRESS,Ld.ERROR,r)));break;case`indeterminate`:e(_d(gd(Pd.ITERM2,Id.PROGRESS,Ld.INDETERMINATE,``)));break;case`running`:e(_d(gd(Pd.ITERM2,Id.PROGRESS,Ld.SET,r)));break;case null:break}},[e]);return(0,Nh.useMemo)(()=>({notifyITerm2:t,notifyKitty:n,notifyGhostty:r,notifyBell:i,progress:a}),[t,n,r,i,a])}var Nh,Ph,Fh,Ih=t((()=>{Nh=n(N(),1),$d(),Gn(),Vd(),Ph=(0,Nh.createContext)(null),Fh=Ph.Provider}));function Lh(e){return Object.freeze({type:`stdout`,content:tr(e,1)})}function Rh(e=process.stdin){if(!e.isTTY)return;try{for(;e.read()!==null;);}catch{}if(process.platform===`win32`)return;let t=e,n=t.isRaw===!0,r=-1;try{n||t.setRawMode?.(!0),r=w(`/dev/tty`,C.O_RDONLY|C.O_NONBLOCK);let e=Buffer.alloc(1024);for(let t=0;t<64&&!(E(r,e,0,e.length,null)<=0);t++);}catch{}finally{if(r>=0)try{S(r)}catch{}if(!n)try{t.setRawMode?.(!1)}catch{}}}var zh,Bh,Vh,Hh,Uh,Wh,Gh,Kh,qh,Jh=t((()=>{se(),le(),ke(),N(),zh=Me(),f(),Ut(),Ln(),yp(),gf(),vc(),Sp(),Vc(),wp(),Ap(),Mp(),qp(),Aa(),Yp(),vm(),Tl(),Sh(),Eh(),kh(),Cu(),jh(),Ku(),$d(),Dr(),md(),Vd(),Ih(),Bh=y(),c(),Vh=Object.freeze({x:0,y:0,visible:!1}),Hh=Object.freeze({type:`stdout`,content:mr}),Uh=Object.freeze({type:`stdout`,content:gr+mr}),Wh={debug(){},error(){}},Gh=class{constructor(e){l(this,`log`,void 0),l(this,`terminal`,void 0),l(this,`scheduleRender`,void 0),l(this,`isUnmounted`,!1),l(this,`isPaused`,!1),l(this,`container`,void 0),l(this,`rootNode`,void 0),l(this,`focusManager`,void 0),l(this,`renderer`,void 0),l(this,`stylePool`,void 0),l(this,`charPool`,void 0),l(this,`hyperlinkPool`,void 0),l(this,`exitPromise`,void 0),l(this,`restoreConsole`,void 0),l(this,`restoreStderr`,void 0),l(this,`unsubscribeTTYHandlers`,void 0),l(this,`terminalColumns`,void 0),l(this,`terminalRows`,void 0),l(this,`currentNode`,null),l(this,`frontFrame`,void 0),l(this,`backFrame`,void 0),l(this,`lastPoolResetTime`,performance.now()),l(this,`drainTimer`,null),l(this,`lastYogaCounters`,{ms:0,visited:0,measured:0,cacheHits:0,live:0}),l(this,`altScreenParkPatch`,void 0),l(this,`selection`,Y()),l(this,`searchHighlightQuery`,``),l(this,`searchPositions`,null),l(this,`selectionListeners`,new Set),l(this,`hoveredNodes`,new Set),l(this,`altScreenActive`,!1),l(this,`altScreenMouseTracking`,!1),l(this,`prevFrameContaminated`,!1),l(this,`needsEraseBeforePaint`,!1),l(this,`cursorDeclaration`,null),l(this,`displayCursor`,null),l(this,`logger`,void 0),l(this,`handleResume`,()=>{if(this.options.stdout.isTTY){if(this.altScreenActive){this.reenterAltScreen();return}this.frontFrame=Cp(this.frontFrame.viewport.height,this.frontFrame.viewport.width,this.stylePool,this.charPool,this.hyperlinkPool),this.backFrame=Cp(this.backFrame.viewport.height,this.backFrame.viewport.width,this.stylePool,this.charPool,this.hyperlinkPool),this.log.reset(),this.displayCursor=null}}),l(this,`handleResize`,()=>{let e=this.options.stdout.columns||80,t=this.options.stdout.rows||24;e===this.terminalColumns&&t===this.terminalRows||(this.terminalColumns=e,this.terminalRows=t,this.altScreenParkPatch=Lh(this.terminalRows),this.altScreenActive&&!this.isPaused&&this.options.stdout.isTTY&&(this.altScreenMouseTracking&&this.options.stdout.write(fd),this.resetFramesForAltScreen(),this.needsEraseBeforePaint=!0),this.currentNode!==null&&this.render(this.currentNode))}),l(this,`resolveExitPromise`,()=>{}),l(this,`rejectExitPromise`,()=>{}),l(this,`unsubscribeExit`,()=>{}),l(this,`reassertTerminalModes`,(e=!1)=>{this.options.stdout.isTTY&&(this.isPaused||(Kd()&&this.options.stdout.write(wr+Cr+Tr),this.altScreenActive&&(this.altScreenMouseTracking&&this.options.stdout.write(fd),e&&this.reenterAltScreen())))}),l(this,`onHyperlinkClick`,void 0),l(this,`stdinListeners`,[]),l(this,`wasRawMode`,!1),l(this,`setCursorDeclaration`,(e,t)=>{e===null&&t!==void 0&&this.cursorDeclaration?.node!==t||(this.cursorDeclaration=e)}),this.options=e,ae(this),this.logger=e.logger??Wh,this.options.patchConsole&&(this.restoreConsole=this.patchConsole(),this.restoreStderr=this.patchStderr()),this.terminal={stdout:e.stdout,stderr:e.stderr},this.terminalColumns=e.stdout.columns||80,this.terminalRows=e.stdout.rows||24,this.altScreenParkPatch=Lh(this.terminalRows),this.stylePool=new fu,this.charPool=new ou,this.hyperlinkPool=new su,this.frontFrame=Cp(this.terminalRows,this.terminalColumns,this.stylePool,this.charPool,this.hyperlinkPool),this.backFrame=Cp(this.terminalRows,this.terminalColumns,this.stylePool,this.charPool,this.hyperlinkPool),this.log=new Gp({isTTY:e.stdout.isTTY||!1,stylePool:this.stylePool}),this.scheduleRender=De(()=>queueMicrotask(this.onRender),16,{leading:!0,trailing:!0}),this.isUnmounted=!1,this.unsubscribeExit=u(this.unmount,{alwaysLast:!1}),e.stdout.isTTY&&(e.stdout.on(`resize`,this.handleResize),process.on(`SIGCONT`,this.handleResume),this.unsubscribeTTYHandlers=()=>{e.stdout.off(`resize`,this.handleResize),process.off(`SIGCONT`,this.handleResume)}),this.rootNode=ic(`ink-root`),this.focusManager=new Bc((e,t)=>pl.dispatchDiscrete(e,t)),this.rootNode.focusManager=this.focusManager,this.renderer=Dh(this.rootNode,this.stylePool),this.rootNode.onRender=this.scheduleRender,this.rootNode.onImmediateRender=this.onRender,this.rootNode.onComputeLayout=()=>{if(!this.isUnmounted&&this.rootNode.yogaNode){let e=performance.now();this.rootNode.yogaNode.setWidth(this.terminalColumns),this.rootNode.yogaNode.calculateLayout(this.terminalColumns);let t=performance.now()-e;il(t),this.lastYogaCounters={ms:t,...ct()}}},this.container=wl.createContainer(this.rootNode,zh.ConcurrentRoot,null,!1,null,`id`,ce,ce,ce,ce)}enterAlternateScreen(){this.pause(),this.suspendStdin(),this.options.stdout.write(wr+Er+(this.altScreenMouseTracking?pd:``)+(this.altScreenActive?``:`\x1B[?1049h`)+`\x1B[?1004l\x1B[0m\x1B[?25h\x1B[2J\x1B[H`)}exitAlternateScreen(){this.options.stdout.write((this.altScreenActive?ud:``)+`\x1B[2J\x1B[H`+(this.altScreenMouseTracking?fd:``)+(this.altScreenActive?``:`\x1B[?1049l`)+`\x1B[?25l`),this.resumeStdin(),this.altScreenActive?this.resetFramesForAltScreen():this.repaint(),this.resume(),this.options.stdout.write(`\x1B[?1004h`+(Kd()?wr+Cr+Tr:``))}onRender(){if(this.isUnmounted||this.isPaused)return;this.drainTimer!==null&&(clearTimeout(this.drainTimer),this.drainTimer=null),this.options.onBeforeRender?.();let e=performance.now(),t=this.options.stdout.columns||80,n=this.options.stdout.rows||24,r=this.renderer({frontFrame:this.frontFrame,backFrame:this.backFrame,isTTY:this.options.stdout.isTTY,terminalWidth:t,terminalRows:n,altScreen:this.altScreenActive,prevFrameContaminated:this.prevFrameContaminated}),i=performance.now()-e,a=qm();if(a&&this.selection.anchor&&this.selection.anchor.row>=a.viewportTop&&this.selection.anchor.row<=a.viewportBottom){let{delta:e,viewportTop:t,viewportBottom:n}=a;if(this.selection.isDragging)Lu(this.selection)&&Hu(this.selection,this.frontFrame.screen,t,t+e-1,`above`),Fu(this.selection,-e,t,n);else if((!this.selection.focus||this.selection.focus.row>=t&&this.selection.focus.row<=n)&&(Lu(this.selection)&&Hu(this.selection,this.frontFrame.screen,t,t+e-1,`above`),Iu(this.selection,-e,t,n)))for(let e of this.selectionListeners)e()}let o=!1,s=!1;if(this.altScreenActive&&(o=Lu(this.selection),o&&Uu(r.screen,this.selection,this.stylePool),s=Ah(r.screen,this.searchHighlightQuery,this.stylePool),this.searchPositions)){let e=this.searchPositions,t=wh(r.screen,this.stylePool,e.positions,e.rowOffset,e.currentIdx);s=s||t}(Hm()||o||s||this.prevFrameContaminated)&&(r.screen.damage={x:0,y:0,width:r.screen.width,height:r.screen.height});let c=this.frontFrame;this.altScreenActive&&(c={...this.frontFrame,cursor:Vh});let l=performance.now(),u=this.log.render(c,r,this.altScreenActive,Qd),d=performance.now()-l;this.backFrame=this.frontFrame,this.frontFrame=r,e-this.lastPoolResetTime>300*1e3&&(this.resetPools(),this.lastPoolResetTime=e);let f=[];for(let e of u)if(e.type===`clearTerminal`&&(f.push({desiredHeight:r.screen.height,availableHeight:r.viewport.height,reason:e.reason}),K()&&e.debug)){let t=rc(this.rootNode,e.debug.triggerY);this.logger.debug(`[REPAINT] full reset · ${e.reason} · row ${e.debug.triggerY}\n prev: "${e.debug.prevLine}"\n next: "${e.debug.nextLine}"\n culprit: ${t.length?t.join(` < `):`(no owner chain captured)`}`,{level:`warn`})}let p=performance.now(),m=Jp(u),h=performance.now()-p,g=m.length>0;this.altScreenActive&&g&&(this.needsEraseBeforePaint?(this.needsEraseBeforePaint=!1,m.unshift(Uh)):m.unshift(Hh),m.push(this.altScreenParkPatch));let _=this.cursorDeclaration,v=_===null?void 0:W.get(_.node),y=_!==null&&v!==void 0?{x:v.x+_.relativeX,y:v.y+_.relativeY}:null,b=this.displayCursor,x=y!==null&&(b===null||b.x!==y.x||b.y!==y.y);if(g||x||y===null&&b!==null){if(b!==null&&!this.altScreenActive&&g){let e=c.cursor.x-b.x,t=c.cursor.y-b.y;(e!==0||t!==0)&&m.unshift({type:`stdout`,content:nr(e,t)})}if(y!==null){if(this.altScreenActive){let e=Math.min(Math.max(y.y+1,1),n),r=Math.min(Math.max(y.x+1,1),t);m.push({type:`stdout`,content:tr(e,r)})}else{let e=!g&&b!==null?b:{x:r.cursor.x,y:r.cursor.y},t=y.x-e.x,n=y.y-e.y;(t!==0||n!==0)&&m.push({type:`stdout`,content:nr(t,n)})}this.displayCursor=y}else{if(b!==null&&!this.altScreenActive&&!g){let e=r.cursor.x-b.x,t=r.cursor.y-b.y;(e!==0||t!==0)&&m.push({type:`stdout`,content:nr(e,t)})}this.displayCursor=null}}let S=performance.now();Jd(this.terminal,m,this.altScreenActive&&!Qd);let C=performance.now()-S;this.prevFrameContaminated=o||s,r.scrollDrainPending&&(this.drainTimer=setTimeout(()=>this.onRender(),4));let w=al(),T=sl(),E=this.lastYogaCounters;cl(),this.lastYogaCounters={ms:0,visited:0,measured:0,cacheHits:0,live:0},this.options.onFrame?.({durationMs:performance.now()-e,phases:{renderer:i,diff:d,optimize:h,write:C,patches:u.length,yoga:w,commit:T,yogaVisited:E.visited,yogaMeasured:E.measured,yogaCacheHits:E.cacheHits,yogaLive:E.live},flickers:f})}pause(){wl.flushSyncFromReconciler(),this.onRender(),this.isPaused=!0}resume(){this.isPaused=!1,this.onRender()}repaint(){this.frontFrame=Cp(this.frontFrame.viewport.height,this.frontFrame.viewport.width,this.stylePool,this.charPool,this.hyperlinkPool),this.backFrame=Cp(this.backFrame.viewport.height,this.backFrame.viewport.width,this.stylePool,this.charPool,this.hyperlinkPool),this.log.reset(),this.displayCursor=null}forceRedraw(){!this.options.stdout.isTTY||this.isUnmounted||this.isPaused||(this.options.stdout.write(gr+mr),this.altScreenActive?this.resetFramesForAltScreen():(this.repaint(),this.prevFrameContaminated=!0),this.onRender())}invalidatePrevFrame(){this.prevFrameContaminated=!0}setAltScreenActive(e,t=!1){this.altScreenActive!==e&&(this.altScreenActive=e,this.altScreenMouseTracking=e&&t,e?this.resetFramesForAltScreen():this.repaint())}get isAltScreenActive(){return this.altScreenActive}detachForShutdown(){this.isUnmounted=!0,this.scheduleRender.cancel?.();let e=this.options.stdin;this.drainStdin(),e.isTTY&&e.isRaw&&e.setRawMode&&e.setRawMode(!1)}drainStdin(){Rh(this.options.stdin)}reenterAltScreen(){this.options.stdout.write(ud+gr+mr+(this.altScreenMouseTracking?fd:``)),this.resetFramesForAltScreen()}resetFramesForAltScreen(){let e=this.terminalRows,t=this.terminalColumns,n=()=>({screen:Rl(t,e,this.stylePool,this.charPool,this.hyperlinkPool),viewport:{width:t,height:e+1},cursor:{x:0,y:0,visible:!0}});this.frontFrame=n(),this.backFrame=n(),this.log.reset(),this.displayCursor=null,this.prevFrameContaminated=!0}copySelectionNoClear(){if(!Lu(this.selection))return``;let e=Vu(this.selection,this.frontFrame.screen);return e&&xd(e).then(e=>{e&&this.options.stdout.write(e)}),e}copySelection(){if(!Lu(this.selection))return``;let e=this.copySelectionNoClear();return Q(this.selection),this.notifySelectionChange(),e}clearTextSelection(){Lu(this.selection)&&(Q(this.selection),this.notifySelectionChange())}setSearchHighlight(e){this.searchHighlightQuery!==e&&(this.searchHighlightQuery=e,this.scheduleRender())}scanElementSubtree(e){if(!this.searchHighlightQuery||!e.yogaNode)return[];let t=Math.ceil(e.yogaNode.getComputedWidth()),n=Math.ceil(e.yogaNode.getComputedHeight());if(t<=0||n<=0)return[];let r=e.yogaNode.getComputedLeft(),i=e.yogaNode.getComputedTop(),a=Rl(t,n,this.stylePool,this.charPool,this.hyperlinkPool),o=new _m({width:t,height:n,stylePool:this.stylePool,screen:a});th(e,o,{offsetX:-r,offsetY:-i,prevScreen:void 0});let s=o.get();mc(e);let c=Ch(s,this.searchHighlightQuery);return this.logger.debug(`scanElementSubtree: q='${this.searchHighlightQuery}' el=${t}x${n}@(${r},${i}) n=${c.length} [${c.slice(0,10).map(e=>`${e.row}:${e.col}`).join(`,`)}${c.length>10?`,…`:``}]`),c}setSearchPositions(e){this.searchPositions=e,this.scheduleRender()}setSelectionBgColor(e){let t=In(`\0`,e,`background`),n=t.indexOf(`\0`);if(n<=0||n===t.length-1){this.stylePool.setSelectionBg(null);return}this.stylePool.setSelectionBg({type:`ansi`,code:t.slice(0,n),endCode:t.slice(n+1)})}captureScrolledRows(e,t,n){Hu(this.selection,this.frontFrame.screen,e,t,n)}shiftSelectionForScroll(e,t,n){let r=Lu(this.selection);Pu(this.selection,e,t,n,this.frontFrame.screen.width),r&&!Lu(this.selection)&&this.notifySelectionChange()}moveSelectionFocus(e){if(!this.altScreenActive)return;let{focus:t}=this.selection;if(!t)return;let{width:n,height:r}=this.frontFrame.screen,i=n-1,a=r-1,{col:o,row:s}=t;switch(e){case`left`:o>0?o--:s>0&&(o=i,s--);break;case`right`:o<i?o++:s<a&&(o=0,s++);break;case`up`:s>0&&s--;break;case`down`:s<a&&s++;break;case`lineStart`:o=0;break;case`lineEnd`:o=i;break}o===t.col&&s===t.row||(Nu(this.selection,o,s),this.notifySelectionChange())}hasTextSelection(){return Lu(this.selection)}subscribeToSelectionChange(e){return this.selectionListeners.add(e),()=>this.selectionListeners.delete(e)}notifySelectionChange(){this.onRender();for(let e of this.selectionListeners)e()}dispatchClick(e,t){if(!this.altScreenActive)return!1;let n=Il(this.frontFrame.screen,e,t);return Op(this.rootNode,e,t,n)}dispatchHover(e,t){this.altScreenActive&&kp(this.rootNode,e,t,this.hoveredNodes)}dispatchKeyboardEvent(e){let t=this.focusManager.activeElement??this.rootNode,n=new xp(e);pl.dispatchDiscrete(t,n),!n.defaultPrevented&&e.name===`tab`&&!e.ctrl&&!e.meta&&(e.shift?this.focusManager.focusPrevious(this.rootNode):this.focusManager.focusNext(this.rootNode))}getHyperlinkAt(e,t){if(!this.altScreenActive)return;let n=this.frontFrame.screen,r=Vl(n,e,t),i=r?.hyperlink;return!i&&r?.width===J.SpacerTail&&e>0&&(i=Vl(n,e-1,t)?.hyperlink),i??Au(n,e,t)}openHyperlink(e){this.onHyperlinkClick?.(e)}handleMultiClick(e,t,n){if(!this.altScreenActive)return;let r=this.frontFrame.screen;wu(this.selection,e,t),n===2?Ou(this.selection,r,e,t):ju(this.selection,r,t),this.selection.focus||(this.selection.focus=this.selection.anchor),this.notifySelectionChange()}handleSelectionDrag(e,t){if(!this.altScreenActive)return;let n=this.selection;n.anchorSpan?Mu(n,this.frontFrame.screen,e,t):X(n,e,t),this.notifySelectionChange()}suspendStdin(){let e=this.options.stdin;if(!e.isTTY)return;let t=e.listeners(`readable`);this.logger.debug(`[stdin] suspendStdin: removing ${t.length} readable listener(s), wasRawMode=${e.isRaw??!1}`),t.forEach(t=>{this.stdinListeners.push({event:`readable`,listener:t}),e.removeListener(`readable`,t)});let n=e;n.isRaw&&n.setRawMode&&(n.setRawMode(!1),this.wasRawMode=!0)}resumeStdin(){let e=this.options.stdin;if(e.isTTY&&(this.stdinListeners.length===0&&!this.wasRawMode&&this.logger.debug(`[stdin] resumeStdin: called with no stored listeners and wasRawMode=false (possible desync)`,{level:`warn`}),this.logger.debug(`[stdin] resumeStdin: re-attaching ${this.stdinListeners.length} listener(s), wasRawMode=${this.wasRawMode}`),this.stdinListeners.forEach(({event:t,listener:n})=>{e.addListener(t,n)}),this.stdinListeners=[],this.wasRawMode)){let t=e;t.setRawMode&&t.setRawMode(!0),this.wasRawMode=!1}}writeRaw(e){this.options.stdout.write(e)}render(e){this.currentNode=e;let t=(0,Bh.jsx)(vp,{stdin:this.options.stdin,stdout:this.options.stdout,stderr:this.options.stderr,exitOnCtrlC:this.options.exitOnCtrlC,onExit:this.unmount,terminalColumns:this.terminalColumns,terminalRows:this.terminalRows,selection:this.selection,onSelectionChange:this.notifySelectionChange,onClickAt:this.dispatchClick,onHoverAt:this.dispatchHover,getHyperlinkAt:this.getHyperlinkAt,onOpenHyperlink:this.openHyperlink,onMultiClick:this.handleMultiClick,onSelectionDrag:this.handleSelectionDrag,onStdinResume:this.reassertTerminalModes,onCursorDeclaration:this.setCursorDeclaration,dispatchKeyboardEvent:this.dispatchKeyboardEvent,children:(0,Bh.jsx)(Fh,{value:this.writeRaw,children:e})});wl.updateContainerSync(t,this.container,null,ce),wl.flushSyncWork()}unmount(e){if(this.isUnmounted)return;this.onRender(),this.unsubscribeExit(),typeof this.restoreConsole==`function`&&this.restoreConsole(),this.restoreStderr?.(),this.unsubscribeTTYHandlers?.();let t=this.log.renderPreviousOutput_DEPRECATED(this.frontFrame);Jd(this.terminal,Jp(t)),this.options.stdout.isTTY&&(this.altScreenActive&&D(1,dd),D(1,pd),this.drainStdin(),D(1,Er),D(1,wr),D(1,sd),D(1,ad),D(1,cd),D(1,Rd),kd()&&D(1,_d(Bd))),this.isUnmounted=!0,this.scheduleRender.cancel?.(),this.drainTimer!==null&&(clearTimeout(this.drainTimer),this.drainTimer=null),wl.updateContainerSync(null,this.container,null,ce),wl.flushSyncWork(),jp.delete(this.options.stdout),this.rootNode.yogaNode?.free(),this.rootNode.yogaNode=void 0,e instanceof Error?this.rejectExitPromise(e):this.resolveExitPromise()}async waitUntilExit(){return this.exitPromise||(this.exitPromise=new Promise((e,t)=>{this.resolveExitPromise=e,this.rejectExitPromise=t})),this.exitPromise}resetLineCount(){this.options.stdout.isTTY&&(this.backFrame=this.frontFrame,this.frontFrame=Cp(this.frontFrame.viewport.height,this.frontFrame.viewport.width,this.stylePool,this.charPool,this.hyperlinkPool),this.log.reset(),this.displayCursor=null)}resetPools(){this.charPool=new ou,this.hyperlinkPool=new su,Bl(this.frontFrame.screen,this.charPool,this.hyperlinkPool),this.backFrame.screen.charPool=this.charPool,this.backFrame.screen.hyperlinkPool=this.hyperlinkPool}patchConsole(){let e=console,t={},n=(...e)=>this.logger.debug(`console.log: ${te(...e)}`),r=(...e)=>this.logger.error(Error(`console.error: ${te(...e)}`));for(let r of Kh)t[r]=e[r],e[r]=n;for(let n of qh)t[n]=e[n],e[n]=r;return t.assert=e.assert,e.assert=(e,...t)=>{e||r(...t)},()=>Object.assign(e,t)}patchStderr(){let e=process.stderr,t=e.write,n=!1,r=(r,i,a)=>{let o=typeof i==`function`?i:a;if(n){let n=typeof i==`string`?i:void 0;return t.call(e,r,n,o)}n=!0;try{let e=typeof r==`string`?r:Buffer.from(r).toString(`utf8`);this.logger.debug(`[stderr] ${e}`,{level:`warn`}),this.altScreenActive&&!this.isUnmounted&&!this.isPaused&&(this.prevFrameContaminated=!0,this.scheduleRender())}finally{n=!1,o?.()}return!0};return e.write=r,()=>{e.write===r&&(e.write=t)}}},Kh=[`log`,`info`,`debug`,`dir`,`dirxml`,`count`,`countReset`,`group`,`groupCollapsed`,`groupEnd`,`table`,`time`,`timeEnd`,`timeLog`],qh=[`warn`,`error`,`trace`]}));async function Yh({stdout:e=process.stdout,stdin:t=process.stdin,stderr:n=process.stderr,exitOnCtrlC:r=!0,patchConsole:i=!0,onFrame:a}={}){await Promise.resolve();let o=new Gh({stdout:e,stdin:t,stderr:n,exitOnCtrlC:r,patchConsole:i,onFrame:a});return jp.set(e,o),{render:e=>o.render(e),unmount:()=>o.unmount(),waitUntilExit:()=>o.waitUntilExit()}}var Xh,Zh,Qh,$h,eg=t((()=>{Jh(),Mp(),Xh=(e,t)=>{let n=Qh(t),r={stdout:process.stdout,stdin:process.stdin,stderr:process.stderr,exitOnCtrlC:!0,patchConsole:!0,...n},i=$h(r.stdout,()=>new Gh(r));return i.render(e),{rerender:i.render,unmount(){i.unmount()},waitUntilExit:i.waitUntilExit,cleanup:()=>jp.delete(r.stdout)}},Zh=async(e,t)=>{await Promise.resolve();let n=Xh(e,t);return process.env.CLAUDE_CODE_DEBUG_REPAINTS===`1`&&console.warn(`[render] first ink render: ${Math.round(process.uptime()*1e3)}ms since process start`),n},Qh=(e={})=>e instanceof x?{stdout:e,stdin:process.stdin}:e,$h=(e,t)=>{let n=jp.get(e);return n||(n=t(),jp.set(e,n)),n}}));function tg(e){switch(e){case`light`:return ag;case`light-ansi`:return og;case`dark-ansi`:return sg;case`light-daltonized`:return cg;case`dark-daltonized`:return ug;default:return lg}}function ng(e){let t=e.match(/rgb\(\s?(\d+),\s?(\d+),\s?(\d+)\s?\)/);if(t){let e=parseInt(t[1],10),n=parseInt(t[2],10),r=parseInt(t[3],10),i=dg.rgb(e,n,r)(`X`);return i.slice(0,i.indexOf(`X`))}return`\x1B[35m`}var rg,ig,ag,og,sg,cg,lg,ug,dg,fg=t((()=>{kn(),rg=[`dark`,`light`,`light-daltonized`,`dark-daltonized`,`light-ansi`,`dark-ansi`],ig=[`auto`,...rg],ag={autoAccept:`rgb(135,0,255)`,bashBorder:`rgb(255,0,135)`,claude:`rgb(215,119,87)`,claudeShimmer:`rgb(245,149,117)`,claudeBlue_FOR_SYSTEM_SPINNER:`rgb(87,105,247)`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`rgb(117,135,255)`,permission:`rgb(87,105,247)`,permissionShimmer:`rgb(137,155,255)`,planMode:`rgb(0,102,102)`,ide:`rgb(71,130,200)`,promptBorder:`rgb(153,153,153)`,promptBorderShimmer:`rgb(183,183,183)`,text:`rgb(0,0,0)`,inverseText:`rgb(255,255,255)`,inactive:`rgb(102,102,102)`,inactiveShimmer:`rgb(142,142,142)`,subtle:`rgb(175,175,175)`,suggestion:`rgb(87,105,247)`,remember:`rgb(0,0,255)`,background:`rgb(0,153,153)`,success:`rgb(44,122,57)`,error:`rgb(171,43,63)`,warning:`rgb(150,108,30)`,merged:`rgb(135,0,255)`,warningShimmer:`rgb(200,158,80)`,diffAdded:`rgb(105,219,124)`,diffRemoved:`rgb(255,168,180)`,diffAddedDimmed:`rgb(199,225,203)`,diffRemovedDimmed:`rgb(253,210,216)`,diffAddedWord:`rgb(47,157,68)`,diffRemovedWord:`rgb(209,69,75)`,red_FOR_SUBAGENTS_ONLY:`rgb(220,38,38)`,blue_FOR_SUBAGENTS_ONLY:`rgb(37,99,235)`,green_FOR_SUBAGENTS_ONLY:`rgb(22,163,74)`,yellow_FOR_SUBAGENTS_ONLY:`rgb(202,138,4)`,purple_FOR_SUBAGENTS_ONLY:`rgb(147,51,234)`,orange_FOR_SUBAGENTS_ONLY:`rgb(234,88,12)`,pink_FOR_SUBAGENTS_ONLY:`rgb(219,39,119)`,cyan_FOR_SUBAGENTS_ONLY:`rgb(8,145,178)`,professionalBlue:`rgb(106,155,204)`,chromeYellow:`rgb(251,188,4)`,clawd_body:`rgb(215,119,87)`,clawd_background:`rgb(0,0,0)`,userMessageBackground:`rgb(240, 240, 240)`,userMessageBackgroundHover:`rgb(252, 252, 252)`,messageActionsBackground:`rgb(232, 236, 244)`,selectionBg:`rgb(180, 213, 255)`,bashMessageBackgroundColor:`rgb(250, 245, 250)`,memoryBackgroundColor:`rgb(230, 245, 250)`,rate_limit_fill:`rgb(87,105,247)`,rate_limit_empty:`rgb(39,47,111)`,fastMode:`rgb(255,106,0)`,fastModeShimmer:`rgb(255,150,50)`,briefLabelYou:`rgb(37,99,235)`,briefLabelClaude:`rgb(215,119,87)`,rainbow_red:`rgb(235,95,87)`,rainbow_orange:`rgb(245,139,87)`,rainbow_yellow:`rgb(250,195,95)`,rainbow_green:`rgb(145,200,130)`,rainbow_blue:`rgb(130,170,220)`,rainbow_indigo:`rgb(155,130,200)`,rainbow_violet:`rgb(200,130,180)`,rainbow_red_shimmer:`rgb(250,155,147)`,rainbow_orange_shimmer:`rgb(255,185,137)`,rainbow_yellow_shimmer:`rgb(255,225,155)`,rainbow_green_shimmer:`rgb(185,230,180)`,rainbow_blue_shimmer:`rgb(180,205,240)`,rainbow_indigo_shimmer:`rgb(195,180,230)`,rainbow_violet_shimmer:`rgb(230,180,210)`},og={autoAccept:`ansi:magenta`,bashBorder:`ansi:magenta`,claude:`ansi:redBright`,claudeShimmer:`ansi:yellowBright`,claudeBlue_FOR_SYSTEM_SPINNER:`ansi:blue`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`ansi:blueBright`,permission:`ansi:blue`,permissionShimmer:`ansi:blueBright`,planMode:`ansi:cyan`,ide:`ansi:blueBright`,promptBorder:`ansi:white`,promptBorderShimmer:`ansi:whiteBright`,text:`ansi:black`,inverseText:`ansi:white`,inactive:`ansi:blackBright`,inactiveShimmer:`ansi:white`,subtle:`ansi:blackBright`,suggestion:`ansi:blue`,remember:`ansi:blue`,background:`ansi:cyan`,success:`ansi:green`,error:`ansi:red`,warning:`ansi:yellow`,merged:`ansi:magenta`,warningShimmer:`ansi:yellowBright`,diffAdded:`ansi:green`,diffRemoved:`ansi:red`,diffAddedDimmed:`ansi:green`,diffRemovedDimmed:`ansi:red`,diffAddedWord:`ansi:greenBright`,diffRemovedWord:`ansi:redBright`,red_FOR_SUBAGENTS_ONLY:`ansi:red`,blue_FOR_SUBAGENTS_ONLY:`ansi:blue`,green_FOR_SUBAGENTS_ONLY:`ansi:green`,yellow_FOR_SUBAGENTS_ONLY:`ansi:yellow`,purple_FOR_SUBAGENTS_ONLY:`ansi:magenta`,orange_FOR_SUBAGENTS_ONLY:`ansi:redBright`,pink_FOR_SUBAGENTS_ONLY:`ansi:magentaBright`,cyan_FOR_SUBAGENTS_ONLY:`ansi:cyan`,professionalBlue:`ansi:blueBright`,chromeYellow:`ansi:yellow`,clawd_body:`ansi:redBright`,clawd_background:`ansi:black`,userMessageBackground:`ansi:white`,userMessageBackgroundHover:`ansi:whiteBright`,messageActionsBackground:`ansi:white`,selectionBg:`ansi:cyan`,bashMessageBackgroundColor:`ansi:whiteBright`,memoryBackgroundColor:`ansi:white`,rate_limit_fill:`ansi:yellow`,rate_limit_empty:`ansi:black`,fastMode:`ansi:red`,fastModeShimmer:`ansi:redBright`,briefLabelYou:`ansi:blue`,briefLabelClaude:`ansi:redBright`,rainbow_red:`ansi:red`,rainbow_orange:`ansi:redBright`,rainbow_yellow:`ansi:yellow`,rainbow_green:`ansi:green`,rainbow_blue:`ansi:cyan`,rainbow_indigo:`ansi:blue`,rainbow_violet:`ansi:magenta`,rainbow_red_shimmer:`ansi:redBright`,rainbow_orange_shimmer:`ansi:yellow`,rainbow_yellow_shimmer:`ansi:yellowBright`,rainbow_green_shimmer:`ansi:greenBright`,rainbow_blue_shimmer:`ansi:cyanBright`,rainbow_indigo_shimmer:`ansi:blueBright`,rainbow_violet_shimmer:`ansi:magentaBright`},sg={autoAccept:`ansi:magentaBright`,bashBorder:`ansi:magentaBright`,claude:`ansi:redBright`,claudeShimmer:`ansi:yellowBright`,claudeBlue_FOR_SYSTEM_SPINNER:`ansi:blueBright`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`ansi:blueBright`,permission:`ansi:blueBright`,permissionShimmer:`ansi:blueBright`,planMode:`ansi:cyanBright`,ide:`ansi:blue`,promptBorder:`ansi:white`,promptBorderShimmer:`ansi:whiteBright`,text:`ansi:whiteBright`,inverseText:`ansi:black`,inactive:`ansi:white`,inactiveShimmer:`ansi:whiteBright`,subtle:`ansi:white`,suggestion:`ansi:blueBright`,remember:`ansi:blueBright`,background:`ansi:cyanBright`,success:`ansi:greenBright`,error:`ansi:redBright`,warning:`ansi:yellowBright`,merged:`ansi:magentaBright`,warningShimmer:`ansi:yellowBright`,diffAdded:`ansi:green`,diffRemoved:`ansi:red`,diffAddedDimmed:`ansi:green`,diffRemovedDimmed:`ansi:red`,diffAddedWord:`ansi:greenBright`,diffRemovedWord:`ansi:redBright`,red_FOR_SUBAGENTS_ONLY:`ansi:redBright`,blue_FOR_SUBAGENTS_ONLY:`ansi:blueBright`,green_FOR_SUBAGENTS_ONLY:`ansi:greenBright`,yellow_FOR_SUBAGENTS_ONLY:`ansi:yellowBright`,purple_FOR_SUBAGENTS_ONLY:`ansi:magentaBright`,orange_FOR_SUBAGENTS_ONLY:`ansi:redBright`,pink_FOR_SUBAGENTS_ONLY:`ansi:magentaBright`,cyan_FOR_SUBAGENTS_ONLY:`ansi:cyanBright`,professionalBlue:`rgb(106,155,204)`,chromeYellow:`ansi:yellowBright`,clawd_body:`ansi:redBright`,clawd_background:`ansi:black`,userMessageBackground:`ansi:blackBright`,userMessageBackgroundHover:`ansi:white`,messageActionsBackground:`ansi:blackBright`,selectionBg:`ansi:blue`,bashMessageBackgroundColor:`ansi:black`,memoryBackgroundColor:`ansi:blackBright`,rate_limit_fill:`ansi:yellow`,rate_limit_empty:`ansi:white`,fastMode:`ansi:redBright`,fastModeShimmer:`ansi:redBright`,briefLabelYou:`ansi:blueBright`,briefLabelClaude:`ansi:redBright`,rainbow_red:`ansi:red`,rainbow_orange:`ansi:redBright`,rainbow_yellow:`ansi:yellow`,rainbow_green:`ansi:green`,rainbow_blue:`ansi:cyan`,rainbow_indigo:`ansi:blue`,rainbow_violet:`ansi:magenta`,rainbow_red_shimmer:`ansi:redBright`,rainbow_orange_shimmer:`ansi:yellow`,rainbow_yellow_shimmer:`ansi:yellowBright`,rainbow_green_shimmer:`ansi:greenBright`,rainbow_blue_shimmer:`ansi:cyanBright`,rainbow_indigo_shimmer:`ansi:blueBright`,rainbow_violet_shimmer:`ansi:magentaBright`},cg={autoAccept:`rgb(135,0,255)`,bashBorder:`rgb(0,102,204)`,claude:`rgb(255,153,51)`,claudeShimmer:`rgb(255,183,101)`,claudeBlue_FOR_SYSTEM_SPINNER:`rgb(51,102,255)`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`rgb(101,152,255)`,permission:`rgb(51,102,255)`,permissionShimmer:`rgb(101,152,255)`,planMode:`rgb(51,102,102)`,ide:`rgb(71,130,200)`,promptBorder:`rgb(153,153,153)`,promptBorderShimmer:`rgb(183,183,183)`,text:`rgb(0,0,0)`,inverseText:`rgb(255,255,255)`,inactive:`rgb(102,102,102)`,inactiveShimmer:`rgb(142,142,142)`,subtle:`rgb(175,175,175)`,suggestion:`rgb(51,102,255)`,remember:`rgb(51,102,255)`,background:`rgb(0,153,153)`,success:`rgb(0,102,153)`,error:`rgb(204,0,0)`,warning:`rgb(255,153,0)`,merged:`rgb(135,0,255)`,warningShimmer:`rgb(255,183,50)`,diffAdded:`rgb(153,204,255)`,diffRemoved:`rgb(255,204,204)`,diffAddedDimmed:`rgb(209,231,253)`,diffRemovedDimmed:`rgb(255,233,233)`,diffAddedWord:`rgb(51,102,204)`,diffRemovedWord:`rgb(153,51,51)`,red_FOR_SUBAGENTS_ONLY:`rgb(204,0,0)`,blue_FOR_SUBAGENTS_ONLY:`rgb(0,102,204)`,green_FOR_SUBAGENTS_ONLY:`rgb(0,204,0)`,yellow_FOR_SUBAGENTS_ONLY:`rgb(255,204,0)`,purple_FOR_SUBAGENTS_ONLY:`rgb(128,0,128)`,orange_FOR_SUBAGENTS_ONLY:`rgb(255,128,0)`,pink_FOR_SUBAGENTS_ONLY:`rgb(255,102,178)`,cyan_FOR_SUBAGENTS_ONLY:`rgb(0,178,178)`,professionalBlue:`rgb(106,155,204)`,chromeYellow:`rgb(251,188,4)`,clawd_body:`rgb(215,119,87)`,clawd_background:`rgb(0,0,0)`,userMessageBackground:`rgb(220, 220, 220)`,userMessageBackgroundHover:`rgb(232, 232, 232)`,messageActionsBackground:`rgb(210, 216, 226)`,selectionBg:`rgb(180, 213, 255)`,bashMessageBackgroundColor:`rgb(250, 245, 250)`,memoryBackgroundColor:`rgb(230, 245, 250)`,rate_limit_fill:`rgb(51,102,255)`,rate_limit_empty:`rgb(23,46,114)`,fastMode:`rgb(255,106,0)`,fastModeShimmer:`rgb(255,150,50)`,briefLabelYou:`rgb(37,99,235)`,briefLabelClaude:`rgb(255,153,51)`,rainbow_red:`rgb(235,95,87)`,rainbow_orange:`rgb(245,139,87)`,rainbow_yellow:`rgb(250,195,95)`,rainbow_green:`rgb(145,200,130)`,rainbow_blue:`rgb(130,170,220)`,rainbow_indigo:`rgb(155,130,200)`,rainbow_violet:`rgb(200,130,180)`,rainbow_red_shimmer:`rgb(250,155,147)`,rainbow_orange_shimmer:`rgb(255,185,137)`,rainbow_yellow_shimmer:`rgb(255,225,155)`,rainbow_green_shimmer:`rgb(185,230,180)`,rainbow_blue_shimmer:`rgb(180,205,240)`,rainbow_indigo_shimmer:`rgb(195,180,230)`,rainbow_violet_shimmer:`rgb(230,180,210)`},lg={autoAccept:`rgb(175,135,255)`,bashBorder:`rgb(253,93,177)`,claude:`rgb(215,119,87)`,claudeShimmer:`rgb(235,159,127)`,claudeBlue_FOR_SYSTEM_SPINNER:`rgb(147,165,255)`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`rgb(177,195,255)`,permission:`rgb(177,185,249)`,permissionShimmer:`rgb(207,215,255)`,planMode:`rgb(72,150,140)`,ide:`rgb(71,130,200)`,promptBorder:`rgb(136,136,136)`,promptBorderShimmer:`rgb(166,166,166)`,text:`rgb(255,255,255)`,inverseText:`rgb(0,0,0)`,inactive:`rgb(153,153,153)`,inactiveShimmer:`rgb(193,193,193)`,subtle:`rgb(80,80,80)`,suggestion:`rgb(177,185,249)`,remember:`rgb(177,185,249)`,background:`rgb(0,204,204)`,success:`rgb(78,186,101)`,error:`rgb(255,107,128)`,warning:`rgb(255,193,7)`,merged:`rgb(175,135,255)`,warningShimmer:`rgb(255,223,57)`,diffAdded:`rgb(34,92,43)`,diffRemoved:`rgb(122,41,54)`,diffAddedDimmed:`rgb(71,88,74)`,diffRemovedDimmed:`rgb(105,72,77)`,diffAddedWord:`rgb(56,166,96)`,diffRemovedWord:`rgb(179,89,107)`,red_FOR_SUBAGENTS_ONLY:`rgb(220,38,38)`,blue_FOR_SUBAGENTS_ONLY:`rgb(37,99,235)`,green_FOR_SUBAGENTS_ONLY:`rgb(22,163,74)`,yellow_FOR_SUBAGENTS_ONLY:`rgb(202,138,4)`,purple_FOR_SUBAGENTS_ONLY:`rgb(147,51,234)`,orange_FOR_SUBAGENTS_ONLY:`rgb(234,88,12)`,pink_FOR_SUBAGENTS_ONLY:`rgb(219,39,119)`,cyan_FOR_SUBAGENTS_ONLY:`rgb(8,145,178)`,professionalBlue:`rgb(106,155,204)`,chromeYellow:`rgb(251,188,4)`,clawd_body:`rgb(215,119,87)`,clawd_background:`rgb(0,0,0)`,userMessageBackground:`rgb(55, 55, 55)`,userMessageBackgroundHover:`rgb(70, 70, 70)`,messageActionsBackground:`rgb(44, 50, 62)`,selectionBg:`rgb(38, 79, 120)`,bashMessageBackgroundColor:`rgb(65, 60, 65)`,memoryBackgroundColor:`rgb(55, 65, 70)`,rate_limit_fill:`rgb(177,185,249)`,rate_limit_empty:`rgb(80,83,112)`,fastMode:`rgb(255,120,20)`,fastModeShimmer:`rgb(255,165,70)`,briefLabelYou:`rgb(122,180,232)`,briefLabelClaude:`rgb(215,119,87)`,rainbow_red:`rgb(235,95,87)`,rainbow_orange:`rgb(245,139,87)`,rainbow_yellow:`rgb(250,195,95)`,rainbow_green:`rgb(145,200,130)`,rainbow_blue:`rgb(130,170,220)`,rainbow_indigo:`rgb(155,130,200)`,rainbow_violet:`rgb(200,130,180)`,rainbow_red_shimmer:`rgb(250,155,147)`,rainbow_orange_shimmer:`rgb(255,185,137)`,rainbow_yellow_shimmer:`rgb(255,225,155)`,rainbow_green_shimmer:`rgb(185,230,180)`,rainbow_blue_shimmer:`rgb(180,205,240)`,rainbow_indigo_shimmer:`rgb(195,180,230)`,rainbow_violet_shimmer:`rgb(230,180,210)`},ug={autoAccept:`rgb(175,135,255)`,bashBorder:`rgb(51,153,255)`,claude:`rgb(255,153,51)`,claudeShimmer:`rgb(255,183,101)`,claudeBlue_FOR_SYSTEM_SPINNER:`rgb(153,204,255)`,claudeBlueShimmer_FOR_SYSTEM_SPINNER:`rgb(183,224,255)`,permission:`rgb(153,204,255)`,permissionShimmer:`rgb(183,224,255)`,planMode:`rgb(102,153,153)`,ide:`rgb(71,130,200)`,promptBorder:`rgb(136,136,136)`,promptBorderShimmer:`rgb(166,166,166)`,text:`rgb(255,255,255)`,inverseText:`rgb(0,0,0)`,inactive:`rgb(153,153,153)`,inactiveShimmer:`rgb(193,193,193)`,subtle:`rgb(80,80,80)`,suggestion:`rgb(153,204,255)`,remember:`rgb(153,204,255)`,background:`rgb(0,204,204)`,success:`rgb(51,153,255)`,error:`rgb(255,102,102)`,warning:`rgb(255,204,0)`,merged:`rgb(175,135,255)`,warningShimmer:`rgb(255,234,50)`,diffAdded:`rgb(0,68,102)`,diffRemoved:`rgb(102,0,0)`,diffAddedDimmed:`rgb(62,81,91)`,diffRemovedDimmed:`rgb(62,44,44)`,diffAddedWord:`rgb(0,119,179)`,diffRemovedWord:`rgb(179,0,0)`,red_FOR_SUBAGENTS_ONLY:`rgb(255,102,102)`,blue_FOR_SUBAGENTS_ONLY:`rgb(102,178,255)`,green_FOR_SUBAGENTS_ONLY:`rgb(102,255,102)`,yellow_FOR_SUBAGENTS_ONLY:`rgb(255,255,102)`,purple_FOR_SUBAGENTS_ONLY:`rgb(178,102,255)`,orange_FOR_SUBAGENTS_ONLY:`rgb(255,178,102)`,pink_FOR_SUBAGENTS_ONLY:`rgb(255,153,204)`,cyan_FOR_SUBAGENTS_ONLY:`rgb(102,204,204)`,professionalBlue:`rgb(106,155,204)`,chromeYellow:`rgb(251,188,4)`,clawd_body:`rgb(215,119,87)`,clawd_background:`rgb(0,0,0)`,userMessageBackground:`rgb(55, 55, 55)`,userMessageBackgroundHover:`rgb(70, 70, 70)`,messageActionsBackground:`rgb(44, 50, 62)`,selectionBg:`rgb(38, 79, 120)`,bashMessageBackgroundColor:`rgb(65, 60, 65)`,memoryBackgroundColor:`rgb(55, 65, 70)`,rate_limit_fill:`rgb(153,204,255)`,rate_limit_empty:`rgb(69,92,115)`,fastMode:`rgb(255,120,20)`,fastModeShimmer:`rgb(255,165,70)`,briefLabelYou:`rgb(122,180,232)`,briefLabelClaude:`rgb(255,153,51)`,rainbow_red:`rgb(235,95,87)`,rainbow_orange:`rgb(245,139,87)`,rainbow_yellow:`rgb(250,195,95)`,rainbow_green:`rgb(145,200,130)`,rainbow_blue:`rgb(130,170,220)`,rainbow_indigo:`rgb(155,130,200)`,rainbow_violet:`rgb(200,130,180)`,rainbow_red_shimmer:`rgb(250,155,147)`,rainbow_orange_shimmer:`rgb(255,185,137)`,rainbow_yellow_shimmer:`rgb(255,225,155)`,rainbow_green_shimmer:`rgb(185,230,180)`,rainbow_blue_shimmer:`rgb(180,205,240)`,rainbow_indigo_shimmer:`rgb(195,180,230)`,rainbow_violet_shimmer:`rgb(230,180,210)`},dg=process.env.TERM_PROGRAM===`Apple_Terminal`?new Sn({level:2}):V})),pg=r(((e,t)=>{var n=`Expected a function`,r=NaN,i=`[object Symbol]`,a=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,c=/^0o[0-7]+$/i,l=parseInt,u=typeof global==`object`&&global&&global.Object===Object&&global,d=typeof self==`object`&&self&&self.Object===Object&&self,f=u||d||Function(`return this`)(),p=Object.prototype.toString,m=Math.max,h=Math.min,g=function(){return f.Date.now()};function _(e,t,r){var i,a,o,s,c,l,u=0,d=!1,f=!1,p=!0;if(typeof e!=`function`)throw TypeError(n);t=x(t)||0,v(r)&&(d=!!r.leading,f=`maxWait`in r,o=f?m(x(r.maxWait)||0,t):o,p=`trailing`in r?!!r.trailing:p);function _(t){var n=i,r=a;return i=a=void 0,u=t,s=e.apply(r,n),s}function y(e){return u=e,c=setTimeout(C,t),d?_(e):s}function b(e){var n=e-l,r=e-u,i=t-n;return f?h(i,o-r):i}function S(e){var n=e-l,r=e-u;return l===void 0||n>=t||n<0||f&&r>=o}function C(){var e=g();if(S(e))return w(e);c=setTimeout(C,b(e))}function w(e){return c=void 0,p&&i?_(e):(i=a=void 0,s)}function T(){c!==void 0&&clearTimeout(c),u=0,i=l=a=c=void 0}function E(){return c===void 0?s:w(g())}function D(){var e=g(),n=S(e);if(i=arguments,a=this,l=e,n){if(c===void 0)return y(l);if(f)return c=setTimeout(C,t),_(l)}return c===void 0&&(c=setTimeout(C,t)),s}return D.cancel=T,D.flush=E,D}function v(e){var t=typeof e;return!!e&&(t==`object`||t==`function`)}function y(e){return!!e&&typeof e==`object`}function b(e){return typeof e==`symbol`||y(e)&&p.call(e)==i}function x(e){if(typeof e==`number`)return e;if(b(e))return r;if(v(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=v(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=e.replace(a,``);var n=s.test(e);return n||c.test(e)?l(e.slice(2),n?2:8):o.test(e)?r:+e}t.exports=_}));function mg(e,t){let n=(0,vg.useRef)(e);bg(()=>{n.current=e},[e]),(0,vg.useEffect)(()=>{if(t===null)return;let e=setInterval(()=>{n.current()},t);return()=>{clearInterval(e)}},[t])}function hg(e){let t=(0,vg.useRef)(()=>{throw Error(`Cannot call an event handler while rendering.`)});return bg(()=>{t.current=e},[e]),(0,vg.useCallback)((...e)=>t.current?.call(t,...e),[t])}function gg(e){let t=(0,vg.useRef)(e);t.current=e,(0,vg.useEffect)(()=>()=>{t.current()},[])}function _g(e,t=500,n){let r=(0,vg.useRef)();gg(()=>{r.current&&r.current.cancel()});let i=(0,vg.useMemo)(()=>{let i=(0,yg.default)(e,t,n),a=(...e)=>i(...e);return a.cancel=()=>{i.cancel()},a.isPending=()=>!!r.current,a.flush=()=>i.flush(),a},[e,t,n]);return(0,vg.useEffect)(()=>{r.current=(0,yg.default)(e,t,n)},[e,t,n]),i}var vg,yg,bg,xg=t((()=>{vg=n(N(),1),yg=n(pg(),1),bg=typeof window<`u`?vg.useLayoutEffect:vg.useEffect})),Sg,Cg,wg=t((()=>{Sg=n(N(),1),ip(),Cg=()=>(0,Sg.useContext)(rp)})),Tg,Eg,Dg=t((()=>{Tg=n(N(),1),xg(),wg(),Eg=(e,t={})=>{let{setRawMode:n,internal_exitOnCtrlC:r,internal_eventEmitter:i}=Cg();(0,Tg.useLayoutEffect)(()=>{if(t.isActive!==!1)return n(!0),()=>{n(!1)}},[t.isActive,n]);let a=hg(n=>{if(t.isActive===!1)return;let{input:i,key:a}=n;(!(i===`c`&&a.ctrl)||!r)&&e(i,a,n)});(0,Tg.useEffect)(()=>(i?.on(`input`,a),()=>{i?.removeListener(`input`,a)}),[i,a])}}));function Og(e){return{ctrl:e.ctrl,shift:e.shift,meta:e.meta,super:e.super}}function kg(e,t){return t.escape?`escape`:t.return?`enter`:t.tab?`tab`:t.backspace?`backspace`:t.delete?`delete`:t.upArrow?`up`:t.downArrow?`down`:t.leftArrow?`left`:t.rightArrow?`right`:t.pageUp?`pageup`:t.pageDown?`pagedown`:t.wheelUp?`wheelup`:t.wheelDown?`wheeldown`:t.home?`home`:t.end?`end`:e.length===1?e.toLowerCase():null}function Ag(e,t){if(e.ctrl!==t.ctrl||e.shift!==t.shift)return!1;let n=t.alt||t.meta;return!(e.meta!==n||e.super!==t.super)}function jg(e,t,n){if(kg(e,t)!==n.key)return!1;let r=Og(t);return t.escape?Ag({...r,meta:!1},n):Ag(r,n)}function Mg(e,t,n){if(n.chord.length!==1)return!1;let r=n.chord[0];return r?jg(e,t,r):!1}var Ng=t((()=>{}));function Pg(e){let t=e.split(`+`),n={key:``,ctrl:!1,alt:!1,shift:!1,meta:!1,super:!1};for(let e of t){let t=e.toLowerCase();switch(t){case`ctrl`:case`control`:n.ctrl=!0;break;case`alt`:case`opt`:case`option`:n.alt=!0;break;case`shift`:n.shift=!0;break;case`meta`:n.meta=!0;break;case`cmd`:case`command`:case`super`:case`win`:n.super=!0;break;case`esc`:n.key=`escape`;break;case`return`:n.key=`enter`;break;case`space`:n.key=` `;break;case`↑`:n.key=`up`;break;case`↓`:n.key=`down`;break;case`←`:n.key=`left`;break;case`→`:n.key=`right`;break;default:n.key=t;break}}return n}function Fg(e){return e===` `?[Pg(`space`)]:e.trim().split(/\s+/).map(Pg)}function Ig(e){let t=[];e.ctrl&&t.push(`ctrl`),e.alt&&t.push(`alt`),e.shift&&t.push(`shift`),e.meta&&t.push(`meta`),e.super&&t.push(`cmd`);let n=Lg(e.key);return t.push(n),t.join(`+`)}function Lg(e){switch(e){case`escape`:return`Esc`;case` `:return`Space`;case`tab`:return`tab`;case`enter`:return`Enter`;case`backspace`:return`Backspace`;case`delete`:return`Delete`;case`up`:return`↑`;case`down`:return`↓`;case`left`:return`←`;case`right`:return`→`;case`pageup`:return`PageUp`;case`pagedown`:return`PageDown`;case`home`:return`Home`;case`end`:return`End`;default:return e}}function Rg(e){return e.map(Ig).join(` `)}function zg(e,t=`linux`){let n=[];e.ctrl&&n.push(`ctrl`),(e.alt||e.meta)&&n.push(t===`macos`?`opt`:`alt`),e.shift&&n.push(`shift`),e.super&&n.push(t===`macos`?`cmd`:`super`);let r=Lg(e.key);return n.push(r),n.join(`+`)}function Bg(e,t=`linux`){return e.map(e=>zg(e,t)).join(` `)}function Vg(e){let t=[];for(let n of e)for(let[e,r]of Object.entries(n.bindings))t.push({chord:Fg(e),action:r,context:n.context});return t}var Hg=t((()=>{}));function Ug(e,t,n,r){let i,a=new Set(n);for(let n of r)n.chord.length===1&&a.has(n.context)&&Mg(e,t,n)&&(i=n);return i?i.action===null?{type:`unbound`}:{type:`match`,action:i.action}:{type:`none`}}function Wg(e,t,n){let r=n.findLast(n=>n.action===e&&n.context===t);return r?Rg(r.chord):void 0}function Gg(e,t){let n=kg(e,t);if(!n)return null;let r=t.escape?!1:t.meta;return{key:n,ctrl:t.ctrl,alt:r,shift:t.shift,meta:r,super:t.super}}function Kg(e,t){return e.key===t.key&&e.ctrl===t.ctrl&&e.shift===t.shift&&(e.alt||e.meta)===(t.alt||t.meta)&&e.super===t.super}function qg(e,t){if(e.length>=t.chord.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t.chord[n];if(!r||!i||!Kg(r,i))return!1}return!0}function Jg(e,t){if(e.length!==t.chord.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t.chord[n];if(!r||!i||!Kg(r,i))return!1}return!0}function Yg(e,t,n,r,i){if(t.escape&&i!==null)return{type:`chord_cancelled`};let a=Gg(e,t);if(!a)return i===null?{type:`none`}:{type:`chord_cancelled`};let o=i?[...i,a]:[a],s=new Set(n),c=r.filter(e=>s.has(e.context)),l=new Map;for(let e of c)e.chord.length>o.length&&qg(o,e)&&l.set(Rg(e.chord),e.action);let u=!1;for(let e of l.values())if(e!==null){u=!0;break}if(u)return{type:`chord_started`,pending:o};let d;for(let e of c)Jg(o,e)&&(d=e);return d?d.action===null?{type:`unbound`}:{type:`match`,action:d.action}:i===null?{type:`none`}:{type:`chord_cancelled`}}var Xg=t((()=>{Ng(),Hg()}));function Zg({bindings:e,pendingChordRef:t,pendingChord:n,setPendingChord:r,activeContexts:i,registerActiveContext:a,unregisterActiveContext:o,handlerRegistryRef:s,children:c}){let l=(0,t_.useMemo)(()=>({resolve:(n,r,i)=>Yg(n,r,i,e,t.current),setPendingChord:r,getDisplayText:(t,n)=>Wg(t,n,e),bindings:e,pendingChord:n,activeContexts:i,registerActiveContext:a,unregisterActiveContext:o,registerHandler:e=>{let t=s.current;return t?(t.has(e.action)||t.set(e.action,new Set),t.get(e.action).add(e),()=>{let n=t.get(e.action);n&&(n.delete(e),n.size===0&&t.delete(e.action))}):()=>{}},invokeAction:e=>{let t=s.current;if(!t)return!1;let n=t.get(e);if(!n||n.size===0)return!1;for(let e of n)if(i.has(e.context))return e.handler(),!0;return!1}}),[e,t,n,r,i,a,o,s]);return(0,n_.jsx)(r_.Provider,{value:l,children:c})}function Qg(){let e=(0,t_.useContext)(r_);if(!e)throw Error(`useKeybindingContext must be used within KeybindingProvider`);return e}function $g(){return(0,t_.useContext)(r_)}function e_(e,t=!0){let n=$g();(0,t_.useLayoutEffect)(()=>{if(!(!n||!t))return n.registerActiveContext(e),()=>{n.unregisterActiveContext(e)}},[e,n,t])}var t_,n_,r_,i_=t((()=>{t_=n(N(),1),Xg(),n_=y(),r_=(0,t_.createContext)(null)}));function a_(e,t,n={}){let{context:r=`Global`,isActive:i=!0}=n,a=$g();(0,s_.useEffect)(()=>{if(!(!a||!i))return a.registerHandler({action:e,context:r,handler:t})},[e,r,t,a,i]),Eg((0,s_.useCallback)((n,i,o)=>{if(!a)return;let s=[...a.activeContexts,r,`Global`],c=[...new Set(s)],l=a.resolve(n,i,c);switch(l.type){case`match`:a.setPendingChord(null),l.action===e&&t()!==!1&&o.stopImmediatePropagation();break;case`chord_started`:a.setPendingChord(l.pending),o.stopImmediatePropagation();break;case`chord_cancelled`:a.setPendingChord(null);break;case`unbound`:a.setPendingChord(null),o.stopImmediatePropagation();break;case`none`:break}},[e,r,t,a]),{isActive:i})}function o_(e,t={}){let{context:n=`Global`,isActive:r=!0}=t,i=$g();(0,s_.useEffect)(()=>{if(!i||!r)return;let t=[];for(let[r,a]of Object.entries(e))t.push(i.registerHandler({action:r,context:n,handler:a}));return()=>{for(let e of t)e()}},[n,e,i,r]),Eg((0,s_.useCallback)((t,r,a)=>{if(!i)return;let o=[...i.activeContexts,n,`Global`],s=[...new Set(o)],c=i.resolve(t,r,s);switch(c.type){case`match`:if(i.setPendingChord(null),c.action in e){let t=e[c.action];t&&t()!==!1&&a.stopImmediatePropagation()}break;case`chord_started`:i.setPendingChord(c.pending),a.stopImmediatePropagation();break;case`chord_cancelled`:i.setPendingChord(null);break;case`unbound`:i.setPendingChord(null),a.stopImmediatePropagation();break;case`none`:break}},[n,e,i]),{isActive:r})}var s_,c_=t((()=>{s_=n(N(),1),Dg(),i_()}));function l_({children:e,loadBindings:t,subscribeToChanges:n,initWatcher:r,onWarnings:i,onDebugLog:a}){let[o,s]=(0,d_.useState)(()=>{let e=t();return a?.(`[keybindings] KeybindingSetup initialized with ${e.bindings.length} bindings, ${e.warnings.length} warnings`),e}),{bindings:c,warnings:l}=o,[u,d]=(0,d_.useState)(!1);(0,d_.useEffect)(()=>{i?.(l,u)},[l,u,i]);let f=(0,d_.useRef)(null),[p,m]=(0,d_.useState)(null),h=(0,d_.useRef)(null),g=(0,d_.useRef)(new Map),_=(0,d_.useRef)(new Set),v=(0,d_.useCallback)(e=>{_.current.add(e)},[]),y=(0,d_.useCallback)(e=>{_.current.delete(e)},[]),b=(0,d_.useCallback)(()=>{h.current&&(clearTimeout(h.current),h.current=null)},[]),x=(0,d_.useCallback)(e=>{b(),e!==null&&(h.current=setTimeout((e,t)=>{a?.(`[keybindings] Chord timeout - cancelling`),e.current=null,t(null)},p_,f,m)),f.current=e,m(e)},[b,a]);return(0,d_.useEffect)(()=>{r?.();let e=n(e=>{d(!0),s(e),a?.(`[keybindings] Reloaded: ${e.bindings.length} bindings, ${e.warnings.length} warnings`)});return()=>{e(),b()}},[n,r,b,a]),(0,f_.jsxs)(Zg,{bindings:c,pendingChordRef:f,pendingChord:p,setPendingChord:x,activeContexts:_.current,registerActiveContext:v,unregisterActiveContext:y,handlerRegistryRef:g,children:[(0,f_.jsx)(u_,{bindings:c,pendingChordRef:f,setPendingChord:x,activeContexts:_.current,handlerRegistryRef:g}),e]})}function u_({bindings:e,pendingChordRef:t,setPendingChord:n,activeContexts:r,handlerRegistryRef:i}){return Eg((0,d_.useCallback)((a,o,s)=>{if((o.wheelUp||o.wheelDown)&&t.current===null)return;let c=i.current,l=new Set;if(c)for(let e of c.values())for(let t of e)l.add(t.context);let u=[...l,...r,`Global`],d=t.current!==null,f=Yg(a,o,u,e,t.current);switch(f.type){case`chord_started`:n(f.pending),s.stopImmediatePropagation();break;case`match`:if(n(null),d){let e=new Set(u);if(c){let t=c.get(f.action);if(t&&t.size>0){for(let n of t)if(e.has(n.context)){n.handler(),s.stopImmediatePropagation();break}}}}break;case`chord_cancelled`:n(null),s.stopImmediatePropagation();break;case`unbound`:n(null),s.stopImmediatePropagation();break;case`none`:break}},[e,t,n,r,i])),null}var d_,f_,p_,m_=t((()=>{d_=n(N(),1),Dg(),i_(),Xg(),f_=y(),p_=1e3}));function h_(e,t=ie.argv){let n=e.startsWith(`-`)?``:e.length===1?`-`:`--`,r=t.indexOf(n+e),i=t.indexOf(`--`);return r!==-1&&(i===-1||r<i)}var g_=t((()=>{}));function __(e=``){if(/^\d{3,4}$/.test(e)){let t=/(\d{1,2})(\d{2})/.exec(e)??[];return{major:0,minor:Number.parseInt(t[1],10),patch:Number.parseInt(t[2],10)}}let t=(e??``).split(`.`).map(e=>Number.parseInt(e,10));return{major:t[0],minor:t[1],patch:t[2]}}function v_(e){let{CI:t,CURSOR_TRACE_ID:n,FORCE_HYPERLINK:r,NETLIFY:i,TEAMCITY_VERSION:a,TERM_PROGRAM:o,TERM_PROGRAM_VERSION:s,VTE_VERSION:c,TERM:l}=b.env;if(r)return!(r.length>0&&Number.parseInt(r,10)===0);if(h_(`no-hyperlink`)||h_(`no-hyperlinks`)||h_(`hyperlink=false`)||h_(`hyperlink=never`))return!1;if(h_(`hyperlink=true`)||h_(`hyperlink=always`)||i)return!0;if(!h(e)||e&&!e.isTTY)return!1;if(`WT_SESSION`in b.env)return!0;if(b.platform===`win32`||t||a)return!1;if(o){let e=__(s);switch(o){case`iTerm.app`:return e.major===3?e.minor>=1:e.major>3;case`WezTerm`:return/^0-unstable-\d{4}-\d{2}-\d{2}$/.test(s)?s.slice(11)>=`2020-06-20`:e.major>=20200620;case`vscode`:return n?!0:e.major>1||e.major===1&&e.minor>=72;case`ghostty`:return!0;case`zed`:return!0}}if(c){if(c===`0.50.0`)return!1;let e=__(c);return e.major>0||e.minor>=50}switch(l){case`alacritty`:return!0;case`xterm-kitty`:return!0}return!1}var y_,b_=t((()=>{m(),g_(),y_={stdout:v_(b.stdout),stderr:v_(b.stderr)}}));function x_(e){if(e?.stdoutSupported??y_.stdout)return!0;let t=e?.env??process.env,n=t.TERM_PROGRAM;if(n&&S_.includes(n))return!0;let r=t.LC_TERMINAL;return!!(r&&S_.includes(r)||t.TERM?.includes(`kitty`))}var S_,C_=t((()=>{b_(),S_=[`ghostty`,`Hyper`,`kitty`,`alacritty`,`iTerm.app`,`iTerm2`]}));function w_({children:e,url:t,fallback:n}){let r=e??t;return x_()?(0,T_.jsx)(Gf,{children:(0,T_.jsx)(`ink-link`,{href:t,children:r})}):(0,T_.jsx)(Gf,{children:n??r})}var T_,E_=t((()=>{N(),C_(),Jf(),T_=y()}));function D_(e){if(e.length===0)return null;let t=e[0];return t===`c`?{type:`reset`}:t===`7`?{type:`cursor`,action:{type:`save`}}:t===`8`?{type:`cursor`,action:{type:`restore`}}:t===`D`?{type:`cursor`,action:{type:`move`,direction:`down`,count:1}}:t===`M`?{type:`cursor`,action:{type:`move`,direction:`up`,count:1}}:t===`E`?{type:`cursor`,action:{type:`nextLine`,count:1}}:t===`H`||`()`.includes(t)&&e.length>=2?null:{type:`unknown`,sequence:`\x1b${e}`}}var O_=t((()=>{}));function k_(){return{bold:!1,dim:!1,italic:!1,underline:`none`,blink:!1,inverse:!1,hidden:!1,strikethrough:!1,overline:!1,fg:{type:`default`},bg:{type:`default`},underlineColor:{type:`default`}}}var A_=t((()=>{}));function j_(e){if(e===``)return[{value:0,subparams:[],colon:!1}];let t=[],n={value:null,subparams:[],colon:!1},r=``,i=!1;for(let a=0;a<=e.length;a++){let o=e[a];if(o===`;`||o===void 0){let e=r===``?null:parseInt(r,10);i?e!==null&&n.subparams.push(e):n.value=e,t.push(n),n={value:null,subparams:[],colon:!1},r=``,i=!1}else if(o===`:`){let e=r===``?null:parseInt(r,10);i?e!==null&&n.subparams.push(e):(n.value=e,n.colon=!0,i=!0),r=``}else o>=`0`&&o<=`9`&&(r+=o)}return t}function M_(e,t){let n=e[t];if(!n)return null;if(n.colon&&n.subparams.length>=1){if(n.subparams[0]===5&&n.subparams.length>=2)return{index:n.subparams[1]};if(n.subparams[0]===2&&n.subparams.length>=4){let e=+(n.subparams.length>=5);return{r:n.subparams[1+e],g:n.subparams[2+e],b:n.subparams[3+e]}}}let r=e[t+1];if(!r)return null;if(r.value===5&&e[t+2]?.value!==null&&e[t+2]?.value!==void 0)return{index:e[t+2].value};if(r.value===2){let n=e[t+2]?.value,r=e[t+3]?.value,i=e[t+4]?.value;if(n!=null&&r!=null&&i!=null)return{r:n,g:r,b:i}}return null}function N_(e,t){let n=j_(e),r={...t},i=0;for(;i<n.length;){let e=n[i],t=e.value??0;if(t===0){r=k_(),i++;continue}if(t===1){r.bold=!0,i++;continue}if(t===2){r.dim=!0,i++;continue}if(t===3){r.italic=!0,i++;continue}if(t===4){r.underline=e.colon?F_[e.subparams[0]]??`single`:`single`,i++;continue}if(t===5||t===6){r.blink=!0,i++;continue}if(t===7){r.inverse=!0,i++;continue}if(t===8){r.hidden=!0,i++;continue}if(t===9){r.strikethrough=!0,i++;continue}if(t===21){r.underline=`double`,i++;continue}if(t===22){r.bold=!1,r.dim=!1,i++;continue}if(t===23){r.italic=!1,i++;continue}if(t===24){r.underline=`none`,i++;continue}if(t===25){r.blink=!1,i++;continue}if(t===27){r.inverse=!1,i++;continue}if(t===28){r.hidden=!1,i++;continue}if(t===29){r.strikethrough=!1,i++;continue}if(t===53){r.overline=!0,i++;continue}if(t===55){r.overline=!1,i++;continue}if(t>=30&&t<=37){r.fg={type:`named`,name:P_[t-30]},i++;continue}if(t===39){r.fg={type:`default`},i++;continue}if(t>=40&&t<=47){r.bg={type:`named`,name:P_[t-40]},i++;continue}if(t===49){r.bg={type:`default`},i++;continue}if(t>=90&&t<=97){r.fg={type:`named`,name:P_[t-90+8]},i++;continue}if(t>=100&&t<=107){r.bg={type:`named`,name:P_[t-100+8]},i++;continue}if(t===38){let t=M_(n,i);if(t){r.fg=`index`in t?{type:`indexed`,index:t.index}:{type:`rgb`,...t},i+=e.colon?1:`index`in t?3:5;continue}}if(t===48){let t=M_(n,i);if(t){r.bg=`index`in t?{type:`indexed`,index:t.index}:{type:`rgb`,...t},i+=e.colon?1:`index`in t?3:5;continue}}if(t===58){let t=M_(n,i);if(t){r.underlineColor=`index`in t?{type:`indexed`,index:t.index}:{type:`rgb`,...t},i+=e.colon?1:`index`in t?3:5;continue}}if(t===59){r.underlineColor={type:`default`},i++;continue}i++}return r}var P_,F_,I_=t((()=>{A_(),P_=[`black`,`red`,`green`,`yellow`,`blue`,`magenta`,`cyan`,`white`,`brightBlack`,`brightRed`,`brightGreen`,`brightYellow`,`brightBlue`,`brightMagenta`,`brightCyan`,`brightWhite`],F_=[`none`,`single`,`double`,`curly`,`dotted`,`dashed`]}));function L_(e){return e>=9728&&e<=9983||e>=9984&&e<=10175||e>=127744&&e<=129535||e>=129536&&e<=129791||e>=127456&&e<=127487}function R_(e){return e>=4352&&e<=4447||e>=11904&&e<=40959||e>=44032&&e<=55203||e>=63744&&e<=64255||e>=65040&&e<=65055||e>=65072&&e<=65135||e>=65280&&e<=65376||e>=65504&&e<=65510||e>=131072&&e<=196605||e>=196608&&e<=262141}function z_(e){let t=0;for(let n of e)if(t++,t>1)return!0;return!1}function B_(e){if(z_(e))return 2;let t=e.codePointAt(0);return t===void 0?1:L_(t)||R_(t)?2:1}function*V_(e){for(let{segment:t}of ca().segment(e))yield{value:t,width:B_(t)}}function H_(e){return e===``?[]:e.split(/[;:]/).map(e=>e===``?0:parseInt(e,10))}function U_(e){let t=e.slice(2);if(t.length===0)return null;let n=t.charCodeAt(t.length-1),r=t.slice(0,-1),i=``,a=r,o=``;r.length>0&&`?>=`.includes(r[0])&&(i=r[0],a=r.slice(1));let s=a.match(/([^0-9;:]+)$/);s&&(o=s[1],a=a.slice(0,-o.length));let c=H_(a),l=c[0]??1,u=c[1]??1;if(n===lr.SGR&&i===``)return{type:`sgr`,params:a};if(n===lr.CUU)return{type:`cursor`,action:{type:`move`,direction:`up`,count:l}};if(n===lr.CUD)return{type:`cursor`,action:{type:`move`,direction:`down`,count:l}};if(n===lr.CUF)return{type:`cursor`,action:{type:`move`,direction:`forward`,count:l}};if(n===lr.CUB)return{type:`cursor`,action:{type:`move`,direction:`back`,count:l}};if(n===lr.CNL)return{type:`cursor`,action:{type:`nextLine`,count:l}};if(n===lr.CPL)return{type:`cursor`,action:{type:`prevLine`,count:l}};if(n===lr.CHA)return{type:`cursor`,action:{type:`column`,col:l}};if(n===lr.CUP||n===lr.HVP)return{type:`cursor`,action:{type:`position`,row:l,col:u}};if(n===lr.VPA)return{type:`cursor`,action:{type:`row`,row:l}};if(n===lr.ED)return{type:`erase`,action:{type:`display`,region:ur[c[0]??0]??`toEnd`}};if(n===lr.EL)return{type:`erase`,action:{type:`line`,region:dr[c[0]??0]??`toEnd`}};if(n===lr.ECH)return{type:`erase`,action:{type:`chars`,count:l}};if(n===lr.SU)return{type:`scroll`,action:{type:`up`,count:l}};if(n===lr.SD)return{type:`scroll`,action:{type:`down`,count:l}};if(n===lr.DECSTBM)return{type:`scroll`,action:{type:`setRegion`,top:l,bottom:u}};if(n===lr.SCOSC)return{type:`cursor`,action:{type:`save`}};if(n===lr.SCORC)return{type:`cursor`,action:{type:`restore`}};if(n===lr.DECSCUSR&&o===` `)return{type:`cursor`,action:{type:`style`,...fr[l]??fr[0]}};if(i===`?`&&(n===lr.SM||n===lr.RM)){let e=n===lr.SM;if(l===td.CURSOR_VISIBLE)return{type:`cursor`,action:e?{type:`show`}:{type:`hide`}};if(l===td.ALT_SCREEN_CLEAR||l===td.ALT_SCREEN)return{type:`mode`,action:{type:`alternateScreen`,enabled:e}};if(l===td.BRACKETED_PASTE)return{type:`mode`,action:{type:`bracketedPaste`,enabled:e}};if(l===td.MOUSE_NORMAL)return{type:`mode`,action:{type:`mouseTracking`,mode:e?`normal`:`off`}};if(l===td.MOUSE_BUTTON)return{type:`mode`,action:{type:`mouseTracking`,mode:e?`button`:`off`}};if(l===td.MOUSE_ANY)return{type:`mode`,action:{type:`mouseTracking`,mode:e?`any`:`off`}};if(l===td.FOCUS_EVENTS)return{type:`mode`,action:{type:`focusEvents`,enabled:e}}}return{type:`unknown`,sequence:e}}function W_(e){if(e.length<2||e.charCodeAt(0)!==Un.ESC)return`unknown`;let t=e.charCodeAt(1);return t===91?`csi`:t===93?`osc`:t===79?`ss3`:`esc`}var G_,K_=t((()=>{ua(),Gn(),Dr(),md(),O_(),Vd(),I_(),Ar(),A_(),c(),G_=class{constructor(){l(this,`tokenizer`,Or()),l(this,`style`,k_()),l(this,`inLink`,!1),l(this,`linkUrl`,void 0)}reset(){this.tokenizer.reset(),this.style=k_(),this.inLink=!1,this.linkUrl=void 0}feed(e){let t=this.tokenizer.feed(e),n=[];for(let e of t){let t=this.processToken(e);n.push(...t)}return n}processToken(e){switch(e.type){case`text`:return this.processText(e.value);case`sequence`:return this.processSequence(e.value)}}processText(e){let t=[],n=``;for(let r of e)if(r.charCodeAt(0)===Un.BEL){if(n){let e=[...V_(n)];e.length>0&&t.push({type:`text`,graphemes:e,style:{...this.style}}),n=``}t.push({type:`bell`})}else n+=r;if(n){let e=[...V_(n)];e.length>0&&t.push({type:`text`,graphemes:e,style:{...this.style}})}return t}processSequence(e){switch(W_(e)){case`csi`:{let t=U_(e);return t?t.type===`sgr`?(this.style=N_(t.params,this.style),[]):[t]:[]}case`osc`:{let t=e.slice(2);t.endsWith(`\x07`)?t=t.slice(0,-1):t.endsWith(`\x1B\\`)&&(t=t.slice(0,-2));let n=Cd(t);return n?(n.type===`link`&&(n.action.type===`start`?(this.inLink=!0,this.linkUrl=n.action.url):(this.inLink=!1,this.linkUrl=void 0)),[n]):[]}case`esc`:{let t=D_(e.slice(1));return t?[t]:[]}case`ss3`:return[{type:`unknown`,sequence:e}];default:return[{type:`unknown`,sequence:e}]}}}})),q_=t((()=>{K_(),A_()}));function J_(e){let t=new G_().feed(e),n=[],r;for(let e of t){if(e.type===`link`){r=e.action.type===`start`?e.action.url:void 0;continue}if(e.type===`text`){let t=e.graphemes.map(e=>e.value).join(``);if(!t)continue;let i=Y_(e.style);r&&(i.hyperlink=r);let a=n[n.length-1];a&&Z_(a.props,i)?a.text+=t:n.push({text:t,props:i})}}return n}function Y_(e){let t={};e.bold&&(t.bold=!0),e.dim&&(t.dim=!0),e.italic&&(t.italic=!0),e.underline!==`none`&&(t.underline=!0),e.strikethrough&&(t.strikethrough=!0),e.inverse&&(t.inverse=!0);let n=X_(e.fg);n&&(t.color=n);let r=X_(e.bg);return r&&(t.backgroundColor=r),t}function X_(e){switch(e.type){case`named`:return iv[e.name];case`indexed`:return`ansi256(${e.index})`;case`rgb`:return`rgb(${e.r},${e.g},${e.b})`;case`default`:return}}function Z_(e,t){return e.color===t.color&&e.backgroundColor===t.backgroundColor&&e.bold===t.bold&&e.dim===t.dim&&e.italic===t.italic&&e.underline===t.underline&&e.strikethrough===t.strikethrough&&e.inverse===t.inverse&&e.hyperlink===t.hyperlink}function Q_(e){return e.color!==void 0||e.backgroundColor!==void 0||e.dim===!0||e.bold===!0||e.italic===!0||e.underline===!0||e.strikethrough===!0||e.inverse===!0||e.hyperlink!==void 0}function $_(e){return e.color!==void 0||e.backgroundColor!==void 0||e.dim===!0||e.bold===!0||e.italic===!0||e.underline===!0||e.strikethrough===!0||e.inverse===!0}function ev({bold:e,dim:t,children:n,...r}){return t?(0,nv.jsx)(Gf,{...r,dim:!0,children:n}):e?(0,nv.jsx)(Gf,{...r,bold:!0,children:n}):(0,nv.jsx)(Gf,{...r,children:n})}var tv,nv,rv,iv,av=t((()=>{tv=n(N(),1),E_(),Jf(),q_(),nv=y(),rv=tv.memo(function({children:e,dimColor:t}){if(typeof e!=`string`)return t?(0,nv.jsx)(Gf,{dim:!0,children:String(e)}):(0,nv.jsx)(Gf,{children:String(e)});if(e===``)return null;let n=J_(e);if(n.length===0)return null;if(n.length===1&&!Q_(n[0].props))return t?(0,nv.jsx)(Gf,{dim:!0,children:n[0].text}):(0,nv.jsx)(Gf,{children:n[0].text});let r=n.map((e,n)=>{let r=e.props.hyperlink;t&&(e.props.dim=!0);let i=$_(e.props);return r?i?(0,nv.jsx)(w_,{url:r,children:(0,nv.jsx)(ev,{color:e.props.color,backgroundColor:e.props.backgroundColor,dim:e.props.dim,bold:e.props.bold,italic:e.props.italic,underline:e.props.underline,strikethrough:e.props.strikethrough,inverse:e.props.inverse,children:e.text})},n):(0,nv.jsx)(w_,{url:r,children:e.text},n):i?(0,nv.jsx)(ev,{color:e.props.color,backgroundColor:e.props.backgroundColor,dim:e.props.dim,bold:e.props.bold,italic:e.props.italic,underline:e.props.underline,strikethrough:e.props.strikethrough,inverse:e.props.inverse,children:e.text},n):e.text});return t?(0,nv.jsx)(Gf,{dim:!0,children:r}):(0,nv.jsx)(Gf,{children:r})}),iv={black:`ansi:black`,red:`ansi:red`,green:`ansi:green`,yellow:`ansi:yellow`,blue:`ansi:blue`,magenta:`ansi:magenta`,cyan:`ansi:cyan`,white:`ansi:white`,brightBlack:`ansi:blackBright`,brightRed:`ansi:redBright`,brightGreen:`ansi:greenBright`,brightYellow:`ansi:yellowBright`,brightBlue:`ansi:blueBright`,brightMagenta:`ansi:magentaBright`,brightCyan:`ansi:cyanBright`,brightWhite:`ansi:whiteBright`}})),ov,sv=t((()=>{ov=e=>({width:e.yogaNode?.getComputedWidth()??0,height:e.yogaNode?.getComputedHeight()??0})}));function cv({onAction:e,tabIndex:t=0,autoFocus:n,children:r,ref:i,...a}){let[o,s]=(0,lv.useState)(!1),[c,l]=(0,lv.useState)(!1),[u,d]=(0,lv.useState)(!1),f=(0,lv.useRef)(null);(0,lv.useEffect)(()=>()=>{f.current&&clearTimeout(f.current)},[]);let p=(0,lv.useCallback)(t=>{(t.key===`return`||t.key===` `)&&(t.preventDefault(),d(!0),e(),f.current&&clearTimeout(f.current),f.current=setTimeout(e=>e(!1),100,d))},[e]),m=(0,lv.useCallback)(t=>{e()},[e]),h=(0,lv.useCallback)(e=>s(!0),[]),g=(0,lv.useCallback)(e=>s(!1),[]),_=(0,lv.useCallback)(()=>l(!0),[]),v=(0,lv.useCallback)(()=>l(!1),[]),y=typeof r==`function`?r({focused:o,hovered:c,active:u}):r;return(0,uv.jsx)(Hf,{ref:i,tabIndex:t,autoFocus:n,onKeyDown:p,onClick:m,onFocus:h,onBlur:g,onMouseEnter:_,onMouseLeave:v,...a,children:y})}var lv,uv,dv=t((()=>{lv=n(N(),1),Wf(),uv=y()}));function fv({count:e=1}){return(0,pv.jsx)(`ink-text`,{children:`
52
+ `.repeat(e)})}var pv,mv=t((()=>{N(),pv=y()}));function hv(){return(0,gv.jsx)(Hf,{flexGrow:1})}var gv,_v=t((()=>{N(),Wf(),gv=y()}));function vv({children:e,fromLeftEdge:t,...n}){return(0,yv.jsx)(Hf,{...n,noSelect:t?`from-left-edge`:!0,children:e})}var yv,bv=t((()=>{N(),Wf(),yv=y()}));function xv({lines:e,width:t}){return e.length===0?null:(0,Sv.jsx)(`ink-raw-ansi`,{rawText:e.join(`
53
+ `),rawWidth:t,rawHeight:e.length})}var Sv,Cv=t((()=>{N(),Sv=y()}));function wv({children:e,ref:t,stickyScroll:n,...r}){let i=(0,Tv.useRef)(null),[,a]=(0,Tv.useState)(0),o=(0,Tv.useRef)(new Set),s=(0,Tv.useRef)(!1),c=()=>{for(let e of o.current)e()};function l(e){mc(e),ol(),c(),!s.current&&(s.current=!0,queueMicrotask(()=>{s.current=!1,hc(e)}))}return(0,Tv.useImperativeHandle)(t,()=>({scrollTo(e){let t=i.current;t&&(t.stickyScroll=!1,t.pendingScrollDelta=void 0,t.scrollAnchor=void 0,t.scrollTop=Math.max(0,Math.floor(e)),l(t))},scrollToElement(e,t=0){let n=i.current;n&&(n.stickyScroll=!1,n.pendingScrollDelta=void 0,n.scrollAnchor={el:e,offset:t},l(n))},scrollBy(e){let t=i.current;t&&(t.stickyScroll=!1,t.scrollAnchor=void 0,t.pendingScrollDelta=(t.pendingScrollDelta??0)+Math.floor(e),l(t))},scrollToBottom(){let e=i.current;e&&(e.pendingScrollDelta=void 0,e.stickyScroll=!0,mc(e),c(),a(e=>e+1))},getScrollTop(){return i.current?.scrollTop??0},getPendingDelta(){return i.current?.pendingScrollDelta??0},getScrollHeight(){return i.current?.scrollHeight??0},getFreshScrollHeight(){return(i.current?.childNodes[0])?.yogaNode?.getComputedHeight()??i.current?.scrollHeight??0},getViewportHeight(){return i.current?.scrollViewportHeight??0},getViewportTop(){return i.current?.scrollViewportTop??0},isSticky(){let e=i.current;return e?e.stickyScroll??!!e.attributes.stickyScroll:!1},subscribe(e){return o.current.add(e),()=>o.current.delete(e)},setClampBounds(e,t){let n=i.current;n&&(n.scrollClampMin=e,n.scrollClampMax=t)}}),[]),(0,Ev.jsx)(`ink-box`,{ref:e=>{i.current=e,e&&(e.scrollTop??(e.scrollTop=0))},style:{flexWrap:`nowrap`,flexDirection:r.flexDirection??`row`,flexGrow:r.flexGrow??0,flexShrink:r.flexShrink??1,...r,overflowX:`scroll`,overflowY:`scroll`},...n?{stickyScroll:!0}:{},children:(0,Ev.jsx)(Hf,{flexDirection:`column`,flexGrow:1,flexShrink:0,width:`100%`,children:e})})}var Tv,Ev,Dv=t((()=>{Tv=n(N(),1),vc(),Tl(),Wf(),Ev=y()}));function Ov({children:e,mouseTracking:t=!0}){let n=(0,kv.useContext)(op),r=(0,kv.useContext)(Ph);return(0,kv.useInsertionEffect)(()=>{let e=jp.get(process.stdout);if(r)return r(ud+`\x1B[2J\x1B[H`+(t?fd:``)),e?.setAltScreenActive(!0,t),()=>{e?.setAltScreenActive(!1),e?.clearTextSelection(),r((t?pd:``)+dd)}},[r,t]),(0,Av.jsx)(Hf,{flexDirection:`column`,height:n?.rows??24,width:`100%`,flexShrink:0,children:e})}var kv,Av,jv=t((()=>{kv=n(N(),1),Mp(),md(),Ih(),Wf(),sp(),Av=y()})),Mv,Nv,Pv=t((()=>{Mv=n(N(),1),hf(),Nv=()=>(0,Mv.useContext)(mf)}));function Fv(){let e=(0,Iv.useContext)(op),t=(0,Iv.useRef)(null),n=(0,Iv.useRef)({isVisible:!0}),r=(0,Iv.useCallback)(e=>{t.current=e},[]);return(0,Iv.useLayoutEffect)(()=>{let r=t.current;if(!r?.yogaNode||!e)return;let i=r.yogaNode.getComputedHeight(),a=e.rows,o=r.yogaNode.getComputedTop(),s=r.parentNode,c=r.yogaNode;for(;s;)s.yogaNode&&(o+=s.yogaNode.getComputedTop(),c=s.yogaNode),s.scrollTop&&(o-=s.scrollTop),s=s.parentNode;let l=c.getComputedHeight(),u=o+i,d=+(l>a),f=Math.max(0,l-a)+d,p=f+a,m=u>f&&o<p;m!==n.current.isVisible&&(n.current={isVisible:m})}),[r,n.current]}var Iv,Lv=t((()=>{Iv=n(N(),1),sp()}));function Rv(e=16){let t=(0,zv.useContext)(kf),[n,{isVisible:r}]=Fv(),[i,a]=(0,zv.useState)(()=>t?.now()??0),o=r&&e!==null;return(0,zv.useEffect)(()=>{if(!t||!o)return;let n=t.now();return t.subscribe(()=>{let r=t.now();r-n>=e&&(n=r,a(r))},!0)},[t,e,o]),[n,i]}var zv,Bv=t((()=>{zv=n(N(),1),jf(),Lv()}));function Vv(e){let t=(0,Uv.useContext)(kf),[n,r]=(0,Uv.useState)(()=>t?.now()??0);return(0,Uv.useEffect)(()=>{if(!t)return;let n=t.now();return t.subscribe(()=>{let i=t.now();i-n>=e&&(n=i,r(i))},!1)},[t,e]),n}function Hv(e,t){let n=(0,Uv.useRef)(e);n.current=e;let r=(0,Uv.useContext)(kf);(0,Uv.useEffect)(()=>{if(!r||t===null)return;let e=r.now();return r.subscribe(()=>{let i=r.now();i-e>=t&&(e=i,n.current())},!1)},[r,t])}var Uv,Wv=t((()=>{Uv=n(N(),1),jf()}));function Gv(){(0,qv.useContext)(rp);let e=jp.get(process.stdout);return(0,qv.useMemo)(()=>e?{copySelection:()=>e.copySelection(),copySelectionNoClear:()=>e.copySelectionNoClear(),clearSelection:()=>e.clearTextSelection(),hasSelection:()=>e.hasTextSelection(),getState:()=>e.selection,subscribe:t=>e.subscribeToSelectionChange(t),shiftAnchor:(t,n,r)=>Fu(e.selection,t,n,r),shiftSelection:(t,n,r)=>e.shiftSelectionForScroll(t,n,r),moveFocus:t=>e.moveSelectionFocus(t),captureScrolledRows:(t,n,r)=>e.captureScrolledRows(t,n,r),setSelectionBgColor:t=>e.setSelectionBgColor(t)}:{copySelection:()=>``,copySelectionNoClear:()=>``,clearSelection:()=>{},hasSelection:()=>!1,getState:()=>null,subscribe:()=>()=>{},shiftAnchor:()=>{},shiftSelection:()=>{},moveFocus:()=>{},captureScrolledRows:()=>{},setSelectionBgColor:()=>{}},[e])}function Kv(){(0,qv.useContext)(rp);let e=jp.get(process.stdout);return(0,qv.useSyncExternalStore)(e?e.subscribeToSelectionChange:Jv,e?e.hasTextSelection:Yv)}var qv,Jv,Yv,Xv=t((()=>{qv=n(N(),1),ip(),Mp(),Ku(),Jv=()=>()=>{},Yv=()=>!1}));function Zv(){let e=(0,Qv.useContext)(op);if(!e)throw Error(`useTerminalSize must be used within an Ink App component`);return e}var Qv,$v=t((()=>{Qv=n(N(),1),sp()}));function ey(e,t){let[n,r]=(0,ty.useState)(!1);return(0,ty.useEffect)(()=>{r(!1);let t=setTimeout(r,e,!0);return()=>clearTimeout(t)},[e,t]),n}var ty,ny=t((()=>{ty=n(N(),1)}));function ry(e,t){let[n,r]=(0,iy.useState)(e),i=(0,iy.useRef)(0);return(0,iy.useEffect)(()=>{let n=Date.now()-i.current;if(n>=t){i.current=Date.now(),r(e);return}let a=setTimeout((e,t,n)=>{e.current=Date.now(),t(n)},t-n,i,r,e);return()=>clearTimeout(a)},[e,t]),n}var iy,ay=t((()=>{iy=n(N(),1)}));function oy(e,t,n){let r=(0,sy.useRef)(0),i=(0,sy.useRef)(void 0),a=(0,sy.useCallback)(()=>{i.current&&(clearTimeout(i.current),i.current=void 0)},[]);return(0,sy.useEffect)(()=>()=>{a()},[a]),(0,sy.useCallback)(()=>{let o=Date.now();o-r.current<=800&&i.current!==void 0?(a(),e(!1),t()):(n?.(),e(!0),a(),i.current=setTimeout((e,t)=>{e(!1),t.current=void 0},800,e,i)),r.current=o},[e,t,n,a])}var sy,cy,ly=t((()=>{sy=n(N(),1),cy=800}));function uy(e){let t=(0,dy.useContext)(Ph),n=(0,dy.useRef)(null);(0,dy.useEffect)(()=>{if(e===null){n.current!==null&&t&&kd()&&t(_d(Bd)),n.current=null;return}n.current=e,!(!t||!kd())&&t(_d(Ad(py[e])))},[e,t])}var dy,fy,py,my=t((()=>{dy=n(N(),1),Vd(),Ih(),fy=(e,t,n)=>({type:`rgb`,r:e,g:t,b:n}),py={idle:{indicator:fy(0,215,95),status:`Idle`,statusColor:fy(136,136,136)},busy:{indicator:fy(255,149,0),status:`Working…`,statusColor:fy(255,149,0)},waiting:{indicator:fy(95,135,255),status:`Waiting`,statusColor:fy(95,135,255)}}}));function hy(e){let t=(0,gy.useContext)(Ph);(0,gy.useEffect)(()=>{if(e===null||!t)return;let n=U(e);process.platform===`win32`?process.title=n:t(gd(Pd.SET_TITLE_AND_ICON,n))},[e,t])}var gy,_y=t((()=>{gy=n(N(),1),sa(),Vd(),Ih()}));function vy(){(0,yy.useContext)(rp);let e=jp.get(process.stdout);return(0,yy.useMemo)(()=>e?{setQuery:t=>e.setSearchHighlight(t),scanElement:t=>e.scanElementSubtree(t),setPositions:t=>e.setSearchPositions(t)}:{setQuery:()=>{},scanElement:()=>[],setPositions:()=>{}},[e])}var yy,by=t((()=>{yy=n(N(),1),ip(),Mp()}));function xy({line:e,column:t,active:n}){let r=(0,Sy.useContext)(Nf),i=(0,Sy.useRef)(null),a=(0,Sy.useCallback)(e=>{i.current=e},[]);return(0,Sy.useLayoutEffect)(()=>{let a=i.current;n&&a?r({relativeX:t,relativeY:e,node:a}):r(null,a)}),(0,Sy.useLayoutEffect)(()=>()=>{r(null,i.current)},[r]),a}var Sy,Cy=t((()=>{Sy=n(N(),1),Pf()}));function wy(){let e=process.env.COLORFGBG;if(!e)return;let t=e.split(`;`);if(t.length<2)return;let n=parseInt(t[t.length-1],10);if(!isNaN(n))return n>=8?`light`:`dark`}function Ty(){return Ey===void 0&&(Ey=wy()??`dark`),Ey}var Ey,Dy=t((()=>{}));function Oy(e){Ly=e.loadTheme,Ry=e.saveTheme}function ky(){return Ly()}function Ay(e){Ry(e)}function jy({children:e,initialState:t,onThemeSave:n=Ay}){let[r,i]=(0,Fy.useState)(t??ky),[a,o]=(0,Fy.useState)(null),[s,c]=(0,Fy.useState)(()=>(t??r)===`auto`?Ty():`dark`),l=a??r,{internal_querier:u}=Cg();(0,Fy.useEffect)(()=>{},[l,u]);let d=l===`auto`?s:l,f=(0,Fy.useMemo)(()=>({themeSetting:r,setThemeSetting:e=>{i(e),o(null),e===`auto`&&c(Ty()),n?.(e)},setPreviewTheme:e=>{o(e),e===`auto`&&c(Ty())},savePreview:()=>{a!==null&&(i(a),o(null),n?.(a))},cancelPreview:()=>{a!==null&&o(null)},currentTheme:d}),[r,a,d,n]);return(0,Iy.jsx)(By.Provider,{value:f,children:e})}function My(){let{currentTheme:e,setThemeSetting:t}=(0,Fy.useContext)(By);return[e,t]}function Ny(){return(0,Fy.useContext)(By).themeSetting}function Py(){let{setPreviewTheme:e,savePreview:t,cancelPreview:n}=(0,Fy.useContext)(By);return{setPreviewTheme:e,savePreview:t,cancelPreview:n}}var Fy,Iy,Ly,Ry,zy,By,Vy=t((()=>{Fy=n(N(),1),wg(),Dy(),Iy=y(),Ly=()=>`dark`,Ry=()=>{},zy=`dark`,By=(0,Fy.createContext)({themeSetting:zy,setThemeSetting:()=>{},setPreviewTheme:()=>{},savePreview:()=>{},cancelPreview:()=>{},currentTheme:zy})}));function Hy(e,t){if(e)return e.startsWith(`rgb(`)||e.startsWith(`#`)||e.startsWith(`ansi256(`)||e.startsWith(`ansi:`)?e:t[e]}function Uy({borderColor:e,borderTopColor:t,borderBottomColor:n,borderLeftColor:r,borderRightColor:i,backgroundColor:a,children:o,ref:s,...c}){let[l]=My(),u=tg(l);return(0,Wy.jsx)(Hf,{ref:s,borderColor:Hy(e,u),borderTopColor:Hy(t,u),borderBottomColor:Hy(n,u),borderLeftColor:Hy(r,u),borderRightColor:Hy(i,u),backgroundColor:Hy(a,u),...c,children:o})}var Wy,Gy=t((()=>{N(),Wf(),fg(),Vy(),Wy=y()}));function Ky(e,t){if(e)return e.startsWith(`rgb(`)||e.startsWith(`#`)||e.startsWith(`ansi256(`)||e.startsWith(`ansi:`)?e:t[e]}function $({color:e,backgroundColor:t,dimColor:n=!1,bold:r=!1,italic:i=!1,underline:a=!1,strikethrough:o=!1,inverse:s=!1,wrap:c=`wrap`,children:l}){let[u]=My(),d=tg(u),f=(0,qy.useContext)(Yy);return(0,Jy.jsx)(Gf,{color:!e&&f?Ky(f,d):n?d.inactive:Ky(e,d),backgroundColor:t?d[t]:void 0,bold:r,italic:i,underline:a,strikethrough:o,inverse:s,wrap:c,children:l})}var qy,Jy,Yy,Xy=t((()=>{qy=n(N(),1),Jf(),fg(),Vy(),Jy=y(),Yy=qy.createContext(void 0)}));function Zy(e,t,n=`foreground`){return r=>e?e.startsWith(`rgb(`)||e.startsWith(`#`)||e.startsWith(`ansi256(`)||e.startsWith(`ansi:`)?In(r,e,n):In(r,tg(t)[e],n):r}var Qy=t((()=>{Ln(),fg()}));function $y({query:e,placeholder:t=`Search…`,isFocused:n,isTerminalFocused:r,prefix:i=`⌕`,width:a,cursorOffset:o,borderless:s=!1}){let c=o??e.length;return(0,eb.jsx)(Uy,{flexShrink:0,borderStyle:s?void 0:`round`,borderColor:n?`suggestion`:void 0,borderDimColor:!n,paddingX:+!s,width:a,children:(0,eb.jsxs)($,{dimColor:!n,children:[i,` `,n?(0,eb.jsx)(eb.Fragment,{children:e?r?(0,eb.jsxs)(eb.Fragment,{children:[(0,eb.jsx)($,{children:e.slice(0,c)}),(0,eb.jsx)($,{inverse:!0,children:c<e.length?e[c]:` `}),c<e.length&&(0,eb.jsx)($,{children:e.slice(c+1)})]}):(0,eb.jsx)($,{children:e}):r?(0,eb.jsxs)(eb.Fragment,{children:[(0,eb.jsx)($,{inverse:!0,children:t.charAt(0)}),(0,eb.jsx)($,{dimColor:!0,children:t.slice(1)})]}):(0,eb.jsx)($,{dimColor:!0,children:t})}):e?(0,eb.jsx)($,{children:e}):(0,eb.jsx)($,{children:t})]})})}var eb,tb=t((()=>{N(),xx(),eb=y()}));function nb(e,t){let n=0,r;return()=>{let i=Date.now();i-n<=ab&&r!==void 0?(clearTimeout(r),r=void 0,e(!1),t()):(e(!0),clearTimeout(r),r=setTimeout(()=>{e(!1),r=void 0},ab)),n=i}}function rb(e,t,n=!0){let[r,i]=(0,ib.useState)({pending:!1,keyName:null}),a=nb(e=>i({pending:e,keyName:e?`Ctrl-C`:null}),()=>process.exit(0)),o=nb(e=>i({pending:e,keyName:e?`Ctrl-D`:null}),()=>process.exit(0));return Eg((0,ib.useCallback)((e,t)=>{n&&(t.ctrl&&t.name===`c`?a():t.ctrl&&t.name===`d`&&o())},[n,a,o]),{isActive:n}),r}var ib,ab,ob=t((()=>{ib=n(N(),1),Dg(),ab=800}));function sb({shortcut:e,action:t,parens:n=!1,bold:r=!1}){let i=r?(0,cb.jsx)(Gf,{bold:!0,children:e}):e;return n?(0,cb.jsxs)(Gf,{children:[`(`,i,` to `,t,`)`]}):(0,cb.jsxs)(Gf,{children:[i,` to `,t]})}var cb,lb=t((()=>{N(),Jf(),cb=y()}));function ub({fallback:e,description:t,parens:n,bold:r}){return(0,db.jsx)(sb,{shortcut:e,action:t,parens:n,bold:r})}var db,fb=t((()=>{N(),lb(),db=y()}));function pb({children:e}){let t=mb.Children.toArray(e);return t.length===0?null:(0,hb.jsx)(hb.Fragment,{children:t.map((e,t)=>(0,hb.jsxs)(mb.Fragment,{children:[t>0&&(0,hb.jsx)($,{dimColor:!0,children:` · `}),e]},(0,mb.isValidElement)(e)?e.key??t:t))})}var mb,hb,gb=t((()=>{mb=n(N(),1),xx(),hb=y()}));function _b(){return(0,yb.useContext)(bb)!==null}function vb(){return(0,yb.useContext)(bb)?.scrollRef??null}var yb,bb,xb=t((()=>{yb=n(N(),1),bb=(0,yb.createContext)(null)}));function Sb({width:e,color:t,char:n=`─`,padding:r=0,title:i}){let{columns:a}=Zv(),o=Math.max(0,(e??a)-r);if(i){let e=va(i)+2,r=Math.max(0,o-e),a=Math.floor(r/2),s=r-a;return(0,Cb.jsxs)($,{color:t,dimColor:!t,children:[n.repeat(a),` `,(0,Cb.jsx)($,{dimColor:!0,children:(0,Cb.jsx)(rv,{children:i})}),` `,n.repeat(s)]})}return(0,Cb.jsx)($,{color:t,dimColor:!t,children:n.repeat(o)})}var Cb,wb=t((()=>{N(),$v(),ya(),xx(),Cb=y()}));function Tb({children:e,color:t}){return _b()?(0,Eb.jsx)(Uy,{flexDirection:`column`,paddingX:1,flexShrink:0,children:e}):(0,Eb.jsxs)(Uy,{flexDirection:`column`,paddingTop:1,children:[(0,Eb.jsx)(Sb,{color:t}),(0,Eb.jsx)(Uy,{flexDirection:`column`,paddingX:2,children:e})]})}var Eb,Db=t((()=>{N(),xb(),xx(),wb(),Eb=y()}));function Ob({title:e,subtitle:t,children:n,onCancel:r,color:i=`permission`,hideInputGuide:a,hideBorder:o,inputGuide:s,isCancelActive:c=!0}){let l=rb(void 0,void 0,c);a_(`confirm:no`,r,{context:`Confirmation`,isActive:c});let u=l.pending?(0,kb.jsxs)($,{children:[`Press `,l.keyName,` again to exit`]}):(0,kb.jsxs)(pb,{children:[(0,kb.jsx)(sb,{shortcut:`Enter`,action:`confirm`}),(0,kb.jsx)(ub,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]}),d=(0,kb.jsxs)(kb.Fragment,{children:[(0,kb.jsxs)(Uy,{flexDirection:`column`,gap:1,children:[(0,kb.jsxs)(Uy,{flexDirection:`column`,children:[(0,kb.jsx)($,{bold:!0,color:i,children:e}),t&&(0,kb.jsx)($,{dimColor:!0,children:t})]}),n]}),!a&&(0,kb.jsx)(Uy,{marginTop:1,children:(0,kb.jsx)($,{dimColor:!0,italic:!0,children:s?s(l):u})})]});return o?d:(0,kb.jsx)(Tb,{color:i,children:d})}var kb,Ab=t((()=>{N(),ob(),xx(),c_(),fb(),gb(),lb(),Db(),kb=y()}));function jb({isActive:e,onExit:t,onCancel:n,onExitUp:r,columns:i,initialQuery:a=``,backspaceExitsOnEmpty:o=!0}){let{columns:s}=Zv(),[c,l]=(0,Mb.useState)(a),[u,d]=(0,Mb.useState)(a.length),f=(0,Mb.useCallback)(e=>{l(e),d(e.length)},[]),p=i=>{if(e){if(i.key===`return`||i.key===`down`){i.preventDefault(),t();return}if(i.key===`up`){i.preventDefault(),r?.();return}if(i.key===`escape`){i.preventDefault(),n?n():c.length>0?(l(``),d(0)):t();return}if(i.key===`backspace`){if(i.preventDefault(),c.length===0){o&&(n??t)();return}let e=Math.max(0,u-1);l(c.slice(0,e)+c.slice(u)),d(e);return}if(i.key===`delete`){i.preventDefault(),u<c.length&&l(c.slice(0,u)+c.slice(u+1));return}if(i.key===`left`){i.preventDefault(),d(Math.max(0,u-1));return}if(i.key===`right`){i.preventDefault(),d(Math.min(c.length,u+1));return}if(i.key===`home`){i.preventDefault(),d(0);return}if(i.key===`end`){i.preventDefault(),d(c.length);return}if(i.ctrl){switch(i.key.toLowerCase()){case`a`:i.preventDefault(),d(0);return;case`e`:i.preventDefault(),d(c.length);return;case`b`:i.preventDefault(),d(Math.max(0,u-1));return;case`f`:i.preventDefault(),d(Math.min(c.length,u+1));return;case`d`:if(i.preventDefault(),c.length===0){(n??t)();return}u<c.length&&l(c.slice(0,u)+c.slice(u+1));return;case`h`:{if(i.preventDefault(),c.length===0){o&&(n??t)();return}let e=Math.max(0,u-1);l(c.slice(0,e)+c.slice(u)),d(e);return}case`c`:i.preventDefault(),n?.();return;case`u`:i.preventDefault(),l(c.slice(u)),d(0);return;case`k`:i.preventDefault(),l(c.slice(0,u));return;case`w`:{i.preventDefault();let e=c.slice(0,u),t=c.slice(u),n=e.replace(/\S+\s*$/,``);l(n+t),d(n.length);return}}return}i.key!==`tab`&&i.key.length>=1&&!Nb.has(i.key)&&(i.preventDefault(),l(c.slice(0,u)+i.key+c.slice(u)),d(u+1))}};return Eg((e,t,n)=>{p(new xp(n.keypress))},{isActive:e}),{query:c,setQuery:f,cursorOffset:u,handleKeyDown:p}}var Mb,Nb,Pb=t((()=>{Mb=n(N(),1),Sp(),Dg(),$v(),Nb=new Set([`pageup`,`pagedown`,`insert`,`wheelup`,`wheeldown`,`mouse`,`f1`,`f2`,`f3`,`f4`,`f5`,`f6`,`f7`,`f8`,`f9`,`f10`,`f11`,`f12`])}));function Fb({isFocused:e,isSelected:t=!1,children:n,description:r,showScrollDown:i,showScrollUp:a,styled:o=!0,disabled:s=!1,declareCursor:c}){function l(){return s?(0,Ib.jsx)($,{children:` `}):e?(0,Ib.jsx)($,{color:`suggestion`,children:p.pointer}):i?(0,Ib.jsx)($,{dimColor:!0,children:p.arrowDown}):a?(0,Ib.jsx)($,{dimColor:!0,children:p.arrowUp}):(0,Ib.jsx)($,{children:` `})}function u(){if(s)return`inactive`;if(o){if(t)return`success`;if(e)return`suggestion`}}let d=u();return(0,Ib.jsxs)(Uy,{ref:xy({line:0,column:0,active:e&&!s&&c!==!1}),flexDirection:`column`,children:[(0,Ib.jsxs)(Uy,{flexDirection:`row`,gap:1,children:[l(),o?(0,Ib.jsx)($,{color:d,dimColor:s,children:n}):n,t&&!s&&(0,Ib.jsx)($,{color:`success`,children:p.tick})]}),r&&(0,Ib.jsx)(Uy,{paddingLeft:2,children:(0,Ib.jsx)($,{color:`inactive`,children:r})})]})}var Ib,Lb=t((()=>{d(),N(),Cy(),xx(),Ib=y()}));function Rb({title:e,placeholder:t=`Type to search…`,initialQuery:n,items:r,getKey:i,renderItem:a,renderPreview:o,previewPosition:s=`bottom`,visibleCount:c=Ub,direction:l=`down`,onQueryChange:u,onSelect:d,onTab:f,onShiftTab:p,onFocus:m,onCancel:h,emptyMessage:g=`No results`,matchLabel:_,selectAction:v=`select`,extraHints:y}){let b=Sf(),{rows:x,columns:S}=Zv(),[C,w]=(0,Vb.useState)(0),T=Math.max(Gb,Math.min(c,x-Wb-+!!_)),E=S<120,D=e=>{w(t=>Dl(t+e,0,r.length-1))},{query:O,cursorOffset:ee}=jb({isActive:!0,onExit:()=>{},onCancel:h,initialQuery:n,backspaceExitsOnEmpty:!1}),te=e=>{if(e.key===`up`||e.ctrl&&e.key===`p`){e.preventDefault(),e.stopImmediatePropagation(),D(l===`up`?1:-1);return}if(e.key===`down`||e.ctrl&&e.key===`n`){e.preventDefault(),e.stopImmediatePropagation(),D(l===`up`?-1:1);return}if(e.key===`return`){e.preventDefault(),e.stopImmediatePropagation();let t=r[C];t&&d(t);return}if(e.key===`tab`){e.preventDefault(),e.stopImmediatePropagation();let t=r[C];if(!t)return;let n=e.shift?p??f:f;n?n.handler(t):d(t)}};(0,Vb.useEffect)(()=>{u(O),w(0)},[O]),(0,Vb.useEffect)(()=>{w(e=>Dl(e,0,r.length-1))},[r.length]);let k=r[C];(0,Vb.useEffect)(()=>{m?.(k)},[k]);let ne=Dl(C-T+1,0,r.length-T),re=r.slice(ne,ne+T),ie=typeof g==`function`?g(O):g,ae=(0,Hb.jsx)($y,{query:O,cursorOffset:ee,placeholder:t,isFocused:!0,isTerminalFocused:b}),oe=(0,Hb.jsx)(zb,{visible:re,windowStart:ne,visibleCount:T,total:r.length,focusedIndex:C,direction:l,getKey:i,renderItem:a,emptyText:ie}),se=o&&k?(0,Hb.jsx)(Uy,{flexDirection:`column`,flexGrow:1,children:o(k)}):null,ce=o&&s===`right`?(0,Hb.jsxs)(Uy,{flexDirection:`row`,gap:2,height:T+ +!!_,children:[(0,Hb.jsxs)(Uy,{flexDirection:`column`,flexShrink:0,children:[oe,_&&(0,Hb.jsx)($,{dimColor:!0,children:_})]}),se??(0,Hb.jsx)(Uy,{flexGrow:1})]}):(0,Hb.jsxs)(Uy,{flexDirection:`column`,children:[oe,_&&(0,Hb.jsx)($,{dimColor:!0,children:_}),se]}),le=l!==`up`;return(0,Hb.jsx)(Tb,{color:`permission`,children:(0,Hb.jsxs)(Uy,{flexDirection:`column`,gap:1,tabIndex:0,autoFocus:!0,onKeyDown:te,children:[(0,Hb.jsx)($,{bold:!0,color:`permission`,children:e}),le&&ae,ce,!le&&ae,(0,Hb.jsx)($,{dimColor:!0,children:(0,Hb.jsxs)(pb,{children:[(0,Hb.jsx)(sb,{shortcut:`↑/↓`,action:E?`nav`:`navigate`}),(0,Hb.jsx)(sb,{shortcut:`Enter`,action:E?Bb(v):v}),f&&(0,Hb.jsx)(sb,{shortcut:`Tab`,action:f.action}),p&&!E&&(0,Hb.jsx)(sb,{shortcut:`shift+tab`,action:p.action}),(0,Hb.jsx)(sb,{shortcut:`Esc`,action:`cancel`}),y]})})]})})}function zb({visible:e,windowStart:t,visibleCount:n,total:r,focusedIndex:i,direction:a,getKey:o,renderItem:s,emptyText:c}){if(e.length===0)return(0,Hb.jsx)(Uy,{height:n,flexShrink:0,children:(0,Hb.jsx)($,{dimColor:!0,children:c})});let l=e.map((c,l)=>{let u=t+l===i,d=l===0&&t>0,f=l===e.length-1&&t+n<r;return(0,Hb.jsx)(Fb,{isFocused:u,showScrollUp:a===`up`?f:d,showScrollDown:a===`up`?d:f,styled:!1,children:s(c,u)},o(c))});return(0,Hb.jsx)(Uy,{height:n,flexShrink:0,flexDirection:a===`up`?`column-reverse`:`column`,children:l})}function Bb(e){let t=e.indexOf(` `);return t===-1?e:e.slice(0,t)}var Vb,Hb,Ub,Wb,Gb,Kb=t((()=>{N(),Vb=n(N(),1),Pb(),$v(),Ol(),xx(),tb(),gb(),lb(),Lb(),Db(),Hb=y(),Ub=8,Wb=10,Gb=2}));function qb(){let[e,t]=(0,Jb.useState)(0);return(0,Jb.useEffect)(()=>{let e=setInterval(()=>{t(e=>(e+1)%Xb.length)},80);return()=>clearInterval(e)},[]),(0,Yb.jsx)($,{children:Xb[e]})}var Jb,Yb,Xb,Zb=t((()=>{Jb=n(N(),1),xx(),Yb=y(),Xb=[`⠋`,`⠙`,`⠹`,`⠸`,`⠼`,`⠴`,`⠦`,`⠧`,`⠇`,`⠏`]}));function Qb({message:e,bold:t=!1,dimColor:n=!1,subtitle:r}){return(0,$b.jsxs)(Uy,{flexDirection:`column`,children:[(0,$b.jsxs)(Uy,{flexDirection:`row`,children:[(0,$b.jsx)(qb,{}),(0,$b.jsxs)($,{bold:t,dimColor:n,children:[` `,e]})]}),r&&(0,$b.jsx)($,{dimColor:!0,children:r})]})}var $b,ex=t((()=>{N(),xx(),Zb(),$b=y()}));function tx({ratio:e,width:t,fillColor:n,emptyColor:r}){let i=Math.min(1,Math.max(0,e)),a=Math.floor(i*t),o=[rx[rx.length-1].repeat(a)];if(a<t){let e=i*t-a,n=Math.floor(e*rx.length);o.push(rx[n]);let r=t-a-1;r>0&&o.push(rx[0].repeat(r))}return(0,nx.jsx)($,{color:n,backgroundColor:r,children:o.join(``)})}var nx,rx,ix=t((()=>{N(),xx(),nx=y(),rx=[` `,`▏`,`▎`,`▍`,`▌`,`▋`,`▊`,`▉`,`█`]}));function ax({children:e,lock:t=`always`}){let[n,{isVisible:r}]=Fv(),{rows:i}=Zv(),a=(0,ox.useRef)(null),o=(0,ox.useRef)(0),[s,c]=(0,ox.useState)(0),l=(0,ox.useCallback)(e=>{n(e)},[n]),u=t===`always`||!r;return(0,ox.useLayoutEffect)(()=>{if(!a.current)return;let{height:e}=ov(a.current);e>o.current&&(o.current=Math.min(e,i),c(o.current))}),(0,sx.jsx)(Uy,{minHeight:u?s:void 0,ref:l,children:(0,sx.jsx)(Uy,{ref:a,flexDirection:`column`,children:e})})}var ox,sx,cx=t((()=>{ox=n(N(),1),$v(),Lv(),xx(),sx=y()}));function lx({status:e,withSpace:t=!1}){let n=dx[e];return(0,ux.jsxs)($,{color:n.color,dimColor:!n.color,children:[n.icon,t&&` `]})}var ux,dx,fx=t((()=>{d(),N(),xx(),ux=y(),dx={success:{icon:p.tick,color:`success`},error:{icon:p.cross,color:`error`},warning:{icon:p.warning,color:`warning`},info:{icon:p.info,color:`suggestion`},pending:{icon:p.circle,color:void 0},loading:{icon:`…`,color:void 0}}}));function px({title:e,color:t,defaultTab:n,children:r,hidden:i,useFullWidth:a,selectedTab:o,onTabChange:s,banner:c,disableNavigation:l,initialHeaderFocused:u=!0,contentHeight:d,navFromContent:f=!1}){let{columns:p}=Zv(),m=r.map(e=>[e.props.id??e.props.title,e.props.title]),h=n?m.findIndex(e=>n===e[0]):0,g=o!==void 0,[_,v]=(0,_x.useState)(h===-1?0:h),y=g?m.findIndex(e=>e[0]===o):-1,b=g?y===-1?0:y:_,x=vb(),[S,C]=(0,_x.useState)(u),w=(0,_x.useCallback)(()=>C(!0),[]),T=(0,_x.useCallback)(()=>C(!1),[]),[E,D]=(0,_x.useState)(0),O=(0,_x.useCallback)(()=>(D(e=>e+1),()=>D(e=>e-1)),[]),ee=E>0,te=e=>{let t=(b+m.length+e)%m.length,n=m[t]?.[0];g&&s&&n?s(n):v(t),C(!0)};o_({"tabs:next":()=>te(1),"tabs:previous":()=>te(-1)},{context:`Tabs`,isActive:!i&&!l&&S});let k=e=>{!S||!ee||i||e.key===`down`&&(e.preventDefault(),C(!1))};o_({"tabs:next":()=>{te(1),C(!0)},"tabs:previous":()=>{te(-1),C(!0)}},{context:`Tabs`,isActive:f&&!S&&ee&&!i&&!l});let ne=(e?va(e)+1:0)+m.reduce((e,[,t])=>e+(t?va(t):0)+2+1,0),re=a?Math.max(0,p-ne):0,ie=a?p:void 0;return(0,vx.jsx)(yx.Provider,{value:{selectedTab:m[b][0],width:ie,headerFocused:S,focusHeader:w,blurHeader:T,registerOptIn:O},children:(0,vx.jsxs)(Uy,{flexDirection:`column`,tabIndex:0,autoFocus:!0,onKeyDown:k,flexShrink:x?0:void 0,children:[!i&&(0,vx.jsxs)(Uy,{flexDirection:`row`,gap:1,flexShrink:x?0:void 0,children:[e!==void 0&&(0,vx.jsx)($,{bold:!0,color:t,children:e}),m.map(([e,n],r)=>{let i=b===r,a=t&&i&&S;return(0,vx.jsxs)($,{backgroundColor:a?t:void 0,color:a?`inverseText`:void 0,inverse:i&&!a,bold:i,children:[` `,n,` `]},e)}),re>0&&(0,vx.jsx)($,{children:` `.repeat(re)})]}),c,x?(0,vx.jsx)(Uy,{width:ie,marginTop:+!i,flexShrink:0,children:(0,vx.jsx)(wv,{ref:x,flexDirection:`column`,flexShrink:0,children:r},b)}):(0,vx.jsx)(Uy,{width:ie,marginTop:+!i,height:d,overflowY:d===void 0?void 0:`hidden`,children:r})]})})}function mx({title:e,id:t,children:n}){let{selectedTab:r,width:i}=(0,_x.useContext)(yx),a=_b();return r===(t??e)?(0,vx.jsx)(Uy,{width:i,flexShrink:a?0:void 0,children:n}):null}function hx(){let{width:e}=(0,_x.useContext)(yx);return e}function gx(){let{headerFocused:e,focusHeader:t,blurHeader:n,registerOptIn:r}=(0,_x.useContext)(yx);return(0,_x.useEffect)(r,[r]),{headerFocused:e,focusHeader:t,blurHeader:n}}var _x,vx,yx,bx=t((()=>{_x=n(N(),1),xb(),$v(),Dv(),ya(),xx(),c_(),vx=y(),yx=(0,_x.createContext)({selectedTab:void 0,width:void 0,headerFocused:!1,focusHeader:()=>{},blurHeader:()=>{},registerOptIn:()=>()=>{}})})),xx=t((()=>{eg(),fg(),Jh(),c_(),i_(),Xg(),Hg(),Ng(),m_(),Ep(),Vn(),zn(),si(),li(),Sp(),Nc(),Vc(),av(),ya(),Qs(),sv(),Vd(),Dr(),md(),Mp(),zm(),$d(),Ln(),qs(),$c(),Ol(),cf(),C_(),Wf(),Jf(),dv(),E_(),mv(),_v(),bv(),Cv(),Dv(),jv(),sp(),Pv(),Dg(),Bv(),Wv(),Xv(),wg(),$v(),ny(),ay(),ly(),my(),wf(),_y(),Lv(),by(),Cy(),Ih(),Vy(),Gy(),Xy(),Qy(),tb(),Ab(),wb(),Kb(),Lb(),ex(),Db(),ix(),cx(),fx(),bx(),gb(),lb()}));export{x_ as $,zd as $t,uy as A,Bn as An,Yh as At,Rv as B,ce as Bn,op as Bt,Oy as C,va as Cn,xg as Ct,xy as D,oi as Dn,ig as Dt,Ny as E,ci as En,rg as Et,Zv as F,Sn as Fn,Mh as Ft,xv as G,tf as Gt,Nv as H,Hf as Ht,Kv as I,V as In,Rm as It,fv as J,Ud as Jt,vv as K,rf as Kt,Gv as L,kn as Ln,jp as Lt,oy as M,Nn as Mn,Zh as Mt,ry as N,Mn as Nn,Gh as Nt,vy as O,wr as On,tg as Ot,ey as P,In as Pn,Fh as Pt,w_ as Q,Bd as Qt,Vv as R,N as Rn,Tp as Rt,jy as S,po as Sn,Cg as St,My as T,U as Tn,mg as Tt,Ov as U,Sf as Ut,Fv as V,Gf as Vt,wv as W,nf as Wt,ov as X,Jd as Xt,cv as Y,Gd as Yt,rv as Z,Rd as Zt,$y as _,Ks as _n,Pg as _t,hx as a,sd as an,$g as at,$ as b,xo as bn,jg as bt,tx as c,ud as cn,Kg as ct,Fb as d,cd as dn,Bg as dt,vd as en,l_ as et,Ob as f,Dl as fn,Rg as ft,sb as g,Xs as gn,Fg as gt,pb as h,Mc as hn,Vg as ht,gx as i,ad as in,Qg as it,cy as j,Rn as jn,Xh as jt,hy as k,Er as kn,ng as kt,Qb as l,dd as ln,Ug as lt,Sb as m,Bc as mn,Ig as mt,mx as n,kd as nn,o_ as nt,lx as o,pd as on,e_ as ot,Tb as p,Qc as pn,zg as pt,hv as q,qd as qt,px as r,_d as rn,Zg as rt,ax as s,fd as sn,Wg as st,xx as t,xd as tn,a_ as tt,Rb as u,ld as un,Yg as ut,Zy as v,zo as vn,kg as vt,Py as w,sa as wn,_g as wt,Uy as x,vo as xn,Eg as xt,Yy as y,Io as yn,Mg as yt,Hv as z,le as zn,xp as zt};