@ai-development-environment/server 0.0.27 → 0.0.29

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 (243) hide show
  1. package/package.json +1 -1
  2. package/prisma-runtime/prisma/migrations/20260718220000_add_build_freshness/migration.sql +1 -0
  3. package/prisma-runtime/prisma/schema.prisma +1 -0
  4. package/standalone/.next/BUILD_ID +1 -1
  5. package/standalone/.next/build-manifest.json +3 -3
  6. package/standalone/.next/prerender-manifest.json +3 -3
  7. package/standalone/.next/server/app/[locale]/actions/page.js.nft.json +1 -1
  8. package/standalone/.next/server/app/[locale]/actions/page_client-reference-manifest.js +1 -1
  9. package/standalone/.next/server/app/[locale]/agents/[id]/page.js.nft.json +1 -1
  10. package/standalone/.next/server/app/[locale]/agents/[id]/page_client-reference-manifest.js +1 -1
  11. package/standalone/.next/server/app/[locale]/agents/page.js.nft.json +1 -1
  12. package/standalone/.next/server/app/[locale]/agents/page_client-reference-manifest.js +1 -1
  13. package/standalone/.next/server/app/[locale]/build-data/page.js.nft.json +1 -1
  14. package/standalone/.next/server/app/[locale]/build-data/page_client-reference-manifest.js +1 -1
  15. package/standalone/.next/server/app/[locale]/builds/[buildId]/page.js.nft.json +1 -1
  16. package/standalone/.next/server/app/[locale]/builds/[buildId]/page_client-reference-manifest.js +1 -1
  17. package/standalone/.next/server/app/[locale]/builds/page.js.nft.json +1 -1
  18. package/standalone/.next/server/app/[locale]/builds/page_client-reference-manifest.js +1 -1
  19. package/standalone/.next/server/app/[locale]/codebases/[codebaseId]/page.js.nft.json +1 -1
  20. package/standalone/.next/server/app/[locale]/codebases/[codebaseId]/page_client-reference-manifest.js +1 -1
  21. package/standalone/.next/server/app/[locale]/codebases/page.js.nft.json +1 -1
  22. package/standalone/.next/server/app/[locale]/codebases/page_client-reference-manifest.js +1 -1
  23. package/standalone/.next/server/app/[locale]/codebases/repositories/[repositoryId]/page_client-reference-manifest.js +1 -1
  24. package/standalone/.next/server/app/[locale]/comments/page.js.nft.json +1 -1
  25. package/standalone/.next/server/app/[locale]/comments/page_client-reference-manifest.js +1 -1
  26. package/standalone/.next/server/app/[locale]/jira/cache/page_client-reference-manifest.js +1 -1
  27. package/standalone/.next/server/app/[locale]/jira/cache/tickets/[issueKey]/page_client-reference-manifest.js +1 -1
  28. package/standalone/.next/server/app/[locale]/jira/tickets/[issueKey]/page.js.nft.json +1 -1
  29. package/standalone/.next/server/app/[locale]/jira/tickets/[issueKey]/page_client-reference-manifest.js +1 -1
  30. package/standalone/.next/server/app/[locale]/jira/tickets/page.js.nft.json +1 -1
  31. package/standalone/.next/server/app/[locale]/jira/tickets/page_client-reference-manifest.js +1 -1
  32. package/standalone/.next/server/app/[locale]/jobs/[jobId]/page_client-reference-manifest.js +1 -1
  33. package/standalone/.next/server/app/[locale]/page_client-reference-manifest.js +1 -1
  34. package/standalone/.next/server/app/[locale]/pull-requests/[owner]/[repository]/[number]/page.js.nft.json +1 -1
  35. package/standalone/.next/server/app/[locale]/pull-requests/[owner]/[repository]/[number]/page_client-reference-manifest.js +1 -1
  36. package/standalone/.next/server/app/[locale]/pull-requests/page.js.nft.json +1 -1
  37. package/standalone/.next/server/app/[locale]/pull-requests/page_client-reference-manifest.js +1 -1
  38. package/standalone/.next/server/app/[locale]/settings/page_client-reference-manifest.js +1 -1
  39. package/standalone/.next/server/app/[locale]/skills/[skillId]/page_client-reference-manifest.js +1 -1
  40. package/standalone/.next/server/app/[locale]/skills/groups/[groupId]/page_client-reference-manifest.js +1 -1
  41. package/standalone/.next/server/app/[locale]/skills/groups/page_client-reference-manifest.js +1 -1
  42. package/standalone/.next/server/app/[locale]/skills/page_client-reference-manifest.js +1 -1
  43. package/standalone/.next/server/app/[locale]/skills/sync/[runId]/page_client-reference-manifest.js +1 -1
  44. package/standalone/.next/server/app/[locale]/tools/page_client-reference-manifest.js +1 -1
  45. package/standalone/.next/server/app/[locale]/usage/page.js.nft.json +1 -1
  46. package/standalone/.next/server/app/[locale]/usage/page_client-reference-manifest.js +1 -1
  47. package/standalone/.next/server/app/[locale]/worktrees/[worktreeId]/page.js.nft.json +1 -1
  48. package/standalone/.next/server/app/[locale]/worktrees/[worktreeId]/page_client-reference-manifest.js +1 -1
  49. package/standalone/.next/server/app/[locale]/worktrees/page.js.nft.json +1 -1
  50. package/standalone/.next/server/app/[locale]/worktrees/page_client-reference-manifest.js +1 -1
  51. package/standalone/.next/server/app/_global-error.html +1 -1
  52. package/standalone/.next/server/app/_global-error.rsc +1 -1
  53. package/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  54. package/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  55. package/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  56. package/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  57. package/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  58. package/standalone/.next/server/app/_not-found.html +1 -1
  59. package/standalone/.next/server/app/_not-found.rsc +1 -1
  60. package/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  61. package/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  62. package/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  63. package/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  64. package/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  65. package/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  66. package/standalone/.next/server/app/api/build-artifact-uploads/[uploadId]/route.js +2 -2
  67. package/standalone/.next/server/app/api/build-artifact-uploads/[uploadId]/route.js.nft.json +1 -1
  68. package/standalone/.next/server/app/api/builds/[buildId]/artifacts/[artifactId]/route.js +2 -2
  69. package/standalone/.next/server/app/api/builds/[buildId]/artifacts/[artifactId]/route.js.nft.json +1 -1
  70. package/standalone/.next/server/app/api/codebases/by-path/route.js +2 -2
  71. package/standalone/.next/server/app/api/codebases/by-path/route.js.nft.json +1 -1
  72. package/standalone/.next/server/app/api/codebases/route.js +2 -2
  73. package/standalone/.next/server/app/api/codebases/route.js.nft.json +1 -1
  74. package/standalone/.next/server/app/api/graphql/route.js +2 -2
  75. package/standalone/.next/server/app/api/graphql/route.js.nft.json +1 -1
  76. package/standalone/.next/server/app/api/mcp/route.js +2 -2
  77. package/standalone/.next/server/app/api/mcp/route.js.nft.json +1 -1
  78. package/standalone/.next/server/app/api/tools/call/route.js +2 -2
  79. package/standalone/.next/server/app/api/tools/call/route.js.nft.json +1 -1
  80. package/standalone/.next/server/app/api/tools/catalog/route.js +2 -2
  81. package/standalone/.next/server/app/api/tools/catalog/route.js.nft.json +1 -1
  82. package/standalone/.next/server/chunks/{[root-of-the-server]__1iv83x0._.js → [root-of-the-server]__0-ypkf7._.js} +1 -1
  83. package/standalone/.next/server/chunks/{[root-of-the-server]__08w_8a-._.js → [root-of-the-server]__00ku6-v._.js} +1 -1
  84. package/standalone/.next/server/chunks/{[root-of-the-server]__0yfvw4a._.js → [root-of-the-server]__0138gz-._.js} +1 -1
  85. package/standalone/.next/server/chunks/{[root-of-the-server]__0r5s0h6._.js → [root-of-the-server]__02vqwey._.js} +2 -2
  86. package/standalone/.next/server/chunks/{[root-of-the-server]__098f8w4._.js → [root-of-the-server]__056cnsc._.js} +1 -1
  87. package/standalone/.next/server/chunks/{[root-of-the-server]__1l6ed2g._.js → [root-of-the-server]__08mfybr._.js} +2 -2
  88. package/standalone/.next/server/chunks/{[root-of-the-server]__0cs2bfc._.js → [root-of-the-server]__08u874i._.js} +1 -1
  89. package/standalone/.next/server/chunks/{[root-of-the-server]__01h2pl1._.js → [root-of-the-server]__09skp6r._.js} +1 -1
  90. package/standalone/.next/server/chunks/{[root-of-the-server]__14-aq4c._.js → [root-of-the-server]__0cyubup._.js} +1 -1
  91. package/standalone/.next/server/chunks/{[root-of-the-server]__0_l5rqe._.js → [root-of-the-server]__0da1wsf._.js} +1 -1
  92. package/standalone/.next/server/chunks/{[root-of-the-server]__1mgcft0._.js → [root-of-the-server]__0e1fqyr._.js} +1 -1
  93. package/standalone/.next/server/chunks/{[root-of-the-server]__1frrx8s._.js → [root-of-the-server]__0f3ptor._.js} +2 -2
  94. package/standalone/.next/server/chunks/{[root-of-the-server]__0k01mi-._.js → [root-of-the-server]__0fih0li._.js} +1 -1
  95. package/standalone/.next/server/chunks/{[root-of-the-server]__02qjyhj._.js → [root-of-the-server]__0g0tnct._.js} +1 -1
  96. package/standalone/.next/server/chunks/{[root-of-the-server]__1ehdq4c._.js → [root-of-the-server]__0gbor-2._.js} +1 -1
  97. package/standalone/.next/server/chunks/{[root-of-the-server]__09lyzw2._.js → [root-of-the-server]__0mj6qcr._.js} +2 -2
  98. package/standalone/.next/server/chunks/{[root-of-the-server]__14uwobw._.js → [root-of-the-server]__0p_h088._.js} +1 -1
  99. package/standalone/.next/server/chunks/{[root-of-the-server]__0i4bd9d._.js → [root-of-the-server]__0vvjqp5._.js} +1 -1
  100. package/standalone/.next/server/chunks/{[root-of-the-server]__04rx7b9._.js → [root-of-the-server]__0w20bq-._.js} +2 -2
  101. package/standalone/.next/server/chunks/{[root-of-the-server]__0hmrx3m._.js → [root-of-the-server]__0wf0pka._.js} +1 -1
  102. package/standalone/.next/server/chunks/{[root-of-the-server]__0nxj1ky._.js → [root-of-the-server]__0wg2umj._.js} +1 -1
  103. package/standalone/.next/server/chunks/{[root-of-the-server]__17bgip6._.js → [root-of-the-server]__0xa_els._.js} +1 -1
  104. package/standalone/.next/server/chunks/{[root-of-the-server]__0wx4-1l._.js → [root-of-the-server]__0xukz2x._.js} +2 -2
  105. package/standalone/.next/server/chunks/[root-of-the-server]__1-z6lg_._.js +3 -0
  106. package/standalone/.next/server/chunks/{[root-of-the-server]__020ggc3._.js → [root-of-the-server]__15aat79._.js} +1 -1
  107. package/standalone/.next/server/chunks/{[root-of-the-server]__00_-x1w._.js → [root-of-the-server]__15bbm2q._.js} +2 -2
  108. package/standalone/.next/server/chunks/{[root-of-the-server]__09c7zmy._.js → [root-of-the-server]__16l4wed._.js} +1 -1
  109. package/standalone/.next/server/chunks/{[root-of-the-server]__04hrhu3._.js → [root-of-the-server]__19zwwdv._.js} +1 -1
  110. package/standalone/.next/server/chunks/{[root-of-the-server]__0d4_f1e._.js → [root-of-the-server]__1a5_am-._.js} +1 -1
  111. package/standalone/.next/server/chunks/{[root-of-the-server]__0kxltc8._.js → [root-of-the-server]__1ajaiy1._.js} +1 -1
  112. package/standalone/.next/server/chunks/[root-of-the-server]__1dtlzq1._.js +3 -0
  113. package/standalone/.next/server/chunks/[root-of-the-server]__1kpqohm._.js +3 -0
  114. package/standalone/.next/server/chunks/[root-of-the-server]__1l7234r._.js +3 -0
  115. package/standalone/.next/server/chunks/{[root-of-the-server]__0qjhcow._.js → [root-of-the-server]__1oahp4o._.js} +2 -2
  116. package/standalone/.next/server/chunks/[root-of-the-server]__1vip3sa._.js +3 -0
  117. package/standalone/.next/server/chunks/{[root-of-the-server]__0cryh-d._.js → [root-of-the-server]__1wtng3p._.js} +1 -1
  118. package/standalone/.next/server/chunks/[root-of-the-server]__1wu654b._.js +3 -0
  119. package/standalone/.next/server/chunks/[root-of-the-server]__1x2nph5._.js +3 -0
  120. package/standalone/.next/server/chunks/[root-of-the-server]__1xk-0be._.js +3 -0
  121. package/standalone/.next/server/chunks/{[root-of-the-server]__0h0mvv8._.js → [root-of-the-server]__210dhdj._.js} +1 -1
  122. package/standalone/.next/server/chunks/_0exkna-._.js +29 -8
  123. package/standalone/.next/server/chunks/{_0bru086._.js → _0jurkow._.js} +26 -26
  124. package/standalone/.next/server/chunks/{_00mzn-u._.js → _0rx5rfm._.js} +27 -27
  125. package/standalone/.next/server/chunks/_0tufgj0._.js +68 -47
  126. package/standalone/.next/server/chunks/_0w2eghf._.js +29 -8
  127. package/standalone/.next/server/chunks/_152rnkf._.js +3 -3
  128. package/standalone/.next/server/chunks/{_1_g2i-t._.js → _16x77b_._.js} +27 -27
  129. package/standalone/.next/server/chunks/_1dbqy8c._.js +3 -3
  130. package/standalone/.next/server/chunks/_1vrixpc._.js +3 -3
  131. package/standalone/.next/server/chunks/_1yfz-9u._.js +3 -3
  132. package/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1osx7qy._.js → [root-of-the-server]__0361lgt._.js} +8 -2
  133. package/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ay4_3d._.js +37 -0
  134. package/standalone/.next/server/chunks/ssr/[root-of-the-server]__0dm8osz._.js +3 -0
  135. package/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0oj1os4._.js → [root-of-the-server]__1xv798-._.js} +2 -2
  136. package/standalone/.next/server/chunks/ssr/[root-of-the-server]__1z955gh._.js +3 -0
  137. package/standalone/.next/server/chunks/ssr/_00ye62k._.js +35 -0
  138. package/standalone/.next/server/chunks/ssr/_07tglcd._.js +35 -0
  139. package/standalone/.next/server/chunks/ssr/_0bvpmhm._.js +29 -25
  140. package/standalone/.next/server/chunks/ssr/{_0hoc_fd._.js → _0ddgabq._.js} +2 -2
  141. package/standalone/.next/server/chunks/ssr/{_1x13g5y._.js → _0eb36qa._.js} +2 -2
  142. package/standalone/.next/server/chunks/ssr/{_1dnm1d4._.js → _0mr9u9p._.js} +2 -2
  143. package/standalone/.next/server/chunks/ssr/_0nm6upn._.js +3 -0
  144. package/standalone/.next/server/chunks/ssr/_0quhjav._.js +3 -0
  145. package/standalone/.next/server/chunks/ssr/_0w05v7m._.js +3 -0
  146. package/standalone/.next/server/chunks/ssr/_0xozjkz._.js +3 -0
  147. package/standalone/.next/server/chunks/ssr/_0xrpdyy._.js +3 -0
  148. package/standalone/.next/server/chunks/ssr/_1-2qcpf._.js +3 -0
  149. package/standalone/.next/server/chunks/ssr/{_1vhf014._.js → _1-grolz._.js} +2 -2
  150. package/standalone/.next/server/chunks/ssr/_12ws_f2._.js +11 -0
  151. package/standalone/.next/server/chunks/ssr/_17p59oz._.js +3 -0
  152. package/standalone/.next/server/chunks/ssr/_19fwji0._.js +11 -0
  153. package/standalone/.next/server/chunks/ssr/_1_1j9nd._.js +13 -0
  154. package/standalone/.next/server/chunks/ssr/_1g3i459._.js +15 -0
  155. package/standalone/.next/server/chunks/ssr/{_1oh35yj._.js → _1g_aflc._.js} +2 -2
  156. package/standalone/.next/server/chunks/ssr/{_1dsdn7w._.js → _1lcwubl._.js} +2 -2
  157. package/standalone/.next/server/chunks/ssr/{_0sp1ojg._.js → _1r2rmfp._.js} +8 -2
  158. package/standalone/.next/server/chunks/ssr/_1za3z6k._.js +28 -24
  159. package/standalone/.next/server/chunks/ssr/{_13jl9nw._.js → _1zyjq9y._.js} +2 -2
  160. package/standalone/.next/server/chunks/ssr/_20ufqtr._.js +3 -0
  161. package/standalone/.next/server/chunks/ssr/messages_de_json_[json]_cjs_1uig1ud._.js +1 -1
  162. package/standalone/.next/server/chunks/ssr/messages_en_json_[json]_cjs_206072-._.js +1 -1
  163. package/standalone/.next/server/chunks/ssr/messages_es_json_[json]_cjs_082yukd._.js +1 -1
  164. package/standalone/.next/server/chunks/ssr/messages_fr_json_[json]_cjs_0j6-w0i._.js +1 -1
  165. package/standalone/.next/server/chunks/ssr/src_components_agents_agent-detail_tsx_0lfa4ui._.js +2 -2
  166. package/standalone/.next/server/chunks/ssr/src_components_builds_build-detail-page_tsx_0q1lvps._.js +9 -13
  167. package/standalone/.next/server/chunks/ssr/src_components_builds_builds-page_tsx_17qzmsl._.js +8 -12
  168. package/standalone/.next/server/chunks/ssr/src_components_github_actions-page_tsx_18434xt._.js +5 -5
  169. package/standalone/.next/server/chunks/ssr/src_components_github_pull-requests-page_tsx_1il3ga-._.js +12 -12
  170. package/standalone/.next/server/chunks/ssr/src_components_tools_tools-page_tsx_0k1jqcz._.js +2 -2
  171. package/standalone/.next/server/chunks/ssr/src_components_worktrees_worktree-detail-page_tsx_1oexgu_._.js +13 -4
  172. package/standalone/.next/server/middleware-build-manifest.js +3 -3
  173. package/standalone/.next/server/pages/404.html +1 -1
  174. package/standalone/.next/server/pages/500.html +1 -1
  175. package/standalone/.next/server/server-reference-manifest.js +1 -1
  176. package/standalone/.next/server/server-reference-manifest.json +1 -1
  177. package/standalone/.next/static/chunks/{0sp_r-c6262te.js → 0newuocvg03xy.js} +1 -1
  178. package/standalone/.next/static/chunks/{3oyhf7rk2xr_g.js → 0rlomhlt6030e.js} +1 -1
  179. package/standalone/.next/static/chunks/16tfdsma_h0r5.js +33 -0
  180. package/standalone/.next/static/chunks/{1xjd6ye7mxyf5.js → 1802j8gq2g47d.js} +2 -2
  181. package/standalone/.next/static/chunks/1_tnhhn4f122y.js +9 -0
  182. package/standalone/.next/static/chunks/1eny65xy2ho48.js +1 -0
  183. package/standalone/.next/static/chunks/1l4bkigul15i3.js +25 -0
  184. package/standalone/.next/static/chunks/{3td_-1s61zkpa.js → 1nnp0crt0mi_-.js} +1 -1
  185. package/standalone/.next/static/chunks/1qd6cse_d9ae1.js +99 -0
  186. package/standalone/.next/static/chunks/{2dwchs_6y_o5f.js → 2-mxmazwsh-wz.js} +1 -1
  187. package/standalone/.next/static/chunks/2fzwgr2iq_783.css +1 -0
  188. package/standalone/.next/static/chunks/{278dxvyf095b_.js → 2jbygfc0lzu0t.js} +7 -7
  189. package/standalone/.next/static/chunks/2n7u72nxziv_5.js +7 -0
  190. package/standalone/.next/static/chunks/{1rivge68m21sm.js → 2rjf8o4g23no8.js} +10 -10
  191. package/standalone/.next/static/chunks/{42flok13o-l0b.js → 2x8qovg070057.js} +1 -1
  192. package/standalone/.next/static/chunks/{091l-ij_cv0b6.js → 3-u7pvogc5_bx.js} +12 -12
  193. package/standalone/.next/static/chunks/3-zh9b0tcttiw.js +33 -0
  194. package/standalone/.next/static/chunks/31wyih3wwkeid.js +1 -0
  195. package/standalone/.next/static/chunks/{1nqkxeuycfmrt.js → 36_1bjzx79v18.js} +5 -5
  196. package/standalone/.next/static/chunks/3ajj69p_sj615.js +1 -0
  197. package/standalone/.next/static/chunks/3jd8_7lna-j_x.js +40 -0
  198. package/standalone/.next/static/chunks/3jv2gnnn4vx-j.js +43 -0
  199. package/standalone/.next/static/chunks/3k0oakdayt9yt.js +40 -0
  200. package/standalone/.next/static/chunks/3pgngh8lg3be3.js +99 -0
  201. package/standalone/.next/static/chunks/{0w8rd_g6hnvmz.js → 4013cp3x6bvuw.js} +1 -1
  202. package/standalone/src/services/builds/build-freshness.test.ts +107 -0
  203. package/standalone/src/services/builds/build-freshness.ts +73 -0
  204. package/standalone/src/services/builds/builds.service.test.ts +167 -8
  205. package/standalone/src/services/builds/builds.service.ts +115 -3
  206. package/standalone/.next/server/chunks/[root-of-the-server]__1878s0b._.js +0 -3
  207. package/standalone/.next/server/chunks/[root-of-the-server]__18zrtty._.js +0 -3
  208. package/standalone/.next/server/chunks/[root-of-the-server]__1_xz_m2._.js +0 -3
  209. package/standalone/.next/server/chunks/[root-of-the-server]__1mx1hqe._.js +0 -3
  210. package/standalone/.next/server/chunks/[root-of-the-server]__1sjjkyp._.js +0 -3
  211. package/standalone/.next/server/chunks/[root-of-the-server]__1vk9266._.js +0 -3
  212. package/standalone/.next/server/chunks/[root-of-the-server]__1yn6pds._.js +0 -3
  213. package/standalone/.next/server/chunks/[root-of-the-server]__1zwpjfo._.js +0 -3
  214. package/standalone/.next/server/chunks/ssr/[root-of-the-server]__03m5q8h._.js +0 -27
  215. package/standalone/.next/server/chunks/ssr/[root-of-the-server]__06bk7ik._.js +0 -3
  216. package/standalone/.next/server/chunks/ssr/_09l5w5d._.js +0 -3
  217. package/standalone/.next/server/chunks/ssr/_0_726fj._.js +0 -3
  218. package/standalone/.next/server/chunks/ssr/_0a1zku5._.js +0 -3
  219. package/standalone/.next/server/chunks/ssr/_0pu14lm._.js +0 -3
  220. package/standalone/.next/server/chunks/ssr/_1eol9we._.js +0 -3
  221. package/standalone/.next/server/chunks/ssr/_1h3t5g1._.js +0 -3
  222. package/standalone/.next/server/chunks/ssr/_1kemhyd._.js +0 -39
  223. package/standalone/.next/server/chunks/ssr/_1kmkrz5._.js +0 -3
  224. package/standalone/.next/server/chunks/ssr/_1r9ohdr._.js +0 -3
  225. package/standalone/.next/server/chunks/ssr/_1yzb5-u._.js +0 -11
  226. package/standalone/.next/server/chunks/ssr/src_components_0wvh73y._.js +0 -11
  227. package/standalone/.next/server/chunks/ssr/src_components_github_167_ydi._.js +0 -35
  228. package/standalone/.next/static/chunks/00dx8gu-2oyqe.js +0 -45
  229. package/standalone/.next/static/chunks/0j5n6p9i-vyzo.js +0 -9
  230. package/standalone/.next/static/chunks/0weklluydd2mf.js +0 -23
  231. package/standalone/.next/static/chunks/1eehbcjby4go8.js +0 -95
  232. package/standalone/.next/static/chunks/23_75iur2dq8p.js +0 -1
  233. package/standalone/.next/static/chunks/2lgsgstcvc7uk.css +0 -1
  234. package/standalone/.next/static/chunks/32agjzrkphjrl.js +0 -9
  235. package/standalone/.next/static/chunks/399uxexoo8x7f.js +0 -33
  236. package/standalone/.next/static/chunks/39ecics7n8z5m.js +0 -1
  237. package/standalone/.next/static/chunks/3_kaby2qep1pd.js +0 -34
  238. package/standalone/.next/static/chunks/3q7vh58-5dkv2.js +0 -25
  239. package/standalone/.next/static/chunks/3xkoiasuwi3ms.js +0 -95
  240. package/standalone/.next/static/chunks/41s57pssydrel.js +0 -43
  241. /package/standalone/.next/static/{AxIbPSeZUHq852SCBMR8d → 8uBWJ8MOV-OEPe88M3PhU}/_buildManifest.js +0 -0
  242. /package/standalone/.next/static/{AxIbPSeZUHq852SCBMR8d → 8uBWJ8MOV-OEPe88M3PhU}/_clientMiddlewareManifest.js +0 -0
  243. /package/standalone/.next/static/{AxIbPSeZUHq852SCBMR8d → 8uBWJ8MOV-OEPe88M3PhU}/_ssgManifest.js +0 -0
@@ -1,3 +1,3 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,573474,e=>{"use strict";let t=(0,e.i(456420).default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",0,t],573474)},340953,e=>{"use strict";var t=e.i(843476),r=e.i(271645),a=e.i(30030);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return r.useCallback(function(...e){return t=>{let r=!1,a=e.map(e=>{let a=n(e,t);return r||"function"!=typeof a||(r=!0),a});if(r)return()=>{for(let t=0;t<a.length;t++){let r=a[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var s=e.i(326999);"u">typeof window&&window.document&&window.document.createElement;var l="AlertDialog",[o,c]=(0,a.createContextScope)(l,[s.createDialogScope]),d=(0,s.createDialogScope)(),u=e=>{let{__scopeAlertDialog:r,...a}=e,n=d(r);return(0,t.jsx)(s.Root,{...n,...a,modal:!0})};u.displayName=l;var m=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Trigger,{...i,...n,ref:r})});m.displayName="AlertDialogTrigger";var p=e=>{let{__scopeAlertDialog:r,...a}=e,n=d(r);return(0,t.jsx)(s.Portal,{...n,...a})};p.displayName="AlertDialogPortal";var h=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Overlay,{...i,...n,ref:r})});h.displayName="AlertDialogOverlay";var f="AlertDialogContent",[x,g]=o(f),j=r.forwardRef((e,a)=>{let{__scopeAlertDialog:n,children:l,...o}=e,c=d(n),u=i(a,r.useRef(null)),m=r.useRef(null);return(0,t.jsx)(x,{scope:n,cancelRef:m,children:(0,t.jsx)(s.Content,{role:"alertdialog",...c,...o,ref:u,onOpenAutoFocus:function(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e?.(a),!1===r||!a||!a.defaultPrevented)return t?.(a)}}(o.onOpenAutoFocus,e=>{e.preventDefault(),m.current?.focus({preventScroll:!0})}),onPointerDownOutside:e=>e.preventDefault(),onInteractOutside:e=>e.preventDefault(),children:l})})});j.displayName=f;var v=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Title,{...i,...n,ref:r})});v.displayName="AlertDialogTitle";var y=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Description,{...i,...n,ref:r})});y.displayName="AlertDialogDescription";var b=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Close,{...i,...n,ref:r})});b.displayName="AlertDialogAction";var w="AlertDialogCancel",k=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,{cancelRef:l}=g(w,a),o=d(a),c=i(r,l);return(0,t.jsx)(s.Close,{...o,...n,ref:c})});k.displayName=w,e.s(["Action",0,b,"AlertDialog",0,u,"AlertDialogAction",0,b,"AlertDialogCancel",0,k,"AlertDialogContent",0,j,"AlertDialogDescription",0,y,"AlertDialogOverlay",0,h,"AlertDialogPortal",0,p,"AlertDialogTitle",0,v,"AlertDialogTrigger",0,m,"Cancel",0,k,"Content",0,j,"Description",0,y,"Overlay",0,h,"Portal",0,p,"Root",0,u,"Title",0,v,"Trigger",0,m,"createAlertDialogScope",0,c],691162);var N=e.i(691162),N=N,S=e.i(975157),C=e.i(519455);function T({...e}){return(0,t.jsx)(N.Root,{"data-slot":"alert-dialog",...e})}function D({...e}){return(0,t.jsx)(N.Trigger,{"data-slot":"alert-dialog-trigger",...e})}function I({...e}){return(0,t.jsx)(N.Portal,{"data-slot":"alert-dialog-portal",...e})}function E({className:e,...r}){return(0,t.jsx)(N.Overlay,{"data-slot":"alert-dialog-overlay",className:(0,S.cn)("fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...r})}function A({className:e,size:r="default",...a}){return(0,t.jsxs)(I,{children:[(0,t.jsx)(E,{}),(0,t.jsx)(N.Content,{"data-slot":"alert-dialog-content","data-size":r,className:(0,S.cn)("group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...a})]})}function R({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"alert-dialog-header",className:(0,S.cn)("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]",e),...r})}function P({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"alert-dialog-footer",className:(0,S.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end",e),...r})}function $({className:e,...r}){return(0,t.jsx)(N.Title,{"data-slot":"alert-dialog-title",className:(0,S.cn)("font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",e),...r})}function B({className:e,...r}){return(0,t.jsx)(N.Description,{"data-slot":"alert-dialog-description",className:(0,S.cn)("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),...r})}function J({className:e,variant:r="default",size:a="default",...n}){return(0,t.jsx)(C.Button,{variant:r,size:a,asChild:!0,children:(0,t.jsx)(N.Action,{"data-slot":"alert-dialog-action",className:(0,S.cn)(e),...n})})}function L({className:e,variant:r="outline",size:a="default",...n}){return(0,t.jsx)(C.Button,{variant:r,size:a,asChild:!0,children:(0,t.jsx)(N.Cancel,{"data-slot":"alert-dialog-cancel",className:(0,S.cn)(e),...n})})}e.s(["ConfirmationDialog",0,function({actionLabel:e,cancelLabel:r,description:a,onConfirm:n,onOpenChange:i,open:s,title:l,trigger:o}){return(0,t.jsxs)(T,{onOpenChange:i,open:s,children:[o&&(0,t.jsx)(D,{asChild:!0,children:o}),(0,t.jsxs)(A,{children:[(0,t.jsxs)(R,{children:[(0,t.jsx)($,{children:l}),(0,t.jsx)(B,{children:a})]}),(0,t.jsxs)(P,{children:[(0,t.jsx)(L,{children:r}),(0,t.jsx)(J,{onClick:()=>void n(),variant:"destructive",children:e})]})]})]})}],340953)},77071,e=>{"use strict";let t=(0,e.i(456420).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",0,t],77071)},776639,e=>{"use strict";var t=e.i(843476),r=e.i(560964),a=e.i(964053),n=e.i(519455),i=e.i(975157);function s({...e}){return(0,t.jsx)(a.Dialog.Portal,{"data-slot":"dialog-portal",...e})}function l({className:e,...r}){return(0,t.jsx)(a.Dialog.Overlay,{className:(0,i.cn)("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),"data-slot":"dialog-overlay",...r})}e.s(["Dialog",0,function({...e}){return(0,t.jsx)(a.Dialog.Root,{"data-slot":"dialog",...e})},"DialogContent",0,function({className:e,children:o,showCloseButton:c=!0,...d}){return(0,t.jsxs)(s,{children:[(0,t.jsx)(l,{}),(0,t.jsxs)(a.Dialog.Content,{className:(0,i.cn)("fixed top-1/2 left-1/2 z-50 grid max-h-[85dvh] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),"data-slot":"dialog-content",...d,children:[o,c&&(0,t.jsx)(a.Dialog.Close,{asChild:!0,"data-slot":"dialog-close",children:(0,t.jsxs)(n.Button,{className:"absolute top-2 right-2",size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(r.XIcon,{}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})})]})]})},"DialogDescription",0,function({className:e,...r}){return(0,t.jsx)(a.Dialog.Description,{className:(0,i.cn)("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),"data-slot":"dialog-description",...r})},"DialogFooter",0,function({className:e,showCloseButton:r=!1,children:s,...l}){return(0,t.jsxs)("div",{className:(0,i.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",e),"data-slot":"dialog-footer",...l,children:[s,r&&(0,t.jsx)(a.Dialog.Close,{asChild:!0,children:(0,t.jsx)(n.Button,{variant:"outline",children:"Close"})})]})},"DialogHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{className:(0,i.cn)("flex flex-col gap-2",e),"data-slot":"dialog-header",...r})},"DialogTitle",0,function({className:e,...r}){return(0,t.jsx)(a.Dialog.Title,{className:(0,i.cn)("font-heading text-base leading-none font-medium",e),"data-slot":"dialog-title",...r})}])},59497,e=>{"use strict";var t=e.i(843476),r=e.i(271645);function a(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function n(...e){return r.useCallback(function(...e){return t=>{let r=!1,n=e.map(e=>{let n=a(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():a(e[t],null)}}}}(...e),e)}var i=e.i(30030);function s(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e?.(a),!1===r||!a||!a.defaultPrevented)return t?.(a)}}"u">typeof window&&window.document&&window.document.createElement;var l=globalThis?.document?r.useLayoutEffect:()=>{};r[" useEffectEvent ".trim().toString()],r[" useInsertionEffect ".trim().toString()];var o=r[" useInsertionEffect ".trim().toString()]||l;Symbol("RADIX:SYNC_STATE");var c=e.i(999682),d=e.i(635804),u=e.i(296626);e.i(174080);var m=Symbol.for("radix.slottable"),p=Symbol.for("react.lazy");function h(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===p&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var f=r[" use ".trim().toString()],x=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,a)=>{var i;let s,l=(i=`Primitive.${a}`,(s=r.forwardRef((e,t)=>{var a;let s,l,{children:o,...c}=e,d=null,u=!1,p=[];h(o)&&"function"==typeof f&&(o=f(o._payload)),r.Children.forEach(o,e=>{var t;if(t=e,r.isValidElement(t)&&"function"==typeof t.type&&"__radixId"in t.type&&t.type.__radixId===m){u=!0;let t="child"in e.props?e.props.child:e.props.children;h(t)&&"function"==typeof f&&(t=f(t._payload)),d=((e,t)=>{if("child"in e.props){let t=e.props.child;return r.isValidElement(t)?r.cloneElement(t,void 0,e.props.children(t.props.children)):null}return r.isValidElement(t)?t:null})(e,t),p.push(d?.props?.children)}else p.push(e)}),d?d=r.cloneElement(d,void 0,p):!u&&1===r.Children.count(o)&&r.isValidElement(o)&&(d=o);let x=d?(a=d,(l=(s=Object.getOwnPropertyDescriptor(a.props,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?a.ref:(l=(s=Object.getOwnPropertyDescriptor(a,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?a.props.ref:a.props.ref||a.ref):void 0,g=n(t,x);if(!d){if(o||0===o){let e,t;throw Error(u?(e=i,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=i,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return o}let j=function(e,t){let r={...t};for(let a in t){let n=e[a],i=t[a];/^on[A-Z]/.test(a)?n&&i?r[a]=(...e)=>{let t=i(...e);return n(...e),t}:n&&(r[a]=n):"style"===a?r[a]={...n,...i}:"className"===a&&(r[a]=[n,i].filter(Boolean).join(" "))}return{...e,...r}}(c,d.props??{});return d.type!==r.Fragment&&(j.ref=t?g:x),r.cloneElement(d,j)})).displayName=`${i}.Slot`,s),o=r.forwardRef((e,r)=>{let{asChild:n,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,t.jsx)(n?l:a,{...i,ref:r})});return o.displayName=`Primitive.${a}`,{...e,[a]:o}},{}),g="Checkbox",[j,v]=(0,i.createContextScope)(g),[y,b]=j(g);function w(e){let{__scopeCheckbox:a,checked:n,children:i,defaultChecked:s,disabled:l,form:c,name:d,onCheckedChange:u,required:m,value:p="on",internal_do_not_use_render:h}=e,[f,x]=function({prop:e,defaultProp:t,onChange:a=()=>{},caller:n}){let[i,s,l]=function({defaultProp:e,onChange:t}){let[a,n]=r.useState(e),i=r.useRef(a),s=r.useRef(t);return o(()=>{s.current=t},[t]),r.useEffect(()=>{i.current!==a&&(s.current?.(a),i.current=a)},[a,i]),[a,n,s]}({defaultProp:t,onChange:a}),c=void 0!==e,d=c?e:i;{let t=r.useRef(void 0!==e);r.useEffect(()=>{let e=t.current;if(e!==c){let t=c?"controlled":"uncontrolled";console.warn(`${n} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=c},[c,n])}return[d,r.useCallback(t=>{if(c){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else s(t)},[c,e,s,l])]}({prop:n,defaultProp:s??!1,onChange:u,caller:g}),[j,v]=r.useState(null),[b,w]=r.useState(null),k=r.useRef(!1),N=!j||!!c||!!j.closest("form"),S={checked:f,disabled:l,setChecked:x,control:j,setControl:v,name:d,form:c,value:p,hasConsumerStoppedPropagationRef:k,required:m,defaultChecked:!E(s)&&s,isFormControl:N,bubbleInput:b,setBubbleInput:w};return(0,t.jsx)(y,{scope:a,...S,children:"function"==typeof h?h(S):i})}var k="CheckboxTrigger",N=r.forwardRef(({__scopeCheckbox:e,onKeyDown:a,onClick:i,...l},o)=>{let{control:c,value:d,disabled:u,checked:m,required:p,setControl:h,setChecked:f,hasConsumerStoppedPropagationRef:g,isFormControl:j,bubbleInput:v}=b(k,e),y=n(o,h),w=r.useRef(m);return r.useEffect(()=>{let e=c?.form;if(e){let t=()=>f(w.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}},[c,f]),(0,t.jsx)(x.button,{type:"button",role:"checkbox","aria-checked":E(m)?"mixed":m,"aria-required":p,"data-state":A(m),"data-disabled":u?"":void 0,disabled:u,value:d,...l,ref:y,onKeyDown:s(a,e=>{"Enter"===e.key&&e.preventDefault()}),onClick:s(i,e=>{f(e=>!!E(e)||!e),v&&j&&(g.current=e.isPropagationStopped(),g.current||e.stopPropagation())})})});N.displayName=k;var S=r.forwardRef((e,r)=>{let{__scopeCheckbox:a,name:n,checked:i,defaultChecked:s,required:l,disabled:o,value:c,onCheckedChange:d,form:u,...m}=e;return(0,t.jsx)(w,{__scopeCheckbox:a,checked:i,defaultChecked:s,disabled:o,required:l,onCheckedChange:d,name:n,form:u,value:c,internal_do_not_use_render:({isFormControl:e})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(N,{...m,ref:r,__scopeCheckbox:a}),e&&(0,t.jsx)(I,{__scopeCheckbox:a})]})})});S.displayName=g;var C="CheckboxIndicator",T=r.forwardRef((e,r)=>{let{__scopeCheckbox:a,forceMount:n,...i}=e,s=b(C,a);return(0,t.jsx)(u.Presence,{present:n||E(s.checked)||!0===s.checked,children:(0,t.jsx)(x.span,{"data-state":A(s.checked),"data-disabled":s.disabled?"":void 0,...i,ref:r,style:{pointerEvents:"none",...e.style}})})});T.displayName=C;var D="CheckboxBubbleInput",I=r.forwardRef(({__scopeCheckbox:e,...a},i)=>{let{control:s,hasConsumerStoppedPropagationRef:l,checked:o,defaultChecked:u,required:m,disabled:p,name:h,value:f,form:g,bubbleInput:j,setBubbleInput:v}=b(D,e),y=n(i,v),w=(0,c.usePrevious)(o),k=(0,d.useSize)(s);r.useEffect(()=>{if(!j)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set,t=!l.current;if(w!==o&&e){let r=new Event("click",{bubbles:t});j.indeterminate=E(o),e.call(j,!E(o)&&o),j.dispatchEvent(r)}},[j,w,o,l]);let N=r.useRef(!E(o)&&o);return(0,t.jsx)(x.input,{type:"checkbox","aria-hidden":!0,defaultChecked:u??N.current,required:m,disabled:p,name:h,value:f,form:g,...a,tabIndex:-1,ref:y,style:{...a.style,...k,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});function E(e){return"indeterminate"===e}function A(e){return E(e)?"indeterminate":e?"checked":"unchecked"}I.displayName=D,e.s(["Checkbox",0,S,"CheckboxIndicator",0,T,"Indicator",0,T,"Root",0,S,"createCheckboxScope",0,v,"unstable_BubbleInput",0,I,"unstable_CheckboxBubbleInput",0,I,"unstable_CheckboxProvider",0,w,"unstable_CheckboxTrigger",0,N,"unstable_Provider",0,w,"unstable_Trigger",0,N],388474);var R=e.i(388474),R=R,P=e.i(975157),$=e.i(593698);e.s(["Checkbox",0,function({className:e,...r}){return(0,t.jsx)(R.Root,{"data-slot":"checkbox",className:(0,P.cn)("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",e),...r,children:(0,t.jsx)(R.Indicator,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none [&>svg]:size-3.5",children:(0,t.jsx)($.CheckIcon,{})})})}],59497)},482022,e=>{"use strict";let t=(0,e.i(456420).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["ExternalLink",0,t],482022)},741120,e=>{"use strict";let t=(0,e.i(456420).default)("refresh-cw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);e.s(["RefreshCw",0,t],741120)},82612,e=>{"use strict";var t=e.i(843476),r=e.i(225913),a=e.i(975157);let n=(0,r.cva)("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"}},defaultVariants:{variant:"default"}});e.s(["Empty",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty",className:(0,a.cn)("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance",e),...r})},"EmptyDescription",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-description",className:(0,a.cn)("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",e),...r})},"EmptyHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-header",className:(0,a.cn)("flex max-w-sm flex-col items-center gap-2",e),...r})},"EmptyMedia",0,function({className:e,variant:r="default",...i}){return(0,t.jsx)("div",{"data-slot":"empty-icon","data-variant":r,className:(0,a.cn)(n({variant:r,className:e})),...i})},"EmptyTitle",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-title",className:(0,a.cn)("font-heading text-sm font-medium tracking-tight",e),...r})}])},462777,e=>{"use strict";async function t(e){if(navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.append(t),t.select();let r=document.execCommand("copy");if(t.remove(),!r)throw Error("Copy is not supported by this browser")}e.s(["copyText",0,t,"createClientId",0,function(){try{if(globalThis.crypto?.randomUUID)return globalThis.crypto.randomUUID()}catch{}if(globalThis.crypto?.getRandomValues)try{let e=globalThis.crypto.getRandomValues(new Uint8Array(16));return Array.from(e,e=>e.toString(16).padStart(2,"0")).join("")}catch{}return`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}])},842727,e=>{"use strict";var t=e.i(271645);function r(e,t,{checkForDefaultPrevented:a=!0}={}){return function(r){if(e?.(r),!1===a||!r||!r.defaultPrevented)return t?.(r)}}"u">typeof window&&window.document&&window.document.createElement;var a=e.i(75830);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return t.useCallback(function(...e){return t=>{let r=!1,a=e.map(e=>{let a=n(e,t);return r||"function"!=typeof a||(r=!0),a});if(r)return()=>{for(let t=0;t<a.length;t++){let r=a[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var s=e.i(30030),l=e.i(610772);e.i(174080);var o=Symbol.for("radix.slottable"),c=Symbol.for("react.lazy");function d(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===c&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var u=t[" use ".trim().toString()],m=e.i(843476),p=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{var a;let n,s=(a=`Primitive.${r}`,(n=t.forwardRef((e,r)=>{var n;let s,l,{children:c,...m}=e,p=null,h=!1,f=[];d(c)&&"function"==typeof u&&(c=u(c._payload)),t.Children.forEach(c,e=>{var r;if(r=e,t.isValidElement(r)&&"function"==typeof r.type&&"__radixId"in r.type&&r.type.__radixId===o){h=!0;let r="child"in e.props?e.props.child:e.props.children;d(r)&&"function"==typeof u&&(r=u(r._payload)),p=((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null})(e,r),f.push(p?.props?.children)}else f.push(e)}),p?p=t.cloneElement(p,void 0,f):!h&&1===t.Children.count(c)&&t.isValidElement(c)&&(p=c);let x=p?(n=p,(l=(s=Object.getOwnPropertyDescriptor(n.props,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?n.ref:(l=(s=Object.getOwnPropertyDescriptor(n,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?n.props.ref:n.props.ref||n.ref):void 0,g=i(r,x);if(!p){if(c||0===c){let e,t;throw Error(h?(e=a,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=a,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return c}let j=function(e,t){let r={...t};for(let a in t){let n=e[a],i=t[a];/^on[A-Z]/.test(a)?n&&i?r[a]=(...e)=>{let t=i(...e);return n(...e),t}:n&&(r[a]=n):"style"===a?r[a]={...n,...i}:"className"===a&&(r[a]=[n,i].filter(Boolean).join(" "))}return{...e,...r}}(m,p.props??{});return p.type!==t.Fragment&&(j.ref=r?g:x),t.cloneElement(p,j)})).displayName=`${a}.Slot`,n),l=t.forwardRef((e,t)=>{let{asChild:a,...n}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,m.jsx)(a?s:r,{...n,ref:t})});return l.displayName=`Primitive.${r}`,{...e,[r]:l}},{}),h=e.i(30207),f=globalThis?.document?t.useLayoutEffect:()=>{};t[" useEffectEvent ".trim().toString()],t[" useInsertionEffect ".trim().toString()];var x=t[" useInsertionEffect ".trim().toString()]||f;Symbol("RADIX:SYNC_STATE");var g=e.i(586318),j=!1,v=t[" useSyncExternalStore ".trim().toString()];function y(){return()=>{}}var b="function"==typeof v?function(){return v(y,()=>!0,()=>!1)}:function(){let[e,r]=t.useState(j);return t.useEffect(()=>{j||(j=!0,r(!0))},[]),e},w="rovingFocusGroup.onEntryFocus",k={bubbles:!1,cancelable:!0},N="RovingFocusGroup",[S,C,T]=(0,a.createCollection)(N),[D,I]=(0,s.createContextScope)(N,[T]),[E,A]=D(N),R=t.forwardRef((e,t)=>(0,m.jsx)(S.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(S.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(P,{...e,ref:t})})}));R.displayName=N;var P=t.forwardRef((e,a)=>{let{__scopeRovingFocusGroup:n,orientation:s,loop:l=!1,dir:o,currentTabStopId:c,defaultCurrentTabStopId:d,onCurrentTabStopIdChange:u,onEntryFocus:f,preventScrollOnEntryFocus:j=!1,...v}=e,y=t.useRef(null),b=i(a,y),S=(0,g.useDirection)(o),[T,D]=function({prop:e,defaultProp:r,onChange:a=()=>{},caller:n}){let[i,s,l]=function({defaultProp:e,onChange:r}){let[a,n]=t.useState(e),i=t.useRef(a),s=t.useRef(r);return x(()=>{s.current=r},[r]),t.useEffect(()=>{i.current!==a&&(s.current?.(a),i.current=a)},[a,i]),[a,n,s]}({defaultProp:r,onChange:a}),o=void 0!==e,c=o?e:i;{let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==o){let t=o?"controlled":"uncontrolled";console.warn(`${n} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=o},[o,n])}return[c,t.useCallback(t=>{if(o){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else s(t)},[o,e,s,l])]}({prop:c,defaultProp:d??null,onChange:u,caller:N}),[I,A]=t.useState(!1),R=(0,h.useCallbackRef)(f),P=C(n),$=t.useRef(!1),[B,J]=t.useState(0);return t.useEffect(()=>{let e=y.current;if(e)return e.addEventListener(w,R),()=>e.removeEventListener(w,R)},[R]),(0,m.jsx)(E,{scope:n,orientation:s,dir:S,loop:l,currentTabStopId:T,onItemFocus:t.useCallback(e=>D(e),[D]),onItemShiftTab:t.useCallback(()=>A(!0),[]),onFocusableItemAdd:t.useCallback(()=>J(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>J(e=>e-1),[]),children:(0,m.jsx)(p.div,{tabIndex:I||0===B?-1:0,"data-orientation":s,...v,ref:b,style:{outline:"none",...e.style},onMouseDown:r(e.onMouseDown,()=>{$.current=!0}),onFocus:r(e.onFocus,e=>{let t=!$.current;if(e.target===e.currentTarget&&t&&!I){let t=new CustomEvent(w,k);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=P().filter(e=>e.focusable);L([e.find(e=>e.active),e.find(e=>e.id===T),...e].filter(Boolean).map(e=>e.ref.current),j)}}$.current=!1}),onBlur:r(e.onBlur,()=>A(!1))})})}),$="RovingFocusGroupItem",B=t.forwardRef((e,a)=>{let{__scopeRovingFocusGroup:n,focusable:i=!0,active:s=!1,tabStopId:o,children:c,...d}=e,u=(0,l.useId)(),h=o||u,x=A($,n),g=x.currentTabStopId===h,j=C(n),{onFocusableItemAdd:v,onFocusableItemRemove:y,currentTabStopId:w}=x,k=b();return f(()=>{if(k&&i)return v(),()=>y()},[k,i,v,y]),t.useEffect(()=>{if(!k&&i)return v(),()=>y()},[k,i,v,y]),(0,m.jsx)(S.ItemSlot,{scope:n,id:h,focusable:i,active:s,children:(0,m.jsx)(p.span,{tabIndex:g?0:-1,"data-orientation":x.orientation,...d,ref:a,onMouseDown:r(e.onMouseDown,e=>{i?x.onItemFocus(h):e.preventDefault()}),onFocus:r(e.onFocus,()=>x.onItemFocus(h)),onKeyDown:r(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void x.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var a;let n=(a=e.key,"rtl"!==r?a:"ArrowLeft"===a?"ArrowRight":"ArrowRight"===a?"ArrowLeft":a);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(n))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(n)))return J[n]}(e,x.orientation,x.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=j().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)n.reverse();else if("prev"===t||"next"===t){var r,a;"prev"===t&&n.reverse();let i=n.indexOf(e.currentTarget);n=x.loop?(r=n,a=i+1,r.map((e,t)=>r[(a+t)%r.length])):n.slice(i+1)}setTimeout(()=>L(n))}}),children:"function"==typeof c?c({isCurrentTabStop:g,hasTabStop:null!=w}):c})})});B.displayName=$;var J={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function L(e,t=!1){let r=document.activeElement;for(let a of e)if(a===r||(a.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",0,B,"Root",0,R,"createRovingFocusGroupScope",0,I],842727)},560972,e=>{"use strict";let t=(0,e.i(456420).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);e.s(["default",0,t])},356505,853138,e=>{"use strict";var t=e.i(843476),r=e.i(456420);let a=(0,r.default)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);e.s(["AlertTriangle",0,a],853138);var n=e.i(482022),i=e.i(269846);let s=(0,r.default)("maximize-2",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]]);var l=e.i(948148),o=e.i(271645),c=e.i(653090),d=e.i(278015),u=e.i(762279),m=e.i(456743),p=e.i(929592),h=e.i(487486),f=e.i(519455),x=e.i(515288),g=e.i(906197),j=e.i(980376),v=e.i(987968),y=e.i(520133),b=e.i(637611),w=e.i(741725),k=e.i(467511);let N={highest:"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300",high:"border-orange-500/30 bg-orange-500/10 text-orange-700 dark:text-orange-300",medium:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",low:"border-blue-500/30 bg-blue-500/10 text-blue-700 dark:text-blue-300",lowest:"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"};function S(e){return e?new Date(e).toLocaleString():"—"}function C({ticket:e}){let r=(0,l.useTranslations)("jiraTickets"),a=[[r("assignee"),(0,t.jsx)(c.JiraUser,{avatarUrl:e.assigneeAvatarUrl,name:e.assignee??r("unassigned")},"assignee")],[r("reporter"),e.reporter?(0,t.jsx)(c.JiraUser,{avatarUrl:e.reporter.avatarUrl,name:e.reporter.displayName},"reporter"):"—"],[r("created"),S(e.createdAt)],[r("updated"),S(e.updatedAt)],[r("due"),S(e.dueAt)],[r("resolved"),S(e.resolvedAt)]];return(0,t.jsx)("dl",{className:"grid gap-3 rounded-lg bg-muted/50 p-4 text-sm sm:grid-cols-2",children:a.map(([e,r])=>(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-xs text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-0.5 font-medium",children:r})]},e))})}function T({label:e,values:r}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-1",children:r.join(", ")})]})}e.s(["JiraTicketDrawer",0,function({issueKey:e,onClose:r,onTicketChange:c}){let S=(0,l.useTranslations)("jiraTickets"),[D,I]=(0,o.useState)(null),[E,A]=(0,o.useState)(null),[R,P]=(0,o.useState)(!1),[$,B]=(0,o.useState)(!1);(0,o.useEffect)(()=>{if(!e){let e=window.setTimeout(()=>I(null),0);return()=>window.clearTimeout(e)}let t=window.setTimeout(async()=>{P(!0);try{let t=await (0,b.controlPlaneRequest)(`query JiraTicket($issueKey: ID!) { jiraTicket(issueKey: $issueKey) { ${k.JIRA_TICKET_DETAIL_FIELDS} } }`,{issueKey:e});I(t.jiraTicket),A(null)}catch(e){A(e instanceof Error?e.message:String(e))}finally{P(!1)}},0);return()=>window.clearTimeout(t)},[e]);let J=e=>{I(e),c?.(e)};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(j.Sheet,{onOpenChange:e=>{e||r()},open:!!e,children:(0,t.jsxs)(j.SheetContent,{className:"w-[min(48rem,95vw)] overflow-y-auto sm:max-w-3xl",children:[(0,t.jsxs)(j.SheetHeader,{className:"border-b pr-12",children:[(0,t.jsx)(j.SheetTitle,{children:D?.key??e??S("ticket")}),(0,t.jsx)(j.SheetDescription,{children:D?.summary??S("loadingTicket")})]}),(0,t.jsxs)("div",{className:"space-y-6 px-4 pb-6",children:[R&&(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,t.jsx)(v.Spinner,{}),S("loadingTicket")]}),E&&(0,t.jsx)(p.Alert,{variant:"destructive",children:(0,t.jsx)(p.AlertDescription,{children:E})}),D&&(0,t.jsxs)(t.Fragment,{children:[(D.cache.stale||D.commentsCache.stale)&&(0,t.jsxs)(p.Alert,{className:"border-amber-500/30 bg-amber-500/10",children:[(0,t.jsx)(a,{}),(0,t.jsx)(p.AlertDescription,{children:S("staleTicket")})]}),(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsx)(h.Badge,{children:D.status}),D.issueType&&(0,t.jsx)(h.Badge,{children:D.issueType}),D.priority&&(0,t.jsx)(h.Badge,{className:N[D.priority.trim().toLowerCase()],children:D.priority})]}),(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsxs)(f.Button,{onClick:()=>B(!0),size:"sm",variant:"outline",children:[(0,t.jsx)(i.GitBranch,{})," ",S("worktreeAction")]}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)(y.Link,{href:`/jira/tickets/${encodeURIComponent(D.key)}`,children:[(0,t.jsx)(s,{})," ",S("openFullDetails")]})}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)("a",{href:D.jiraUrl,rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(n.ExternalLink,{})," ",S("openInJira")]})})]})]}),(0,t.jsx)(u.JiraTicketActions,{onTicketChange:J,ticket:D}),(0,t.jsx)(C,{ticket:D}),(0,t.jsx)("section",{children:(0,t.jsx)(x.Card,{size:"sm",children:(0,t.jsx)(x.CardContent,{children:(0,t.jsx)(d.JiraRichTextBlock,{content:D.descriptionContent,header:(0,t.jsx)("h3",{className:"font-semibold",children:S("descriptionTitle")}),headerClassName:"border-b pb-2",value:D.description})})})}),(D.labels.length>0||D.components.length>0||D.fixVersions.length>0||D.sprintNames.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("classification")}),(0,t.jsxs)("dl",{className:"grid gap-3 text-sm sm:grid-cols-2",children:[D.labels.length>0&&(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:S("labels")}),(0,t.jsx)("dd",{className:"mt-1 flex flex-wrap gap-1",children:D.labels.map(e=>(0,t.jsx)(h.Badge,{children:e},e))})]}),D.components.length>0&&(0,t.jsx)(T,{label:S("components"),values:D.components.map(e=>e.name)}),D.fixVersions.length>0&&(0,t.jsx)(T,{label:S("fixVersions"),values:D.fixVersions.map(e=>e.name)}),D.sprintNames.length>0&&(0,t.jsx)(T,{label:S("sprints"),values:D.sprintNames})]})]}),(D.parent||D.subtasks.length>0||D.issueLinks.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("relatedIssues")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:[...D.parent?[D.parent]:[],...D.subtasks,...D.issueLinks].map((e,r)=>(0,t.jsx)(g.Item,{asChild:!0,size:"xs",variant:"outline",children:(0,t.jsxs)(y.Link,{href:`/jira/tickets/${encodeURIComponent(e.key)}`,children:[(0,t.jsxs)(g.ItemContent,{children:[(0,t.jsxs)(g.ItemTitle,{className:"leading-tight",children:[e.key," · ",e.summary]}),(0,t.jsx)(g.ItemDescription,{className:"leading-tight",children:e.relationship})]}),(0,t.jsx)(g.ItemActions,{children:e.status&&(0,t.jsx)(h.Badge,{children:e.status})})]})},`${e.key}-${r}`))})]}),D.attachments.length>0&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("attachments")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:D.attachments.map(e=>(0,t.jsx)(g.Item,{asChild:!0,variant:"outline",children:(0,t.jsxs)("a",{href:e.contentUrl??"#",rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(g.ItemContent,{children:(0,t.jsx)(g.ItemTitle,{children:e.filename})}),(0,t.jsx)(g.ItemActions,{className:"text-xs text-muted-foreground",children:e.size?`${Math.round(e.size/1024)} KB`:""})]})},e.id))})]}),(0,t.jsx)(m.JiraTicketComments,{onTicketChange:J,ticket:D})]})]})]})}),D&&(0,t.jsx)(w.TicketWorktreeDialog,{issueKey:D.key,onOpenChange:B,open:$})]})}],356505)},250832,e=>{"use strict";let t=(0,e.i(456420).default)("settings-2",[["path",{d:"M14 17H5",key:"gfn3mx"}],["path",{d:"M19 7h-9",key:"6i9tg"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]]);e.s(["Settings2",0,t],250832)},630299,e=>{"use strict";let t=(0,e.i(456420).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["default",0,t])},784774,e=>{"use strict";var t=e.i(843476),r=e.i(975157);e.s(["Table",0,function({className:e,containerClassName:a,...n}){return(0,t.jsx)("div",{className:(0,r.cn)("w-full overflow-x-auto",a),children:(0,t.jsx)("table",{className:(0,r.cn)("w-full caption-bottom text-sm",e),...n})})},"TableBody",0,function({className:e,...a}){return(0,t.jsx)("tbody",{className:(0,r.cn)("divide-y",e),...a})},"TableCell",0,function({className:e,...a}){return(0,t.jsx)("td",{className:(0,r.cn)("whitespace-nowrap px-3 py-3 align-middle",e),...a})},"TableFooter",0,function({className:e,...a}){return(0,t.jsx)("tfoot",{className:(0,r.cn)("border-t bg-muted/50 font-medium",e),...a})},"TableHead",0,function({className:e,...a}){return(0,t.jsx)("th",{className:(0,r.cn)("h-10 whitespace-nowrap px-3 text-left align-middle text-xs font-medium text-muted-foreground",e),...a})},"TableHeader",0,function({className:e,...a}){return(0,t.jsx)("thead",{className:(0,r.cn)("border-b",e),...a})},"TableRow",0,function({className:e,...a}){return(0,t.jsx)("tr",{className:(0,r.cn)("transition-colors hover:bg-muted/40",e),...a})}])},689664,e=>{"use strict";var t=e.i(643957);e.s(["Check",()=>t.default])},508734,e=>{"use strict";let t=(0,e.i(456420).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],508734)},986253,e=>{"use strict";let t=(0,e.i(456420).default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);e.s(["default",0,t])},716327,e=>{"use strict";var t=e.i(26495);e.s(["ChevronDown",()=>t.default])},867927,e=>{"use strict";var t=e.i(986253);e.s(["ChevronRight",()=>t.default])},515281,e=>{"use strict";let t=(0,e.i(456420).default)("pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);e.s(["Pencil",0,t],515281)},960024,e=>{"use strict";var t=e.i(843476),r=e.i(853138),a=e.i(716327),n=e.i(867927),i=e.i(456420);let s=(0,i.default)("columns-3",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]]),l=(0,i.default)("folder-kanban",[["path",{d:"M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z",key:"1fr9dc"}],["path",{d:"M8 10v4",key:"tgpxqk"}],["path",{d:"M12 10v2",key:"hh53o1"}],["path",{d:"M16 10v6",key:"1d6xys"}]]);var o=e.i(515281),c=e.i(77071),d=e.i(741120),u=e.i(250832);let m=(0,i.default)("table-2",[["path",{d:"M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18",key:"gugj83"}]]);var p=e.i(573474),h=e.i(948148),f=e.i(618566),x=e.i(271645),g=e.i(340953),j=e.i(653090),v=e.i(356505),y=e.i(929592),b=e.i(487486),w=e.i(519455),k=e.i(515288),N=e.i(59497),S=e.i(776639),C=e.i(755146),T=e.i(82612),D=e.i(793479),I=e.i(906197),E=e.i(110204),A=e.i(967489),R=e.i(987968),P=e.i(784774),$=e.i(677572),B=e.i(624687),J=e.i(637611);let L="id projectId name kind value boardId position",z=`id jiraId key name avatarUrl position ticketAssignmentFilter hideCompletedTickets completedStatusIds branchNamingScript sources { ${L} }`,_=`source { ${L} } tickets { id key summary statusId status statusCategory issueType priority assignee assigneeAccountId assigneeAvatarUrl projectKey updatedAt } statusOrder cache { source stale fetchedAt } truncated warnings`,M={highest:"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300",high:"border-orange-500/30 bg-orange-500/10 text-orange-700 dark:text-orange-300",medium:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",low:"border-blue-500/30 bg-blue-500/10 text-blue-700 dark:text-blue-300",lowest:"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"};function F(e){let t=new URLSearchParams(window.location.search);for(let[r,a]of Object.entries(e))a?t.set(r,a):t.delete(r);let r=t.toString();window.history.pushState(null,"",`${window.location.pathname}${r?`?${r}`:""}`)}function U(e){return M[e.trim().toLowerCase()]}function O({statuses:e,value:r,onChange:n,label:i,placeholder:s,disabled:l}){let o=new Set(r);return(0,t.jsxs)(C.DropdownMenu,{children:[(0,t.jsx)(C.DropdownMenuTrigger,{asChild:!0,children:(0,t.jsxs)(w.Button,{"aria-label":i,className:"w-full justify-between font-normal",disabled:l,type:"button",variant:"outline",children:[(0,t.jsx)("span",{className:"truncate",children:r.length>0?`${r.length} ${i}`:s}),(0,t.jsx)(a.ChevronDown,{className:"shrink-0"})]})}),(0,t.jsx)(C.DropdownMenuContent,{align:"start",className:"z-60 max-h-64",children:e.map(e=>(0,t.jsxs)(C.DropdownMenuCheckboxItem,{checked:o.has(e.id),onCheckedChange:t=>n(t?[...o,e.id]:r.filter(t=>t!==e.id)),onSelect:e=>e.preventDefault(),children:[(0,t.jsx)("span",{className:"truncate",children:e.name}),(0,t.jsx)("span",{className:"ml-auto mr-5 pl-2 text-xs text-muted-foreground",children:e.category})]},e.id))})]})}function V({open:e,setOpen:r,projects:a,selectedProjectId:n,onProjectsChanged:i}){let s=(0,h.useTranslations)("jiraTickets"),l=(0,h.useTranslations)("common"),[d,u]=(0,x.useState)([]),[m,f]=(0,x.useState)(""),[j,v]=(0,x.useState)(null),[b,k]=(0,x.useState)(""),[C,T]=(0,x.useState)("JQL"),[R,P]=(0,x.useState)(""),[$,L]=(0,x.useState)(null),[_,M]=(0,x.useState)([]),[U,q]=(0,x.useState)(!1),[H,K]=(0,x.useState)("ALL"),[G,W]=(0,x.useState)(!1),[Q,X]=(0,x.useState)([]),[Z,Y]=(0,x.useState)(""),[ee,et]=(0,x.useState)(!1),[er,ea]=(0,x.useState)(null);(0,x.useEffect)(()=>{if(!e)return;let t=window.setTimeout(async()=>{try{let e=await (0,J.controlPlaneRequest)("query { jiraAvailableProjects { jiraId key name avatarUrl } }");u(e.jiraAvailableProjects)}catch(e){ea(e instanceof Error?e.message:String(e))}},0);return()=>window.clearTimeout(t)},[e]);let en=a.find(e=>e.id===j)??a.find(e=>e.id===n)??a[0]??null,ei=d.filter(e=>!a.some(t=>t.jiraId===e.jiraId));(0,x.useEffect)(()=>{if(!e||!en)return;let t=!1,r=window.setTimeout(async()=>{K(en.ticketAssignmentFilter),W(en.hideCompletedTickets),X(en.completedStatusIds),Y(en.branchNamingScript??""),q(!0);try{let e=await (0,J.controlPlaneRequest)("query JiraProjectStatuses($projectId: ID!) { jiraProjectStatuses(projectId: $projectId) { id name category } }",{projectId:en.id});if(t)return;M(e.jiraProjectStatuses),ea(null)}catch(e){if(t)return;ea(e instanceof Error?e.message:String(e)),M([])}finally{t||q(!1)}},0);return()=>{t=!0,window.clearTimeout(r)}},[e,en]);let es=async()=>{if(m){et(!0);try{let e=await (0,J.controlPlaneRequest)(`mutation AddJiraProject($jiraId: ID!) { addJiraProject(jiraId: $jiraId) { ${z} } }`,{jiraId:m});i(e.addJiraProject);let t=e.addJiraProject.find(e=>e.jiraId===m);t&&v(t.id),f(""),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},el=async e=>{et(!0);try{let t=await (0,J.controlPlaneRequest)(`mutation RemoveJiraProject($projectId: ID!) { removeJiraProject(projectId: $projectId) { ${z} } }`,{projectId:e});i(t.removeJiraProject),e===en?.id&&v(t.removeJiraProject[0]?.id??null),F({project:t.removeJiraProject[0]?.id??null,source:t.removeJiraProject[0]?.sources[0]?.id??null,issue:null}),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}},eo=async e=>{if(e.preventDefault(),en){et(!0);try{let e=$?`mutation UpdateJiraSource($input: UpdateJiraSourceInput!) { updateJiraSource(input: $input) { ${z} } }`:`mutation CreateJiraSource($input: CreateJiraSourceInput!) { createJiraSource(input: $input) { ${z} } }`,t=$?{id:$.id,name:b,kind:C,value:R}:{projectId:en.id,name:b,kind:C,value:R},r=await (0,J.controlPlaneRequest)(e,{input:t});i($?r.updateJiraSource:r.createJiraSource),k(""),P(""),T("JQL"),L(null),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},ec=async e=>{et(!0);try{let t=await (0,J.controlPlaneRequest)(`mutation DeleteJiraSource($id: ID!) { deleteJiraSource(id: $id) { ${z} } }`,{id:e});i(t.deleteJiraSource);let r=t.deleteJiraSource.find(e=>e.id===en?.id);F({source:r?.sources[0]?.id??null,issue:null}),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}},ed=async()=>{if(en){et(!0);try{let e={projectId:en.id,ticketAssignmentFilter:H,hideCompletedTickets:G,completedStatusIds:Q},t=await (0,J.controlPlaneRequest)(`mutation UpdateJiraProjectDisplaySettings($input: UpdateJiraProjectDisplaySettingsInput!) { updateJiraProjectDisplaySettings(input: $input) { ${z} } }`,{input:e});i(t.updateJiraProjectDisplaySettings),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},eu=async()=>{if(en){et(!0);try{let e=await (0,J.controlPlaneRequest)(`mutation UpdateJiraProjectBranchNaming($projectId: ID!, $branchNamingScript: String!) {
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,573474,e=>{"use strict";let t=(0,e.i(456420).default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",0,t],573474)},340953,e=>{"use strict";var t=e.i(843476),r=e.i(271645),a=e.i(30030);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return r.useCallback(function(...e){return t=>{let r=!1,a=e.map(e=>{let a=n(e,t);return r||"function"!=typeof a||(r=!0),a});if(r)return()=>{for(let t=0;t<a.length;t++){let r=a[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var s=e.i(326999);"u">typeof window&&window.document&&window.document.createElement;var l="AlertDialog",[o,c]=(0,a.createContextScope)(l,[s.createDialogScope]),d=(0,s.createDialogScope)(),u=e=>{let{__scopeAlertDialog:r,...a}=e,n=d(r);return(0,t.jsx)(s.Root,{...n,...a,modal:!0})};u.displayName=l;var m=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Trigger,{...i,...n,ref:r})});m.displayName="AlertDialogTrigger";var p=e=>{let{__scopeAlertDialog:r,...a}=e,n=d(r);return(0,t.jsx)(s.Portal,{...n,...a})};p.displayName="AlertDialogPortal";var h=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Overlay,{...i,...n,ref:r})});h.displayName="AlertDialogOverlay";var f="AlertDialogContent",[x,g]=o(f),j=r.forwardRef((e,a)=>{let{__scopeAlertDialog:n,children:l,...o}=e,c=d(n),u=i(a,r.useRef(null)),m=r.useRef(null);return(0,t.jsx)(x,{scope:n,cancelRef:m,children:(0,t.jsx)(s.Content,{role:"alertdialog",...c,...o,ref:u,onOpenAutoFocus:function(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e?.(a),!1===r||!a||!a.defaultPrevented)return t?.(a)}}(o.onOpenAutoFocus,e=>{e.preventDefault(),m.current?.focus({preventScroll:!0})}),onPointerDownOutside:e=>e.preventDefault(),onInteractOutside:e=>e.preventDefault(),children:l})})});j.displayName=f;var v=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Title,{...i,...n,ref:r})});v.displayName="AlertDialogTitle";var y=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Description,{...i,...n,ref:r})});y.displayName="AlertDialogDescription";var b=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,i=d(a);return(0,t.jsx)(s.Close,{...i,...n,ref:r})});b.displayName="AlertDialogAction";var w="AlertDialogCancel",k=r.forwardRef((e,r)=>{let{__scopeAlertDialog:a,...n}=e,{cancelRef:l}=g(w,a),o=d(a),c=i(r,l);return(0,t.jsx)(s.Close,{...o,...n,ref:c})});k.displayName=w,e.s(["Action",0,b,"AlertDialog",0,u,"AlertDialogAction",0,b,"AlertDialogCancel",0,k,"AlertDialogContent",0,j,"AlertDialogDescription",0,y,"AlertDialogOverlay",0,h,"AlertDialogPortal",0,p,"AlertDialogTitle",0,v,"AlertDialogTrigger",0,m,"Cancel",0,k,"Content",0,j,"Description",0,y,"Overlay",0,h,"Portal",0,p,"Root",0,u,"Title",0,v,"Trigger",0,m,"createAlertDialogScope",0,c],691162);var N=e.i(691162),N=N,S=e.i(975157),C=e.i(519455);function T({...e}){return(0,t.jsx)(N.Root,{"data-slot":"alert-dialog",...e})}function D({...e}){return(0,t.jsx)(N.Trigger,{"data-slot":"alert-dialog-trigger",...e})}function I({...e}){return(0,t.jsx)(N.Portal,{"data-slot":"alert-dialog-portal",...e})}function E({className:e,...r}){return(0,t.jsx)(N.Overlay,{"data-slot":"alert-dialog-overlay",className:(0,S.cn)("fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...r})}function A({className:e,size:r="default",...a}){return(0,t.jsxs)(I,{children:[(0,t.jsx)(E,{}),(0,t.jsx)(N.Content,{"data-slot":"alert-dialog-content","data-size":r,className:(0,S.cn)("group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...a})]})}function R({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"alert-dialog-header",className:(0,S.cn)("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]",e),...r})}function P({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"alert-dialog-footer",className:(0,S.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end",e),...r})}function $({className:e,...r}){return(0,t.jsx)(N.Title,{"data-slot":"alert-dialog-title",className:(0,S.cn)("font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2",e),...r})}function B({className:e,...r}){return(0,t.jsx)(N.Description,{"data-slot":"alert-dialog-description",className:(0,S.cn)("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),...r})}function J({className:e,variant:r="default",size:a="default",...n}){return(0,t.jsx)(C.Button,{variant:r,size:a,asChild:!0,children:(0,t.jsx)(N.Action,{"data-slot":"alert-dialog-action",className:(0,S.cn)(e),...n})})}function L({className:e,variant:r="outline",size:a="default",...n}){return(0,t.jsx)(C.Button,{variant:r,size:a,asChild:!0,children:(0,t.jsx)(N.Cancel,{"data-slot":"alert-dialog-cancel",className:(0,S.cn)(e),...n})})}e.s(["ConfirmationDialog",0,function({actionLabel:e,cancelLabel:r,description:a,onConfirm:n,onOpenChange:i,open:s,title:l,trigger:o}){return(0,t.jsxs)(T,{onOpenChange:i,open:s,children:[o&&(0,t.jsx)(D,{asChild:!0,children:o}),(0,t.jsxs)(A,{children:[(0,t.jsxs)(R,{children:[(0,t.jsx)($,{children:l}),(0,t.jsx)(B,{children:a})]}),(0,t.jsxs)(P,{children:[(0,t.jsx)(L,{children:r}),(0,t.jsx)(J,{onClick:()=>void n(),variant:"destructive",children:e})]})]})]})}],340953)},77071,e=>{"use strict";let t=(0,e.i(456420).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",0,t],77071)},776639,e=>{"use strict";var t=e.i(843476),r=e.i(560964),a=e.i(964053),n=e.i(519455),i=e.i(975157);function s({...e}){return(0,t.jsx)(a.Dialog.Portal,{"data-slot":"dialog-portal",...e})}function l({className:e,...r}){return(0,t.jsx)(a.Dialog.Overlay,{className:(0,i.cn)("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),"data-slot":"dialog-overlay",...r})}e.s(["Dialog",0,function({...e}){return(0,t.jsx)(a.Dialog.Root,{"data-slot":"dialog",...e})},"DialogContent",0,function({className:e,children:o,showCloseButton:c=!0,...d}){return(0,t.jsxs)(s,{children:[(0,t.jsx)(l,{}),(0,t.jsxs)(a.Dialog.Content,{className:(0,i.cn)("fixed top-1/2 left-1/2 z-50 grid max-h-[85dvh] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),"data-slot":"dialog-content",...d,children:[o,c&&(0,t.jsx)(a.Dialog.Close,{asChild:!0,"data-slot":"dialog-close",children:(0,t.jsxs)(n.Button,{className:"absolute top-2 right-2",size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(r.XIcon,{}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})})]})]})},"DialogDescription",0,function({className:e,...r}){return(0,t.jsx)(a.Dialog.Description,{className:(0,i.cn)("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),"data-slot":"dialog-description",...r})},"DialogFooter",0,function({className:e,showCloseButton:r=!1,children:s,...l}){return(0,t.jsxs)("div",{className:(0,i.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",e),"data-slot":"dialog-footer",...l,children:[s,r&&(0,t.jsx)(a.Dialog.Close,{asChild:!0,children:(0,t.jsx)(n.Button,{variant:"outline",children:"Close"})})]})},"DialogHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{className:(0,i.cn)("flex flex-col gap-2",e),"data-slot":"dialog-header",...r})},"DialogTitle",0,function({className:e,...r}){return(0,t.jsx)(a.Dialog.Title,{className:(0,i.cn)("font-heading text-base leading-none font-medium",e),"data-slot":"dialog-title",...r})}])},59497,e=>{"use strict";var t=e.i(843476),r=e.i(271645);function a(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function n(...e){return r.useCallback(function(...e){return t=>{let r=!1,n=e.map(e=>{let n=a(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():a(e[t],null)}}}}(...e),e)}var i=e.i(30030);function s(e,t,{checkForDefaultPrevented:r=!0}={}){return function(a){if(e?.(a),!1===r||!a||!a.defaultPrevented)return t?.(a)}}"u">typeof window&&window.document&&window.document.createElement;var l=globalThis?.document?r.useLayoutEffect:()=>{};r[" useEffectEvent ".trim().toString()],r[" useInsertionEffect ".trim().toString()];var o=r[" useInsertionEffect ".trim().toString()]||l;Symbol("RADIX:SYNC_STATE");var c=e.i(999682),d=e.i(635804),u=e.i(296626);e.i(174080);var m=Symbol.for("radix.slottable"),p=Symbol.for("react.lazy");function h(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===p&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var f=r[" use ".trim().toString()],x=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,a)=>{var i;let s,l=(i=`Primitive.${a}`,(s=r.forwardRef((e,t)=>{var a;let s,l,{children:o,...c}=e,d=null,u=!1,p=[];h(o)&&"function"==typeof f&&(o=f(o._payload)),r.Children.forEach(o,e=>{var t;if(t=e,r.isValidElement(t)&&"function"==typeof t.type&&"__radixId"in t.type&&t.type.__radixId===m){u=!0;let t="child"in e.props?e.props.child:e.props.children;h(t)&&"function"==typeof f&&(t=f(t._payload)),d=((e,t)=>{if("child"in e.props){let t=e.props.child;return r.isValidElement(t)?r.cloneElement(t,void 0,e.props.children(t.props.children)):null}return r.isValidElement(t)?t:null})(e,t),p.push(d?.props?.children)}else p.push(e)}),d?d=r.cloneElement(d,void 0,p):!u&&1===r.Children.count(o)&&r.isValidElement(o)&&(d=o);let x=d?(a=d,(l=(s=Object.getOwnPropertyDescriptor(a.props,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?a.ref:(l=(s=Object.getOwnPropertyDescriptor(a,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?a.props.ref:a.props.ref||a.ref):void 0,g=n(t,x);if(!d){if(o||0===o){let e,t;throw Error(u?(e=i,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=i,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return o}let j=function(e,t){let r={...t};for(let a in t){let n=e[a],i=t[a];/^on[A-Z]/.test(a)?n&&i?r[a]=(...e)=>{let t=i(...e);return n(...e),t}:n&&(r[a]=n):"style"===a?r[a]={...n,...i}:"className"===a&&(r[a]=[n,i].filter(Boolean).join(" "))}return{...e,...r}}(c,d.props??{});return d.type!==r.Fragment&&(j.ref=t?g:x),r.cloneElement(d,j)})).displayName=`${i}.Slot`,s),o=r.forwardRef((e,r)=>{let{asChild:n,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,t.jsx)(n?l:a,{...i,ref:r})});return o.displayName=`Primitive.${a}`,{...e,[a]:o}},{}),g="Checkbox",[j,v]=(0,i.createContextScope)(g),[y,b]=j(g);function w(e){let{__scopeCheckbox:a,checked:n,children:i,defaultChecked:s,disabled:l,form:c,name:d,onCheckedChange:u,required:m,value:p="on",internal_do_not_use_render:h}=e,[f,x]=function({prop:e,defaultProp:t,onChange:a=()=>{},caller:n}){let[i,s,l]=function({defaultProp:e,onChange:t}){let[a,n]=r.useState(e),i=r.useRef(a),s=r.useRef(t);return o(()=>{s.current=t},[t]),r.useEffect(()=>{i.current!==a&&(s.current?.(a),i.current=a)},[a,i]),[a,n,s]}({defaultProp:t,onChange:a}),c=void 0!==e,d=c?e:i;{let t=r.useRef(void 0!==e);r.useEffect(()=>{let e=t.current;if(e!==c){let t=c?"controlled":"uncontrolled";console.warn(`${n} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=c},[c,n])}return[d,r.useCallback(t=>{if(c){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else s(t)},[c,e,s,l])]}({prop:n,defaultProp:s??!1,onChange:u,caller:g}),[j,v]=r.useState(null),[b,w]=r.useState(null),k=r.useRef(!1),N=!j||!!c||!!j.closest("form"),S={checked:f,disabled:l,setChecked:x,control:j,setControl:v,name:d,form:c,value:p,hasConsumerStoppedPropagationRef:k,required:m,defaultChecked:!E(s)&&s,isFormControl:N,bubbleInput:b,setBubbleInput:w};return(0,t.jsx)(y,{scope:a,...S,children:"function"==typeof h?h(S):i})}var k="CheckboxTrigger",N=r.forwardRef(({__scopeCheckbox:e,onKeyDown:a,onClick:i,...l},o)=>{let{control:c,value:d,disabled:u,checked:m,required:p,setControl:h,setChecked:f,hasConsumerStoppedPropagationRef:g,isFormControl:j,bubbleInput:v}=b(k,e),y=n(o,h),w=r.useRef(m);return r.useEffect(()=>{let e=c?.form;if(e){let t=()=>f(w.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}},[c,f]),(0,t.jsx)(x.button,{type:"button",role:"checkbox","aria-checked":E(m)?"mixed":m,"aria-required":p,"data-state":A(m),"data-disabled":u?"":void 0,disabled:u,value:d,...l,ref:y,onKeyDown:s(a,e=>{"Enter"===e.key&&e.preventDefault()}),onClick:s(i,e=>{f(e=>!!E(e)||!e),v&&j&&(g.current=e.isPropagationStopped(),g.current||e.stopPropagation())})})});N.displayName=k;var S=r.forwardRef((e,r)=>{let{__scopeCheckbox:a,name:n,checked:i,defaultChecked:s,required:l,disabled:o,value:c,onCheckedChange:d,form:u,...m}=e;return(0,t.jsx)(w,{__scopeCheckbox:a,checked:i,defaultChecked:s,disabled:o,required:l,onCheckedChange:d,name:n,form:u,value:c,internal_do_not_use_render:({isFormControl:e})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(N,{...m,ref:r,__scopeCheckbox:a}),e&&(0,t.jsx)(I,{__scopeCheckbox:a})]})})});S.displayName=g;var C="CheckboxIndicator",T=r.forwardRef((e,r)=>{let{__scopeCheckbox:a,forceMount:n,...i}=e,s=b(C,a);return(0,t.jsx)(u.Presence,{present:n||E(s.checked)||!0===s.checked,children:(0,t.jsx)(x.span,{"data-state":A(s.checked),"data-disabled":s.disabled?"":void 0,...i,ref:r,style:{pointerEvents:"none",...e.style}})})});T.displayName=C;var D="CheckboxBubbleInput",I=r.forwardRef(({__scopeCheckbox:e,...a},i)=>{let{control:s,hasConsumerStoppedPropagationRef:l,checked:o,defaultChecked:u,required:m,disabled:p,name:h,value:f,form:g,bubbleInput:j,setBubbleInput:v}=b(D,e),y=n(i,v),w=(0,c.usePrevious)(o),k=(0,d.useSize)(s);r.useEffect(()=>{if(!j)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set,t=!l.current;if(w!==o&&e){let r=new Event("click",{bubbles:t});j.indeterminate=E(o),e.call(j,!E(o)&&o),j.dispatchEvent(r)}},[j,w,o,l]);let N=r.useRef(!E(o)&&o);return(0,t.jsx)(x.input,{type:"checkbox","aria-hidden":!0,defaultChecked:u??N.current,required:m,disabled:p,name:h,value:f,form:g,...a,tabIndex:-1,ref:y,style:{...a.style,...k,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});function E(e){return"indeterminate"===e}function A(e){return E(e)?"indeterminate":e?"checked":"unchecked"}I.displayName=D,e.s(["Checkbox",0,S,"CheckboxIndicator",0,T,"Indicator",0,T,"Root",0,S,"createCheckboxScope",0,v,"unstable_BubbleInput",0,I,"unstable_CheckboxBubbleInput",0,I,"unstable_CheckboxProvider",0,w,"unstable_CheckboxTrigger",0,N,"unstable_Provider",0,w,"unstable_Trigger",0,N],388474);var R=e.i(388474),R=R,P=e.i(975157),$=e.i(593698);e.s(["Checkbox",0,function({className:e,...r}){return(0,t.jsx)(R.Root,{"data-slot":"checkbox",className:(0,P.cn)("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",e),...r,children:(0,t.jsx)(R.Indicator,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none [&>svg]:size-3.5",children:(0,t.jsx)($.CheckIcon,{})})})}],59497)},482022,e=>{"use strict";let t=(0,e.i(456420).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["ExternalLink",0,t],482022)},741120,e=>{"use strict";let t=(0,e.i(456420).default)("refresh-cw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);e.s(["RefreshCw",0,t],741120)},82612,e=>{"use strict";var t=e.i(843476),r=e.i(225913),a=e.i(975157);let n=(0,r.cva)("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"}},defaultVariants:{variant:"default"}});e.s(["Empty",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty",className:(0,a.cn)("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance",e),...r})},"EmptyDescription",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-description",className:(0,a.cn)("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",e),...r})},"EmptyHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-header",className:(0,a.cn)("flex max-w-sm flex-col items-center gap-2",e),...r})},"EmptyMedia",0,function({className:e,variant:r="default",...i}){return(0,t.jsx)("div",{"data-slot":"empty-icon","data-variant":r,className:(0,a.cn)(n({variant:r,className:e})),...i})},"EmptyTitle",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-title",className:(0,a.cn)("font-heading text-sm font-medium tracking-tight",e),...r})}])},462777,e=>{"use strict";async function t(e){if(navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.append(t),t.select();let r=document.execCommand("copy");if(t.remove(),!r)throw Error("Copy is not supported by this browser")}e.s(["copyText",0,t,"createClientId",0,function(){try{if(globalThis.crypto?.randomUUID)return globalThis.crypto.randomUUID()}catch{}if(globalThis.crypto?.getRandomValues)try{let e=globalThis.crypto.getRandomValues(new Uint8Array(16));return Array.from(e,e=>e.toString(16).padStart(2,"0")).join("")}catch{}return`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}])},842727,e=>{"use strict";var t=e.i(271645);function r(e,t,{checkForDefaultPrevented:a=!0}={}){return function(r){if(e?.(r),!1===a||!r||!r.defaultPrevented)return t?.(r)}}"u">typeof window&&window.document&&window.document.createElement;var a=e.i(75830);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return t.useCallback(function(...e){return t=>{let r=!1,a=e.map(e=>{let a=n(e,t);return r||"function"!=typeof a||(r=!0),a});if(r)return()=>{for(let t=0;t<a.length;t++){let r=a[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var s=e.i(30030),l=e.i(610772);e.i(174080);var o=Symbol.for("radix.slottable"),c=Symbol.for("react.lazy");function d(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===c&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var u=t[" use ".trim().toString()],m=e.i(843476),p=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{var a;let n,s=(a=`Primitive.${r}`,(n=t.forwardRef((e,r)=>{var n;let s,l,{children:c,...m}=e,p=null,h=!1,f=[];d(c)&&"function"==typeof u&&(c=u(c._payload)),t.Children.forEach(c,e=>{var r;if(r=e,t.isValidElement(r)&&"function"==typeof r.type&&"__radixId"in r.type&&r.type.__radixId===o){h=!0;let r="child"in e.props?e.props.child:e.props.children;d(r)&&"function"==typeof u&&(r=u(r._payload)),p=((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null})(e,r),f.push(p?.props?.children)}else f.push(e)}),p?p=t.cloneElement(p,void 0,f):!h&&1===t.Children.count(c)&&t.isValidElement(c)&&(p=c);let x=p?(n=p,(l=(s=Object.getOwnPropertyDescriptor(n.props,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?n.ref:(l=(s=Object.getOwnPropertyDescriptor(n,"ref")?.get)&&"isReactWarning"in s&&s.isReactWarning)?n.props.ref:n.props.ref||n.ref):void 0,g=i(r,x);if(!p){if(c||0===c){let e,t;throw Error(h?(e=a,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=a,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return c}let j=function(e,t){let r={...t};for(let a in t){let n=e[a],i=t[a];/^on[A-Z]/.test(a)?n&&i?r[a]=(...e)=>{let t=i(...e);return n(...e),t}:n&&(r[a]=n):"style"===a?r[a]={...n,...i}:"className"===a&&(r[a]=[n,i].filter(Boolean).join(" "))}return{...e,...r}}(m,p.props??{});return p.type!==t.Fragment&&(j.ref=r?g:x),t.cloneElement(p,j)})).displayName=`${a}.Slot`,n),l=t.forwardRef((e,t)=>{let{asChild:a,...n}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,m.jsx)(a?s:r,{...n,ref:t})});return l.displayName=`Primitive.${r}`,{...e,[r]:l}},{}),h=e.i(30207),f=globalThis?.document?t.useLayoutEffect:()=>{};t[" useEffectEvent ".trim().toString()],t[" useInsertionEffect ".trim().toString()];var x=t[" useInsertionEffect ".trim().toString()]||f;Symbol("RADIX:SYNC_STATE");var g=e.i(586318),j=!1,v=t[" useSyncExternalStore ".trim().toString()];function y(){return()=>{}}var b="function"==typeof v?function(){return v(y,()=>!0,()=>!1)}:function(){let[e,r]=t.useState(j);return t.useEffect(()=>{j||(j=!0,r(!0))},[]),e},w="rovingFocusGroup.onEntryFocus",k={bubbles:!1,cancelable:!0},N="RovingFocusGroup",[S,C,T]=(0,a.createCollection)(N),[D,I]=(0,s.createContextScope)(N,[T]),[E,A]=D(N),R=t.forwardRef((e,t)=>(0,m.jsx)(S.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(S.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(P,{...e,ref:t})})}));R.displayName=N;var P=t.forwardRef((e,a)=>{let{__scopeRovingFocusGroup:n,orientation:s,loop:l=!1,dir:o,currentTabStopId:c,defaultCurrentTabStopId:d,onCurrentTabStopIdChange:u,onEntryFocus:f,preventScrollOnEntryFocus:j=!1,...v}=e,y=t.useRef(null),b=i(a,y),S=(0,g.useDirection)(o),[T,D]=function({prop:e,defaultProp:r,onChange:a=()=>{},caller:n}){let[i,s,l]=function({defaultProp:e,onChange:r}){let[a,n]=t.useState(e),i=t.useRef(a),s=t.useRef(r);return x(()=>{s.current=r},[r]),t.useEffect(()=>{i.current!==a&&(s.current?.(a),i.current=a)},[a,i]),[a,n,s]}({defaultProp:r,onChange:a}),o=void 0!==e,c=o?e:i;{let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==o){let t=o?"controlled":"uncontrolled";console.warn(`${n} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=o},[o,n])}return[c,t.useCallback(t=>{if(o){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else s(t)},[o,e,s,l])]}({prop:c,defaultProp:d??null,onChange:u,caller:N}),[I,A]=t.useState(!1),R=(0,h.useCallbackRef)(f),P=C(n),$=t.useRef(!1),[B,J]=t.useState(0);return t.useEffect(()=>{let e=y.current;if(e)return e.addEventListener(w,R),()=>e.removeEventListener(w,R)},[R]),(0,m.jsx)(E,{scope:n,orientation:s,dir:S,loop:l,currentTabStopId:T,onItemFocus:t.useCallback(e=>D(e),[D]),onItemShiftTab:t.useCallback(()=>A(!0),[]),onFocusableItemAdd:t.useCallback(()=>J(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>J(e=>e-1),[]),children:(0,m.jsx)(p.div,{tabIndex:I||0===B?-1:0,"data-orientation":s,...v,ref:b,style:{outline:"none",...e.style},onMouseDown:r(e.onMouseDown,()=>{$.current=!0}),onFocus:r(e.onFocus,e=>{let t=!$.current;if(e.target===e.currentTarget&&t&&!I){let t=new CustomEvent(w,k);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=P().filter(e=>e.focusable);L([e.find(e=>e.active),e.find(e=>e.id===T),...e].filter(Boolean).map(e=>e.ref.current),j)}}$.current=!1}),onBlur:r(e.onBlur,()=>A(!1))})})}),$="RovingFocusGroupItem",B=t.forwardRef((e,a)=>{let{__scopeRovingFocusGroup:n,focusable:i=!0,active:s=!1,tabStopId:o,children:c,...d}=e,u=(0,l.useId)(),h=o||u,x=A($,n),g=x.currentTabStopId===h,j=C(n),{onFocusableItemAdd:v,onFocusableItemRemove:y,currentTabStopId:w}=x,k=b();return f(()=>{if(k&&i)return v(),()=>y()},[k,i,v,y]),t.useEffect(()=>{if(!k&&i)return v(),()=>y()},[k,i,v,y]),(0,m.jsx)(S.ItemSlot,{scope:n,id:h,focusable:i,active:s,children:(0,m.jsx)(p.span,{tabIndex:g?0:-1,"data-orientation":x.orientation,...d,ref:a,onMouseDown:r(e.onMouseDown,e=>{i?x.onItemFocus(h):e.preventDefault()}),onFocus:r(e.onFocus,()=>x.onItemFocus(h)),onKeyDown:r(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void x.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var a;let n=(a=e.key,"rtl"!==r?a:"ArrowLeft"===a?"ArrowRight":"ArrowRight"===a?"ArrowLeft":a);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(n))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(n)))return J[n]}(e,x.orientation,x.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=j().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)n.reverse();else if("prev"===t||"next"===t){var r,a;"prev"===t&&n.reverse();let i=n.indexOf(e.currentTarget);n=x.loop?(r=n,a=i+1,r.map((e,t)=>r[(a+t)%r.length])):n.slice(i+1)}setTimeout(()=>L(n))}}),children:"function"==typeof c?c({isCurrentTabStop:g,hasTabStop:null!=w}):c})})});B.displayName=$;var J={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function L(e,t=!1){let r=document.activeElement;for(let a of e)if(a===r||(a.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",0,B,"Root",0,R,"createRovingFocusGroupScope",0,I],842727)},560972,e=>{"use strict";let t=(0,e.i(456420).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);e.s(["default",0,t])},356505,853138,e=>{"use strict";var t=e.i(843476),r=e.i(456420);let a=(0,r.default)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);e.s(["AlertTriangle",0,a],853138);var n=e.i(482022),i=e.i(269846);let s=(0,r.default)("maximize-2",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]]);var l=e.i(948148),o=e.i(271645),c=e.i(653090),d=e.i(278015),u=e.i(762279),m=e.i(456743),p=e.i(929592),h=e.i(487486),f=e.i(519455),x=e.i(515288),g=e.i(906197),j=e.i(980376),v=e.i(987968),y=e.i(520133),b=e.i(637611),w=e.i(741725),k=e.i(467511);let N={highest:"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300",high:"border-orange-500/30 bg-orange-500/10 text-orange-700 dark:text-orange-300",medium:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",low:"border-blue-500/30 bg-blue-500/10 text-blue-700 dark:text-blue-300",lowest:"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"};function S(e){return e?new Date(e).toLocaleString():"—"}function C({ticket:e}){let r=(0,l.useTranslations)("jiraTickets"),a=[[r("assignee"),(0,t.jsx)(c.JiraUser,{avatarUrl:e.assigneeAvatarUrl,name:e.assignee??r("unassigned")},"assignee")],[r("reporter"),e.reporter?(0,t.jsx)(c.JiraUser,{avatarUrl:e.reporter.avatarUrl,name:e.reporter.displayName},"reporter"):"—"],[r("created"),S(e.createdAt)],[r("updated"),S(e.updatedAt)],[r("due"),S(e.dueAt)],[r("resolved"),S(e.resolvedAt)]];return(0,t.jsx)("dl",{className:"grid gap-3 rounded-lg bg-muted/50 p-4 text-sm sm:grid-cols-2",children:a.map(([e,r])=>(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-xs text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-0.5 font-medium",children:r})]},e))})}function T({label:e,values:r}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-1",children:r.join(", ")})]})}e.s(["JiraTicketDrawer",0,function({issueKey:e,onClose:r,onTicketChange:c}){let S=(0,l.useTranslations)("jiraTickets"),[D,I]=(0,o.useState)(null),[E,A]=(0,o.useState)(null),[R,P]=(0,o.useState)(!1),[$,B]=(0,o.useState)(!1);(0,o.useEffect)(()=>{if(!e){let e=window.setTimeout(()=>I(null),0);return()=>window.clearTimeout(e)}let t=window.setTimeout(async()=>{P(!0);try{let t=await (0,b.controlPlaneRequest)(`query JiraTicket($issueKey: ID!) { jiraTicket(issueKey: $issueKey) { ${k.JIRA_TICKET_DETAIL_FIELDS} } }`,{issueKey:e});I(t.jiraTicket),A(null)}catch(e){A(e instanceof Error?e.message:String(e))}finally{P(!1)}},0);return()=>window.clearTimeout(t)},[e]);let J=e=>{I(e),c?.(e)};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(j.Sheet,{onOpenChange:e=>{e||r()},open:!!e,children:(0,t.jsxs)(j.SheetContent,{className:"w-[min(48rem,95vw)] overflow-y-auto sm:max-w-3xl",children:[(0,t.jsxs)(j.SheetHeader,{className:"border-b pr-12",children:[(0,t.jsx)(j.SheetTitle,{children:D?.key??e??S("ticket")}),(0,t.jsx)(j.SheetDescription,{children:D?.summary??S("loadingTicket")})]}),(0,t.jsxs)("div",{className:"space-y-6 px-4 pb-6",children:[R&&(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,t.jsx)(v.Spinner,{}),S("loadingTicket")]}),E&&(0,t.jsx)(p.Alert,{variant:"destructive",children:(0,t.jsx)(p.AlertDescription,{children:E})}),D&&(0,t.jsxs)(t.Fragment,{children:[(D.cache.stale||D.commentsCache.stale)&&(0,t.jsxs)(p.Alert,{className:"border-amber-500/30 bg-amber-500/10",children:[(0,t.jsx)(a,{}),(0,t.jsx)(p.AlertDescription,{children:S("staleTicket")})]}),(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsx)(h.Badge,{children:D.status}),D.issueType&&(0,t.jsx)(h.Badge,{children:D.issueType}),D.priority&&(0,t.jsx)(h.Badge,{className:N[D.priority.trim().toLowerCase()],children:D.priority})]}),(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsxs)(f.Button,{onClick:()=>B(!0),size:"sm",variant:"outline",children:[(0,t.jsx)(i.GitBranch,{})," ",S("worktreeAction")]}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)(y.Link,{href:`/jira/tickets/${encodeURIComponent(D.key)}`,children:[(0,t.jsx)(s,{})," ",S("openFullDetails")]})}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)("a",{href:D.jiraUrl,rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(n.ExternalLink,{})," ",S("openInJira")]})})]})]}),(0,t.jsx)(u.JiraTicketActions,{onTicketChange:J,ticket:D}),(0,t.jsx)(C,{ticket:D}),(0,t.jsx)("section",{children:(0,t.jsx)(x.Card,{size:"sm",children:(0,t.jsx)(x.CardContent,{children:(0,t.jsx)(d.JiraRichTextBlock,{content:D.descriptionContent,header:(0,t.jsx)("h3",{className:"font-semibold",children:S("descriptionTitle")}),headerClassName:"border-b pb-2",value:D.description})})})}),(D.labels.length>0||D.components.length>0||D.fixVersions.length>0||D.sprintNames.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("classification")}),(0,t.jsxs)("dl",{className:"grid gap-3 text-sm sm:grid-cols-2",children:[D.labels.length>0&&(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:S("labels")}),(0,t.jsx)("dd",{className:"mt-1 flex flex-wrap gap-1",children:D.labels.map(e=>(0,t.jsx)(h.Badge,{children:e},e))})]}),D.components.length>0&&(0,t.jsx)(T,{label:S("components"),values:D.components.map(e=>e.name)}),D.fixVersions.length>0&&(0,t.jsx)(T,{label:S("fixVersions"),values:D.fixVersions.map(e=>e.name)}),D.sprintNames.length>0&&(0,t.jsx)(T,{label:S("sprints"),values:D.sprintNames})]})]}),(D.parent||D.subtasks.length>0||D.issueLinks.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("relatedIssues")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:[...D.parent?[D.parent]:[],...D.subtasks,...D.issueLinks].map((e,r)=>(0,t.jsx)(g.Item,{asChild:!0,size:"xs",variant:"outline",children:(0,t.jsxs)(y.Link,{href:`/jira/tickets/${encodeURIComponent(e.key)}`,children:[(0,t.jsxs)(g.ItemContent,{children:[(0,t.jsxs)(g.ItemTitle,{className:"leading-tight",children:[e.key," · ",e.summary]}),(0,t.jsx)(g.ItemDescription,{className:"leading-tight",children:e.relationship})]}),(0,t.jsx)(g.ItemActions,{children:e.status&&(0,t.jsx)(h.Badge,{children:e.status})})]})},`${e.key}-${r}`))})]}),D.attachments.length>0&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:S("attachments")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:D.attachments.map(e=>(0,t.jsx)(g.Item,{asChild:!0,variant:"outline",children:(0,t.jsxs)("a",{href:e.contentUrl??"#",rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(g.ItemContent,{children:(0,t.jsx)(g.ItemTitle,{children:e.filename})}),(0,t.jsx)(g.ItemActions,{className:"text-xs text-muted-foreground",children:e.size?`${Math.round(e.size/1024)} KB`:""})]})},e.id))})]}),(0,t.jsx)(m.JiraTicketComments,{onTicketChange:J,ticket:D})]})]})]})}),D&&(0,t.jsx)(w.TicketWorktreeDialog,{issueKey:D.key,onOpenChange:B,open:$})]})}],356505)},250832,e=>{"use strict";let t=(0,e.i(456420).default)("settings-2",[["path",{d:"M14 17H5",key:"gfn3mx"}],["path",{d:"M19 7h-9",key:"6i9tg"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]]);e.s(["Settings2",0,t],250832)},508734,e=>{"use strict";let t=(0,e.i(456420).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],508734)},784774,e=>{"use strict";var t=e.i(843476),r=e.i(975157);e.s(["Table",0,function({className:e,containerClassName:a,...n}){return(0,t.jsx)("div",{className:(0,r.cn)("w-full overflow-x-auto",a),children:(0,t.jsx)("table",{className:(0,r.cn)("w-full caption-bottom text-sm",e),...n})})},"TableBody",0,function({className:e,...a}){return(0,t.jsx)("tbody",{className:(0,r.cn)("divide-y",e),...a})},"TableCell",0,function({className:e,...a}){return(0,t.jsx)("td",{className:(0,r.cn)("whitespace-nowrap px-3 py-3 align-middle",e),...a})},"TableFooter",0,function({className:e,...a}){return(0,t.jsx)("tfoot",{className:(0,r.cn)("border-t bg-muted/50 font-medium",e),...a})},"TableHead",0,function({className:e,...a}){return(0,t.jsx)("th",{className:(0,r.cn)("h-10 whitespace-nowrap px-3 text-left align-middle text-xs font-medium text-muted-foreground",e),...a})},"TableHeader",0,function({className:e,...a}){return(0,t.jsx)("thead",{className:(0,r.cn)("border-b",e),...a})},"TableRow",0,function({className:e,...a}){return(0,t.jsx)("tr",{className:(0,r.cn)("transition-colors hover:bg-muted/40",e),...a})}])},689664,e=>{"use strict";var t=e.i(643957);e.s(["Check",()=>t.default])},630299,e=>{"use strict";let t=(0,e.i(456420).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["default",0,t])},986253,e=>{"use strict";let t=(0,e.i(456420).default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);e.s(["default",0,t])},716327,e=>{"use strict";var t=e.i(26495);e.s(["ChevronDown",()=>t.default])},867927,e=>{"use strict";var t=e.i(986253);e.s(["ChevronRight",()=>t.default])},515281,e=>{"use strict";let t=(0,e.i(456420).default)("pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);e.s(["Pencil",0,t],515281)},960024,e=>{"use strict";var t=e.i(843476),r=e.i(853138),a=e.i(716327),n=e.i(867927),i=e.i(456420);let s=(0,i.default)("columns-3",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]]),l=(0,i.default)("folder-kanban",[["path",{d:"M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z",key:"1fr9dc"}],["path",{d:"M8 10v4",key:"tgpxqk"}],["path",{d:"M12 10v2",key:"hh53o1"}],["path",{d:"M16 10v6",key:"1d6xys"}]]);var o=e.i(515281),c=e.i(77071),d=e.i(741120),u=e.i(250832);let m=(0,i.default)("table-2",[["path",{d:"M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18",key:"gugj83"}]]);var p=e.i(573474),h=e.i(948148),f=e.i(618566),x=e.i(271645),g=e.i(340953),j=e.i(653090),v=e.i(356505),y=e.i(929592),b=e.i(487486),w=e.i(519455),k=e.i(515288),N=e.i(59497),S=e.i(776639),C=e.i(755146),T=e.i(82612),D=e.i(793479),I=e.i(906197),E=e.i(110204),A=e.i(967489),R=e.i(987968),P=e.i(784774),$=e.i(677572),B=e.i(624687),J=e.i(637611);let L="id projectId name kind value boardId position",z=`id jiraId key name avatarUrl position ticketAssignmentFilter hideCompletedTickets completedStatusIds branchNamingScript sources { ${L} }`,_=`source { ${L} } tickets { id key summary statusId status statusCategory issueType priority assignee assigneeAccountId assigneeAvatarUrl projectKey updatedAt } statusOrder cache { source stale fetchedAt } truncated warnings`,M={highest:"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300",high:"border-orange-500/30 bg-orange-500/10 text-orange-700 dark:text-orange-300",medium:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",low:"border-blue-500/30 bg-blue-500/10 text-blue-700 dark:text-blue-300",lowest:"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"};function F(e){let t=new URLSearchParams(window.location.search);for(let[r,a]of Object.entries(e))a?t.set(r,a):t.delete(r);let r=t.toString();window.history.pushState(null,"",`${window.location.pathname}${r?`?${r}`:""}`)}function U(e){return M[e.trim().toLowerCase()]}function O({statuses:e,value:r,onChange:n,label:i,placeholder:s,disabled:l}){let o=new Set(r);return(0,t.jsxs)(C.DropdownMenu,{children:[(0,t.jsx)(C.DropdownMenuTrigger,{asChild:!0,children:(0,t.jsxs)(w.Button,{"aria-label":i,className:"w-full justify-between font-normal",disabled:l,type:"button",variant:"outline",children:[(0,t.jsx)("span",{className:"truncate",children:r.length>0?`${r.length} ${i}`:s}),(0,t.jsx)(a.ChevronDown,{className:"shrink-0"})]})}),(0,t.jsx)(C.DropdownMenuContent,{align:"start",className:"z-60 max-h-64",children:e.map(e=>(0,t.jsxs)(C.DropdownMenuCheckboxItem,{checked:o.has(e.id),onCheckedChange:t=>n(t?[...o,e.id]:r.filter(t=>t!==e.id)),onSelect:e=>e.preventDefault(),children:[(0,t.jsx)("span",{className:"truncate",children:e.name}),(0,t.jsx)("span",{className:"ml-auto mr-5 pl-2 text-xs text-muted-foreground",children:e.category})]},e.id))})]})}function V({open:e,setOpen:r,projects:a,selectedProjectId:n,onProjectsChanged:i}){let s=(0,h.useTranslations)("jiraTickets"),l=(0,h.useTranslations)("common"),[d,u]=(0,x.useState)([]),[m,f]=(0,x.useState)(""),[j,v]=(0,x.useState)(null),[b,k]=(0,x.useState)(""),[C,T]=(0,x.useState)("JQL"),[R,P]=(0,x.useState)(""),[$,L]=(0,x.useState)(null),[_,M]=(0,x.useState)([]),[U,q]=(0,x.useState)(!1),[H,K]=(0,x.useState)("ALL"),[G,W]=(0,x.useState)(!1),[Q,X]=(0,x.useState)([]),[Z,Y]=(0,x.useState)(""),[ee,et]=(0,x.useState)(!1),[er,ea]=(0,x.useState)(null);(0,x.useEffect)(()=>{if(!e)return;let t=window.setTimeout(async()=>{try{let e=await (0,J.controlPlaneRequest)("query { jiraAvailableProjects { jiraId key name avatarUrl } }");u(e.jiraAvailableProjects)}catch(e){ea(e instanceof Error?e.message:String(e))}},0);return()=>window.clearTimeout(t)},[e]);let en=a.find(e=>e.id===j)??a.find(e=>e.id===n)??a[0]??null,ei=d.filter(e=>!a.some(t=>t.jiraId===e.jiraId));(0,x.useEffect)(()=>{if(!e||!en)return;let t=!1,r=window.setTimeout(async()=>{K(en.ticketAssignmentFilter),W(en.hideCompletedTickets),X(en.completedStatusIds),Y(en.branchNamingScript??""),q(!0);try{let e=await (0,J.controlPlaneRequest)("query JiraProjectStatuses($projectId: ID!) { jiraProjectStatuses(projectId: $projectId) { id name category } }",{projectId:en.id});if(t)return;M(e.jiraProjectStatuses),ea(null)}catch(e){if(t)return;ea(e instanceof Error?e.message:String(e)),M([])}finally{t||q(!1)}},0);return()=>{t=!0,window.clearTimeout(r)}},[e,en]);let es=async()=>{if(m){et(!0);try{let e=await (0,J.controlPlaneRequest)(`mutation AddJiraProject($jiraId: ID!) { addJiraProject(jiraId: $jiraId) { ${z} } }`,{jiraId:m});i(e.addJiraProject);let t=e.addJiraProject.find(e=>e.jiraId===m);t&&v(t.id),f(""),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},el=async e=>{et(!0);try{let t=await (0,J.controlPlaneRequest)(`mutation RemoveJiraProject($projectId: ID!) { removeJiraProject(projectId: $projectId) { ${z} } }`,{projectId:e});i(t.removeJiraProject),e===en?.id&&v(t.removeJiraProject[0]?.id??null),F({project:t.removeJiraProject[0]?.id??null,source:t.removeJiraProject[0]?.sources[0]?.id??null,issue:null}),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}},eo=async e=>{if(e.preventDefault(),en){et(!0);try{let e=$?`mutation UpdateJiraSource($input: UpdateJiraSourceInput!) { updateJiraSource(input: $input) { ${z} } }`:`mutation CreateJiraSource($input: CreateJiraSourceInput!) { createJiraSource(input: $input) { ${z} } }`,t=$?{id:$.id,name:b,kind:C,value:R}:{projectId:en.id,name:b,kind:C,value:R},r=await (0,J.controlPlaneRequest)(e,{input:t});i($?r.updateJiraSource:r.createJiraSource),k(""),P(""),T("JQL"),L(null),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},ec=async e=>{et(!0);try{let t=await (0,J.controlPlaneRequest)(`mutation DeleteJiraSource($id: ID!) { deleteJiraSource(id: $id) { ${z} } }`,{id:e});i(t.deleteJiraSource);let r=t.deleteJiraSource.find(e=>e.id===en?.id);F({source:r?.sources[0]?.id??null,issue:null}),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}},ed=async()=>{if(en){et(!0);try{let e={projectId:en.id,ticketAssignmentFilter:H,hideCompletedTickets:G,completedStatusIds:Q},t=await (0,J.controlPlaneRequest)(`mutation UpdateJiraProjectDisplaySettings($input: UpdateJiraProjectDisplaySettingsInput!) { updateJiraProjectDisplaySettings(input: $input) { ${z} } }`,{input:e});i(t.updateJiraProjectDisplaySettings),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}},eu=async()=>{if(en){et(!0);try{let e=await (0,J.controlPlaneRequest)(`mutation UpdateJiraProjectBranchNaming($projectId: ID!, $branchNamingScript: String!) {
2
2
  updateJiraProjectBranchNaming(projectId: $projectId, branchNamingScript: $branchNamingScript) { ${z} }
3
3
  }`,{projectId:en.id,branchNamingScript:Z});i(e.updateJiraProjectBranchNaming),ea(null)}catch(e){ea(e instanceof Error?e.message:String(e))}finally{et(!1)}}};return(0,t.jsx)(S.Dialog,{onOpenChange:e=>{e||v(null),r(e)},open:e,children:(0,t.jsxs)(S.DialogContent,{className:"overflow-x-hidden sm:max-w-4xl",children:[(0,t.jsxs)(S.DialogHeader,{children:[(0,t.jsx)(S.DialogTitle,{children:s("manageTitle")}),(0,t.jsx)(S.DialogDescription,{children:s("manageDescription")})]}),er&&(0,t.jsx)(y.Alert,{variant:"destructive",children:(0,t.jsx)(y.AlertDescription,{children:er})}),(0,t.jsxs)("div",{className:"grid min-w-0 gap-6 md:grid-cols-2",children:[(0,t.jsxs)("section",{className:"min-w-0 space-y-3",children:[(0,t.jsx)("h3",{className:"font-medium",children:s("projects")}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsxs)(A.Select,{onValueChange:f,value:m,children:[(0,t.jsx)(A.SelectTrigger,{"aria-label":s("availableProjects"),className:"w-full",children:(0,t.jsx)(A.SelectValue,{placeholder:s("selectProject")})}),(0,t.jsx)(A.SelectContent,{className:"z-60",children:ei.map(e=>(0,t.jsxs)(A.SelectItem,{value:e.jiraId,children:[e.key," · ",e.name]},e.jiraId))})]}),(0,t.jsxs)(w.Button,{disabled:!m||ee,onClick:()=>void es(),size:"icon",children:[(0,t.jsx)(c.Plus,{}),(0,t.jsx)("span",{className:"sr-only",children:s("addProject")})]})]}),(0,t.jsx)("div",{className:"space-y-2",children:a.map(e=>(0,t.jsxs)(I.Item,{className:`min-w-0 gap-2 p-1 ${e.id===en?.id?"border-primary bg-primary/5":""}`,variant:"outline",children:[(0,t.jsxs)(w.Button,{"aria-pressed":e.id===en?.id,className:"h-auto min-w-0 flex-1 flex-col items-start p-2 text-left whitespace-normal",onClick:()=>{v(e.id),L(null),k(""),P(""),T("JQL")},type:"button",variant:"ghost",children:[(0,t.jsxs)("p",{className:"truncate text-sm font-medium",children:[e.key," · ",e.name]}),(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:s("sourceCount",{count:e.sources.length})})]}),(0,t.jsx)(g.ConfirmationDialog,{actionLabel:s("removeProject"),cancelLabel:l("cancel"),description:l("cannotBeUndone"),onConfirm:()=>el(e.id),title:s("confirmRemoveProject"),trigger:(0,t.jsxs)(w.Button,{disabled:ee,size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(p.Trash2,{}),(0,t.jsx)("span",{className:"sr-only",children:s("removeProject")})]})})]},e.id))})]}),(0,t.jsxs)("section",{className:"min-w-0 space-y-3",children:[(0,t.jsx)("h3",{className:"font-medium",children:s("sourcesFor",{project:en?.key??"—"})}),en?.sources.map(e=>(0,t.jsxs)(I.Item,{className:"min-w-0 items-start gap-2 overflow-hidden",variant:"outline",children:[(0,t.jsxs)("div",{className:"min-w-0",children:[(0,t.jsx)("p",{className:"truncate text-sm font-medium",children:e.name}),(0,t.jsxs)("div",{className:"flex min-w-0 items-center gap-1 text-xs text-muted-foreground",children:[(0,t.jsxs)("span",{className:"shrink-0",children:[e.kind," ·"]}),(0,t.jsx)("span",{className:"min-w-0 overflow-hidden text-ellipsis whitespace-nowrap [direction:rtl] md:[direction:ltr]",children:(0,t.jsx)("bdi",{children:e.value})})]})]}),(0,t.jsxs)("div",{className:"flex shrink-0",children:[(0,t.jsxs)(w.Button,{onClick:()=>{L(e),k(e.name),T(e.kind),P(e.value)},size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(o.Pencil,{}),(0,t.jsx)("span",{className:"sr-only",children:s("editSource")})]}),(0,t.jsx)(g.ConfirmationDialog,{actionLabel:s("deleteSource"),cancelLabel:l("cancel"),description:l("cannotBeUndone"),onConfirm:()=>ec(e.id),title:s("confirmDeleteSource"),trigger:(0,t.jsxs)(w.Button,{disabled:ee,size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(p.Trash2,{}),(0,t.jsx)("span",{className:"sr-only",children:s("deleteSource")})]})})]})]},e.id)),en&&(0,t.jsxs)("form",{className:"min-w-0 space-y-3 rounded-lg border p-3",onSubmit:e=>void eo(e),children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(E.Label,{className:"mb-1 block text-xs font-medium",htmlFor:"source-name",children:s("sourceName")}),(0,t.jsx)(D.Input,{id:"source-name",maxLength:100,onChange:e=>k(e.target.value),required:!0,value:b})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(E.Label,{className:"mb-1 block text-xs font-medium",htmlFor:"source-kind",children:s("sourceType")}),(0,t.jsxs)(A.Select,{onValueChange:e=>T(e),value:C,children:[(0,t.jsx)(A.SelectTrigger,{className:"w-full",id:"source-kind",children:(0,t.jsx)(A.SelectValue,{})}),(0,t.jsxs)(A.SelectContent,{className:"z-60",children:[(0,t.jsx)(A.SelectItem,{value:"JQL",children:"JQL"}),(0,t.jsx)(A.SelectItem,{value:"BOARD",children:s("boardUrl")})]})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(E.Label,{className:"mb-1 block text-xs font-medium",htmlFor:"source-value",children:"JQL"===C?"JQL":s("boardUrl")}),(0,t.jsx)(B.Textarea,{id:"source-value",onChange:e=>P(e.target.value),required:!0,value:R})]}),(0,t.jsxs)("div",{className:"flex justify-end gap-2",children:[$&&(0,t.jsx)(w.Button,{onClick:()=>{L(null),k(""),P("")},type:"button",variant:"ghost",children:s("cancel")}),(0,t.jsx)(w.Button,{disabled:ee,type:"submit",children:$?s("saveSource"):s("addSource")})]})]}),en&&(0,t.jsxs)("section",{className:"min-w-0 space-y-3 rounded-lg border p-3",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h4",{className:"text-sm font-medium",children:s("displaySettings")}),(0,t.jsx)("p",{className:"mt-0.5 text-xs text-muted-foreground",children:s("displaySettingsDescription")})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(E.Label,{className:"mb-1 block text-xs font-medium",htmlFor:"ticket-assignment-filter",children:s("ticketsToShow")}),(0,t.jsxs)(A.Select,{onValueChange:e=>K(e),value:H,children:[(0,t.jsx)(A.SelectTrigger,{className:"w-full",id:"ticket-assignment-filter",children:(0,t.jsx)(A.SelectValue,{})}),(0,t.jsxs)(A.SelectContent,{className:"z-60",children:[(0,t.jsx)(A.SelectItem,{value:"ALL",children:s("allTickets")}),(0,t.jsx)(A.SelectItem,{value:"UNASSIGNED_OR_SELF",children:s("unassignedOrSelfAssigned")}),(0,t.jsx)(A.SelectItem,{value:"SELF_IN_PROGRESS",children:s("selfAssignedInProgress")})]})]})]}),(0,t.jsxs)("div",{className:"flex items-start gap-2 text-sm",children:[(0,t.jsx)(N.Checkbox,{checked:G,className:"mt-0.5",id:"hide-completed-tickets",onCheckedChange:e=>W(!0===e)}),(0,t.jsx)(E.Label,{className:"block leading-normal",htmlFor:"hide-completed-tickets",children:(0,t.jsxs)("span",{children:[(0,t.jsx)("span",{className:"block font-medium",children:s("hideCompletedTickets")}),(0,t.jsx)("span",{className:"block text-xs text-muted-foreground",children:s("hideCompletedTicketsDescription")})]})})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"mb-1 text-xs font-medium",children:s("completedStatuses")}),(0,t.jsx)(O,{disabled:!G||U,label:s("completedStatuses"),onChange:X,placeholder:U?s("loadingStatuses"):s("selectCompletedStatuses"),statuses:_,value:Q})]}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)(w.Button,{disabled:ee,onClick:()=>void ed(),type:"button",children:s("saveDisplaySettings")})})]}),en&&(0,t.jsxs)("section",{className:"min-w-0 space-y-3 rounded-lg border p-3",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h4",{className:"text-sm font-medium",children:s("branchNaming")}),(0,t.jsx)("p",{className:"mt-0.5 text-xs text-muted-foreground",children:s("branchNamingDescription")})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(E.Label,{className:"mb-1 block text-xs font-medium",htmlFor:"jira-branch-naming-script",children:s("branchNamingFunction")}),(0,t.jsx)(B.Textarea,{className:"min-h-48 font-mono text-xs",id:"jira-branch-naming-script",onChange:e=>Y(e.target.value),spellCheck:!1,value:Z}),(0,t.jsx)("p",{className:"mt-1 text-xs text-muted-foreground",children:s("branchNamingFunctionHelp")})]}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)(w.Button,{disabled:ee||!Z.trim(),onClick:()=>void eu(),type:"button",children:s("saveBranchNaming")})})]})]})]}),(0,t.jsx)(S.DialogFooter,{children:(0,t.jsx)(w.Button,{onClick:()=>r(!1),variant:"outline",children:s("done")})})]})})}e.s(["JiraTicketsPage",0,function(){let e=(0,h.useTranslations)("jiraTickets"),i=(0,f.useSearchParams)(),[o,p]=(0,x.useState)([]),[g,N]=(0,x.useState)(null),[S,C]=(0,x.useState)(!0),[D,I]=(0,x.useState)(!1),[E,A]=(0,x.useState)(null),[B,L]=(0,x.useState)(!1),[M,O]=(0,x.useState)("table"),[q,H]=(0,x.useState)(()=>new Set),K=i.get("project"),G=i.get("source"),W=i.get("issue"),Q=o.find(e=>e.id===K)??o[0]??null,X=Q?.sources.find(e=>e.id===G)??Q?.sources[0]??null,Z=(0,x.useRef)(0),Y=g?.source.id===X?.id?g:null,ee=(0,x.useCallback)(async()=>{try{let e=await (0,J.controlPlaneRequest)(`query JiraProjects { jiraProjects { ${z} } }`);p(e.jiraProjects),A(null)}catch(e){A(e instanceof Error?e.message:String(e))}finally{C(!1)}},[]);(0,x.useEffect)(()=>{let e=window.setTimeout(()=>void ee(),0);return()=>window.clearTimeout(e)},[ee]),(0,x.useEffect)(()=>{if(!Q)return;let e={};K!==Q.id&&(e.project=Q.id),X&&G!==X.id&&(e.source=X.id),Object.keys(e).length>0&&F(e)},[K,G,Q,X]);let et=(0,x.useCallback)(async(e,t=!1)=>{let r=++Z.current;I(!0),N(t=>t?.source.id===e?t:null);try{let a=t?`mutation RefreshJiraSource($sourceId: ID!) { refreshJiraSource(sourceId: $sourceId) { ${_} } }`:`query JiraTicketBoard($sourceId: ID!) { jiraTicketBoard(sourceId: $sourceId) { ${_} } }`,n=await (0,J.controlPlaneRequest)(a,{sourceId:e});if(r!==Z.current)return;N(t?n.refreshJiraSource:n.jiraTicketBoard),A(null)}catch(e){if(r!==Z.current)return;A(e instanceof Error?e.message:String(e)),N(null)}finally{r===Z.current&&I(!1)}},[]),er=(0,x.useCallback)(()=>{X&&et(X.id)},[et,X]);(0,x.useEffect)(()=>{if(!X){Z.current+=1;let e=window.setTimeout(()=>{N(null),I(!1)},0);return()=>window.clearTimeout(e)}let e=window.setTimeout(()=>void et(X.id),0);return()=>{window.clearTimeout(e),Z.current+=1}},[et,X]);let ea=(0,x.useMemo)(()=>{let e=new Map;for(let t of Y?.statusOrder??[])e.set(t,[]);for(let t of Y?.tickets??[]){let r=e.get(t.status)??[];r.push(t),e.set(t.status,r)}return[...e.entries()]},[Y]),en=e=>{H(t=>{let r=new Set(t);return r.has(e)?r.delete(e):r.add(e),r})};return(0,t.jsxs)("section",{className:"mx-auto flex w-full max-w-[1600px] flex-col gap-5",children:[(0,t.jsxs)("div",{className:"flex flex-wrap items-start justify-between gap-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h1",{className:"text-2xl font-semibold tracking-tight",children:e("title")}),(0,t.jsx)("p",{className:"mt-1 text-sm text-muted-foreground",children:e("description")})]}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsxs)(w.Button,{onClick:()=>O(e=>"table"===e?"board":"table"),variant:"outline",children:["table"===M?(0,t.jsx)(s,{}):(0,t.jsx)(m,{}),"table"===M?e("showBoardLayout"):e("showTableLayout")]}),(0,t.jsxs)(w.Button,{disabled:!X||D,onClick:()=>X&&void et(X.id,!0),variant:"outline",children:[(0,t.jsx)(d.RefreshCw,{className:D?"animate-spin":void 0}),e("refresh")]}),(0,t.jsxs)(w.Button,{onClick:()=>L(!0),children:[(0,t.jsx)(u.Settings2,{}),e("manage")]})]})]}),E&&(0,t.jsx)(y.Alert,{variant:"destructive",children:(0,t.jsx)(y.AlertDescription,{children:E})}),S?(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,t.jsx)(R.Spinner,{}),e("loading")]}):0===o.length?(0,t.jsxs)(T.Empty,{className:"border py-10",children:[(0,t.jsxs)(T.EmptyHeader,{children:[(0,t.jsx)(T.EmptyMedia,{variant:"icon",children:(0,t.jsx)(l,{})}),(0,t.jsx)(T.EmptyTitle,{children:e("emptyProjects")}),(0,t.jsx)(T.EmptyDescription,{children:e("emptyProjectsDescription")})]}),(0,t.jsxs)(w.Button,{className:"mt-4",onClick:()=>L(!0),children:[(0,t.jsx)(c.Plus,{}),e("addProject")]})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"overflow-x-auto pb-1",children:(0,t.jsx)($.Tabs,{value:Q?.id,onValueChange:e=>{let t=o.find(t=>t.id===e);F({project:e,source:t?.sources[0]?.id??null,issue:null})},children:(0,t.jsx)($.TabsList,{"aria-label":e("projectTabs"),children:o.map(e=>(0,t.jsx)($.TabsTrigger,{value:e.id,children:e.key},e.id))})})}),Q&&Q.sources.length>1?(0,t.jsx)("div",{className:"overflow-x-auto border-b pb-3",children:(0,t.jsx)($.Tabs,{value:X?.id,onValueChange:e=>F({source:e,issue:null}),children:(0,t.jsx)($.TabsList,{"aria-label":e("sourceTabs"),variant:"line",children:Q.sources.map(e=>(0,t.jsx)($.TabsTrigger,{value:e.id,children:e.name},e.id))})})}):Q?.sources.length===0?(0,t.jsxs)(T.Empty,{className:"border py-8",children:[(0,t.jsxs)(T.EmptyHeader,{children:[(0,t.jsx)(T.EmptyTitle,{children:e("emptySources")}),(0,t.jsx)(T.EmptyDescription,{children:e("emptySourcesDescription")})]}),(0,t.jsxs)(w.Button,{className:"mt-4",onClick:()=>L(!0),children:[(0,t.jsx)(c.Plus,{}),e("addSource")]})]}):null,Y?.cache.stale&&(0,t.jsxs)(y.Alert,{className:"border-amber-500/30 bg-amber-500/10 text-amber-800 dark:text-amber-300",children:[(0,t.jsx)(r.AlertTriangle,{}),(0,t.jsx)(y.AlertDescription,{className:"text-current",children:e("staleWarning")})]}),Y?.truncated&&(0,t.jsx)(y.Alert,{className:"bg-muted",children:(0,t.jsx)(y.AlertDescription,{children:e("truncatedWarning")})}),Y?.warnings.map(e=>(0,t.jsx)(y.Alert,{className:"bg-muted",children:(0,t.jsx)(y.AlertDescription,{children:e})},e)),X&&D&&!Y?(0,t.jsxs)("div",{className:"flex items-center gap-2 py-8 text-sm text-muted-foreground",children:[(0,t.jsx)(R.Spinner,{}),e("loadingTickets")]}):Y&&0===Y.tickets.length?(0,t.jsx)(T.Empty,{className:"border py-10",children:(0,t.jsx)(T.EmptyHeader,{children:(0,t.jsx)(T.EmptyDescription,{children:e("emptyTickets")})})}):Y?"table"===M?(0,t.jsx)("div",{className:"space-y-5 pb-4",children:ea.map(([r,i])=>(0,t.jsxs)(k.Card,{className:"gap-0 py-0",children:[(0,t.jsx)(k.CardHeader,{className:q.has(r)?"bg-muted/40 py-3":"border-b bg-muted/40 py-3",children:(0,t.jsxs)("div",{className:"flex items-center justify-between gap-3",children:[(0,t.jsx)(w.Button,{"aria-expanded":!q.has(r),className:"-m-2 h-auto min-w-0 flex-1 justify-start p-2 text-left aria-expanded:bg-transparent aria-expanded:hover:bg-muted dark:aria-expanded:bg-transparent dark:aria-expanded:hover:bg-muted/50",onClick:()=>en(r),type:"button",variant:"ghost",children:(0,t.jsx)("span",{className:"truncate font-medium",children:r})}),(0,t.jsxs)("div",{className:"ml-auto flex items-center justify-end gap-2",children:[(0,t.jsx)(b.Badge,{children:i.length}),(0,t.jsx)(w.Button,{"aria-expanded":!q.has(r),"aria-label":e(q.has(r)?"expandStatus":"collapseStatus",{status:r}),className:"aria-expanded:bg-transparent aria-expanded:hover:bg-muted dark:aria-expanded:bg-transparent dark:aria-expanded:hover:bg-muted/50",onClick:()=>en(r),size:"icon-sm",title:e(q.has(r)?"expandStatus":"collapseStatus",{status:r}),type:"button",variant:"ghost",children:q.has(r)?(0,t.jsx)(n.ChevronRight,{className:"size-5"}):(0,t.jsx)(a.ChevronDown,{className:"size-5"})})]})]})}),!q.has(r)&&(0,t.jsx)(k.CardContent,{className:"px-0",children:(0,t.jsxs)(P.Table,{children:[(0,t.jsx)(P.TableHeader,{children:(0,t.jsxs)(P.TableRow,{className:"hover:bg-transparent",children:[(0,t.jsx)(P.TableHead,{children:e("ticket")}),(0,t.jsx)(P.TableHead,{children:e("issueType")}),(0,t.jsx)(P.TableHead,{children:e("priority")}),(0,t.jsx)(P.TableHead,{children:e("assignee")}),(0,t.jsx)(P.TableHead,{children:e("updated")})]})}),(0,t.jsx)(P.TableBody,{children:i.map(r=>{var a;return(0,t.jsxs)(P.TableRow,{children:[(0,t.jsx)(P.TableCell,{className:"min-w-80 whitespace-normal",children:(0,t.jsxs)(w.Button,{className:"group h-auto w-full flex-col items-start justify-start gap-0 px-1 py-0.5 text-left whitespace-normal",onClick:()=>F({issue:r.key}),type:"button",variant:"ghost",children:[(0,t.jsx)("span",{className:"block text-xs font-semibold text-primary group-hover:underline",children:r.key}),(0,t.jsx)("span",{className:"mt-1 block font-medium",children:r.summary})]})}),(0,t.jsx)(P.TableCell,{children:r.issueType??e("issue")}),(0,t.jsx)(P.TableCell,{children:r.priority?(0,t.jsx)(b.Badge,{className:U(r.priority),children:r.priority}):"—"}),(0,t.jsx)(P.TableCell,{children:(0,t.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,t.jsx)(j.JiraPersonAvatar,{avatarUrl:r.assigneeAvatarUrl}),r.assignee??e("unassigned")]})}),(0,t.jsx)(P.TableCell,{className:"text-muted-foreground",children:(a=r.updatedAt)?new Date(a).toLocaleString():"—"})]},r.key)})})]})})]},r))}):(0,t.jsx)("div",{className:"overflow-x-auto pb-4",children:(0,t.jsx)("div",{className:"flex min-w-max items-start gap-4",children:ea.map(([r,a])=>(0,t.jsxs)("section",{className:"w-[19rem] rounded-xl bg-muted/50 p-3",children:[(0,t.jsxs)("div",{className:"mb-3 flex items-center justify-between gap-2",children:[(0,t.jsx)("h2",{className:"font-medium",children:r}),(0,t.jsx)(b.Badge,{children:a.length})]}),(0,t.jsx)("div",{className:"space-y-2",children:a.map(r=>(0,t.jsxs)(w.Button,{className:"h-auto w-full flex-col items-stretch rounded-lg p-3 text-left whitespace-normal shadow-sm",onClick:()=>F({issue:r.key}),type:"button",variant:"outline",children:[(0,t.jsxs)("div",{className:"flex items-start justify-between gap-2",children:[(0,t.jsx)("span",{className:"text-xs font-semibold text-primary",children:r.key}),r.priority&&(0,t.jsx)(b.Badge,{className:U(r.priority),children:r.priority})]}),(0,t.jsx)("p",{className:"mt-2 line-clamp-3 text-sm font-medium",children:r.summary}),(0,t.jsxs)("div",{className:"mt-3 flex items-center justify-between gap-2 text-xs text-muted-foreground",children:[(0,t.jsx)("span",{children:r.issueType??e("issue")}),(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1",children:[(0,t.jsx)(j.JiraPersonAvatar,{avatarUrl:r.assigneeAvatarUrl,compact:!0}),(0,t.jsx)("span",{className:"truncate",children:r.assignee??e("unassigned")})]})]})]},r.key))})]},r))})}):null]}),(0,t.jsx)(V,{onProjectsChanged:p,open:B,projects:o,selectedProjectId:Q?.id??null,setOpen:L}),(0,t.jsx)(v.JiraTicketDrawer,{issueKey:W,onClose:()=>F({issue:null}),onTicketChange:er})]})}],960024)}]);
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,711241,e=>{"use strict";let t=(0,e.i(456420).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",0,t],711241)},776639,e=>{"use strict";var t=e.i(843476),r=e.i(560964),n=e.i(964053),o=e.i(519455),i=e.i(975157);function a({...e}){return(0,t.jsx)(n.Dialog.Portal,{"data-slot":"dialog-portal",...e})}function l({className:e,...r}){return(0,t.jsx)(n.Dialog.Overlay,{className:(0,i.cn)("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),"data-slot":"dialog-overlay",...r})}e.s(["Dialog",0,function({...e}){return(0,t.jsx)(n.Dialog.Root,{"data-slot":"dialog",...e})},"DialogContent",0,function({className:e,children:c,showCloseButton:s=!0,...u}){return(0,t.jsxs)(a,{children:[(0,t.jsx)(l,{}),(0,t.jsxs)(n.Dialog.Content,{className:(0,i.cn)("fixed top-1/2 left-1/2 z-50 grid max-h-[85dvh] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),"data-slot":"dialog-content",...u,children:[c,s&&(0,t.jsx)(n.Dialog.Close,{asChild:!0,"data-slot":"dialog-close",children:(0,t.jsxs)(o.Button,{className:"absolute top-2 right-2",size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(r.XIcon,{}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})})]})]})},"DialogDescription",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Description,{className:(0,i.cn)("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),"data-slot":"dialog-description",...r})},"DialogFooter",0,function({className:e,showCloseButton:r=!1,children:a,...l}){return(0,t.jsxs)("div",{className:(0,i.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",e),"data-slot":"dialog-footer",...l,children:[a,r&&(0,t.jsx)(n.Dialog.Close,{asChild:!0,children:(0,t.jsx)(o.Button,{variant:"outline",children:"Close"})})]})},"DialogHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{className:(0,i.cn)("flex flex-col gap-2",e),"data-slot":"dialog-header",...r})},"DialogTitle",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Title,{className:(0,i.cn)("font-heading text-base leading-none font-medium",e),"data-slot":"dialog-title",...r})}])},59497,e=>{"use strict";var t=e.i(843476),r=e.i(271645);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function o(...e){return r.useCallback(function(...e){return t=>{let r=!1,o=e.map(e=>{let o=n(e,t);return r||"function"!=typeof o||(r=!0),o});if(r)return()=>{for(let t=0;t<o.length;t++){let r=o[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var i=e.i(30030);function a(e,t,{checkForDefaultPrevented:r=!0}={}){return function(n){if(e?.(n),!1===r||!n||!n.defaultPrevented)return t?.(n)}}"u">typeof window&&window.document&&window.document.createElement;var l=globalThis?.document?r.useLayoutEffect:()=>{};r[" useEffectEvent ".trim().toString()],r[" useInsertionEffect ".trim().toString()];var c=r[" useInsertionEffect ".trim().toString()]||l;Symbol("RADIX:SYNC_STATE");var s=e.i(999682),u=e.i(635804),d=e.i(296626);e.i(174080);var f=Symbol.for("radix.slottable"),p=Symbol.for("react.lazy");function m(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===p&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var h=r[" use ".trim().toString()],y=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,n)=>{var i;let a,l=(i=`Primitive.${n}`,(a=r.forwardRef((e,t)=>{var n;let a,l,{children:c,...s}=e,u=null,d=!1,p=[];m(c)&&"function"==typeof h&&(c=h(c._payload)),r.Children.forEach(c,e=>{var t;if(t=e,r.isValidElement(t)&&"function"==typeof t.type&&"__radixId"in t.type&&t.type.__radixId===f){d=!0;let t="child"in e.props?e.props.child:e.props.children;m(t)&&"function"==typeof h&&(t=h(t._payload)),u=((e,t)=>{if("child"in e.props){let t=e.props.child;return r.isValidElement(t)?r.cloneElement(t,void 0,e.props.children(t.props.children)):null}return r.isValidElement(t)?t:null})(e,t),p.push(u?.props?.children)}else p.push(e)}),u?u=r.cloneElement(u,void 0,p):!d&&1===r.Children.count(c)&&r.isValidElement(c)&&(u=c);let y=u?(n=u,(l=(a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?n.ref:(l=(a=Object.getOwnPropertyDescriptor(n,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?n.props.ref:n.props.ref||n.ref):void 0,v=o(t,y);if(!u){if(c||0===c){let e,t;throw Error(d?(e=i,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=i,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return c}let g=function(e,t){let r={...t};for(let n in t){let o=e[n],i=t[n];/^on[A-Z]/.test(n)?o&&i?r[n]=(...e)=>{let t=i(...e);return o(...e),t}:o&&(r[n]=o):"style"===n?r[n]={...o,...i}:"className"===n&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}(s,u.props??{});return u.type!==r.Fragment&&(g.ref=t?v:y),r.cloneElement(u,g)})).displayName=`${i}.Slot`,a),c=r.forwardRef((e,r)=>{let{asChild:o,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,t.jsx)(o?l:n,{...i,ref:r})});return c.displayName=`Primitive.${n}`,{...e,[n]:c}},{}),v="Checkbox",[g,x]=(0,i.createContextScope)(v),[b,w]=g(v);function k(e){let{__scopeCheckbox:n,checked:o,children:i,defaultChecked:a,disabled:l,form:s,name:u,onCheckedChange:d,required:f,value:p="on",internal_do_not_use_render:m}=e,[h,y]=function({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){let[i,a,l]=function({defaultProp:e,onChange:t}){let[n,o]=r.useState(e),i=r.useRef(n),a=r.useRef(t);return c(()=>{a.current=t},[t]),r.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,o,a]}({defaultProp:t,onChange:n}),s=void 0!==e,u=s?e:i;{let t=r.useRef(void 0!==e);r.useEffect(()=>{let e=t.current;if(e!==s){let t=s?"controlled":"uncontrolled";console.warn(`${o} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=s},[s,o])}return[u,r.useCallback(t=>{if(s){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else a(t)},[s,e,a,l])]}({prop:o,defaultProp:a??!1,onChange:d,caller:v}),[g,x]=r.useState(null),[w,k]=r.useState(null),j=r.useRef(!1),E=!g||!!s||!!g.closest("form"),C={checked:h,disabled:l,setChecked:y,control:g,setControl:x,name:u,form:s,value:p,hasConsumerStoppedPropagationRef:j,required:f,defaultChecked:!I(a)&&a,isFormControl:E,bubbleInput:w,setBubbleInput:k};return(0,t.jsx)(b,{scope:n,...C,children:"function"==typeof m?m(C):i})}var j="CheckboxTrigger",E=r.forwardRef(({__scopeCheckbox:e,onKeyDown:n,onClick:i,...l},c)=>{let{control:s,value:u,disabled:d,checked:f,required:p,setControl:m,setChecked:h,hasConsumerStoppedPropagationRef:v,isFormControl:g,bubbleInput:x}=w(j,e),b=o(c,m),k=r.useRef(f);return r.useEffect(()=>{let e=s?.form;if(e){let t=()=>h(k.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}},[s,h]),(0,t.jsx)(y.button,{type:"button",role:"checkbox","aria-checked":I(f)?"mixed":f,"aria-required":p,"data-state":N(f),"data-disabled":d?"":void 0,disabled:d,value:u,...l,ref:b,onKeyDown:a(n,e=>{"Enter"===e.key&&e.preventDefault()}),onClick:a(i,e=>{h(e=>!!I(e)||!e),x&&g&&(v.current=e.isPropagationStopped(),v.current||e.stopPropagation())})})});E.displayName=j;var C=r.forwardRef((e,r)=>{let{__scopeCheckbox:n,name:o,checked:i,defaultChecked:a,required:l,disabled:c,value:s,onCheckedChange:u,form:d,...f}=e;return(0,t.jsx)(k,{__scopeCheckbox:n,checked:i,defaultChecked:a,disabled:c,required:l,onCheckedChange:u,name:o,form:d,value:s,internal_do_not_use_render:({isFormControl:e})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(E,{...f,ref:r,__scopeCheckbox:n}),e&&(0,t.jsx)(T,{__scopeCheckbox:n})]})})});C.displayName=v;var R="CheckboxIndicator",S=r.forwardRef((e,r)=>{let{__scopeCheckbox:n,forceMount:o,...i}=e,a=w(R,n);return(0,t.jsx)(d.Presence,{present:o||I(a.checked)||!0===a.checked,children:(0,t.jsx)(y.span,{"data-state":N(a.checked),"data-disabled":a.disabled?"":void 0,...i,ref:r,style:{pointerEvents:"none",...e.style}})})});S.displayName=R;var D="CheckboxBubbleInput",T=r.forwardRef(({__scopeCheckbox:e,...n},i)=>{let{control:a,hasConsumerStoppedPropagationRef:l,checked:c,defaultChecked:d,required:f,disabled:p,name:m,value:h,form:v,bubbleInput:g,setBubbleInput:x}=w(D,e),b=o(i,x),k=(0,s.usePrevious)(c),j=(0,u.useSize)(a);r.useEffect(()=>{if(!g)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set,t=!l.current;if(k!==c&&e){let r=new Event("click",{bubbles:t});g.indeterminate=I(c),e.call(g,!I(c)&&c),g.dispatchEvent(r)}},[g,k,c,l]);let E=r.useRef(!I(c)&&c);return(0,t.jsx)(y.input,{type:"checkbox","aria-hidden":!0,defaultChecked:d??E.current,required:f,disabled:p,name:m,value:h,form:v,...n,tabIndex:-1,ref:b,style:{...n.style,...j,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});function I(e){return"indeterminate"===e}function N(e){return I(e)?"indeterminate":e?"checked":"unchecked"}T.displayName=D,e.s(["Checkbox",0,C,"CheckboxIndicator",0,S,"Indicator",0,S,"Root",0,C,"createCheckboxScope",0,x,"unstable_BubbleInput",0,T,"unstable_CheckboxBubbleInput",0,T,"unstable_CheckboxProvider",0,k,"unstable_CheckboxTrigger",0,E,"unstable_Provider",0,k,"unstable_Trigger",0,E],388474);var _=e.i(388474),_=_,P=e.i(975157),$=e.i(593698);e.s(["Checkbox",0,function({className:e,...r}){return(0,t.jsx)(_.Root,{"data-slot":"checkbox",className:(0,P.cn)("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",e),...r,children:(0,t.jsx)(_.Indicator,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none [&>svg]:size-3.5",children:(0,t.jsx)($.CheckIcon,{})})})}],59497)},515281,e=>{"use strict";let t=(0,e.i(456420).default)("pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);e.s(["Pencil",0,t],515281)},630299,e=>{"use strict";let t=(0,e.i(456420).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["default",0,t])},784774,e=>{"use strict";var t=e.i(843476),r=e.i(975157);e.s(["Table",0,function({className:e,containerClassName:n,...o}){return(0,t.jsx)("div",{className:(0,r.cn)("w-full overflow-x-auto",n),children:(0,t.jsx)("table",{className:(0,r.cn)("w-full caption-bottom text-sm",e),...o})})},"TableBody",0,function({className:e,...n}){return(0,t.jsx)("tbody",{className:(0,r.cn)("divide-y",e),...n})},"TableCell",0,function({className:e,...n}){return(0,t.jsx)("td",{className:(0,r.cn)("whitespace-nowrap px-3 py-3 align-middle",e),...n})},"TableFooter",0,function({className:e,...n}){return(0,t.jsx)("tfoot",{className:(0,r.cn)("border-t bg-muted/50 font-medium",e),...n})},"TableHead",0,function({className:e,...n}){return(0,t.jsx)("th",{className:(0,r.cn)("h-10 whitespace-nowrap px-3 text-left align-middle text-xs font-medium text-muted-foreground",e),...n})},"TableHeader",0,function({className:e,...n}){return(0,t.jsx)("thead",{className:(0,r.cn)("border-b",e),...n})},"TableRow",0,function({className:e,...n}){return(0,t.jsx)("tr",{className:(0,r.cn)("transition-colors hover:bg-muted/40",e),...n})}])},689664,e=>{"use strict";var t=e.i(643957);e.s(["Check",()=>t.default])},508734,e=>{"use strict";let t=(0,e.i(456420).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],508734)},986253,e=>{"use strict";let t=(0,e.i(456420).default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);e.s(["default",0,t])},716327,e=>{"use strict";var t=e.i(26495);e.s(["ChevronDown",()=>t.default])},867927,e=>{"use strict";var t=e.i(986253);e.s(["ChevronRight",()=>t.default])},482022,e=>{"use strict";let t=(0,e.i(456420).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["ExternalLink",0,t],482022)},741120,e=>{"use strict";let t=(0,e.i(456420).default)("refresh-cw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);e.s(["RefreshCw",0,t],741120)},82612,e=>{"use strict";var t=e.i(843476),r=e.i(225913),n=e.i(975157);let o=(0,r.cva)("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"}},defaultVariants:{variant:"default"}});e.s(["Empty",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty",className:(0,n.cn)("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance",e),...r})},"EmptyDescription",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-description",className:(0,n.cn)("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",e),...r})},"EmptyHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-header",className:(0,n.cn)("flex max-w-sm flex-col items-center gap-2",e),...r})},"EmptyMedia",0,function({className:e,variant:r="default",...i}){return(0,t.jsx)("div",{"data-slot":"empty-icon","data-variant":r,className:(0,n.cn)(o({variant:r,className:e})),...i})},"EmptyTitle",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-title",className:(0,n.cn)("font-heading text-sm font-medium tracking-tight",e),...r})}])},462777,e=>{"use strict";async function t(e){if(navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.append(t),t.select();let r=document.execCommand("copy");if(t.remove(),!r)throw Error("Copy is not supported by this browser")}e.s(["copyText",0,t,"createClientId",0,function(){try{if(globalThis.crypto?.randomUUID)return globalThis.crypto.randomUUID()}catch{}if(globalThis.crypto?.getRandomValues)try{let e=globalThis.crypto.getRandomValues(new Uint8Array(16));return Array.from(e,e=>e.toString(16).padStart(2,"0")).join("")}catch{}return`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}])},842727,e=>{"use strict";var t=e.i(271645);function r(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r||!r.defaultPrevented)return t?.(r)}}"u">typeof window&&window.document&&window.document.createElement;var n=e.i(75830);function o(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return t.useCallback(function(...e){return t=>{let r=!1,n=e.map(e=>{let n=o(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():o(e[t],null)}}}}(...e),e)}var a=e.i(30030),l=e.i(610772);e.i(174080);var c=Symbol.for("radix.slottable"),s=Symbol.for("react.lazy");function u(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===s&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var d=t[" use ".trim().toString()],f=e.i(843476),p=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{var n;let o,a=(n=`Primitive.${r}`,(o=t.forwardRef((e,r)=>{var o;let a,l,{children:s,...f}=e,p=null,m=!1,h=[];u(s)&&"function"==typeof d&&(s=d(s._payload)),t.Children.forEach(s,e=>{var r;if(r=e,t.isValidElement(r)&&"function"==typeof r.type&&"__radixId"in r.type&&r.type.__radixId===c){m=!0;let r="child"in e.props?e.props.child:e.props.children;u(r)&&"function"==typeof d&&(r=d(r._payload)),p=((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null})(e,r),h.push(p?.props?.children)}else h.push(e)}),p?p=t.cloneElement(p,void 0,h):!m&&1===t.Children.count(s)&&t.isValidElement(s)&&(p=s);let y=p?(o=p,(l=(a=Object.getOwnPropertyDescriptor(o.props,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?o.ref:(l=(a=Object.getOwnPropertyDescriptor(o,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?o.props.ref:o.props.ref||o.ref):void 0,v=i(r,y);if(!p){if(s||0===s){let e,t;throw Error(m?(e=n,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=n,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return s}let g=function(e,t){let r={...t};for(let n in t){let o=e[n],i=t[n];/^on[A-Z]/.test(n)?o&&i?r[n]=(...e)=>{let t=i(...e);return o(...e),t}:o&&(r[n]=o):"style"===n?r[n]={...o,...i}:"className"===n&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}(f,p.props??{});return p.type!==t.Fragment&&(g.ref=r?v:y),t.cloneElement(p,g)})).displayName=`${n}.Slot`,o),l=t.forwardRef((e,t)=>{let{asChild:n,...o}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,f.jsx)(n?a:r,{...o,ref:t})});return l.displayName=`Primitive.${r}`,{...e,[r]:l}},{}),m=e.i(30207),h=globalThis?.document?t.useLayoutEffect:()=>{};t[" useEffectEvent ".trim().toString()],t[" useInsertionEffect ".trim().toString()];var y=t[" useInsertionEffect ".trim().toString()]||h;Symbol("RADIX:SYNC_STATE");var v=e.i(586318),g=!1,x=t[" useSyncExternalStore ".trim().toString()];function b(){return()=>{}}var w="function"==typeof x?function(){return x(b,()=>!0,()=>!1)}:function(){let[e,r]=t.useState(g);return t.useEffect(()=>{g||(g=!0,r(!0))},[]),e},k="rovingFocusGroup.onEntryFocus",j={bubbles:!1,cancelable:!0},E="RovingFocusGroup",[C,R,S]=(0,n.createCollection)(E),[D,T]=(0,a.createContextScope)(E,[S]),[I,N]=D(E),_=t.forwardRef((e,t)=>(0,f.jsx)(C.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,f.jsx)(C.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,f.jsx)(P,{...e,ref:t})})}));_.displayName=E;var P=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,orientation:a,loop:l=!1,dir:c,currentTabStopId:s,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:d,onEntryFocus:h,preventScrollOnEntryFocus:g=!1,...x}=e,b=t.useRef(null),w=i(n,b),C=(0,v.useDirection)(c),[S,D]=function({prop:e,defaultProp:r,onChange:n=()=>{},caller:o}){let[i,a,l]=function({defaultProp:e,onChange:r}){let[n,o]=t.useState(e),i=t.useRef(n),a=t.useRef(r);return y(()=>{a.current=r},[r]),t.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,o,a]}({defaultProp:r,onChange:n}),c=void 0!==e,s=c?e:i;{let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==c){let t=c?"controlled":"uncontrolled";console.warn(`${o} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=c},[c,o])}return[s,t.useCallback(t=>{if(c){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else a(t)},[c,e,a,l])]}({prop:s,defaultProp:u??null,onChange:d,caller:E}),[T,N]=t.useState(!1),_=(0,m.useCallbackRef)(h),P=R(o),$=t.useRef(!1),[A,F]=t.useState(0);return t.useEffect(()=>{let e=b.current;if(e)return e.addEventListener(k,_),()=>e.removeEventListener(k,_)},[_]),(0,f.jsx)(I,{scope:o,orientation:a,dir:C,loop:l,currentTabStopId:S,onItemFocus:t.useCallback(e=>D(e),[D]),onItemShiftTab:t.useCallback(()=>N(!0),[]),onFocusableItemAdd:t.useCallback(()=>F(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>F(e=>e-1),[]),children:(0,f.jsx)(p.div,{tabIndex:T||0===A?-1:0,"data-orientation":a,...x,ref:w,style:{outline:"none",...e.style},onMouseDown:r(e.onMouseDown,()=>{$.current=!0}),onFocus:r(e.onFocus,e=>{let t=!$.current;if(e.target===e.currentTarget&&t&&!T){let t=new CustomEvent(k,j);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=P().filter(e=>e.focusable);z([e.find(e=>e.active),e.find(e=>e.id===S),...e].filter(Boolean).map(e=>e.ref.current),g)}}$.current=!1}),onBlur:r(e.onBlur,()=>N(!1))})})}),$="RovingFocusGroupItem",A=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,focusable:i=!0,active:a=!1,tabStopId:c,children:s,...u}=e,d=(0,l.useId)(),m=c||d,y=N($,o),v=y.currentTabStopId===m,g=R(o),{onFocusableItemAdd:x,onFocusableItemRemove:b,currentTabStopId:k}=y,j=w();return h(()=>{if(j&&i)return x(),()=>b()},[j,i,x,b]),t.useEffect(()=>{if(!j&&i)return x(),()=>b()},[j,i,x,b]),(0,f.jsx)(C.ItemSlot,{scope:o,id:m,focusable:i,active:a,children:(0,f.jsx)(p.span,{tabIndex:v?0:-1,"data-orientation":y.orientation,...u,ref:n,onMouseDown:r(e.onMouseDown,e=>{i?y.onItemFocus(m):e.preventDefault()}),onFocus:r(e.onFocus,()=>y.onItemFocus(m)),onKeyDown:r(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void y.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var n;let o=(n=e.key,"rtl"!==r?n:"ArrowLeft"===n?"ArrowRight":"ArrowRight"===n?"ArrowLeft":n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(o))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(o)))return F[o]}(e,y.orientation,y.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let o=g().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)o.reverse();else if("prev"===t||"next"===t){var r,n;"prev"===t&&o.reverse();let i=o.indexOf(e.currentTarget);o=y.loop?(r=o,n=i+1,r.map((e,t)=>r[(n+t)%r.length])):o.slice(i+1)}setTimeout(()=>z(o))}}),children:"function"==typeof s?s({isCurrentTabStop:v,hasTabStop:null!=k}):s})})});A.displayName=$;var F={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function z(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",0,A,"Root",0,_,"createRovingFocusGroupScope",0,T],842727)},560972,e=>{"use strict";let t=(0,e.i(456420).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);e.s(["default",0,t])},170428,e=>{"use strict";let t=(0,e.i(456420).default)("git-compare-arrows",[["circle",{cx:"5",cy:"6",r:"3",key:"1qnov2"}],["path",{d:"M12 6h5a2 2 0 0 1 2 2v7",key:"1yj91y"}],["path",{d:"m15 9-3-3 3-3",key:"1lwv8l"}],["circle",{cx:"19",cy:"18",r:"3",key:"1qljk2"}],["path",{d:"M12 18H7a2 2 0 0 1-2-2V9",key:"16sdep"}],["path",{d:"m9 15 3 3-3 3",key:"1m3kbl"}]]);e.s(["GitCompareArrows",0,t],170428)}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,711241,e=>{"use strict";let t=(0,e.i(456420).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",0,t],711241)},776639,e=>{"use strict";var t=e.i(843476),r=e.i(560964),n=e.i(964053),o=e.i(519455),i=e.i(975157);function a({...e}){return(0,t.jsx)(n.Dialog.Portal,{"data-slot":"dialog-portal",...e})}function l({className:e,...r}){return(0,t.jsx)(n.Dialog.Overlay,{className:(0,i.cn)("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),"data-slot":"dialog-overlay",...r})}e.s(["Dialog",0,function({...e}){return(0,t.jsx)(n.Dialog.Root,{"data-slot":"dialog",...e})},"DialogContent",0,function({className:e,children:c,showCloseButton:s=!0,...u}){return(0,t.jsxs)(a,{children:[(0,t.jsx)(l,{}),(0,t.jsxs)(n.Dialog.Content,{className:(0,i.cn)("fixed top-1/2 left-1/2 z-50 grid max-h-[85dvh] w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),"data-slot":"dialog-content",...u,children:[c,s&&(0,t.jsx)(n.Dialog.Close,{asChild:!0,"data-slot":"dialog-close",children:(0,t.jsxs)(o.Button,{className:"absolute top-2 right-2",size:"icon-sm",variant:"ghost",children:[(0,t.jsx)(r.XIcon,{}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})})]})]})},"DialogDescription",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Description,{className:(0,i.cn)("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground",e),"data-slot":"dialog-description",...r})},"DialogFooter",0,function({className:e,showCloseButton:r=!1,children:a,...l}){return(0,t.jsxs)("div",{className:(0,i.cn)("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end",e),"data-slot":"dialog-footer",...l,children:[a,r&&(0,t.jsx)(n.Dialog.Close,{asChild:!0,children:(0,t.jsx)(o.Button,{variant:"outline",children:"Close"})})]})},"DialogHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{className:(0,i.cn)("flex flex-col gap-2",e),"data-slot":"dialog-header",...r})},"DialogTitle",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Title,{className:(0,i.cn)("font-heading text-base leading-none font-medium",e),"data-slot":"dialog-title",...r})}])},59497,e=>{"use strict";var t=e.i(843476),r=e.i(271645);function n(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function o(...e){return r.useCallback(function(...e){return t=>{let r=!1,o=e.map(e=>{let o=n(e,t);return r||"function"!=typeof o||(r=!0),o});if(r)return()=>{for(let t=0;t<o.length;t++){let r=o[t];"function"==typeof r?r():n(e[t],null)}}}}(...e),e)}var i=e.i(30030);function a(e,t,{checkForDefaultPrevented:r=!0}={}){return function(n){if(e?.(n),!1===r||!n||!n.defaultPrevented)return t?.(n)}}"u">typeof window&&window.document&&window.document.createElement;var l=globalThis?.document?r.useLayoutEffect:()=>{};r[" useEffectEvent ".trim().toString()],r[" useInsertionEffect ".trim().toString()];var c=r[" useInsertionEffect ".trim().toString()]||l;Symbol("RADIX:SYNC_STATE");var s=e.i(999682),u=e.i(635804),d=e.i(296626);e.i(174080);var f=Symbol.for("radix.slottable"),p=Symbol.for("react.lazy");function m(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===p&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var h=r[" use ".trim().toString()],y=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,n)=>{var i;let a,l=(i=`Primitive.${n}`,(a=r.forwardRef((e,t)=>{var n;let a,l,{children:c,...s}=e,u=null,d=!1,p=[];m(c)&&"function"==typeof h&&(c=h(c._payload)),r.Children.forEach(c,e=>{var t;if(t=e,r.isValidElement(t)&&"function"==typeof t.type&&"__radixId"in t.type&&t.type.__radixId===f){d=!0;let t="child"in e.props?e.props.child:e.props.children;m(t)&&"function"==typeof h&&(t=h(t._payload)),u=((e,t)=>{if("child"in e.props){let t=e.props.child;return r.isValidElement(t)?r.cloneElement(t,void 0,e.props.children(t.props.children)):null}return r.isValidElement(t)?t:null})(e,t),p.push(u?.props?.children)}else p.push(e)}),u?u=r.cloneElement(u,void 0,p):!d&&1===r.Children.count(c)&&r.isValidElement(c)&&(u=c);let y=u?(n=u,(l=(a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?n.ref:(l=(a=Object.getOwnPropertyDescriptor(n,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?n.props.ref:n.props.ref||n.ref):void 0,v=o(t,y);if(!u){if(c||0===c){let e,t;throw Error(d?(e=i,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=i,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return c}let g=function(e,t){let r={...t};for(let n in t){let o=e[n],i=t[n];/^on[A-Z]/.test(n)?o&&i?r[n]=(...e)=>{let t=i(...e);return o(...e),t}:o&&(r[n]=o):"style"===n?r[n]={...o,...i}:"className"===n&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}(s,u.props??{});return u.type!==r.Fragment&&(g.ref=t?v:y),r.cloneElement(u,g)})).displayName=`${i}.Slot`,a),c=r.forwardRef((e,r)=>{let{asChild:o,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,t.jsx)(o?l:n,{...i,ref:r})});return c.displayName=`Primitive.${n}`,{...e,[n]:c}},{}),v="Checkbox",[g,x]=(0,i.createContextScope)(v),[b,w]=g(v);function k(e){let{__scopeCheckbox:n,checked:o,children:i,defaultChecked:a,disabled:l,form:s,name:u,onCheckedChange:d,required:f,value:p="on",internal_do_not_use_render:m}=e,[h,y]=function({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){let[i,a,l]=function({defaultProp:e,onChange:t}){let[n,o]=r.useState(e),i=r.useRef(n),a=r.useRef(t);return c(()=>{a.current=t},[t]),r.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,o,a]}({defaultProp:t,onChange:n}),s=void 0!==e,u=s?e:i;{let t=r.useRef(void 0!==e);r.useEffect(()=>{let e=t.current;if(e!==s){let t=s?"controlled":"uncontrolled";console.warn(`${o} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=s},[s,o])}return[u,r.useCallback(t=>{if(s){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else a(t)},[s,e,a,l])]}({prop:o,defaultProp:a??!1,onChange:d,caller:v}),[g,x]=r.useState(null),[w,k]=r.useState(null),j=r.useRef(!1),E=!g||!!s||!!g.closest("form"),C={checked:h,disabled:l,setChecked:y,control:g,setControl:x,name:u,form:s,value:p,hasConsumerStoppedPropagationRef:j,required:f,defaultChecked:!I(a)&&a,isFormControl:E,bubbleInput:w,setBubbleInput:k};return(0,t.jsx)(b,{scope:n,...C,children:"function"==typeof m?m(C):i})}var j="CheckboxTrigger",E=r.forwardRef(({__scopeCheckbox:e,onKeyDown:n,onClick:i,...l},c)=>{let{control:s,value:u,disabled:d,checked:f,required:p,setControl:m,setChecked:h,hasConsumerStoppedPropagationRef:v,isFormControl:g,bubbleInput:x}=w(j,e),b=o(c,m),k=r.useRef(f);return r.useEffect(()=>{let e=s?.form;if(e){let t=()=>h(k.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}},[s,h]),(0,t.jsx)(y.button,{type:"button",role:"checkbox","aria-checked":I(f)?"mixed":f,"aria-required":p,"data-state":N(f),"data-disabled":d?"":void 0,disabled:d,value:u,...l,ref:b,onKeyDown:a(n,e=>{"Enter"===e.key&&e.preventDefault()}),onClick:a(i,e=>{h(e=>!!I(e)||!e),x&&g&&(v.current=e.isPropagationStopped(),v.current||e.stopPropagation())})})});E.displayName=j;var C=r.forwardRef((e,r)=>{let{__scopeCheckbox:n,name:o,checked:i,defaultChecked:a,required:l,disabled:c,value:s,onCheckedChange:u,form:d,...f}=e;return(0,t.jsx)(k,{__scopeCheckbox:n,checked:i,defaultChecked:a,disabled:c,required:l,onCheckedChange:u,name:o,form:d,value:s,internal_do_not_use_render:({isFormControl:e})=>(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(E,{...f,ref:r,__scopeCheckbox:n}),e&&(0,t.jsx)(T,{__scopeCheckbox:n})]})})});C.displayName=v;var R="CheckboxIndicator",S=r.forwardRef((e,r)=>{let{__scopeCheckbox:n,forceMount:o,...i}=e,a=w(R,n);return(0,t.jsx)(d.Presence,{present:o||I(a.checked)||!0===a.checked,children:(0,t.jsx)(y.span,{"data-state":N(a.checked),"data-disabled":a.disabled?"":void 0,...i,ref:r,style:{pointerEvents:"none",...e.style}})})});S.displayName=R;var D="CheckboxBubbleInput",T=r.forwardRef(({__scopeCheckbox:e,...n},i)=>{let{control:a,hasConsumerStoppedPropagationRef:l,checked:c,defaultChecked:d,required:f,disabled:p,name:m,value:h,form:v,bubbleInput:g,setBubbleInput:x}=w(D,e),b=o(i,x),k=(0,s.usePrevious)(c),j=(0,u.useSize)(a);r.useEffect(()=>{if(!g)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set,t=!l.current;if(k!==c&&e){let r=new Event("click",{bubbles:t});g.indeterminate=I(c),e.call(g,!I(c)&&c),g.dispatchEvent(r)}},[g,k,c,l]);let E=r.useRef(!I(c)&&c);return(0,t.jsx)(y.input,{type:"checkbox","aria-hidden":!0,defaultChecked:d??E.current,required:f,disabled:p,name:m,value:h,form:v,...n,tabIndex:-1,ref:b,style:{...n.style,...j,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});function I(e){return"indeterminate"===e}function N(e){return I(e)?"indeterminate":e?"checked":"unchecked"}T.displayName=D,e.s(["Checkbox",0,C,"CheckboxIndicator",0,S,"Indicator",0,S,"Root",0,C,"createCheckboxScope",0,x,"unstable_BubbleInput",0,T,"unstable_CheckboxBubbleInput",0,T,"unstable_CheckboxProvider",0,k,"unstable_CheckboxTrigger",0,E,"unstable_Provider",0,k,"unstable_Trigger",0,E],388474);var _=e.i(388474),_=_,P=e.i(975157),$=e.i(593698);e.s(["Checkbox",0,function({className:e,...r}){return(0,t.jsx)(_.Root,{"data-slot":"checkbox",className:(0,P.cn)("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",e),...r,children:(0,t.jsx)(_.Indicator,{"data-slot":"checkbox-indicator",className:"grid place-content-center text-current transition-none [&>svg]:size-3.5",children:(0,t.jsx)($.CheckIcon,{})})})}],59497)},515281,e=>{"use strict";let t=(0,e.i(456420).default)("pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);e.s(["Pencil",0,t],515281)},508734,e=>{"use strict";let t=(0,e.i(456420).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],508734)},784774,e=>{"use strict";var t=e.i(843476),r=e.i(975157);e.s(["Table",0,function({className:e,containerClassName:n,...o}){return(0,t.jsx)("div",{className:(0,r.cn)("w-full overflow-x-auto",n),children:(0,t.jsx)("table",{className:(0,r.cn)("w-full caption-bottom text-sm",e),...o})})},"TableBody",0,function({className:e,...n}){return(0,t.jsx)("tbody",{className:(0,r.cn)("divide-y",e),...n})},"TableCell",0,function({className:e,...n}){return(0,t.jsx)("td",{className:(0,r.cn)("whitespace-nowrap px-3 py-3 align-middle",e),...n})},"TableFooter",0,function({className:e,...n}){return(0,t.jsx)("tfoot",{className:(0,r.cn)("border-t bg-muted/50 font-medium",e),...n})},"TableHead",0,function({className:e,...n}){return(0,t.jsx)("th",{className:(0,r.cn)("h-10 whitespace-nowrap px-3 text-left align-middle text-xs font-medium text-muted-foreground",e),...n})},"TableHeader",0,function({className:e,...n}){return(0,t.jsx)("thead",{className:(0,r.cn)("border-b",e),...n})},"TableRow",0,function({className:e,...n}){return(0,t.jsx)("tr",{className:(0,r.cn)("transition-colors hover:bg-muted/40",e),...n})}])},689664,e=>{"use strict";var t=e.i(643957);e.s(["Check",()=>t.default])},630299,e=>{"use strict";let t=(0,e.i(456420).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["default",0,t])},986253,e=>{"use strict";let t=(0,e.i(456420).default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);e.s(["default",0,t])},716327,e=>{"use strict";var t=e.i(26495);e.s(["ChevronDown",()=>t.default])},867927,e=>{"use strict";var t=e.i(986253);e.s(["ChevronRight",()=>t.default])},482022,e=>{"use strict";let t=(0,e.i(456420).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["ExternalLink",0,t],482022)},741120,e=>{"use strict";let t=(0,e.i(456420).default)("refresh-cw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);e.s(["RefreshCw",0,t],741120)},82612,e=>{"use strict";var t=e.i(843476),r=e.i(225913),n=e.i(975157);let o=(0,r.cva)("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"}},defaultVariants:{variant:"default"}});e.s(["Empty",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty",className:(0,n.cn)("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance",e),...r})},"EmptyDescription",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-description",className:(0,n.cn)("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",e),...r})},"EmptyHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-header",className:(0,n.cn)("flex max-w-sm flex-col items-center gap-2",e),...r})},"EmptyMedia",0,function({className:e,variant:r="default",...i}){return(0,t.jsx)("div",{"data-slot":"empty-icon","data-variant":r,className:(0,n.cn)(o({variant:r,className:e})),...i})},"EmptyTitle",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-title",className:(0,n.cn)("font-heading text-sm font-medium tracking-tight",e),...r})}])},462777,e=>{"use strict";async function t(e){if(navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.append(t),t.select();let r=document.execCommand("copy");if(t.remove(),!r)throw Error("Copy is not supported by this browser")}e.s(["copyText",0,t,"createClientId",0,function(){try{if(globalThis.crypto?.randomUUID)return globalThis.crypto.randomUUID()}catch{}if(globalThis.crypto?.getRandomValues)try{let e=globalThis.crypto.getRandomValues(new Uint8Array(16));return Array.from(e,e=>e.toString(16).padStart(2,"0")).join("")}catch{}return`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}])},842727,e=>{"use strict";var t=e.i(271645);function r(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r||!r.defaultPrevented)return t?.(r)}}"u">typeof window&&window.document&&window.document.createElement;var n=e.i(75830);function o(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function i(...e){return t.useCallback(function(...e){return t=>{let r=!1,n=e.map(e=>{let n=o(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():o(e[t],null)}}}}(...e),e)}var a=e.i(30030),l=e.i(610772);e.i(174080);var c=Symbol.for("radix.slottable"),s=Symbol.for("react.lazy");function u(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===s&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var d=t[" use ".trim().toString()],f=e.i(843476),p=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{var n;let o,a=(n=`Primitive.${r}`,(o=t.forwardRef((e,r)=>{var o;let a,l,{children:s,...f}=e,p=null,m=!1,h=[];u(s)&&"function"==typeof d&&(s=d(s._payload)),t.Children.forEach(s,e=>{var r;if(r=e,t.isValidElement(r)&&"function"==typeof r.type&&"__radixId"in r.type&&r.type.__radixId===c){m=!0;let r="child"in e.props?e.props.child:e.props.children;u(r)&&"function"==typeof d&&(r=d(r._payload)),p=((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null})(e,r),h.push(p?.props?.children)}else h.push(e)}),p?p=t.cloneElement(p,void 0,h):!m&&1===t.Children.count(s)&&t.isValidElement(s)&&(p=s);let y=p?(o=p,(l=(a=Object.getOwnPropertyDescriptor(o.props,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?o.ref:(l=(a=Object.getOwnPropertyDescriptor(o,"ref")?.get)&&"isReactWarning"in a&&a.isReactWarning)?o.props.ref:o.props.ref||o.ref):void 0,v=i(r,y);if(!p){if(s||0===s){let e,t;throw Error(m?(e=n,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=n,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return s}let g=function(e,t){let r={...t};for(let n in t){let o=e[n],i=t[n];/^on[A-Z]/.test(n)?o&&i?r[n]=(...e)=>{let t=i(...e);return o(...e),t}:o&&(r[n]=o):"style"===n?r[n]={...o,...i}:"className"===n&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}(f,p.props??{});return p.type!==t.Fragment&&(g.ref=r?v:y),t.cloneElement(p,g)})).displayName=`${n}.Slot`,o),l=t.forwardRef((e,t)=>{let{asChild:n,...o}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,f.jsx)(n?a:r,{...o,ref:t})});return l.displayName=`Primitive.${r}`,{...e,[r]:l}},{}),m=e.i(30207),h=globalThis?.document?t.useLayoutEffect:()=>{};t[" useEffectEvent ".trim().toString()],t[" useInsertionEffect ".trim().toString()];var y=t[" useInsertionEffect ".trim().toString()]||h;Symbol("RADIX:SYNC_STATE");var v=e.i(586318),g=!1,x=t[" useSyncExternalStore ".trim().toString()];function b(){return()=>{}}var w="function"==typeof x?function(){return x(b,()=>!0,()=>!1)}:function(){let[e,r]=t.useState(g);return t.useEffect(()=>{g||(g=!0,r(!0))},[]),e},k="rovingFocusGroup.onEntryFocus",j={bubbles:!1,cancelable:!0},E="RovingFocusGroup",[C,R,S]=(0,n.createCollection)(E),[D,T]=(0,a.createContextScope)(E,[S]),[I,N]=D(E),_=t.forwardRef((e,t)=>(0,f.jsx)(C.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,f.jsx)(C.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,f.jsx)(P,{...e,ref:t})})}));_.displayName=E;var P=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,orientation:a,loop:l=!1,dir:c,currentTabStopId:s,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:d,onEntryFocus:h,preventScrollOnEntryFocus:g=!1,...x}=e,b=t.useRef(null),w=i(n,b),C=(0,v.useDirection)(c),[S,D]=function({prop:e,defaultProp:r,onChange:n=()=>{},caller:o}){let[i,a,l]=function({defaultProp:e,onChange:r}){let[n,o]=t.useState(e),i=t.useRef(n),a=t.useRef(r);return y(()=>{a.current=r},[r]),t.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,o,a]}({defaultProp:r,onChange:n}),c=void 0!==e,s=c?e:i;{let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==c){let t=c?"controlled":"uncontrolled";console.warn(`${o} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=c},[c,o])}return[s,t.useCallback(t=>{if(c){let r="function"==typeof t?t(e):t;r!==e&&l.current?.(r)}else a(t)},[c,e,a,l])]}({prop:s,defaultProp:u??null,onChange:d,caller:E}),[T,N]=t.useState(!1),_=(0,m.useCallbackRef)(h),P=R(o),$=t.useRef(!1),[A,F]=t.useState(0);return t.useEffect(()=>{let e=b.current;if(e)return e.addEventListener(k,_),()=>e.removeEventListener(k,_)},[_]),(0,f.jsx)(I,{scope:o,orientation:a,dir:C,loop:l,currentTabStopId:S,onItemFocus:t.useCallback(e=>D(e),[D]),onItemShiftTab:t.useCallback(()=>N(!0),[]),onFocusableItemAdd:t.useCallback(()=>F(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>F(e=>e-1),[]),children:(0,f.jsx)(p.div,{tabIndex:T||0===A?-1:0,"data-orientation":a,...x,ref:w,style:{outline:"none",...e.style},onMouseDown:r(e.onMouseDown,()=>{$.current=!0}),onFocus:r(e.onFocus,e=>{let t=!$.current;if(e.target===e.currentTarget&&t&&!T){let t=new CustomEvent(k,j);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=P().filter(e=>e.focusable);z([e.find(e=>e.active),e.find(e=>e.id===S),...e].filter(Boolean).map(e=>e.ref.current),g)}}$.current=!1}),onBlur:r(e.onBlur,()=>N(!1))})})}),$="RovingFocusGroupItem",A=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,focusable:i=!0,active:a=!1,tabStopId:c,children:s,...u}=e,d=(0,l.useId)(),m=c||d,y=N($,o),v=y.currentTabStopId===m,g=R(o),{onFocusableItemAdd:x,onFocusableItemRemove:b,currentTabStopId:k}=y,j=w();return h(()=>{if(j&&i)return x(),()=>b()},[j,i,x,b]),t.useEffect(()=>{if(!j&&i)return x(),()=>b()},[j,i,x,b]),(0,f.jsx)(C.ItemSlot,{scope:o,id:m,focusable:i,active:a,children:(0,f.jsx)(p.span,{tabIndex:v?0:-1,"data-orientation":y.orientation,...u,ref:n,onMouseDown:r(e.onMouseDown,e=>{i?y.onItemFocus(m):e.preventDefault()}),onFocus:r(e.onFocus,()=>y.onItemFocus(m)),onKeyDown:r(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void y.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var n;let o=(n=e.key,"rtl"!==r?n:"ArrowLeft"===n?"ArrowRight":"ArrowRight"===n?"ArrowLeft":n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(o))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(o)))return F[o]}(e,y.orientation,y.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let o=g().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)o.reverse();else if("prev"===t||"next"===t){var r,n;"prev"===t&&o.reverse();let i=o.indexOf(e.currentTarget);o=y.loop?(r=o,n=i+1,r.map((e,t)=>r[(n+t)%r.length])):o.slice(i+1)}setTimeout(()=>z(o))}}),children:"function"==typeof s?s({isCurrentTabStop:v,hasTabStop:null!=k}):s})})});A.displayName=$;var F={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function z(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",0,A,"Root",0,_,"createRovingFocusGroupScope",0,T],842727)},560972,e=>{"use strict";let t=(0,e.i(456420).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);e.s(["default",0,t])},170428,e=>{"use strict";let t=(0,e.i(456420).default)("git-compare-arrows",[["circle",{cx:"5",cy:"6",r:"3",key:"1qnov2"}],["path",{d:"M12 6h5a2 2 0 0 1 2 2v7",key:"1yj91y"}],["path",{d:"m15 9-3-3 3-3",key:"1lwv8l"}],["circle",{cx:"19",cy:"18",r:"3",key:"1qljk2"}],["path",{d:"M12 18H7a2 2 0 0 1-2-2V9",key:"16sdep"}],["path",{d:"m9 15 3 3-3 3",key:"1m3kbl"}]]);e.s(["GitCompareArrows",0,t],170428)}]);
@@ -0,0 +1,33 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,395925,e=>{"use strict";let t=(0,e.i(456420).default)("rotate-ccw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);e.s(["RotateCcw",0,t],395925)},482022,e=>{"use strict";let t=(0,e.i(456420).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["ExternalLink",0,t],482022)},986253,e=>{"use strict";let t=(0,e.i(456420).default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);e.s(["default",0,t])},716327,e=>{"use strict";var t=e.i(26495);e.s(["ChevronDown",()=>t.default])},508734,e=>{"use strict";let t=(0,e.i(456420).default)("copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);e.s(["Copy",0,t],508734)},784774,e=>{"use strict";var t=e.i(843476),r=e.i(975157);e.s(["Table",0,function({className:e,containerClassName:n,...i}){return(0,t.jsx)("div",{className:(0,r.cn)("w-full overflow-x-auto",n),children:(0,t.jsx)("table",{className:(0,r.cn)("w-full caption-bottom text-sm",e),...i})})},"TableBody",0,function({className:e,...n}){return(0,t.jsx)("tbody",{className:(0,r.cn)("divide-y",e),...n})},"TableCell",0,function({className:e,...n}){return(0,t.jsx)("td",{className:(0,r.cn)("whitespace-nowrap px-3 py-3 align-middle",e),...n})},"TableFooter",0,function({className:e,...n}){return(0,t.jsx)("tfoot",{className:(0,r.cn)("border-t bg-muted/50 font-medium",e),...n})},"TableHead",0,function({className:e,...n}){return(0,t.jsx)("th",{className:(0,r.cn)("h-10 whitespace-nowrap px-3 text-left align-middle text-xs font-medium text-muted-foreground",e),...n})},"TableHeader",0,function({className:e,...n}){return(0,t.jsx)("thead",{className:(0,r.cn)("border-b",e),...n})},"TableRow",0,function({className:e,...n}){return(0,t.jsx)("tr",{className:(0,r.cn)("transition-colors hover:bg-muted/40",e),...n})}])},689664,e=>{"use strict";var t=e.i(643957);e.s(["Check",()=>t.default])},630299,e=>{"use strict";let t=(0,e.i(456420).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["default",0,t])},741120,e=>{"use strict";let t=(0,e.i(456420).default)("refresh-cw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);e.s(["RefreshCw",0,t],741120)},82612,e=>{"use strict";var t=e.i(843476),r=e.i(225913),n=e.i(975157);let i=(0,r.cva)("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",icon:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-muted text-foreground [&_svg:not([class*='size-'])]:size-4"}},defaultVariants:{variant:"default"}});e.s(["Empty",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty",className:(0,n.cn)("flex w-full min-w-0 flex-1 flex-col items-center justify-center gap-4 rounded-xl border-dashed p-6 text-center text-balance",e),...r})},"EmptyDescription",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-description",className:(0,n.cn)("text-sm/relaxed text-muted-foreground [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",e),...r})},"EmptyHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-header",className:(0,n.cn)("flex max-w-sm flex-col items-center gap-2",e),...r})},"EmptyMedia",0,function({className:e,variant:r="default",...s}){return(0,t.jsx)("div",{"data-slot":"empty-icon","data-variant":r,className:(0,n.cn)(i({variant:r,className:e})),...s})},"EmptyTitle",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"empty-title",className:(0,n.cn)("font-heading text-sm font-medium tracking-tight",e),...r})}])},462777,e=>{"use strict";async function t(e){if(navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}let t=document.createElement("textarea");t.value=e,t.style.position="fixed",t.style.opacity="0",document.body.append(t),t.select();let r=document.execCommand("copy");if(t.remove(),!r)throw Error("Copy is not supported by this browser")}e.s(["copyText",0,t,"createClientId",0,function(){try{if(globalThis.crypto?.randomUUID)return globalThis.crypto.randomUUID()}catch{}if(globalThis.crypto?.getRandomValues)try{let e=globalThis.crypto.getRandomValues(new Uint8Array(16));return Array.from(e,e=>e.toString(16).padStart(2,"0")).join("")}catch{}return`${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`}])},842727,e=>{"use strict";var t=e.i(271645);function r(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r||!r.defaultPrevented)return t?.(r)}}"u">typeof window&&window.document&&window.document.createElement;var n=e.i(75830);function i(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function s(...e){return t.useCallback(function(...e){return t=>{let r=!1,n=e.map(e=>{let n=i(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():i(e[t],null)}}}}(...e),e)}var l=e.i(30030),a=e.i(610772);e.i(174080);var o=Symbol.for("radix.slottable"),c=Symbol.for("react.lazy");function u(e){var t;return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===c&&"_payload"in e&&"object"==typeof(t=e._payload)&&null!==t&&"then"in t}var d=t[" use ".trim().toString()],m=e.i(843476),p=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,r)=>{var n;let i,l=(n=`Primitive.${r}`,(i=t.forwardRef((e,r)=>{var i;let l,a,{children:c,...m}=e,p=null,h=!1,f=[];u(c)&&"function"==typeof d&&(c=d(c._payload)),t.Children.forEach(c,e=>{var r;if(r=e,t.isValidElement(r)&&"function"==typeof r.type&&"__radixId"in r.type&&r.type.__radixId===o){h=!0;let r="child"in e.props?e.props.child:e.props.children;u(r)&&"function"==typeof d&&(r=d(r._payload)),p=((e,r)=>{if("child"in e.props){let r=e.props.child;return t.isValidElement(r)?t.cloneElement(r,void 0,e.props.children(r.props.children)):null}return t.isValidElement(r)?r:null})(e,r),f.push(p?.props?.children)}else f.push(e)}),p?p=t.cloneElement(p,void 0,f):!h&&1===t.Children.count(c)&&t.isValidElement(c)&&(p=c);let x=p?(i=p,(a=(l=Object.getOwnPropertyDescriptor(i.props,"ref")?.get)&&"isReactWarning"in l&&l.isReactWarning)?i.ref:(a=(l=Object.getOwnPropertyDescriptor(i,"ref")?.get)&&"isReactWarning"in l&&l.isReactWarning)?i.props.ref:i.props.ref||i.ref):void 0,g=s(r,x);if(!p){if(c||0===c){let e,t;throw Error(h?(e=n,`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`):(t=n,`${t} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`))}return c}let y=function(e,t){let r={...t};for(let n in t){let i=e[n],s=t[n];/^on[A-Z]/.test(n)?i&&s?r[n]=(...e)=>{let t=s(...e);return i(...e),t}:i&&(r[n]=i):"style"===n?r[n]={...i,...s}:"className"===n&&(r[n]=[i,s].filter(Boolean).join(" "))}return{...e,...r}}(m,p.props??{});return p.type!==t.Fragment&&(y.ref=r?g:x),t.cloneElement(p,y)})).displayName=`${n}.Slot`,i),a=t.forwardRef((e,t)=>{let{asChild:n,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,m.jsx)(n?l:r,{...i,ref:t})});return a.displayName=`Primitive.${r}`,{...e,[r]:a}},{}),h=e.i(30207),f=globalThis?.document?t.useLayoutEffect:()=>{};t[" useEffectEvent ".trim().toString()],t[" useInsertionEffect ".trim().toString()];var x=t[" useInsertionEffect ".trim().toString()]||f;Symbol("RADIX:SYNC_STATE");var g=e.i(586318),y=!1,b=t[" useSyncExternalStore ".trim().toString()];function j(){return()=>{}}var v="function"==typeof b?function(){return b(j,()=>!0,()=>!1)}:function(){let[e,r]=t.useState(y);return t.useEffect(()=>{y||(y=!0,r(!0))},[]),e},w="rovingFocusGroup.onEntryFocus",k={bubbles:!1,cancelable:!0},S="RovingFocusGroup",[T,R,C]=(0,n.createCollection)(S),[N,E]=(0,l.createContextScope)(S,[C]),[I,D]=N(S),M=t.forwardRef((e,t)=>(0,m.jsx)(T.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(T.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,m.jsx)(A,{...e,ref:t})})}));M.displayName=S;var A=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:i,orientation:l,loop:a=!1,dir:o,currentTabStopId:c,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:d,onEntryFocus:f,preventScrollOnEntryFocus:y=!1,...b}=e,j=t.useRef(null),v=s(n,j),T=(0,g.useDirection)(o),[C,N]=function({prop:e,defaultProp:r,onChange:n=()=>{},caller:i}){let[s,l,a]=function({defaultProp:e,onChange:r}){let[n,i]=t.useState(e),s=t.useRef(n),l=t.useRef(r);return x(()=>{l.current=r},[r]),t.useEffect(()=>{s.current!==n&&(l.current?.(n),s.current=n)},[n,s]),[n,i,l]}({defaultProp:r,onChange:n}),o=void 0!==e,c=o?e:s;{let r=t.useRef(void 0!==e);t.useEffect(()=>{let e=r.current;if(e!==o){let t=o?"controlled":"uncontrolled";console.warn(`${i} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}r.current=o},[o,i])}return[c,t.useCallback(t=>{if(o){let r="function"==typeof t?t(e):t;r!==e&&a.current?.(r)}else l(t)},[o,e,l,a])]}({prop:c,defaultProp:u??null,onChange:d,caller:S}),[E,D]=t.useState(!1),M=(0,h.useCallbackRef)(f),A=R(i),$=t.useRef(!1),[P,U]=t.useState(0);return t.useEffect(()=>{let e=j.current;if(e)return e.addEventListener(w,M),()=>e.removeEventListener(w,M)},[M]),(0,m.jsx)(I,{scope:i,orientation:l,dir:T,loop:a,currentTabStopId:C,onItemFocus:t.useCallback(e=>N(e),[N]),onItemShiftTab:t.useCallback(()=>D(!0),[]),onFocusableItemAdd:t.useCallback(()=>U(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>U(e=>e-1),[]),children:(0,m.jsx)(p.div,{tabIndex:E||0===P?-1:0,"data-orientation":l,...b,ref:v,style:{outline:"none",...e.style},onMouseDown:r(e.onMouseDown,()=>{$.current=!0}),onFocus:r(e.onFocus,e=>{let t=!$.current;if(e.target===e.currentTarget&&t&&!E){let t=new CustomEvent(w,k);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=A().filter(e=>e.focusable);q([e.find(e=>e.active),e.find(e=>e.id===C),...e].filter(Boolean).map(e=>e.ref.current),y)}}$.current=!1}),onBlur:r(e.onBlur,()=>D(!1))})})}),$="RovingFocusGroupItem",P=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:i,focusable:s=!0,active:l=!1,tabStopId:o,children:c,...u}=e,d=(0,a.useId)(),h=o||d,x=D($,i),g=x.currentTabStopId===h,y=R(i),{onFocusableItemAdd:b,onFocusableItemRemove:j,currentTabStopId:w}=x,k=v();return f(()=>{if(k&&s)return b(),()=>j()},[k,s,b,j]),t.useEffect(()=>{if(!k&&s)return b(),()=>j()},[k,s,b,j]),(0,m.jsx)(T.ItemSlot,{scope:i,id:h,focusable:s,active:l,children:(0,m.jsx)(p.span,{tabIndex:g?0:-1,"data-orientation":x.orientation,...u,ref:n,onMouseDown:r(e.onMouseDown,e=>{s?x.onItemFocus(h):e.preventDefault()}),onFocus:r(e.onFocus,()=>x.onItemFocus(h)),onKeyDown:r(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void x.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var n;let i=(n=e.key,"rtl"!==r?n:"ArrowLeft"===n?"ArrowRight":"ArrowRight"===n?"ArrowLeft":n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(i))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(i)))return U[i]}(e,x.orientation,x.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let i=y().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)i.reverse();else if("prev"===t||"next"===t){var r,n;"prev"===t&&i.reverse();let s=i.indexOf(e.currentTarget);i=x.loop?(r=i,n=s+1,r.map((e,t)=>r[(n+t)%r.length])):i.slice(s+1)}setTimeout(()=>q(i))}}),children:"function"==typeof c?c({isCurrentTabStop:g,hasTabStop:null!=w}):c})})});P.displayName=$;var U={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function q(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",0,P,"Root",0,M,"createRovingFocusGroupScope",0,E],842727)},560972,e=>{"use strict";let t=(0,e.i(456420).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]);e.s(["default",0,t])},356505,853138,e=>{"use strict";var t=e.i(843476),r=e.i(456420);let n=(0,r.default)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);e.s(["AlertTriangle",0,n],853138);var i=e.i(482022),s=e.i(269846);let l=(0,r.default)("maximize-2",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]]);var a=e.i(948148),o=e.i(271645),c=e.i(653090),u=e.i(278015),d=e.i(762279),m=e.i(456743),p=e.i(929592),h=e.i(487486),f=e.i(519455),x=e.i(515288),g=e.i(906197),y=e.i(980376),b=e.i(987968),j=e.i(520133),v=e.i(637611),w=e.i(741725),k=e.i(467511);let S={highest:"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300",high:"border-orange-500/30 bg-orange-500/10 text-orange-700 dark:text-orange-300",medium:"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300",low:"border-blue-500/30 bg-blue-500/10 text-blue-700 dark:text-blue-300",lowest:"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"};function T(e){return e?new Date(e).toLocaleString():"—"}function R({ticket:e}){let r=(0,a.useTranslations)("jiraTickets"),n=[[r("assignee"),(0,t.jsx)(c.JiraUser,{avatarUrl:e.assigneeAvatarUrl,name:e.assignee??r("unassigned")},"assignee")],[r("reporter"),e.reporter?(0,t.jsx)(c.JiraUser,{avatarUrl:e.reporter.avatarUrl,name:e.reporter.displayName},"reporter"):"—"],[r("created"),T(e.createdAt)],[r("updated"),T(e.updatedAt)],[r("due"),T(e.dueAt)],[r("resolved"),T(e.resolvedAt)]];return(0,t.jsx)("dl",{className:"grid gap-3 rounded-lg bg-muted/50 p-4 text-sm sm:grid-cols-2",children:n.map(([e,r])=>(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-xs text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-0.5 font-medium",children:r})]},e))})}function C({label:e,values:r}){return(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:e}),(0,t.jsx)("dd",{className:"mt-1",children:r.join(", ")})]})}e.s(["JiraTicketDrawer",0,function({issueKey:e,onClose:r,onTicketChange:c}){let T=(0,a.useTranslations)("jiraTickets"),[N,E]=(0,o.useState)(null),[I,D]=(0,o.useState)(null),[M,A]=(0,o.useState)(!1),[$,P]=(0,o.useState)(!1);(0,o.useEffect)(()=>{if(!e){let e=window.setTimeout(()=>E(null),0);return()=>window.clearTimeout(e)}let t=window.setTimeout(async()=>{A(!0);try{let t=await (0,v.controlPlaneRequest)(`query JiraTicket($issueKey: ID!) { jiraTicket(issueKey: $issueKey) { ${k.JIRA_TICKET_DETAIL_FIELDS} } }`,{issueKey:e});E(t.jiraTicket),D(null)}catch(e){D(e instanceof Error?e.message:String(e))}finally{A(!1)}},0);return()=>window.clearTimeout(t)},[e]);let U=e=>{E(e),c?.(e)};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(y.Sheet,{onOpenChange:e=>{e||r()},open:!!e,children:(0,t.jsxs)(y.SheetContent,{className:"w-[min(48rem,95vw)] overflow-y-auto sm:max-w-3xl",children:[(0,t.jsxs)(y.SheetHeader,{className:"border-b pr-12",children:[(0,t.jsx)(y.SheetTitle,{children:N?.key??e??T("ticket")}),(0,t.jsx)(y.SheetDescription,{children:N?.summary??T("loadingTicket")})]}),(0,t.jsxs)("div",{className:"space-y-6 px-4 pb-6",children:[M&&(0,t.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,t.jsx)(b.Spinner,{}),T("loadingTicket")]}),I&&(0,t.jsx)(p.Alert,{variant:"destructive",children:(0,t.jsx)(p.AlertDescription,{children:I})}),N&&(0,t.jsxs)(t.Fragment,{children:[(N.cache.stale||N.commentsCache.stale)&&(0,t.jsxs)(p.Alert,{className:"border-amber-500/30 bg-amber-500/10",children:[(0,t.jsx)(n,{}),(0,t.jsx)(p.AlertDescription,{children:T("staleTicket")})]}),(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsx)(h.Badge,{children:N.status}),N.issueType&&(0,t.jsx)(h.Badge,{children:N.issueType}),N.priority&&(0,t.jsx)(h.Badge,{className:S[N.priority.trim().toLowerCase()],children:N.priority})]}),(0,t.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,t.jsxs)(f.Button,{onClick:()=>P(!0),size:"sm",variant:"outline",children:[(0,t.jsx)(s.GitBranch,{})," ",T("worktreeAction")]}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)(j.Link,{href:`/jira/tickets/${encodeURIComponent(N.key)}`,children:[(0,t.jsx)(l,{})," ",T("openFullDetails")]})}),(0,t.jsx)(f.Button,{asChild:!0,size:"sm",variant:"outline",children:(0,t.jsxs)("a",{href:N.jiraUrl,rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(i.ExternalLink,{})," ",T("openInJira")]})})]})]}),(0,t.jsx)(d.JiraTicketActions,{onTicketChange:U,ticket:N}),(0,t.jsx)(R,{ticket:N}),(0,t.jsx)("section",{children:(0,t.jsx)(x.Card,{size:"sm",children:(0,t.jsx)(x.CardContent,{children:(0,t.jsx)(u.JiraRichTextBlock,{content:N.descriptionContent,header:(0,t.jsx)("h3",{className:"font-semibold",children:T("descriptionTitle")}),headerClassName:"border-b pb-2",value:N.description})})})}),(N.labels.length>0||N.components.length>0||N.fixVersions.length>0||N.sprintNames.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:T("classification")}),(0,t.jsxs)("dl",{className:"grid gap-3 text-sm sm:grid-cols-2",children:[N.labels.length>0&&(0,t.jsxs)("div",{children:[(0,t.jsx)("dt",{className:"text-muted-foreground",children:T("labels")}),(0,t.jsx)("dd",{className:"mt-1 flex flex-wrap gap-1",children:N.labels.map(e=>(0,t.jsx)(h.Badge,{children:e},e))})]}),N.components.length>0&&(0,t.jsx)(C,{label:T("components"),values:N.components.map(e=>e.name)}),N.fixVersions.length>0&&(0,t.jsx)(C,{label:T("fixVersions"),values:N.fixVersions.map(e=>e.name)}),N.sprintNames.length>0&&(0,t.jsx)(C,{label:T("sprints"),values:N.sprintNames})]})]}),(N.parent||N.subtasks.length>0||N.issueLinks.length>0)&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:T("relatedIssues")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:[...N.parent?[N.parent]:[],...N.subtasks,...N.issueLinks].map((e,r)=>(0,t.jsx)(g.Item,{asChild:!0,size:"xs",variant:"outline",children:(0,t.jsxs)(j.Link,{href:`/jira/tickets/${encodeURIComponent(e.key)}`,children:[(0,t.jsxs)(g.ItemContent,{children:[(0,t.jsxs)(g.ItemTitle,{className:"leading-tight",children:[e.key," · ",e.summary]}),(0,t.jsx)(g.ItemDescription,{className:"leading-tight",children:e.relationship})]}),(0,t.jsx)(g.ItemActions,{children:e.status&&(0,t.jsx)(h.Badge,{children:e.status})})]})},`${e.key}-${r}`))})]}),N.attachments.length>0&&(0,t.jsxs)("section",{children:[(0,t.jsx)("h3",{className:"mb-2 font-semibold",children:T("attachments")}),(0,t.jsx)(g.ItemGroup,{className:"gap-2",children:N.attachments.map(e=>(0,t.jsx)(g.Item,{asChild:!0,variant:"outline",children:(0,t.jsxs)("a",{href:e.contentUrl??"#",rel:"noreferrer",target:"_blank",children:[(0,t.jsx)(g.ItemContent,{children:(0,t.jsx)(g.ItemTitle,{children:e.filename})}),(0,t.jsx)(g.ItemActions,{className:"text-xs text-muted-foreground",children:e.size?`${Math.round(e.size/1024)} KB`:""})]})},e.id))})]}),(0,t.jsx)(m.JiraTicketComments,{onTicketChange:U,ticket:N})]})]})]})}),N&&(0,t.jsx)(w.TicketWorktreeDialog,{issueKey:N.key,onOpenChange:P,open:$})]})}],356505)},948812,e=>{"use strict";function t(e){return`${e.repositoryNameWithOwner}#${e.number}`}e.s(["pullRequestCommentsHref",0,function(e){return`/comments?pullRequest=${encodeURIComponent(t(e))}`},"pullRequestDetailHref",0,function(e){let[t="",r=""]=e.repositoryNameWithOwner.split("/");return`/pull-requests/${encodeURIComponent(t)}/${encodeURIComponent(r)}/${e.number}`},"pullRequestKey",0,t])},647776,e=>{"use strict";var t=e.i(843476),r=e.i(716327),n=e.i(482022),i=e.i(395925),s=e.i(948148),l=e.i(271645),a=e.i(487486),o=e.i(519455),c=e.i(755146),u=e.i(987968),d=e.i(746798),m=e.i(637611);function p({pipeline:e,repositoryId:r,onPipelineRetried:n,onError:a}){let c=(0,s.useTranslations)("pullRequests"),[h,f]=(0,l.useState)(!1),x=async t=>{if(t.stopPropagation(),e.canRetry&&e.checkSuiteId){f(!0);try{let t=await (0,m.controlPlaneRequest)(`mutation RetryGitHubPipeline(
2
+ $repositoryId: ID!
3
+ $checkSuiteId: ID!
4
+ ) {
5
+ retryGitHubPipeline(
6
+ repositoryId: $repositoryId
7
+ checkSuiteId: $checkSuiteId
8
+ ) { id name status url checkSuiteId canRetry retryUnavailableReason jobs { id name status url canRetry retryUnavailableReason steps { number name status } } }
9
+ }`,{repositoryId:r,checkSuiteId:e.checkSuiteId});n?.(t.retryGitHubPipeline),a?.(null)}catch(e){a?.(e instanceof Error?e.message:String(e))}finally{f(!1)}}},g=(0,t.jsxs)(o.Button,{disabled:h||!e.canRetry||!e.checkSuiteId,onClick:e=>void x(e),size:"sm",variant:"outline",children:[h?(0,t.jsx)(u.Spinner,{}):(0,t.jsx)(i.RotateCcw,{}),c(h?"retrying":"retry")]});if(!e.retryUnavailableReason||h)return g;let y=c(`retryUnavailable.${e.retryUnavailableReason}`);return(0,t.jsx)(d.TooltipProvider,{children:(0,t.jsxs)(d.Tooltip,{children:[(0,t.jsx)(d.TooltipTrigger,{asChild:!0,children:(0,t.jsx)("span",{"aria-label":y,className:"inline-flex",tabIndex:0,children:g})}),(0,t.jsx)(d.TooltipContent,{children:y})]})})}function h(e){return"SUCCESS"===e?"border-emerald-500/30 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300":"PENDING"===e||"EXPECTED"===e||"QUEUED"===e||"IN_PROGRESS"===e||"ACTION_REQUIRED"===e?"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-300":"FAILURE"===e||"ERROR"===e||"CANCELLED"===e||"STALE"===e||"STARTUP_FAILURE"===e||"TIMED_OUT"===e?"border-red-500/30 bg-red-500/10 text-red-700 dark:text-red-300":"border-slate-500/30 bg-slate-500/10 text-slate-700 dark:text-slate-300"}e.s(["PipelineMenu",0,function({pipelineStatus:e,pipelines:i,repositoryId:u,onPipelineRetried:d}){let m=(0,s.useTranslations)("pullRequests"),[f,x]=(0,l.useState)(null),g=e=>e.stopPropagation();return(0,t.jsxs)(c.DropdownMenu,{children:[(0,t.jsx)(c.DropdownMenuTrigger,{asChild:!0,children:(0,t.jsxs)(o.Button,{className:`h-5 rounded-full px-2 py-0.5 text-xs ${h(e)}`,onClick:g,variant:"outline",children:[m(`pipelineStates.${e}`),(0,t.jsx)(r.ChevronDown,{className:"size-3"})]})}),(0,t.jsxs)(c.DropdownMenuContent,{align:"end",className:"w-80",onClick:g,children:[(0,t.jsx)(c.DropdownMenuLabel,{children:m("pipelineMenuTitle")}),(0,t.jsx)(c.DropdownMenuSeparator,{}),f&&(0,t.jsx)("p",{className:"px-2 py-1.5 text-xs text-destructive",children:f}),0===i.length?(0,t.jsx)("p",{className:"px-2 py-3 text-sm text-muted-foreground",children:m("noPipelines")}):(0,t.jsx)("div",{className:"space-y-1 p-1",children:i.map(e=>(0,t.jsxs)("div",{className:"flex items-center gap-2 rounded-md px-2 py-2 hover:bg-muted",children:[(0,t.jsxs)("div",{className:"min-w-0 flex-1",children:[e.url?(0,t.jsxs)("a",{className:"flex min-w-0 items-center gap-1 text-sm font-medium hover:underline",href:e.url,rel:"noreferrer",target:"_blank",children:[(0,t.jsx)("span",{className:"truncate",children:e.name}),(0,t.jsx)(n.ExternalLink,{className:"size-3 shrink-0"})]}):(0,t.jsx)("p",{className:"truncate text-sm font-medium",children:e.name}),(0,t.jsx)(a.Badge,{className:`mt-1 ${h(e.status)}`,children:m(`pipelineStates.${e.status}`)})]}),e.checkSuiteId&&(0,t.jsx)(p,{onError:x,onPipelineRetried:d,pipeline:e,repositoryId:u})]},e.id))})]})]})},"RetryPipelineButton",0,p,"pipelineStateClass",0,h])},346194,113030,e=>{"use strict";var t=e.i(843476);let r=(0,e.i(456420).default)("git-merge",[["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}],["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M6 21V9a9 9 0 0 0 9 9",key:"7kw0sc"}]]);e.s(["GitMerge",0,r],113030);var n=e.i(948148),i=e.i(271645),s=e.i(929592),l=e.i(519455),a=e.i(776639),o=e.i(793479),c=e.i(110204),u=e.i(967489),d=e.i(987968),m=e.i(624687),p=e.i(637611);let h="__github_account_default__";e.s(["MergePullRequestButton",0,function({pullRequest:e,onMerged:f,size:x="sm",variant:g="outline",open:y,onOpenChange:b,showTrigger:j=!0}){let v=(0,n.useTranslations)("pullRequests"),[w,k]=(0,i.useState)(!1),[S,T]=(0,i.useState)(null),[R,C]=(0,i.useState)(""),[N,E]=(0,i.useState)(""),[I,D]=(0,i.useState)(""),[M,A]=(0,i.useState)(h),[$,P]=(0,i.useState)(!1),[U,q]=(0,i.useState)(!1),[_,F]=(0,i.useState)(null),[L="",B=""]=e.repositoryNameWithOwner.split("/",2),O=y??w,H=e=>{e||(P(!1),T(null),F(null)),void 0===y&&k(e),b?.(e)};(0,i.useEffect)(()=>{if(!O)return;let t=!0,r=window.setTimeout(()=>{P(!0),T(null),F(null),(0,p.controlPlaneRequest)(`query GitHubPullRequestMergeOptions(
10
+ $owner: String!
11
+ $name: String!
12
+ $number: Int!
13
+ ) {
14
+ githubPullRequestMergeOptions(
15
+ owner: $owner
16
+ name: $name
17
+ number: $number
18
+ ) {
19
+ availableMethods
20
+ commitEmails
21
+ defaultCommitEmail
22
+ defaultCommitHeadline
23
+ defaultCommitBody
24
+ canMerge
25
+ blockedReason
26
+ }
27
+ }`,{owner:L,name:B,number:e.number}).then(e=>{if(!t)return;let r=e.githubPullRequestMergeOptions;T(r),C(r.availableMethods[0]??""),E(r.defaultCommitHeadline),D(r.defaultCommitBody),A(r.defaultCommitEmail??h)}).catch(e=>{t&&F(e instanceof Error?e.message:String(e))}).finally(()=>{t&&P(!1)})},0);return()=>{t=!1,window.clearTimeout(r)}},[B,O,L,e.number]);let z=async()=>{if(R&&S?.canMerge&&N.trim()){q(!0),F(null);try{let t=await (0,p.controlPlaneRequest)(`mutation MergeGitHubPullRequest(
28
+ $input: MergeGitHubPullRequestInput!
29
+ ) {
30
+ mergeGitHubPullRequest(input: $input) {
31
+ id state url mergedAt
32
+ }
33
+ }`,{input:{owner:L,name:B,number:e.number,method:R,commitHeadline:N,commitBody:I,authorEmail:M===h?null:M}});H(!1),await f?.(t.mergeGitHubPullRequest)}catch(e){F(e instanceof Error?e.message:String(e))}finally{q(!1)}}},G=S?.blockedReason??null;return(0,t.jsxs)(t.Fragment,{children:[j&&(0,t.jsxs)(l.Button,{onClick:e=>{e.stopPropagation(),H(!0)},size:x,type:"button",variant:g,children:[(0,t.jsx)(r,{}),v("merge")]}),(0,t.jsx)(a.Dialog,{onOpenChange:e=>{U||H(e)},open:O,children:(0,t.jsxs)(a.DialogContent,{className:"sm:max-w-xl",children:[(0,t.jsxs)(a.DialogHeader,{children:[(0,t.jsx)(a.DialogTitle,{children:v("mergePullRequest")}),(0,t.jsx)(a.DialogDescription,{children:v("mergePullRequestDescription",{repository:e.repositoryNameWithOwner,number:e.number})})]}),!$&&(S||_)?(0,t.jsxs)("div",{className:"space-y-4",children:[(_||G)&&(0,t.jsx)(s.Alert,{variant:"destructive",children:(0,t.jsx)(s.AlertDescription,{children:_||G})}),S&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Label,{className:"mb-1.5 block",htmlFor:"merge-method",children:v("mergeType")}),(0,t.jsxs)(u.Select,{disabled:U||0===S.availableMethods.length,onValueChange:e=>C(e),value:R,children:[(0,t.jsx)(u.SelectTrigger,{id:"merge-method",children:(0,t.jsx)(u.SelectValue,{placeholder:v("selectMergeType")})}),(0,t.jsx)(u.SelectContent,{children:S.availableMethods.map(e=>(0,t.jsx)(u.SelectItem,{value:e,children:v(`mergeTypes.${e}`)},e))})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Label,{className:"mb-1.5 block",htmlFor:"merge-commit-headline",children:v("commitMessage")}),(0,t.jsx)(o.Input,{disabled:U,id:"merge-commit-headline",onChange:e=>E(e.target.value),value:N})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Label,{className:"mb-1.5 block",htmlFor:"merge-commit-body",children:v("commitDescription")}),(0,t.jsx)(m.Textarea,{className:"min-h-28",disabled:U,id:"merge-commit-body",onChange:e=>D(e.target.value),value:I})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(c.Label,{className:"mb-1.5 block",htmlFor:"merge-email",children:v("commitEmail")}),(0,t.jsxs)(u.Select,{disabled:U,onValueChange:A,value:M,children:[(0,t.jsx)(u.SelectTrigger,{id:"merge-email",children:(0,t.jsx)(u.SelectValue,{})}),(0,t.jsxs)(u.SelectContent,{children:[(0,t.jsx)(u.SelectItem,{value:h,children:v("githubDefaultEmail")}),S.commitEmails.map(e=>(0,t.jsx)(u.SelectItem,{value:e,children:e},e))]})]})]})]})]}):(0,t.jsxs)("div",{className:"flex items-center gap-2 py-6 text-sm text-muted-foreground",children:[(0,t.jsx)(d.Spinner,{})," ",v("loadingMergeOptions")]}),(0,t.jsxs)(a.DialogFooter,{children:[(0,t.jsx)(l.Button,{disabled:U,onClick:()=>H(!1),type:"button",variant:"outline",children:v("cancelMerge")}),(0,t.jsxs)(l.Button,{disabled:$||U||!S?.canMerge||!R||!N.trim(),onClick:()=>void z(),type:"button",children:[U?(0,t.jsx)(d.Spinner,{}):(0,t.jsx)(r,{}),U?v("merging"):v("mergePullRequest")]})]})]})})]})}],346194)}]);