decocms 4.372.3 → 4.373.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/assets/{AlertCircle-CMjsP_Tk.js → AlertCircle-2L7lI8NL.js} +1 -1
- package/dist/client/assets/{AreaChart-Bh_grNQZ.js → AreaChart-BSJ08P7a.js} +1 -1
- package/dist/client/assets/{ArrowLeft-CjYy5Nhj.js → ArrowLeft-8rouBEwC.js} +1 -1
- package/dist/client/assets/{ArrowRight-CLncCNat.js → ArrowRight-DCA5zjxW.js} +1 -1
- package/dist/client/assets/{ArrowUp-Cii1LHW7.js → ArrowUp-BtksDHBQ.js} +1 -1
- package/dist/client/assets/{CartesianChart-CD-5y_pX.js → CartesianChart-BbOaLmfq.js} +1 -1
- package/dist/client/assets/{CheckCircle-DHXQFnpK.js → CheckCircle-BmVuh1xp.js} +1 -1
- package/dist/client/assets/{ChevronUp-DiYhGG4T.js → ChevronUp-fg9sod-H.js} +1 -1
- package/dist/client/assets/{Copy01-nMxlBfeT.js → Copy01-BgwuTJFm.js} +1 -1
- package/dist/client/assets/{CreditCard01-CWXVH3ZM.js → CreditCard01-CIt471eG.js} +1 -1
- package/dist/client/assets/DotsVertical-CE2o6L6N.js +1 -0
- package/dist/client/assets/{Download01-BRrSA3Yx.js → Download01-DNhEQzg0.js} +1 -1
- package/dist/client/assets/{ErrorBarContext-fXvhmekg.js → ErrorBarContext-DxNax47N.js} +1 -1
- package/dist/client/assets/{Eye-Dyg2WPG4.js → Eye-Dq6Vw6FI.js} +1 -1
- package/dist/client/assets/{Globe01-D6FaaFR2.js → Globe01-g_y8gAs1.js} +1 -1
- package/dist/client/assets/{Users03-Y0Jco4zL.js → Globe04-GFiRExL0.js} +1 -1
- package/dist/client/assets/{Image01-CxnjAzbb.js → Image01-QB6twEDu.js} +1 -1
- package/dist/client/assets/{Key01-CIXwHMRo.js → Key01-CO_i2QPb.js} +1 -1
- package/dist/client/assets/LayoutLeft-BfySK4h8.js +1 -0
- package/dist/client/assets/{Line-YO4Ozgbt.js → Line-Cr57fOtp.js} +1 -1
- package/dist/client/assets/{Link01-C0FvgZZB.js → Link01-BIFMl_M0.js} +1 -1
- package/dist/client/assets/{LinkExternal01-AWlhN5o7.js → LinkExternal01-DQD59o7F.js} +1 -1
- package/dist/client/assets/{Monitor01-Ccs1gh2Z.js → Monitor01-Ddm2yOG6.js} +1 -1
- package/dist/client/assets/{Package-nTbucmaQ.js → Package-CvzEol5_.js} +1 -1
- package/dist/client/assets/{Palette-DSdn1Xis.js → Palette-DT856bn6.js} +1 -1
- package/dist/client/assets/{Play-lMuWOObF.js → Play-wYDcJhBq.js} +1 -1
- package/dist/client/assets/{Plus-CVauOqLT.js → Plus-BSp00qOC.js} +1 -1
- package/dist/client/assets/{SearchLg-BrrPVuXr.js → SearchLg-DFD1t2UL.js} +1 -1
- package/dist/client/assets/{SearchMd-C45D2PMI.js → SearchMd-Bb5gjLcX.js} +1 -1
- package/dist/client/assets/{Sector-9mXbxJ9i.js → Sector-wViCnB96.js} +5 -5
- package/dist/client/assets/{Settings02-Cyf85ea0.js → Settings02-D9Qv7BDm.js} +1 -1
- package/dist/client/assets/{Share07-wC47qn2E.js → Share07-CZ7JzYs9.js} +1 -1
- package/dist/client/assets/{Stars01-oAh9h5b5.js → Stars01-D-wYuyik.js} +1 -1
- package/dist/client/assets/{Sun-0Ied-kyZ.js → Sun-DLRcOzSd.js} +1 -1
- package/dist/client/assets/Tool01-Dwy1nlT9.js +1 -0
- package/dist/client/assets/{Tool02-CATStXCy.js → Tool02-CvlAGFBM.js} +1 -1
- package/dist/client/assets/{Trash01-nl-t4IoV.js → Trash01-DtE0n00a.js} +1 -1
- package/dist/client/assets/{TrendUp01-BFAEMx9E.js → TrendUp01-BCriuXJd.js} +1 -1
- package/dist/client/assets/{Upload01-B4Fqdkae.js → Upload01-Ba-RLxE1.js} +1 -1
- package/dist/client/assets/{User01-ClMaVCaJ.js → User01-DHd46PZp.js} +1 -1
- package/dist/client/assets/{UserSquare-B2lKdt4w.js → UserSquare-CcF49LHs.js} +1 -1
- package/dist/client/assets/{Users01-BFhxJVhO.js → Users01-B8gdz27Y.js} +1 -1
- package/dist/client/assets/{X-CFCE4a-Q.js → X-BtMi8Qau.js} +1 -1
- package/dist/client/assets/{XCircle-CleKT0Id.js → XCircle-BLCHBIhx.js} +1 -1
- package/dist/client/assets/{SwitchHorizontal01-DpXsFGyJ.js → XClose-CvcHLHe2.js} +1 -1
- package/dist/client/assets/{Zap-B6zkqKWB.js → Zap-DZAIluO6.js} +1 -1
- package/dist/client/assets/ZoomOut-DUFJq3-K.js +1 -0
- package/dist/client/assets/{access-gate-Ds4n25mC.js → access-gate-C9Dl5e5c.js} +1 -1
- package/dist/client/assets/add-connection-dialog-DA05asFs.js +1 -0
- package/dist/client/assets/agent-analytics-CDo5Hugr.js +2 -0
- package/dist/client/assets/agent-app-lfl4wDqj.js +1 -0
- package/dist/client/assets/agent-assets-6UK-ev9d.js +1 -0
- package/dist/client/assets/agent-automation-BC-cMvrG.js +20 -0
- package/dist/client/assets/agent-automations-CnHTcvU7.js +1 -0
- package/dist/client/assets/agent-connect-sources-CJ8artss.js +1 -0
- package/dist/client/assets/agent-deck-BCZ0G4O2.js +1 -0
- package/dist/client/assets/agent-e2e-Cj1Q_JS0.js +1 -0
- package/dist/client/assets/agent-experiments-DJ13yAp9.js +1 -0
- package/dist/client/assets/agent-file-DbKP1r-4.js +1 -0
- package/dist/client/assets/{agent-git-D4IYczGa.js → agent-git-B8LMQ2zl.js} +2 -2
- package/dist/client/assets/agent-hosting-Bm-WxahY.js +1 -0
- package/dist/client/assets/agent-icon-CTsmTxHg.js +1 -0
- package/dist/client/assets/agent-library-file-DvybgEEZ.js +1 -0
- package/dist/client/assets/agent-monitor-DgVt0zbx.js +1 -0
- package/dist/client/assets/agent-overview-pOglhwpN.js +1 -0
- package/dist/client/assets/agent-settings-Bx-Ya3hQ.js +1 -0
- package/dist/client/assets/{agent-site-editor-DJSdtoNU.js → agent-site-editor-DVT-M9T0.js} +13 -13
- package/dist/client/assets/agent-site-editor-code-DpPWdLwT.js +2 -0
- package/dist/client/assets/agent-site-editor-content-eM0WchN0.js +2 -0
- package/dist/client/assets/agent-site-editor-preview-3VO_kTqr.js +518 -0
- package/dist/client/assets/{agent-view-guard-DHJpzCVR.js → agent-view-guard-BNYKK-x9.js} +1 -1
- package/dist/client/assets/agent-view-v-h5B6vN.js +1 -0
- package/dist/client/assets/agents-list-BXPjUzIN.js +1 -0
- package/dist/client/assets/{ai-providers-jxGd6MbV.js → ai-providers-BAmCFPvS.js} +2 -2
- package/dist/client/assets/{alert-U2IStW1f.js → alert-C8o4-kn8.js} +1 -1
- package/dist/client/assets/{alert-dialog-BI-B_8hq.js → alert-dialog-9n2p5SCQ.js} +2 -2
- package/dist/client/assets/api-keys-Cu1KdEtK.js +1 -0
- package/dist/client/assets/api-keys-DCurVLgh.js +1 -0
- package/dist/client/assets/app-editor-C3QSidsO.js +1 -0
- package/dist/client/assets/asset-utils-CK3Em4fb.js +1 -0
- package/dist/client/assets/{auth-DhzAq_9m.js → auth-BBW3DF0r.js} +1 -1
- package/dist/client/assets/{auth-catchall-Dar7OygY.js → auth-catchall-Bva2z4Gj.js} +1 -1
- package/dist/client/assets/auth-entry-BuHqwUIr.js +1 -0
- package/dist/client/assets/{auth-split-layout-DLFqjvPt.js → auth-split-layout-DMgxvbll.js} +1 -1
- package/dist/client/assets/{authenticate-and-persist-oauth-DkJ4g-X5.js → authenticate-and-persist-oauth-Pk9b2m8R.js} +1 -1
- package/dist/client/assets/automation-list-row-D-zBLXA-.js +1 -0
- package/dist/client/assets/automation-runs-C8Wbje-n.js +1 -0
- package/dist/client/assets/automations-D69ikqKh.js +1 -0
- package/dist/client/assets/{autosend-BberXmli.js → autosend-CVNOmzPu.js} +1 -1
- package/dist/client/assets/{avatar-C9HiP4eS.js → avatar-BzRNaDEk.js} +1 -1
- package/dist/client/assets/badge-C5M6nZd4.js +1 -0
- package/dist/client/assets/block-document-UPtnFOJG.js +3 -0
- package/dist/client/assets/{blocks-preview-workspace-context-Bwmvvd4S.js → blocks-preview-workspace-context-DAFMxzU6.js} +1 -1
- package/dist/client/assets/breadcrumb-0yy48vm9.js +1 -0
- package/dist/client/assets/{buckets-BndbOAGO.js → buckets-CktpbsrB.js} +1 -1
- package/dist/client/assets/build-improve-prompt-doc-C-SX02eL.js +2 -0
- package/dist/client/assets/bulk-category-panel-MrIv4eD2.js +1 -0
- package/dist/client/assets/calendar-QcX36iLy.js +1 -0
- package/dist/client/assets/capability-load-error-BVb3VEU2.js +1 -0
- package/dist/client/assets/category-editor-DZThBJlF.js +1 -0
- package/dist/client/assets/{chart-8nXuVw9P.js → chart-BVjaATZw.js} +5 -5
- package/dist/client/assets/{chat-context-tZCX_cqt.js → chat-context-ELO8A2Ar.js} +6 -6
- package/dist/client/assets/{chat-draft-BCeqPSxA.js → chat-draft-tDfZTlxU.js} +1 -1
- package/dist/client/assets/checkbox-iGlb02v9.js +1 -0
- package/dist/client/assets/choose-editor-CWLAiGtz.js +1 -0
- package/dist/client/assets/{cli-auth-success-D39z_FO3.js → cli-auth-success-DyNW_Pmq.js} +1 -1
- package/dist/client/assets/{client-icons-DpcP1bht.js → client-icons-BuRYGGKe.js} +1 -1
- package/dist/client/assets/collapsible-PyJ2NOzW.js +1 -0
- package/dist/client/assets/collection-detail-DXmBNKMr.js +1 -0
- package/dist/client/assets/collection-display-button-Cz5AkuIg.js +1 -0
- package/dist/client/assets/{collection-search-J9Bt25gS.js → collection-search-DM8MkJfo.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-DBeauaNS.js → collection-table-wrapper-cBr_X4Jo.js} +1 -1
- package/dist/client/assets/collection-tabs-aKKPIP9M.js +1 -0
- package/dist/client/assets/combobox-CQBdlQef.js +1 -0
- package/dist/client/assets/command-CZcxzTcw.js +1 -0
- package/dist/client/assets/{companion-mcps-section-xmRpNJBK.js → companion-mcps-section-B7qgbnOZ.js} +1 -1
- package/dist/client/assets/connect-D6Wz7x6C.js +8 -0
- package/dist/client/assets/connect-layout-DzSDvFP2.js +1 -0
- package/dist/client/assets/{connection-DD0omVHZ.js → connection-DStV2sLP.js} +1 -1
- package/dist/client/assets/connection-card-CpIJKLp3.js +1 -0
- package/dist/client/assets/connection-detail-junbbrHX.js +1 -0
- package/dist/client/assets/{connection-form-helpers-CHlcdgAK.js → connection-form-helpers-DM_wSOEJ.js} +1 -1
- package/dist/client/assets/connections-DvjnCZJT.js +1 -0
- package/dist/client/assets/{create-organization-dialog-1mI4Ad1B.js → create-organization-dialog-CvXOAbwA.js} +1 -1
- package/dist/client/assets/{decofile-api-BNWbEMR6.js → decofile-api-zRlIvvNL.js} +1 -1
- package/dist/client/assets/{decopilot-BvepxP_-.js → decopilot-BI8eOOPY.js} +2 -2
- package/dist/client/assets/dialog-AoC07APJ.js +1 -0
- package/dist/client/assets/discover-zo2iAYFW.js +1 -0
- package/dist/client/assets/domain-settings-C6kSznIr.js +1 -0
- package/dist/client/assets/download-app-dialog-CsiIuf7j.js +1 -0
- package/dist/client/assets/{drawer-BIjkXMV3.js → drawer-DGzquxJ8.js} +1 -1
- package/dist/client/assets/{editor-D4Ls62vg.js → editor-oL1B7LVJ.js} +1 -1
- package/dist/client/assets/{empty-state-BdiOfgle.js → empty-state-DxJQDjCw.js} +1 -1
- package/dist/client/assets/{empty-state-CyICQznD.js → empty-state-Y08kvU5o.js} +1 -1
- package/dist/client/assets/{extract-connection-data-Dbm_cKaX.js → extract-connection-data-C7Wh9xkI.js} +1 -1
- package/dist/client/assets/{feature-gate-Bp7Cydio.js → feature-gate-C1d068b1.js} +1 -1
- package/dist/client/assets/feature-paywall-BoABVlUQ.js +1 -0
- package/dist/client/assets/file-explorer-DG5Gvb-w.js +2 -0
- package/dist/client/assets/{file-preview-CARebwHJ.js → file-preview-iaqpqUYi.js} +1 -1
- package/dist/client/assets/file-share-button-D0lT5ixf.js +3 -0
- package/dist/client/assets/{file-type-icon-C9Qn36v4.js → file-type-icon-lZW2ows7.js} +1 -1
- package/dist/client/assets/{folder-icon-BLBZBD_a.js → folder-icon-DVG7PK8X.js} +1 -1
- package/dist/client/assets/{form-CSXgIHLz.js → form-CYsJTpNM.js} +1 -1
- package/dist/client/assets/{gateway-client-BuiOykcN.js → gateway-client-CnYYocwu.js} +1 -1
- package/dist/client/assets/general-BiYLEv2o.js +1 -0
- package/dist/client/assets/{github-icon-huXDOAgf.js → github-icon-swNUSpAU.js} +1 -1
- package/dist/client/assets/home-BbjS-573.js +1 -0
- package/dist/client/assets/{hooks-BoX5BC-f.js → hooks-BlE0QZwR.js} +2 -2
- package/dist/client/assets/{hooks-DZOMRp7D.js → hooks-D0dDgrIf.js} +1 -1
- package/dist/client/assets/icon-button-7c--Wy5B.js +1 -0
- package/dist/client/assets/{index-BWpNlf6e.js → index-0-s9o3tr.js} +1 -1
- package/dist/client/assets/index-BDYXeKzz.js +1 -0
- package/dist/client/assets/index-BOHOyAF8.css +1 -0
- package/dist/client/assets/{index-tj4CWdxr.js → index-BUfoj27y.js} +1 -1
- package/dist/client/assets/index-BchRuDAc.js +26 -0
- package/dist/client/assets/{index-BD213WLU.js → index-C97O3ClY.js} +1 -1
- package/dist/client/assets/index-CutV0Ygc.js +1 -0
- package/dist/client/assets/{index-DqT4mG5l.js → index-DGY2nhhI.js} +1 -1
- package/dist/client/assets/index-DItj2r3e.js +5 -0
- package/dist/client/assets/index-DKXWNSdB.js +1 -0
- package/dist/client/assets/{index-Bb-Re5q8.js → index-DllcfiZL.js} +1 -1
- package/dist/client/assets/{index-DiULBiX9.js → index-DyCAAYSx.js} +1 -1
- package/dist/client/assets/index-EcuFIS2a.js +235 -0
- package/dist/client/assets/{index-DWw5wi2G.js → index-Exw_Yjch.js} +1 -1
- package/dist/client/assets/{index-2gtoysbs.js → index-fN6RkMSD.js} +1 -1
- package/dist/client/assets/{index-redirect-BQTLrDGT.js → index-redirect-Bm4zqVUy.js} +1 -1
- package/dist/client/assets/{infiniteQueryObserver-CjWlcBHD.js → infiniteQueryObserver-3RxH1tr-.js} +1 -1
- package/dist/client/assets/infra-billing-CmY2herT.js +1 -0
- package/dist/client/assets/input-BrPa4I3Z.js +8 -0
- package/dist/client/assets/input-Buz_7xoG.js +1 -0
- package/dist/client/assets/input-C5klQNJJ.js +1 -0
- package/dist/client/assets/{integration-icon-BeEdjsn9.js → integration-icon-D3FHJbYu.js} +1 -1
- package/dist/client/assets/{label-BMxIRiEr.js → label-BX1BwzZ4.js} +1 -1
- package/dist/client/assets/{last-preview-page-B_H0ubHa.js → last-preview-page-BSVfE6AT.js} +1 -1
- package/dist/client/assets/layout-030aDjqi.js +1 -0
- package/dist/client/assets/legacy-agents-deep-BblX_qPq.js +1 -0
- package/dist/client/assets/legacy-main-redirect-BDaODIKZ.js +1 -0
- package/dist/client/assets/library-CmkU9fCT.js +161 -0
- package/dist/client/assets/{login-C4Dx9xMO.js → login-BpUdj6Fq.js} +1 -1
- package/dist/client/assets/{markdown-DGWjAeXL.js → markdown-VKlC4_bJ.js} +3 -3
- package/dist/client/assets/{mcp-app-renderer-BTjC7Gse.js → mcp-app-renderer-wS7imsel.js} +2 -2
- package/dist/client/assets/{mcp-oauth-C4khbNJJ.js → mcp-oauth-B7YJNr4N.js} +1 -1
- package/dist/client/assets/members-2ZkimP3H.js +1 -0
- package/dist/client/assets/message-templates-DyGM313y.js +1 -0
- package/dist/client/assets/{mini-report-page-Ci4cxCz8.js → mini-report-page-CYdef8vQ.js} +1 -1
- package/dist/client/assets/mock-board-Dk2mRFCa.js +90 -0
- package/dist/client/assets/{monaco-editor-CMRYkmyb.js → monaco-editor-ChRh_qus.js} +2 -2
- package/dist/client/assets/{monitoring-stats-row-PncjnNwy.js → monitoring-stats-row-DirMMFq2.js} +1 -1
- package/dist/client/assets/multi-select-CYKeAXVo.js +1 -0
- package/dist/client/assets/{mustache-CPZS2ebG.js → mustache-BpzqsH6c.js} +1 -1
- package/dist/client/assets/{oauth-callback-CETK2WZB.js → oauth-callback-CLQttSb2.js} +1 -1
- package/dist/client/assets/{oauth-callback-ai-provider-DqbbngEF.js → oauth-callback-ai-provider-C5AqSldx.js} +1 -1
- package/dist/client/assets/{onboarding-B5zAGi2B.js → onboarding-BYeSkDcE.js} +1 -1
- package/dist/client/assets/optimistic-project-sidebar-views-hB0JGrCs.js +1 -0
- package/dist/client/assets/{org-file-open-context-BCUpiY_R.js → org-file-open-context-D26BTBiX.js} +1 -1
- package/dist/client/assets/{organization-choice-BNulT5zU.js → organization-choice-sm9k2ko4.js} +1 -1
- package/dist/client/assets/orgs-BT6gh3Sc.js +1 -0
- package/dist/client/assets/{page-seo-form-BrHgBXF1.js → page-seo-form-Bhk-2qvu.js} +1 -1
- package/dist/client/assets/{pair-B46EBBjF.js → pair-Bh73YYpe.js} +8 -8
- package/dist/client/assets/plan-ladder-B-hb17ya.js +1 -0
- package/dist/client/assets/{popover-yk_ePqAA.js → popover-Bff85VlI.js} +1 -1
- package/dist/client/assets/post-calendar-BUJnl75O.js +1 -0
- package/dist/client/assets/post-editor-B8ClYTJb.js +1 -0
- package/dist/client/assets/{preview-content-CfbsbElk.js → preview-content-C4FuOpTi.js} +1 -1
- package/dist/client/assets/{preview-dialog-CA2C3DS4.js → preview-dialog-DY1kQ4y_.js} +1 -1
- package/dist/client/assets/primitives-BCCkMTJb.js +1 -0
- package/dist/client/assets/profile-T7ySaz_t.js +1 -0
- package/dist/client/assets/project-app-view-D4HCSkue.js +1 -0
- package/dist/client/assets/project-feed-CRHprIgj.js +1 -0
- package/dist/client/assets/{project-icon-MWmzrrm8.js → project-icon-D_oHwik9.js} +1 -1
- package/dist/client/assets/project-reports-CzVFjEoR.js +1 -0
- package/dist/client/assets/project-tasks-c_cBe8VF.js +1 -0
- package/dist/client/assets/{prompts-4lILOzK9.js → prompts-BuPAnA4R.js} +1 -1
- package/dist/client/assets/record-editor-CHfqyrFA.js +1 -0
- package/dist/client/assets/redirect-editor-BrEMZWAU.js +1 -0
- package/dist/client/assets/registry-4kJYrulU.js +2 -0
- package/dist/client/assets/registry-layout-o90YrVKa.js +27 -0
- package/dist/client/assets/reports-COffkxyo.js +1 -0
- package/dist/client/assets/{reports-BpxYdv2_.js → reports-DEVutxJq.js} +2 -2
- package/dist/client/assets/reports-onboarding-Dt5mvf07.js +1 -0
- package/dist/client/assets/reports-tab-C6PZg0b6.js +2 -0
- package/dist/client/assets/repositories-DBFrDUwl.js +1 -0
- package/dist/client/assets/repository-import-picker-ftg0FRzY.js +1 -0
- package/dist/client/assets/repository-picker-BKj90hIS.js +1 -0
- package/dist/client/assets/{require-capability-CmtOZnXt.js → require-capability-gpVnF6U4.js} +1 -1
- package/dist/client/assets/{required-auth-layout-RoMNnMPO.js → required-auth-layout-BhdxJMdb.js} +1 -1
- package/dist/client/assets/{reset-password-BeUL8IgX.js → reset-password-DD2ixVIR.js} +1 -1
- package/dist/client/assets/resizable-wU1MiASn.js +1 -0
- package/dist/client/assets/review-settings-3uLiRV1J.js +1 -0
- package/dist/client/assets/{rich-text-link-control-CHsxXHIo.js → rich-text-link-control-Bn-QsIS6.js} +2 -2
- package/dist/client/assets/roles-DX_ap2B0.js +1 -0
- package/dist/client/assets/route-Bdqr734y.js +1 -0
- package/dist/client/assets/route-Cg6AOuOY.js +1 -0
- package/dist/client/assets/route-DGhKwFXa.js +1 -0
- package/dist/client/assets/route-page-header-DKm5kHtX.js +1 -0
- package/dist/client/assets/runnable-block-editor-9i5DpxOA.js +16 -0
- package/dist/client/assets/{sandbox-lifecycle-context-C7VKOJoV.js → sandbox-lifecycle-context-BHn9YFEW.js} +2 -2
- package/dist/client/assets/{schema-1zAO-l7e.js → schema-FDf70VFI.js} +1 -1
- package/dist/client/assets/{scroll-area-C-wtbVS1.js → scroll-area-DMmJ7JtI.js} +1 -1
- package/dist/client/assets/search-input-BHVk6m6A.js +1 -0
- package/dist/client/assets/search-toggle-CCC7TvwN.js +1 -0
- package/dist/client/assets/secrets-BNtrMaDs.js +1 -0
- package/dist/client/assets/sections-editor-HtflyYMM.js +2 -0
- package/dist/client/assets/select-DBfOOW9i.js +1 -0
- package/dist/client/assets/select-model-2C5Fdpra.js +1 -0
- package/dist/client/assets/seo-editor-CFULobkJ.js +1 -0
- package/dist/client/assets/separator-8fswVHAH.js +1 -0
- package/dist/client/assets/settings-tab-s3d5MtS-.js +5 -0
- package/dist/client/assets/{sheet-i72Qx7sL.js → sheet-DWSThpSZ.js} +1 -1
- package/dist/client/assets/shell-layout-BQnbNNla.js +1 -0
- package/dist/client/assets/{shell-layout-CuFt8bor.css → shell-layout-CE2Eihra.css} +1 -1
- package/dist/client/assets/sidebar-CoC2_Nad.js +1 -0
- package/dist/client/assets/{skill-preview-gfYVdSdM.js → skill-preview-QgrtYNqp.js} +1 -1
- package/dist/client/assets/skills-BVINvlqv.js +1 -0
- package/dist/client/assets/sso-CSqM_F3b.js +1 -0
- package/dist/client/assets/store-DBNpNTVQ.js +1 -0
- package/dist/client/assets/store-registry-DLmFNBij.js +2 -0
- package/dist/client/assets/{switch-BQFtt3BH.js → switch-BIfmgDHS.js} +1 -1
- package/dist/client/assets/synced-repos-CG_pm_Ch.js +1 -0
- package/dist/client/assets/{table-6I6YKvFY.js → table-CEVOOGGz.js} +1 -1
- package/dist/client/assets/{tabs-CLziM0Ww.js → tabs-Dd0IWElc.js} +1 -1
- package/dist/client/assets/{task-board-DrUf5p-Z.js → task-board-Dip4Wu9j.js} +1 -1
- package/dist/client/assets/task-route-SKFoAFiU.js +1 -0
- package/dist/client/assets/task-status-k7EGfTLN.js +1 -0
- package/dist/client/assets/taskboard-analytics-C3lk9wb7.js +1 -0
- package/dist/client/assets/tasks-Sl_c9zFF.js +1 -0
- package/dist/client/assets/{tasks-Drgd6az8.js → tasks-ebQIYdwz.js} +4 -4
- package/dist/client/assets/textarea-D5v3ol7T.js +1 -0
- package/dist/client/assets/thread-button-C3YUAV-G.js +1 -0
- package/dist/client/assets/{thread-intent-F-sZEflj.js → thread-intent-CTSjhfEo.js} +1 -1
- package/dist/client/assets/thread-route-B57JfaL5.js +1 -0
- package/dist/client/assets/thread-route-CHwqHPf_.js +1 -0
- package/dist/client/assets/thread-sheet-body-Hqh1hVbj.js +1 -0
- package/dist/client/assets/toggle-group-CwAn2mKr.js +1 -0
- package/dist/client/assets/toolbar-icon-button-ChZE-2zp.js +1 -0
- package/dist/client/assets/{tooltip-DV2xHesQ.js → tooltip-nr5oS_bm.js} +1 -1
- package/dist/client/assets/{track-ZuOMvhd2.js → track-BDYWN4z3.js} +1 -1
- package/dist/client/assets/{types-27TVsPN_.js → types-7UQ7SDxU.js} +3 -3
- package/dist/client/assets/usage-stats-YafP0g9G.js +1 -0
- package/dist/client/assets/use-ai-providers-D-abiIwe.js +1 -0
- package/dist/client/assets/use-automations-D_y1YNke.js +1 -0
- package/dist/client/assets/{use-autosave-DOzyZumC.js → use-autosave-z8cIzzdm.js} +1 -1
- package/dist/client/assets/use-connect-companion-jQzCS0Na.js +1 -0
- package/dist/client/assets/use-connection-BKZRi94S.js +1 -0
- package/dist/client/assets/{use-copy-C_ctOeuP.js → use-copy-Cp_DyXH6.js} +1 -1
- package/dist/client/assets/{use-create-virtual-mcp-D1w9d4ex.js → use-create-virtual-mcp-nvoTomrD.js} +1 -1
- package/dist/client/assets/{use-date-fns-locale-onM9TTf8.js → use-date-fns-locale-CNoKSvxx.js} +1 -1
- package/dist/client/assets/{use-debounced-autosave-DqyNKPJM.js → use-debounced-autosave-B0HBbqeX.js} +1 -1
- package/dist/client/assets/{use-debounced-value-B9nG3bW5.js → use-debounced-value-BgYHDTDk.js} +1 -1
- package/dist/client/assets/use-deco-credits-CqbkXgA9.js +1 -0
- package/dist/client/assets/{use-decopilot-events-BpuQrfKN.js → use-decopilot-events-qaEKsixC.js} +1 -1
- package/dist/client/assets/use-delete-connection-CqvqqWgS.js +1 -0
- package/dist/client/assets/{use-deployment-admin-BVfgEagI.js → use-deployment-admin-DzkF6L4b.js} +1 -1
- package/dist/client/assets/{use-entitlements-Dl7pAsQ5.js → use-entitlements-kPr6KRf9.js} +1 -1
- package/dist/client/assets/{use-fast-preview-draft-url-mcfOeAAq.js → use-fast-preview-draft-url-BBBDyhsD.js} +1 -1
- package/dist/client/assets/use-file-configs-6ygOocDG.js +1 -0
- package/dist/client/assets/use-in-settings-BCDqA2EC.js +1 -0
- package/dist/client/assets/{use-infinite-scroll-PhBGPm8H.js → use-infinite-scroll-D0T36z_V.js} +1 -1
- package/dist/client/assets/use-join-requests-BBovhUnp.js +1 -0
- package/dist/client/assets/use-main-panel-tabs-BghanH6r.js +1 -0
- package/dist/client/assets/use-mcp-auth-status-h4sAecTI.js +1 -0
- package/dist/client/assets/{use-mcp-client-e_hCatGm.js → use-mcp-client-B_gcvvCy.js} +6 -6
- package/dist/client/assets/{use-mcp-prompts-DJRXjL4_.js → use-mcp-prompts-DfSKL4Gu.js} +1 -1
- package/dist/client/assets/{use-mcp-tools-g86k4oib.js → use-mcp-tools-DC47roTz.js} +1 -1
- package/dist/client/assets/use-members-C6brpkJ1.js +1 -0
- package/dist/client/assets/{use-mobile-hIijCK0k.js → use-mobile-BZ15DgEB.js} +1 -1
- package/dist/client/assets/use-navigate-to-agent-B8SXI0oO.js +1 -0
- package/dist/client/assets/use-open-billing-url-BAg3ZeFq.js +1 -0
- package/dist/client/assets/use-org-auth-client-8fDIgHEZ.js +1 -0
- package/dist/client/assets/use-org-fs-Bf6n51Xm.js +1 -0
- package/dist/client/assets/use-org-repo-syncs-CnBqiATM.js +8 -0
- package/dist/client/assets/{use-org-sso-BvfIL0yq.js → use-org-sso-QeqdMaIa.js} +1 -1
- package/dist/client/assets/use-organization-roles-tuKknI1K.js +1 -0
- package/dist/client/assets/use-organization-settings-DvtBymY3.js +1 -0
- package/dist/client/assets/{use-panel-navigate-WrD0KEYx.js → use-panel-navigate-IItrbgmN.js} +1 -1
- package/dist/client/assets/use-project-native-view-presence-WwnxvZuP.js +1 -0
- package/dist/client/assets/use-project-scope-CCxyXvEU.js +1 -0
- package/dist/client/assets/use-registry-connections-Bd4wJHbx.js +1 -0
- package/dist/client/assets/use-releases-DZvNer89.js +1 -0
- package/dist/client/assets/use-reports-diagnostic-BeTEI2FZ.js +1 -0
- package/dist/client/assets/{use-route-default-main-Djaj_cL9.js → use-route-default-main-BhbKsXCz.js} +1 -1
- package/dist/client/assets/use-secrets-Bq9yyXHE.js +1 -0
- package/dist/client/assets/{use-section-preview-base-BOFovHh4.js → use-section-preview-base--XbKHK2U.js} +1 -1
- package/dist/client/assets/{use-session-runtime-BR1aW1y5.js → use-session-runtime-B5wMaHtP.js} +1 -1
- package/dist/client/assets/use-tags-Do2tDPSO.js +1 -0
- package/dist/client/assets/use-task-board-analytics-MK_Z2cUq.js +1 -0
- package/dist/client/assets/use-task-metadata-CQjLXps1.js +1 -0
- package/dist/client/assets/use-thread-outputs-DYukUH5N.js +1 -0
- package/dist/client/assets/{use-view-mode-B0LeaJg7.js → use-view-mode-BEPkb8x0.js} +1 -1
- package/dist/client/assets/use-virtual-mcp-Ji9vcgUj.js +1 -0
- package/dist/client/assets/useInfiniteQuery-CzQJkRT9.js +1 -0
- package/dist/client/assets/{useQueries-C-SV8tD7.js → useQueries-D0xhxw7a.js} +1 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-D9iG0Y5m.js +1 -0
- package/dist/client/assets/{users-BiOPZ43X.js → users-DzwkCv2F.js} +1 -1
- package/dist/client/assets/utils-y2q6u6PK.js +4 -0
- package/dist/client/assets/variant-calendar-D1R9xk7D.js +1 -0
- package/dist/client/assets/{variant-matcher-override-BFQoXu82.js → variant-matcher-override-qHzE4baz.js} +1 -1
- package/dist/client/assets/view-mode-toggle-Ca0bFull.js +1 -0
- package/dist/client/assets/{virtual-mcp-ldxphi5G.js → virtual-mcp-Dji-1ojO.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/server/cli.js +3 -3
- package/dist/server/server.js +3 -3
- package/package.json +1 -1
- package/dist/client/assets/Check-B3RSsr_D.js +0 -1
- package/dist/client/assets/ChevronRight-USKkhEpL.js +0 -1
- package/dist/client/assets/ChevronSelectorVertical-DpRb2z1l.js +0 -1
- package/dist/client/assets/Database01-C0YJpjc3.js +0 -1
- package/dist/client/assets/DotsVertical-CsjwfYzf.js +0 -1
- package/dist/client/assets/File02-BvR-HYxK.js +0 -1
- package/dist/client/assets/GitBranch01-rWb2SJK9.js +0 -1
- package/dist/client/assets/HardDrive-DNTPLPT4.js +0 -1
- package/dist/client/assets/MessageCircle01-DBcg2aiD.js +0 -1
- package/dist/client/assets/Printer-CvyxF9Jo.js +0 -1
- package/dist/client/assets/Shield01-CqB4I7qm.js +0 -1
- package/dist/client/assets/Tool01-DouqPjim.js +0 -1
- package/dist/client/assets/XClose-BgzK-Dwz.js +0 -1
- package/dist/client/assets/ZoomOut-BPxprY2s.js +0 -1
- package/dist/client/assets/add-connection-dialog-DZjTm9W3.js +0 -1
- package/dist/client/assets/agent-analytics-DmvdLg8B.js +0 -2
- package/dist/client/assets/agent-app-BvmFdS4C.js +0 -1
- package/dist/client/assets/agent-assets-czUGY90q.js +0 -1
- package/dist/client/assets/agent-automation-C5Kr5Oj3.js +0 -20
- package/dist/client/assets/agent-automations-D-3-Opoc.js +0 -1
- package/dist/client/assets/agent-connect-sources-CjhmYssY.js +0 -1
- package/dist/client/assets/agent-deck-BC5MWVm-.js +0 -1
- package/dist/client/assets/agent-e2e-DkL4Ltr6.js +0 -1
- package/dist/client/assets/agent-experiments--rXT-2aB.js +0 -1
- package/dist/client/assets/agent-file-C3XkHLMm.js +0 -1
- package/dist/client/assets/agent-hosting-DaIfm8Hu.js +0 -1
- package/dist/client/assets/agent-icon-CczrFEe7.js +0 -1
- package/dist/client/assets/agent-library-file-Dji653pU.js +0 -1
- package/dist/client/assets/agent-monitor-C-HIyaF_.js +0 -1
- package/dist/client/assets/agent-overview-cm15sxNU.js +0 -1
- package/dist/client/assets/agent-settings-XmhY1FOi.js +0 -1
- package/dist/client/assets/agent-site-editor-code-_Tz57RqE.js +0 -2
- package/dist/client/assets/agent-site-editor-content-DOAcxz0t.js +0 -2
- package/dist/client/assets/agent-site-editor-preview-mg5Q6hoW.js +0 -518
- package/dist/client/assets/agent-view-ClMILC98.js +0 -1
- package/dist/client/assets/agents-list-rKFF5b3o.js +0 -1
- package/dist/client/assets/anchors-yqDzZN4K.js +0 -1
- package/dist/client/assets/api-keys-AIfL76r6.js +0 -1
- package/dist/client/assets/api-keys-B6ry5Bc6.js +0 -1
- package/dist/client/assets/app-editor-BZKFeBmU.js +0 -1
- package/dist/client/assets/asset-utils-DhbLEVKo.js +0 -1
- package/dist/client/assets/auth-entry-CwWjlqGu.js +0 -1
- package/dist/client/assets/automation-list-row-Btr-Kty6.js +0 -1
- package/dist/client/assets/automation-runs-CnOOOwZJ.js +0 -1
- package/dist/client/assets/automations-CtLmB1Eo.js +0 -1
- package/dist/client/assets/badge-Bu51Hlti.js +0 -1
- package/dist/client/assets/block-document-BLCekKXO.js +0 -3
- package/dist/client/assets/breadcrumb-Dhdru7Jh.js +0 -1
- package/dist/client/assets/build-improve-prompt-doc-Cedp3vV1.js +0 -2
- package/dist/client/assets/bulk-category-panel-D3c_qJDk.js +0 -1
- package/dist/client/assets/calendar-DIQx67oO.js +0 -1
- package/dist/client/assets/capability-load-error-CJMvYDf4.js +0 -1
- package/dist/client/assets/cards-BVw8sRdW.js +0 -8
- package/dist/client/assets/category-editor-C7sRrVfl.js +0 -1
- package/dist/client/assets/checkbox-jLf7fBuW.js +0 -1
- package/dist/client/assets/choose-editor-Cbu3-nVC.js +0 -1
- package/dist/client/assets/collapsible-CTgXdVQa.js +0 -1
- package/dist/client/assets/collection-detail-BF7WM7Gn.js +0 -1
- package/dist/client/assets/collection-display-button-C-4xB6xx.js +0 -1
- package/dist/client/assets/collection-tabs-CrXIJeNf.js +0 -1
- package/dist/client/assets/combobox-BHrqHmge.js +0 -1
- package/dist/client/assets/command-B-XD29Nx.js +0 -1
- package/dist/client/assets/command-palette-store-DK-56E2K.js +0 -1
- package/dist/client/assets/connect-D4qCE3TM.js +0 -8
- package/dist/client/assets/connect-layout-DGO84ImO.js +0 -1
- package/dist/client/assets/connection-card-fcMCwbTh.js +0 -1
- package/dist/client/assets/connection-detail-DS015J4e.js +0 -1
- package/dist/client/assets/connections-C98FMYyY.js +0 -1
- package/dist/client/assets/dialog-llvhXw2o.js +0 -1
- package/dist/client/assets/discover-DNPHmIfF.js +0 -1
- package/dist/client/assets/domain-settings-CXxEmIjB.js +0 -1
- package/dist/client/assets/download-app-dialog-D_4eQbbs.js +0 -1
- package/dist/client/assets/dropdown-menu-C5iafa8S.js +0 -1
- package/dist/client/assets/feature-paywall-DEy2mpV2.js +0 -1
- package/dist/client/assets/file-explorer-Bs7B2-rr.js +0 -2
- package/dist/client/assets/file-share-button-Dk1ugrdV.js +0 -3
- package/dist/client/assets/general-BYFfG0fF.js +0 -1
- package/dist/client/assets/home-DTaaCW3K.js +0 -1
- package/dist/client/assets/index-2eKztu7k.js +0 -5
- package/dist/client/assets/index-BH7uCYoT.js +0 -1
- package/dist/client/assets/index-CSd_k8Np.js +0 -1
- package/dist/client/assets/index-CiMUXLco.js +0 -26
- package/dist/client/assets/index-CpNTsElB.css +0 -1
- package/dist/client/assets/index-D4RUT3q0.js +0 -1
- package/dist/client/assets/index-D_X-LIyA.js +0 -1
- package/dist/client/assets/index-Dc7hzqoi.js +0 -235
- package/dist/client/assets/infra-billing-D6jrbNxA.js +0 -1
- package/dist/client/assets/input-DXlaTX4w.js +0 -1
- package/dist/client/assets/input-D_FfvHr0.js +0 -8
- package/dist/client/assets/input-uIV5S_EX.js +0 -1
- package/dist/client/assets/layout-Dli4i2a0.js +0 -1
- package/dist/client/assets/legacy-agents-deep-CoiLV3QJ.js +0 -1
- package/dist/client/assets/legacy-main-redirect-BZ4nzqkQ.js +0 -1
- package/dist/client/assets/library-Dste3SFA.js +0 -161
- package/dist/client/assets/members-CRtKrUle.js +0 -1
- package/dist/client/assets/message-templates-B8kOo0Kk.js +0 -1
- package/dist/client/assets/mock-board-DRa60E6i.js +0 -90
- package/dist/client/assets/multi-select-DzAZ8Rb8.js +0 -1
- package/dist/client/assets/optimistic-project-sidebar-views-CrZ9OeIk.js +0 -1
- package/dist/client/assets/orgs-B1TBklWZ.js +0 -1
- package/dist/client/assets/plan-ladder-B2pv9Y73.js +0 -1
- package/dist/client/assets/post-calendar-Bx8YiCbs.js +0 -1
- package/dist/client/assets/post-editor-B1fD7o8C.js +0 -1
- package/dist/client/assets/primitives-JiGRyPkw.js +0 -1
- package/dist/client/assets/profile-CDR0JVtv.js +0 -1
- package/dist/client/assets/project-app-view-8VWdrWMf.js +0 -1
- package/dist/client/assets/project-feed-ChJRKxhk.js +0 -1
- package/dist/client/assets/project-reports-D31utlHg.js +0 -1
- package/dist/client/assets/project-tasks-D2AAgqxo.js +0 -1
- package/dist/client/assets/record-editor-DPAL8Tq5.js +0 -1
- package/dist/client/assets/redirect-editor-EPs_GX-_.js +0 -1
- package/dist/client/assets/registry-Dw8UrRRZ.js +0 -2
- package/dist/client/assets/registry-layout-CC2lewiS.js +0 -27
- package/dist/client/assets/reports-Ch9UvBcS.js +0 -1
- package/dist/client/assets/reports-onboarding-Dhm8IBuD.js +0 -1
- package/dist/client/assets/reports-tab-BJWrZp37.js +0 -2
- package/dist/client/assets/repositories-CMIGVJwC.js +0 -1
- package/dist/client/assets/repository-import-picker-DhVniDI2.js +0 -1
- package/dist/client/assets/repository-picker-BkoSI-jm.js +0 -1
- package/dist/client/assets/resizable-Bt7dvMCc.js +0 -1
- package/dist/client/assets/review-settings-Cx_Yzx40.js +0 -1
- package/dist/client/assets/roles-BNleKwt9.js +0 -1
- package/dist/client/assets/route-CHqG9ihd.js +0 -1
- package/dist/client/assets/route-DqJoK5dW.js +0 -1
- package/dist/client/assets/route-x8jgkj5T.js +0 -1
- package/dist/client/assets/runnable-block-editor-xmOnaiFL.js +0 -16
- package/dist/client/assets/search-input-Pobww52G.js +0 -1
- package/dist/client/assets/secrets-BF5nuoR4.js +0 -1
- package/dist/client/assets/sections-editor-B1LpXw4X.js +0 -2
- package/dist/client/assets/select-BkKPcZFe.js +0 -1
- package/dist/client/assets/select-model-DPv-zVVj.js +0 -1
- package/dist/client/assets/seo-editor-9G7mQFJ5.js +0 -1
- package/dist/client/assets/settings-tab-D1V5Uszb.js +0 -5
- package/dist/client/assets/shell-layout-Ce0aCJuX.js +0 -1
- package/dist/client/assets/sidebar-C5KRz1Pj.js +0 -1
- package/dist/client/assets/skills-CgTiBPyO.js +0 -1
- package/dist/client/assets/sso-BK-aRT5P.js +0 -1
- package/dist/client/assets/store-Nm6KtwbD.js +0 -1
- package/dist/client/assets/store-registry-Cs6bPPkP.js +0 -2
- package/dist/client/assets/synced-repos-B1z4DDCt.js +0 -1
- package/dist/client/assets/task-route-BCTCy27Q.js +0 -1
- package/dist/client/assets/task-status-DhCT2ly_.js +0 -1
- package/dist/client/assets/taskboard-analytics-Cf1r1f7I.js +0 -1
- package/dist/client/assets/tasks-BNvHI7hJ.js +0 -1
- package/dist/client/assets/textarea-BU6xemAP.js +0 -1
- package/dist/client/assets/thread-route-BBf64Mwk.js +0 -1
- package/dist/client/assets/thread-route-BSYRqZDg.js +0 -1
- package/dist/client/assets/thread-sheet-body-B4OUWlMn.js +0 -1
- package/dist/client/assets/toggle-group-BiU_UDOq.js +0 -1
- package/dist/client/assets/toolbar-icon-button-PuQFE8Y9.js +0 -1
- package/dist/client/assets/usage-stats-vMRDbAUM.js +0 -1
- package/dist/client/assets/use-ai-providers-BnF5Rw_n.js +0 -1
- package/dist/client/assets/use-automations-Bo0S3g8m.js +0 -1
- package/dist/client/assets/use-connect-companion-CClQCUMS.js +0 -1
- package/dist/client/assets/use-connection-Ba04fHwa.js +0 -1
- package/dist/client/assets/use-deco-credits-BGBshlLi.js +0 -1
- package/dist/client/assets/use-delete-connection-Cns6x8UC.js +0 -1
- package/dist/client/assets/use-file-configs-DYGSdjth.js +0 -1
- package/dist/client/assets/use-join-requests-DjeVFQr9.js +0 -1
- package/dist/client/assets/use-main-panel-tabs-sSRGo66A.js +0 -1
- package/dist/client/assets/use-mcp-auth-status-I377R0Kg.js +0 -1
- package/dist/client/assets/use-members-DPYHJDe2.js +0 -1
- package/dist/client/assets/use-navigate-to-agent-C8pu0B4z.js +0 -1
- package/dist/client/assets/use-open-billing-url-Df7K1DCF.js +0 -1
- package/dist/client/assets/use-org-auth-client-DbPU3bA-.js +0 -1
- package/dist/client/assets/use-org-fs-Du-ErRPs.js +0 -1
- package/dist/client/assets/use-org-notice-CyiiFkRG.js +0 -1
- package/dist/client/assets/use-organization-roles-FAEtbpE5.js +0 -1
- package/dist/client/assets/use-organization-settings-CKbX2SdA.js +0 -1
- package/dist/client/assets/use-project-native-view-presence-DWzPH-Sc.js +0 -1
- package/dist/client/assets/use-project-scope-DU0-JxYr.js +0 -1
- package/dist/client/assets/use-registry-connections-SLFMHpqj.js +0 -1
- package/dist/client/assets/use-releases-CFNTwgY3.js +0 -1
- package/dist/client/assets/use-reports-diagnostic-8BvW2in8.js +0 -1
- package/dist/client/assets/use-secrets-DVry--sz.js +0 -1
- package/dist/client/assets/use-tags-CZXCbbwL.js +0 -1
- package/dist/client/assets/use-task-board-analytics-Ci1AhxvH.js +0 -1
- package/dist/client/assets/use-task-metadata-Dt9l5S_a.js +0 -1
- package/dist/client/assets/use-thread-outputs-Dq-RN0P_.js +0 -1
- package/dist/client/assets/use-virtual-mcp-DkK7ErtB.js +0 -1
- package/dist/client/assets/useInfiniteQuery-CspLjV7h.js +0 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-BiQYAhJn.js +0 -1
- package/dist/client/assets/utils-DsvmRe8M.js +0 -4
- package/dist/client/assets/variant-calendar-DImnsJnP.js +0 -1
- package/dist/client/assets/view-mode-toggle-DvGhnpsV.js +0 -1
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/route-Bdqr734y.js","assets/index-EcuFIS2a.js","assets/index-BOHOyAF8.css","assets/AlertCircle-2L7lI8NL.js","assets/LayoutLeft-BfySK4h8.js","assets/sidebar-CoC2_Nad.js","assets/use-mobile-BZ15DgEB.js","assets/sheet-DWSThpSZ.js","assets/X-BtMi8Qau.js","assets/tooltip-nr5oS_bm.js","assets/index-Exw_Yjch.js","assets/toolbar-icon-button-ChZE-2zp.js","assets/index-CutV0Ygc.js","assets/ArrowUp-BtksDHBQ.js","assets/chat-context-ELO8A2Ar.js","assets/use-panel-navigate-IItrbgmN.js","assets/thread-route-CHwqHPf_.js","assets/use-project-scope-CCxyXvEU.js","assets/use-virtual-mcp-Ji9vcgUj.js","assets/use-mcp-client-B_gcvvCy.js","assets/auth-BBW3DF0r.js","assets/github-repo-BknN0SVI.js","assets/autosend-CVNOmzPu.js","assets/thread-intent-CTSjhfEo.js","assets/slugify-CEUa2lfQ.js","assets/hooks-D0dDgrIf.js","assets/backoff-8mStPHYB.js","assets/task-board-Dip4Wu9j.js","assets/schema-FDf70VFI.js","assets/use-is-desktop-app-BNujXJc_.js","assets/use-entitlements-kPr6KRf9.js","assets/use-ai-providers-D-abiIwe.js","assets/location-oTTXFrSF.js","assets/use-decopilot-events-qaEKsixC.js","assets/use-organization-settings-DvtBymY3.js","assets/gateway-client-CnYYocwu.js","assets/dialog-AoC07APJ.js","assets/drawer-DGzquxJ8.js","assets/collection-search-DM8MkJfo.js","assets/SearchMd-Bb5gjLcX.js","assets/use-mcp-prompts-DfSKL4Gu.js","assets/index-DyCAAYSx.js","assets/form-CYsJTpNM.js","assets/label-BX1BwzZ4.js","assets/input-Buz_7xoG.js","assets/utils-CVEq3hMx.js","assets/org-file-open-context-D26BTBiX.js","assets/input-BrPa4I3Z.js","assets/shell-layout-BQnbNNla.js","assets/avatar-BzRNaDEk.js","assets/User01-DHd46PZp.js","assets/Globe04-GFiRExL0.js","assets/SearchLg-DFD1t2UL.js","assets/agent-icon-CTsmTxHg.js","assets/Tool01-Dwy1nlT9.js","assets/ArrowLeft-8rouBEwC.js","assets/Tool02-CvlAGFBM.js","assets/ArrowRight-DCA5zjxW.js","assets/TrendUp01-BCriuXJd.js","assets/ZoomOut-DUFJq3-K.js","assets/CheckCircle-BmVuh1xp.js","assets/ChevronUp-fg9sod-H.js","assets/UserSquare-CcF49LHs.js","assets/Copy01-BgwuTJFm.js","assets/CreditCard01-CIt471eG.js","assets/DotsVertical-CE2o6L6N.js","assets/Download01-DNhEQzg0.js","assets/Settings02-D9Qv7BDm.js","assets/Eye-Dq6Vw6FI.js","assets/Share07-CZ7JzYs9.js","assets/Globe01-g_y8gAs1.js","assets/XClose-CvcHLHe2.js","assets/Image01-QB6twEDu.js","assets/Key01-CO_i2QPb.js","assets/Link01-BIFMl_M0.js","assets/LinkExternal01-DQD59o7F.js","assets/Monitor01-Ddm2yOG6.js","assets/Sun-DLRcOzSd.js","assets/Package-CvzEol5_.js","assets/Palette-DT856bn6.js","assets/Play-wYDcJhBq.js","assets/Plus-BSp00qOC.js","assets/Stars01-D-wYuyik.js","assets/Trash01-DtE0n00a.js","assets/Upload01-Ba-RLxE1.js","assets/Users01-B8gdz27Y.js","assets/XCircle-BLCHBIhx.js","assets/Zap-DZAIluO6.js","assets/download-app-dialog-CsiIuf7j.js","assets/command-CZcxzTcw.js","assets/index-C97O3ClY.js","assets/integration-icon-D3FHJbYu.js","assets/project-icon-D_oHwik9.js","assets/required-auth-layout-BhdxJMdb.js","assets/use-org-sso-QeqdMaIa.js","assets/shell-layout-CE2Eihra.css","assets/chat-draft-tDfZTlxU.js","assets/use-session-runtime-B5wMaHtP.js","assets/select-DBfOOW9i.js","assets/usage-stats-YafP0g9G.js","assets/use-copy-Cp_DyXH6.js","assets/markdown-VKlC4_bJ.js","assets/format-time-BtXRrtv4.js","assets/differenceInSeconds-C3x8sHUj.js","assets/tabs-Dd0IWElc.js","assets/use-deco-credits-CqbkXgA9.js","assets/toggle-group-CwAn2mKr.js","assets/tool-namespace-DmnQIdtF.js","assets/use-open-billing-url-BAg3ZeFq.js","assets/decopilot-BI8eOOPY.js","assets/checkbox-iGlb02v9.js","assets/ai-providers-logos-DD3qZ33J.js","assets/popover-Bff85VlI.js","assets/index-DllcfiZL.js","assets/input-C5klQNJJ.js","assets/hooks-BlE0QZwR.js","assets/use-org-fs-Bf6n51Xm.js","assets/question-004-sINsf4GQ.js","assets/use-members-C6brpkJ1.js","assets/use-org-auth-client-8fDIgHEZ.js","assets/feature-paywall-BoABVlUQ.js","assets/plan-ladder-B-hb17ya.js","assets/add-connection-dialog-DA05asFs.js","assets/extract-connection-data-C7Wh9xkI.js","assets/metadata-dUsYcpuu.js","assets/github-D4UJ99TO.js","assets/connection-DStV2sLP.js","assets/connection-card-CpIJKLp3.js","assets/use-registry-connections-Bd4wJHbx.js","assets/use-connection-BKZRi94S.js","assets/useInfiniteQuery-CzQJkRT9.js","assets/infiniteQueryObserver-3RxH1tr-.js","assets/retry-i8LvYSZg.js","assets/connection-slug-CITJ0kGN.js","assets/textarea-D5v3ol7T.js","assets/connection-form-helpers-DM_wSOEJ.js","assets/authenticate-and-persist-oauth-Pk9b2m8R.js","assets/mcp-oauth-B7YJNr4N.js","assets/collection-tabs-aKKPIP9M.js","assets/badge-C5M6nZd4.js","assets/use-infinite-scroll-D0T36z_V.js","assets/useSuspenseInfiniteQuery-D9iG0Y5m.js","assets/pair-Bh73YYpe.js","assets/collapsible-PyJ2NOzW.js","assets/content-blocks-o63cs2vh.js","assets/mcp-app-renderer-wS7imsel.js","assets/types-7UQ7SDxU.js","assets/omit-sandbox-map-jj4lCB2U.js","assets/use-navigate-to-agent-B8SXI0oO.js","assets/use-thread-outputs-DYukUH5N.js","assets/file-type-icon-lZW2ows7.js","assets/decofile-api-zRlIvvNL.js","assets/use-releases-DZvNer89.js","assets/serial-task-queue-CGOeQgpr.js","assets/sandbox-lifecycle-context-BHn9YFEW.js","assets/sandbox-url-D3mC8qhT.js","assets/sandbox-start-errors-BK_aDCyt.js","assets/empty-state-Y08kvU5o.js","assets/thread-button-C3YUAV-G.js","assets/use-route-default-main-BhbKsXCz.js","assets/use-in-settings-BCDqA2EC.js","assets/index-DKXWNSdB.js","assets/resizable-wU1MiASn.js","assets/route-page-header-DKm5kHtX.js","assets/alert-dialog-9n2p5SCQ.js","assets/task-status-k7EGfTLN.js","assets/use-main-panel-tabs-BghanH6r.js","assets/use-mcp-tools-DC47roTz.js","assets/use-task-metadata-CQjLXps1.js","assets/use-project-native-view-presence-WwnxvZuP.js","assets/match-site-slug-config-D3fUJ6vX.js","assets/use-file-configs-6ygOocDG.js","assets/site-slug-uya6Wp4-.js","assets/virtual-mcp-Dji-1ojO.js","assets/legacy-main-redirect-BDaODIKZ.js","assets/preview-dialog-DY1kQ4y_.js","assets/preview-content-C4FuOpTi.js","assets/file-preview-iaqpqUYi.js","assets/utils-y2q6u6PK.js","assets/editor-oL1B7LVJ.js","assets/file-share-button-D0lT5ixf.js","assets/blocks-preview-workspace-context-DAFMxzU6.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{c as $,j as a,b as J,r as W,B as ke,l as F,aC as rl,F as Ke,H as We,aD as Ri,I as Ge,a9 as Ct,a0 as Qe,f as xl,u as zi,h as yt,c2 as xc,d as oa,L as kc,eP as bc,eQ as yc,m as xr,K as ft,aO as Ei,t as Je,$ as Ii,a6 as Ut,o as $r,e as fr,z as jc,G as Ce,aM as ca,aN as pr,a as Li,Z as Mi,aH as kl,aw as vc,n as Ft,R as wc,an as Dr,aP as ar,aJ as Sc,x as Pi,N as Pa,P as Cc,aR as ir,aS as or,aT as cr,q as Fa,au as Nc,T as Tc,eR as Bc,E as _c,eS as Ac}from"./index-EcuFIS2a.js";import{Q as xt,M as ll,v as $c,f as Dc,X as Rc,Y as zc,_ as Ec,x as Ic,aL as Lc,aH as Mc,aM as da,aN as Pc,aO as Fc,w as Fi,d as al,aP as Oc,aQ as Oa,e as Oi,B as sl,ap as ua,a8 as bl,aR as Hc,n as qc}from"./agent-icon-CTsmTxHg.js";import{i as kr}from"./CheckCircle-BmVuh1xp.js";import{i as Hi}from"./XClose-CvcHLHe2.js";import{s as ts}from"./Plus-BSp00qOC.js";import{i as Ht}from"./X-BtMi8Qau.js";import{A as Fe}from"./avatar-BzRNaDEk.js";import{c as Uc,b as Kc,f as Wc,g as Gc,a as Vc,D as Qc}from"./drawer-DGzquxJ8.js";import{a as gt,b as kt,P as bt,c as Yc}from"./popover-Bff85VlI.js";import{T as qi,a as Ui,c as Ki}from"./tooltip-nr5oS_bm.js";import{a as et,e as ls,C as as,b as He,c as is,d as os,g as Wi}from"./command-CZcxzTcw.js";import{t as Kt}from"./ChevronUp-fg9sod-H.js";import{i as fa}from"./Tool02-CvlAGFBM.js";import{s as Gi}from"./TrendUp01-BCriuXJd.js";import{a as Vi}from"./Settings02-D9Qv7BDm.js";import{s as ss}from"./User01-DHd46PZp.js";import{E as yl,m as Rr,U as mr,e as Le,P as br,n as il,D as Qi,o as qt,k as Nr,N as gr,S as Ve,b as Zc,s as Yi,t as Zi,q as Xi,r as Ji,v as Zl,l as Tr,w as eo,f as Ot,T as to,x as Xc,y as Jc,z as ed,A as td,B as ha,C as sd,u as nd,F as rd,a as Ha,G as so,H as ld,L as Xl,I as ad,J as id,i as od,c as cd,K as dd,M as ud,O as qa,Q as fd,R as hd}from"./task-route-SKFoAFiU.js";import{G as pd}from"./github-icon-swNUSpAU.js";import{P as md}from"./project-icon-D_oHwik9.js";import{g as Oe}from"./get-initials-D-f_fDFw.js";import{S as ye,R as gd,e as xd,C as kd,D as bd,i as Jl,n as yd,f as jd}from"./task-board-Dip4Wu9j.js";import{T as ct,n as vd,i as wd,a as Sd,b as Ua,K as Cd,P as Nd,d as Td,D as Bd,f as _d,g as Ad,s as $d,e as Dd,S as Rd,v as zd,u as Ed,C as Id}from"./rich-text-link-control-Bn-QsIS6.js";import{u as no}from"./use-task-board-analytics-MK_Z2cUq.js";import{C as Ld}from"./combobox-CQBdlQef.js";import{S as Md}from"./search-toggle-CCC7TvwN.js";import{R as Pd}from"./repository-import-picker-ftg0FRzY.js";import{a as pa}from"./use-members-C6brpkJ1.js";import{a as ma}from"./format-time-BtXRrtv4.js";import{u as ga,a as Fd,b as Od}from"./use-tags-Do2tDPSO.js";import{a as xa,g as ro}from"./use-organization-settings-DvtBymY3.js";import{B as Hd,a as qd,b as Ka,c as Ud,d as Kd,e as Wd}from"./breadcrumb-0yy48vm9.js";import{d as ol,b as cl,D as dl,h as lo,c as ao,e as io}from"./dialog-AoC07APJ.js";import{C as ka}from"./calendar-QcX36iLy.js";import{I as Jt}from"./icon-button-7c--Wy5B.js";import{A as Wa,a as Gd,b as Vd}from"./alert-C8o4-kn8.js";import{C as Qd,a as Yd,b as Zd}from"./collapsible-PyJ2NOzW.js";import{u as Wl}from"./use-copy-Cp_DyXH6.js";import{i as ns}from"./AlertCircle-2L7lI8NL.js";import{i as oo,b as Xd}from"./UserSquare-CcF49LHs.js";import{a as Jd}from"./Copy01-BgwuTJFm.js";import{i as ea}from"./Globe01-g_y8gAs1.js";import{n as Br}from"./LinkExternal01-DQD59o7F.js";import{m as eu,a as tu,M as co}from"./markdown-VKlC4_bJ.js";import{a as su,E as ba,r as wt,t as nu,v as ru,w as uo,x as Zt,y as Ga,z as lu,A as au,B as Va,C as iu,G as _r,N as cs,m as Nt,H as ul,T as fo,R as ya,I as ja,h as ou,J as cu,K as du,L as uu,O as fu,Q as hu,s as ho,S as pu,u as po,b as mo,U as mu,c as gu}from"./index-DyCAAYSx.js";import{B as xu,c as ku,t as bu,C as go,f as yu,g as Qa,s as ju,m as Ya,a as Za,b as vu,d as Xa,e as wu,h as Su,i as Cu,j as Nu,k as Tu,l as Bu,n as _u}from"./index-DGY2nhhI.js";import{i as Au}from"./Link01-BIFMl_M0.js";import{s as $u}from"./Trash01-DtE0n00a.js";import{c as Du,e as xo,s as ko}from"./hooks-BlE0QZwR.js";import{n as Ru}from"./Download01-DNhEQzg0.js";import{i as zu}from"./ZoomOut-DUFJq3-K.js";import{u as Eu}from"./use-org-auth-client-8fDIgHEZ.js";import{h as Iu,b as Lu}from"./use-org-fs-Bf6n51Xm.js";import{d as Mu,S as Ja}from"./sandbox-start-errors-BK_aDCyt.js";import{p as Pu,r as Fu,u as bo,G as Ou}from"./repository-picker-BKj90hIS.js";import{i as Hu,c as qu}from"./hooks-D0dDgrIf.js";import{u as yo}from"./use-connection-BKZRi94S.js";import{e as Uu,b as Ku}from"./use-virtual-mcp-Ji9vcgUj.js";import{s as Wu}from"./use-project-scope-CCxyXvEU.js";import{l as Gu}from"./github-repo-scope-C8GSbvaz.js";import{c as Vu,S as Qu,a as Yu,b as Zu}from"./sheet-DWSThpSZ.js";import{T as Xu}from"./thread-sheet-body-Hqh1hVbj.js";import{u as Ju}from"./use-mcp-client-B_gcvvCy.js";import{i as ef}from"./ArrowUp-BtksDHBQ.js";import{i as tf}from"./Tool01-Dwy1nlT9.js";import{u as sf}from"./use-open-billing-url-BAg3ZeFq.js";import{s as nf,w as rf}from"./chat-draft-tDfZTlxU.js";import{B as lf}from"./badge-C5M6nZd4.js";import{S as ta}from"./separator-8fswVHAH.js";import{a as af}from"./shell-layout-BQnbNNla.js";const of={github:"pull",gitlab:"-/merge_requests",bitbucket:"pull-requests"};function cf(t,e){return`${Fu(t)}/${of[t.provider]}/${e}`}const df=[{re:/https?:\/\/([^/\s"']+)\/([^\s"']+?)\/-\/merge_requests\/(\d+)/},{re:/https?:\/\/([^/\s"']+)\/([^/\s"']+\/[^/\s"']+)\/pull\/(\d+)/},{re:/https?:\/\/([^/\s"']+)\/([^/\s"']+\/[^/\s"']+)\/pull-requests\/(\d+)/},{re:/https?:\/\/([^/\s"']+)\/repos\/([^/\s"']+\/[^/\s"']+)\/pulls\/(\d+)/,api:!0},{re:/https?:\/\/([^/\s"']+)\/api\/v4\/projects\/([^/\s"']+)\/merge_requests\/(\d+)/,api:!0},{re:/https?:\/\/([^/\s"']+)\/2\.0\/repositories\/([^/\s"']+\/[^/\s"']+)\/pullrequests\/(\d+)/,api:!0}],uf={"api.github.com":"github.com","api.bitbucket.org":"bitbucket.org"};function ff(t){const e=t.toLowerCase();return uf[e]??e}function hf(t,e){const s=Number(t[3]);if(!Number.isSafeInteger(s)||s<=0)return null;const n=ff(t[1]),r=t[2],l=e?decodeURIComponent(r):r;if(/^\d+$/.test(l))return null;const i=Pu(`https://${n}/${l}`);return i?{repo:i,number:s,url:cf(i,s)}:null}function pf(t){const e=t.trim();if(!e)return null;for(const{re:s,api:n}of df){const r=s.exec(e),l=r?hf(r,n===!0):null;if(l)return l}return null}function jo(t){return t?.projects.length===1?t.projects[0]:void 0}function mf(t){return jo(t)?t.repo:t.projects.length>1?t.projects.map(e=>e.title).join(", "):null}function es(t){const e=$.c(6),{entry:s}=t;let n;e[0]!==s?(n=jo(s),e[0]=s,e[1]=n):n=e[1];const r=n;if(r){let i;return e[2]!==r.icon||e[3]!==r.title?(i=a.jsx(md,{icon:r.icon,name:r.title}),e[2]=r.icon,e[3]=r.title,e[4]=i):i=e[4],i}let l;return e[5]===Symbol.for("react.memo_cache_sentinel")?(l=a.jsx("span",{className:"flex size-4 shrink-0 items-center justify-center",children:a.jsx(pd,{className:"size-3"})}),e[5]=l):l=e[5],l}function va(t){const e=$.c(14),{entry:s}=t;let n;e[0]!==s?(n=mf(s),e[0]=s,e[1]=n):n=e[1];const r=n;let l;e[2]!==s?(l=a.jsx(es,{entry:s}),e[2]=s,e[3]=l):l=e[3];let i;e[4]!==s.title?(i=a.jsx("span",{className:"truncate",children:s.title}),e[4]=s.title,e[5]=i):i=e[5];let c;e[6]!==r?(c=r&&a.jsx("span",{className:"truncate text-xs text-muted-foreground",children:r}),e[6]=r,e[7]=c):c=e[7];let o;e[8]!==i||e[9]!==c?(o=a.jsxs("span",{className:"flex min-w-0 flex-1 flex-col",children:[i,c]}),e[8]=i,e[9]=c,e[10]=o):o=e[10];let d;return e[11]!==l||e[12]!==o?(d=a.jsxs(a.Fragment,{children:[l,o]}),e[11]=l,e[12]=o,e[13]=d):d=e[13],d}const hr="__any__";function gf(t,e){return t.assignee!==null||t.priority!==null||t.due!==null||t.tags.length>0||Rr(t.project,e)||t.search.trim()!==""}function xf(t,e){return(t.assignee!==null?1:0)+(t.priority!==null?1:0)+(t.due!==null?1:0)+(t.tags.length>0?1:0)+(Rr(t.project,e)?1:0)+(t.search.trim()!==""?1:0)}function ds(t,e=!1){return F("inline-flex h-8 items-center gap-1.5 rounded-lg border px-2.5 text-xs font-medium outline-none transition-colors focus-visible:border-ring focus-visible:ring-[2px] focus-visible:ring-ring/20",e&&"h-10 w-full justify-start px-3 text-sm",t?"border-transparent bg-accent text-foreground":"border-border text-muted-foreground hover:bg-muted/60 hover:text-foreground")}function kf(t){const e=$.c(107),{value:s,members:n,onChange:r,block:l}=t,i=J(),[c,o]=W.useState(!1);let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=a.jsx(ss,{size:14,className:"shrink-0"}),e[0]=d):d=e[0];let u=d,f;e[1]!==i?(f=i("taskBoard.taskFilters.assigneeLabel"),e[1]=i,e[2]=f):f=e[2];let h=f;if(s===mr){let R;e[3]!==i?(R=i("taskBoard.taskFilters.assigneeUnassigned"),e[3]=i,e[4]=R):R=e[4],h=R}else if(s===ye){let R;e[5]===Symbol.for("react.memo_cache_sentinel")?(R=a.jsx(Ve,{size:14}),e[5]=R):R=e[5],u=R;let O;e[6]!==i?(O=i("taskBoard.taskFilters.assigneeSuperAgent"),e[6]=i,e[7]=O):O=e[7],h=O}else if(s){let R,O,fe,de;if(e[8]!==n||e[9]!==s){let le;e[14]!==s?(le=xe=>xe.userId===s,e[14]=s,e[15]=le):le=e[15],O=n.find(le),R=Fe,fe=O?.user?.image??void 0,de=Oe(O?.user?.name),e[8]=n,e[9]=s,e[10]=R,e[11]=O,e[12]=fe,e[13]=de}else R=e[10],O=e[11],fe=e[12],de=e[13];let be;e[16]!==R||e[17]!==fe||e[18]!==de?(be=a.jsx(R,{url:fe,fallback:de,shape:"circle",size:"2xs"}),e[16]=R,e[17]=fe,e[18]=de,e[19]=be):be=e[19],u=be;let Ne;e[20]!==O?.user?.name||e[21]!==i?(Ne=O?.user?.name??i("taskBoard.taskFilters.assigneeMember"),e[20]=O?.user?.name,e[21]=i,e[22]=Ne):Ne=e[22],h=Ne}let x;e[23]!==r?(x=R=>{r(R),o(!1)},e[23]=r,e[24]=x):x=e[24];const m=x,g=s!==null;let k;e[25]!==l||e[26]!==g?(k=ds(g,l),e[25]=l,e[26]=g,e[27]=k):k=e[27];const y=k,v=l&&"ml-auto";let p;e[28]!==v?(p=F("shrink-0 opacity-60",v),e[28]=v,e[29]=p):p=e[29];const b=p;let j;e[30]!==h?(j=a.jsx("span",{className:"max-w-[10rem] truncate",children:h}),e[30]=h,e[31]=j):j=e[31];let w;e[32]!==b?(w=a.jsx(Kt,{size:12,className:b}),e[32]=b,e[33]=w):w=e[33];let S;e[34]!==u||e[35]!==j||e[36]!==w||e[37]!==y?(S=a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:y,children:[u,j,w]})}),e[34]=u,e[35]=j,e[36]=w,e[37]=y,e[38]=S):S=e[38];let C;e[39]!==i?(C=i("taskBoard.taskFilters.assigneeFilterPlaceholder"),e[39]=i,e[40]=C):C=e[40];let T;e[41]!==i?(T=i("taskBoard.taskFilters.assigneeFilterPlaceholder"),e[41]=i,e[42]=T):T=e[42];let N;e[43]!==C||e[44]!==T?(N=a.jsx(ls,{placeholder:C,"aria-label":T,className:"h-9"}),e[43]=C,e[44]=T,e[45]=N):N=e[45];let _;e[46]!==i?(_=i("taskBoard.taskFilters.assigneeNoMembersFound"),e[46]=i,e[47]=_):_=e[47];let D;e[48]!==_?(D=a.jsx(as,{children:_}),e[48]=_,e[49]=D):D=e[49];let A;e[50]!==i?(A=i("taskBoard.taskFilters.assigneeAnyone"),e[50]=i,e[51]=A):A=e[51];let L;e[52]!==m?(L=()=>m(null),e[52]=m,e[53]=L):L=e[53];let z;e[54]!==i?(z=i("taskBoard.taskFilters.assigneeAnyone"),e[54]=i,e[55]=z):z=e[55];let P;e[56]!==A||e[57]!==L||e[58]!==z?(P=a.jsx(He,{value:A,onSelect:L,children:z}),e[56]=A,e[57]=L,e[58]=z,e[59]=P):P=e[59];let E;e[60]!==i?(E=i("taskBoard.taskFilters.assigneeUnassigned"),e[60]=i,e[61]=E):E=e[61];let I;e[62]!==m?(I=()=>m(mr),e[62]=m,e[63]=I):I=e[63];let V;e[64]===Symbol.for("react.memo_cache_sentinel")?(V=a.jsx(ss,{size:16,className:"text-muted-foreground"}),e[64]=V):V=e[64];let Q;e[65]!==i?(Q=i("taskBoard.taskFilters.assigneeUnassigned"),e[65]=i,e[66]=Q):Q=e[66];let Y;e[67]!==E||e[68]!==I||e[69]!==Q?(Y=a.jsxs(He,{value:E,onSelect:I,className:"gap-2",children:[V,Q]}),e[67]=E,e[68]=I,e[69]=Q,e[70]=Y):Y=e[70];let se;e[71]!==i?(se=i("taskBoard.taskFilters.assigneeSuperAgent"),e[71]=i,e[72]=se):se=e[72];let H;e[73]!==m?(H=()=>m(ye),e[73]=m,e[74]=H):H=e[74];let ee;e[75]===Symbol.for("react.memo_cache_sentinel")?(ee=a.jsx(Ve,{size:16}),e[75]=ee):ee=e[75];let q;e[76]!==i?(q=i("taskBoard.taskFilters.assigneeSuperAgent"),e[76]=i,e[77]=q):q=e[77];let Z;e[78]!==se||e[79]!==H||e[80]!==q?(Z=a.jsxs(He,{value:se,onSelect:H,className:"gap-2",children:[ee,q]}),e[78]=se,e[79]=H,e[80]=q,e[81]=Z):Z=e[81];let X;e[82]!==P||e[83]!==Y||e[84]!==Z?(X=a.jsxs(et,{children:[P,Y,Z]}),e[82]=P,e[83]=Y,e[84]=Z,e[85]=X):X=e[85];let re;e[86]!==i?(re=i("taskBoard.taskFilters.assigneeGroupMembers"),e[86]=i,e[87]=re):re=e[87];let G;if(e[88]!==n||e[89]!==m){let R;e[91]!==m?(R=O=>a.jsxs(He,{value:O.user?.name??O.userId,onSelect:()=>m(O.userId),className:"gap-2",children:[a.jsx(Fe,{url:O.user?.image??void 0,fallback:Oe(O.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate",children:O.user?.name??O.userId})]},O.userId),e[91]=m,e[92]=R):R=e[92],G=n.map(R),e[88]=n,e[89]=m,e[90]=G}else G=e[90];let ne;e[93]!==re||e[94]!==G?(ne=a.jsx(et,{heading:re,children:G}),e[93]=re,e[94]=G,e[95]=ne):ne=e[95];let ce;e[96]!==D||e[97]!==X||e[98]!==ne?(ce=a.jsxs(is,{children:[D,X,ne]}),e[96]=D,e[97]=X,e[98]=ne,e[99]=ce):ce=e[99];let ue;e[100]!==N||e[101]!==ce?(ue=a.jsx(kt,{align:"start",className:"w-56 p-0",children:a.jsxs(os,{children:[N,ce]})}),e[100]=N,e[101]=ce,e[102]=ue):ue=e[102];let oe;return e[103]!==c||e[104]!==S||e[105]!==ue?(oe=a.jsxs(bt,{open:c,onOpenChange:o,children:[S,ue]}),e[103]=c,e[104]=S,e[105]=ue,e[106]=oe):oe=e[106],oe}function bf(t){const e=$.c(33),{value:s,onChange:n,block:r}=t,l=J(),i=s!==null;let c;e[0]!==r||e[1]!==i?(c=ds(i,r),e[0]=r,e[1]=i,e[2]=c):c=e[2];const o=c,d=r&&"ml-auto";let u;e[3]!==d?(u=F("shrink-0 opacity-60",d),e[3]=d,e[4]=u):u=e[4];const f=u;let h;e[5]!==s?(h=s?a.jsx("span",{className:F("size-2 shrink-0 rounded-full",Le[s].dotClassName)}):a.jsx(Gi,{size:14,className:"shrink-0"}),e[5]=s,e[6]=h):h=e[6];let x;e[7]!==l||e[8]!==s?(x=l(s?Le[s].labelKey:"taskBoard.taskFilters.priorityLabel"),e[7]=l,e[8]=s,e[9]=x):x=e[9];let m;e[10]!==f?(m=a.jsx(Kt,{size:12,className:f}),e[10]=f,e[11]=m):m=e[11];let g;e[12]!==h||e[13]!==x||e[14]!==m||e[15]!==o?(g=a.jsx(Ke,{asChild:!0,children:a.jsxs("button",{type:"button",className:o,children:[h,x,m]})}),e[12]=h,e[13]=x,e[14]=m,e[15]=o,e[16]=g):g=e[16];const k=s??hr;let y;e[17]!==n?(y=S=>n(S===hr?null:S),e[17]=n,e[18]=y):y=e[18];let v;e[19]!==l?(v=l("taskBoard.taskFilters.priorityAnyPriority"),e[19]=l,e[20]=v):v=e[20];let p;e[21]!==v?(p=a.jsx(rl,{value:hr,children:v}),e[21]=v,e[22]=p):p=e[22];let b;e[23]!==l?(b=br.map(S=>a.jsxs(rl,{value:S,className:"gap-2",children:[a.jsx("span",{className:F("size-2 rounded-full",Le[S].dotClassName)}),l(Le[S].labelKey)]},S)),e[23]=l,e[24]=b):b=e[24];let j;e[25]!==y||e[26]!==p||e[27]!==b||e[28]!==k?(j=a.jsx(We,{align:"start",className:"w-40",children:a.jsxs(Ri,{value:k,onValueChange:y,children:[p,b]})}),e[25]=y,e[26]=p,e[27]=b,e[28]=k,e[29]=j):j=e[29];let w;return e[30]!==j||e[31]!==g?(w=a.jsxs(Ge,{children:[g,j]}),e[30]=j,e[31]=g,e[32]=w):w=e[32],w}function yf(t){const e=$.c(35),{value:s,onChange:n,block:r}=t,l=J();let i;e[0]!==l||e[1]!==s?(i=s?l(il(s)):void 0,e[0]=l,e[1]=s,e[2]=i):i=e[2];const c=i,o=s!==null;let d;e[3]!==r||e[4]!==o?(d=ds(o,r),e[3]=r,e[4]=o,e[5]=d):d=e[5];const u=d,f=r&&"ml-auto";let h;e[6]!==f?(h=F("shrink-0 opacity-60",f),e[6]=f,e[7]=h):h=e[7];const x=h;let m;e[8]===Symbol.for("react.memo_cache_sentinel")?(m=a.jsx(xt,{size:14,className:"shrink-0"}),e[8]=m):m=e[8];let g;e[9]!==c||e[10]!==l?(g=c??l("taskBoard.taskFilters.dueDateLabel"),e[9]=c,e[10]=l,e[11]=g):g=e[11];let k;e[12]!==x?(k=a.jsx(Kt,{size:12,className:x}),e[12]=x,e[13]=k):k=e[13];let y;e[14]!==g||e[15]!==k||e[16]!==u?(y=a.jsx(Ke,{asChild:!0,children:a.jsxs("button",{type:"button",className:u,children:[m,g,k]})}),e[14]=g,e[15]=k,e[16]=u,e[17]=y):y=e[17];const v=s??hr;let p;e[18]!==n?(p=N=>n(N===hr?null:N),e[18]=n,e[19]=p):p=e[19];let b;e[20]===Symbol.for("react.memo_cache_sentinel")?(b=a.jsx(xt,{size:16,className:"text-muted-foreground"}),e[20]=b):b=e[20];let j;e[21]!==l?(j=l("taskBoard.taskFilters.dueDateAnyTime"),e[21]=l,e[22]=j):j=e[22];let w;e[23]!==j?(w=a.jsxs(rl,{value:hr,className:"gap-2",children:[b,j]}),e[23]=j,e[24]=w):w=e[24];let S;e[25]!==l?(S=Qi.map(N=>{const _=N==="overdue";return a.jsxs(rl,{value:N,className:F("gap-2",_&&"text-destructive"),children:[a.jsx(xt,{size:16,className:F("shrink-0",_?"text-destructive":"text-muted-foreground")}),l(il(N))]},N)}),e[25]=l,e[26]=S):S=e[26];let C;e[27]!==v||e[28]!==p||e[29]!==w||e[30]!==S?(C=a.jsx(We,{align:"start",className:"w-44",children:a.jsxs(Ri,{value:v,onValueChange:p,children:[w,S]})}),e[27]=v,e[28]=p,e[29]=w,e[30]=S,e[31]=C):C=e[31];let T;return e[32]!==C||e[33]!==y?(T=a.jsxs(Ge,{children:[y,C]}),e[32]=C,e[33]=y,e[34]=T):T=e[34],T}function jf(t){const e=$.c(56),{value:s,tags:n,onChange:r,block:l}=t,i=J(),[c,o]=W.useState(!1);let d;e[0]!==r||e[1]!==s?(d=E=>r(s.includes(E)?s.filter(I=>I!==E):[...s,E]),e[0]=r,e[1]=s,e[2]=d):d=e[2];const u=d;let f;e[3]!==i||e[4]!==n||e[5]!==s[0]||e[6]!==s.length?(f=s.length===0?i("taskBoard.taskFilters.tagsLabel"):s.length===1?n.find(E=>E.id===s[0])?.name??i("taskBoard.taskFilters.tagsLabel"):i("taskBoard.taskFilters.tagsSelectedCount",{count:s.length}),e[3]=i,e[4]=n,e[5]=s[0],e[6]=s.length,e[7]=f):f=e[7];const h=f,x=s.length>0;let m;e[8]!==l||e[9]!==x?(m=ds(x,l),e[8]=l,e[9]=x,e[10]=m):m=e[10];const g=m,k=l&&"ml-auto";let y;e[11]!==k?(y=F("shrink-0 opacity-60",k),e[11]=k,e[12]=y):y=e[12];const v=y;let p;e[13]!==n||e[14]!==s[0]||e[15]!==s.length?(p=s.length===1?a.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:qt(n.find(E=>E.id===s[0])?.color)}}):a.jsx(ll,{size:14,className:"shrink-0"}),e[13]=n,e[14]=s[0],e[15]=s.length,e[16]=p):p=e[16];let b;e[17]!==h?(b=a.jsx("span",{className:"max-w-[10rem] truncate",children:h}),e[17]=h,e[18]=b):b=e[18];let j;e[19]!==v?(j=a.jsx(Kt,{size:12,className:v}),e[19]=v,e[20]=j):j=e[20];let w;e[21]!==p||e[22]!==b||e[23]!==j||e[24]!==g?(w=a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:g,children:[p,b,j]})}),e[21]=p,e[22]=b,e[23]=j,e[24]=g,e[25]=w):w=e[25];let S;e[26]!==i?(S=i("taskBoard.taskFilters.tagsFilterPlaceholder"),e[26]=i,e[27]=S):S=e[27];let C;e[28]!==i?(C=i("taskBoard.taskFilters.tagsFilterPlaceholder"),e[28]=i,e[29]=C):C=e[29];let T;e[30]!==S||e[31]!==C?(T=a.jsx(ls,{placeholder:S,"aria-label":C,className:"h-9"}),e[30]=S,e[31]=C,e[32]=T):T=e[32];let N;e[33]!==i?(N=i("taskBoard.taskFilters.tagsNoTagsFound"),e[33]=i,e[34]=N):N=e[34];let _;e[35]!==N?(_=a.jsx(as,{children:N}),e[35]=N,e[36]=_):_=e[36];let D;if(e[37]!==n||e[38]!==u||e[39]!==s){let E;e[41]!==u||e[42]!==s?(E=I=>a.jsxs(He,{value:I.name,onSelect:()=>u(I.id),className:"gap-2",children:[a.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:qt(I.color)}}),a.jsx("span",{className:"flex-1 truncate",children:I.name}),s.includes(I.id)&&a.jsx(Ct,{size:14,className:"shrink-0 text-foreground"})]},I.id),e[41]=u,e[42]=s,e[43]=E):E=e[43],D=n.map(E),e[37]=n,e[38]=u,e[39]=s,e[40]=D}else D=e[40];let A;e[44]!==D?(A=a.jsx(et,{children:D}),e[44]=D,e[45]=A):A=e[45];let L;e[46]!==_||e[47]!==A?(L=a.jsxs(is,{children:[_,A]}),e[46]=_,e[47]=A,e[48]=L):L=e[48];let z;e[49]!==T||e[50]!==L?(z=a.jsx(kt,{align:"start",className:"w-56 p-0",children:a.jsxs(os,{children:[T,L]})}),e[49]=T,e[50]=L,e[51]=z):z=e[51];let P;return e[52]!==c||e[53]!==w||e[54]!==z?(P=a.jsxs(bt,{open:c,onOpenChange:o,children:[w,z]}),e[52]=c,e[53]=w,e[54]=z,e[55]=P):P=e[55],P}function ei(t){const e=$.c(11),{entry:s,selected:n,onSelect:r}=t,l=s.id,i=s.title;let c;e[0]!==s.projects?(c=s.projects.map(vf).join(" "),e[0]=s.projects,e[1]=c):c=e[1];const o=`${l} ${i} ${s.repo??""} ${c}`;let d;e[2]!==s?(d=a.jsx(va,{entry:s}),e[2]=s,e[3]=d):d=e[3];let u;e[4]!==n?(u=n&&a.jsx(Ct,{size:14,className:"shrink-0 text-foreground"}),e[4]=n,e[5]=u):u=e[5];let f;return e[6]!==r||e[7]!==o||e[8]!==d||e[9]!==u?(f=a.jsxs(He,{value:o,onSelect:r,className:"gap-2",children:[d,u]}),e[6]=r,e[7]=o,e[8]=d,e[9]=u,e[10]=f):f=e[10],f}function vf(t){return t.title}function wf(t,e,s,n){return t===null||!s?n("taskBoard.taskFilters.projectLabel"):t===gr?n("taskBoard.taskFilters.projectNone"):e?.title??t}function Sf(t){const e=$.c(90),{value:s,index:n,onChange:r,block:l}=t,i=J(),[c,o]=W.useState(!1);let d,u,f,h,x,m,g,k,y,v,p,b,j,w;if(e[0]!==l||e[1]!==n||e[2]!==r||e[3]!==c||e[4]!==i||e[5]!==s){const _=s===null?void 0:Nr(s,n),D=Rr(s,n),A=wf(s,_,D,i);let L;e[20]!==r?(L=de=>{r(de),o(!1)},e[20]=r,e[21]=L):L=e[21];const z=L,P=n.entries.filter(Nf),E=n.entries.filter(Cf),I=ds(D,l),V=l&&"ml-auto";let Q;e[22]!==V?(Q=F("shrink-0 opacity-60",V),e[22]=V,e[23]=Q):Q=e[23];const Y=Q;h=bt,j=c,w=o;const se=D?_:void 0;let H;e[24]!==se?(H=a.jsx(es,{entry:se}),e[24]=se,e[25]=H):H=e[25];let ee;e[26]!==A?(ee=a.jsx("span",{className:"max-w-[12rem] truncate",children:A}),e[26]=A,e[27]=ee):ee=e[27];let q;e[28]!==Y?(q=a.jsx(Kt,{size:12,className:Y}),e[28]=Y,e[29]=q):q=e[29],e[30]!==H||e[31]!==ee||e[32]!==q||e[33]!==I?(m=a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:I,children:[H,ee,q]})}),e[30]=H,e[31]=ee,e[32]=q,e[33]=I,e[34]=m):m=e[34],f=kt,p="start",b="w-72 p-0",u=os;let Z;e[35]!==i?(Z=i("taskBoard.taskFilters.projectFilterPlaceholder"),e[35]=i,e[36]=Z):Z=e[36];let X;e[37]!==i?(X=i("taskBoard.taskFilters.projectFilterPlaceholder"),e[37]=i,e[38]=X):X=e[38],e[39]!==Z||e[40]!==X?(v=a.jsx(ls,{placeholder:Z,"aria-label":X,className:"h-9"}),e[39]=Z,e[40]=X,e[41]=v):v=e[41],d=is;let re;e[42]!==i?(re=i("taskBoard.taskFilters.projectNoneFound"),e[42]=i,e[43]=re):re=e[43],e[44]!==re?(x=a.jsx(as,{children:re}),e[44]=re,e[45]=x):x=e[45];let G;e[46]!==i?(G=i("taskBoard.taskFilters.projectAny"),e[46]=i,e[47]=G):G=e[47];let ne;e[48]!==z?(ne=()=>z(null),e[48]=z,e[49]=ne):ne=e[49];let ce;e[50]!==i?(ce=i("taskBoard.taskFilters.projectAny"),e[50]=i,e[51]=ce):ce=e[51];let ue;e[52]!==G||e[53]!==ne||e[54]!==ce?(ue=a.jsx(He,{value:G,onSelect:ne,children:ce}),e[52]=G,e[53]=ne,e[54]=ce,e[55]=ue):ue=e[55];let oe;e[56]!==i?(oe=i("taskBoard.taskFilters.projectNone"),e[56]=i,e[57]=oe):oe=e[57];let R;e[58]!==z?(R=()=>z(gr),e[58]=z,e[59]=R):R=e[59];let O;e[60]!==i?(O=i("taskBoard.taskFilters.projectNone"),e[60]=i,e[61]=O):O=e[61];let fe;e[62]!==oe||e[63]!==R||e[64]!==O?(fe=a.jsx(He,{value:oe,onSelect:R,children:O}),e[62]=oe,e[63]=R,e[64]=O,e[65]=fe):fe=e[65],e[66]!==ue||e[67]!==fe?(g=a.jsxs(et,{children:[ue,fe]}),e[66]=ue,e[67]=fe,e[68]=g):g=e[68],k=P.length>0&&a.jsx(et,{heading:i("taskBoard.taskFilters.projectGroupProjects"),children:P.map(de=>a.jsx(ei,{entry:de,selected:_===de,onSelect:()=>z(de.id)},de.id))}),y=E.length>0&&a.jsx(et,{heading:i("taskBoard.taskFilters.projectGroupRepos"),children:E.map(de=>a.jsx(ei,{entry:de,selected:_===de,onSelect:()=>z(de.id)},de.id))}),e[0]=l,e[1]=n,e[2]=r,e[3]=c,e[4]=i,e[5]=s,e[6]=d,e[7]=u,e[8]=f,e[9]=h,e[10]=x,e[11]=m,e[12]=g,e[13]=k,e[14]=y,e[15]=v,e[16]=p,e[17]=b,e[18]=j,e[19]=w}else d=e[6],u=e[7],f=e[8],h=e[9],x=e[10],m=e[11],g=e[12],k=e[13],y=e[14],v=e[15],p=e[16],b=e[17],j=e[18],w=e[19];let S;e[69]!==d||e[70]!==x||e[71]!==g||e[72]!==k||e[73]!==y?(S=a.jsxs(d,{children:[x,g,k,y]}),e[69]=d,e[70]=x,e[71]=g,e[72]=k,e[73]=y,e[74]=S):S=e[74];let C;e[75]!==u||e[76]!==S||e[77]!==v?(C=a.jsxs(u,{children:[v,S]}),e[75]=u,e[76]=S,e[77]=v,e[78]=C):C=e[78];let T;e[79]!==f||e[80]!==C||e[81]!==p||e[82]!==b?(T=a.jsx(f,{align:p,className:b,children:C}),e[79]=f,e[80]=C,e[81]=p,e[82]=b,e[83]=T):T=e[83];let N;return e[84]!==h||e[85]!==m||e[86]!==T||e[87]!==j||e[88]!==w?(N=a.jsxs(h,{open:j,onOpenChange:w,children:[m,T]}),e[84]=h,e[85]=m,e[86]=T,e[87]=j,e[88]=w,e[89]=N):N=e[89],N}function Cf(t){return t.projects.length===0}function Nf(t){return t.projects.length>0}function Tf(t){const e=$.c(25),{value:s,onChange:n,block:r}=t,l=J(),[i,c]=W.useState(s!==""),[o,d]=W.useState(!1),[u,f]=W.useState(s);s!==u&&(f(s),s===""&&!o&&c(!1));const h=i||r,x=h?"w-32 sm:w-44":"w-8 px-0 justify-center",m=r&&"h-10 w-full px-3 text-sm sm:w-full";let g;e[0]!==x||e[1]!==m?(g=F("inline-flex h-8 shrink-0 items-center gap-1.5 overflow-hidden rounded-lg border border-border px-2.5 text-xs text-foreground transition-all duration-200 ease-out",x,m),e[0]=x,e[1]=m,e[2]=g):g=e[2];let k;e[3]!==l?(k=l("taskBoard.taskFilters.searchLabel"),e[3]=l,e[4]=k):k=e[4];let y;e[5]===Symbol.for("react.memo_cache_sentinel")?(y=()=>c(!0),e[5]=y):y=e[5];let v;e[6]===Symbol.for("react.memo_cache_sentinel")?(v=a.jsx($c,{size:14}),e[6]=v):v=e[6];let p;e[7]!==k?(p=a.jsx("button",{type:"button","aria-label":k,onClick:y,className:"shrink-0 text-muted-foreground transition-colors hover:text-foreground",children:v}),e[7]=k,e[8]=p):p=e[8];let b;e[9]!==r||e[10]!==h||e[11]!==n||e[12]!==l||e[13]!==s?(b=h&&a.jsx("input",{autoFocus:!r,value:s,onChange:S=>n(S.target.value),onFocus:()=>d(!0),onBlur:()=>{d(!1),s===""&&c(!1)},placeholder:l("taskBoard.taskFilters.searchPlaceholder"),"aria-label":l("taskBoard.taskFilters.searchPlaceholder"),className:"w-full min-w-0 bg-transparent text-xs outline-none placeholder:text-muted-foreground"}),e[9]=r,e[10]=h,e[11]=n,e[12]=l,e[13]=s,e[14]=b):b=e[14];let j;e[15]!==r||e[16]!==n||e[17]!==l||e[18]!==s?(j=s!==""&&a.jsx("button",{type:"button","aria-label":l("taskBoard.taskFilters.searchClearLabel"),onMouseDown:Bf,onClick:()=>{n(""),r||c(!1)},className:"shrink-0 text-muted-foreground hover:text-foreground",children:a.jsx(Ht,{size:14})}),e[15]=r,e[16]=n,e[17]=l,e[18]=s,e[19]=j):j=e[19];let w;return e[20]!==g||e[21]!==p||e[22]!==b||e[23]!==j?(w=a.jsxs("div",{className:g,children:[p,b,j]}),e[20]=g,e[21]=p,e[22]=b,e[23]=j,e[24]=w):w=e[24],w}function Bf(t){return t.preventDefault()}function _f(t){const e=$.c(20),{block:s,onClick:n}=t,r=J();let l;e[0]!==r?(l=r("taskBoard.taskFilters.boardSettingsLabel"),e[0]=r,e[1]=l):l=e[1];const i=l;let c;e[2]!==s?(c=F(ds(!1,s),s?"h-10 w-full":"w-8 justify-center px-0"),e[2]=s,e[3]=c):c=e[3];let o;e[4]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(Vi,{size:14,className:"shrink-0"}),e[4]=o):o=e[4];let d;e[5]!==s||e[6]!==i?(d=s&&a.jsx("span",{children:i}),e[5]=s,e[6]=i,e[7]=d):d=e[7];let u;e[8]!==i||e[9]!==n||e[10]!==c||e[11]!==d?(u=a.jsxs("button",{type:"button",onClick:n,"aria-label":i,className:c,children:[o,d]}),e[8]=i,e[9]=n,e[10]=c,e[11]=d,e[12]=u):u=e[12];const f=u;if(s)return f;let h;e[13]!==f?(h=a.jsx(qi,{asChild:!0,children:f}),e[13]=f,e[14]=h):h=e[14];let x;e[15]!==i?(x=a.jsx(Ui,{side:"top",children:i}),e[15]=i,e[16]=x):x=e[16];let m;return e[17]!==h||e[18]!==x?(m=a.jsxs(Ki,{children:[h,x]}),e[17]=h,e[18]=x,e[19]=m):m=e[19],m}function vo(t){const e=$.c(53),{filters:s,members:n,tags:r,index:l,onChange:i,onOpenBoardSettings:c,block:o}=t;let d;e[0]!==s||e[1]!==i?(d=w=>i({...s,search:w}),e[0]=s,e[1]=i,e[2]=d):d=e[2];let u;e[3]!==o||e[4]!==s.search||e[5]!==d?(u=a.jsx(Tf,{block:o,value:s.search,onChange:d}),e[3]=o,e[4]=s.search,e[5]=d,e[6]=u):u=e[6];let f;e[7]!==s||e[8]!==i?(f=w=>i({...s,assignee:w}),e[7]=s,e[8]=i,e[9]=f):f=e[9];let h;e[10]!==o||e[11]!==s.assignee||e[12]!==n||e[13]!==f?(h=a.jsx(kf,{block:o,value:s.assignee,members:n,onChange:f}),e[10]=o,e[11]=s.assignee,e[12]=n,e[13]=f,e[14]=h):h=e[14];let x;e[15]!==s||e[16]!==i?(x=w=>i({...s,priority:w}),e[15]=s,e[16]=i,e[17]=x):x=e[17];let m;e[18]!==o||e[19]!==s.priority||e[20]!==x?(m=a.jsx(bf,{block:o,value:s.priority,onChange:x}),e[18]=o,e[19]=s.priority,e[20]=x,e[21]=m):m=e[21];let g;e[22]!==s||e[23]!==i?(g=w=>i({...s,due:w}),e[22]=s,e[23]=i,e[24]=g):g=e[24];let k;e[25]!==o||e[26]!==s.due||e[27]!==g?(k=a.jsx(yf,{block:o,value:s.due,onChange:g}),e[25]=o,e[26]=s.due,e[27]=g,e[28]=k):k=e[28];let y;e[29]!==s||e[30]!==i?(y=w=>i({...s,tags:w}),e[29]=s,e[30]=i,e[31]=y):y=e[31];let v;e[32]!==o||e[33]!==s.tags||e[34]!==y||e[35]!==r?(v=a.jsx(jf,{block:o,value:s.tags,tags:r,onChange:y}),e[32]=o,e[33]=s.tags,e[34]=y,e[35]=r,e[36]=v):v=e[36];let p;e[37]!==o||e[38]!==s||e[39]!==l||e[40]!==i?(p=(l.entries.length>0||Rr(s.project,l))&&a.jsx(Sf,{block:o,value:s.project,index:l,onChange:w=>i({...s,project:w})}),e[37]=o,e[38]=s,e[39]=l,e[40]=i,e[41]=p):p=e[41];let b;e[42]!==o||e[43]!==c?(b=a.jsx(_f,{block:o,onClick:c}),e[42]=o,e[43]=c,e[44]=b):b=e[44];let j;return e[45]!==v||e[46]!==p||e[47]!==b||e[48]!==u||e[49]!==h||e[50]!==m||e[51]!==k?(j=a.jsxs(a.Fragment,{children:[u,h,m,k,v,p,b]}),e[45]=v,e[46]=p,e[47]=b,e[48]=u,e[49]=h,e[50]=m,e[51]=k,e[52]=j):j=e[52],j}function Af(t){const e=$.c(16),{filters:s,members:n,tags:r,index:l,onChange:i,onOpenBoardSettings:c}=t,o=J();let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=a.jsx(fa,{size:16,className:"mr-0.5 shrink-0 text-muted-foreground"}),e[0]=d):d=e[0];let u;e[1]!==s||e[2]!==l||e[3]!==n||e[4]!==i||e[5]!==c||e[6]!==r?(u=a.jsx(vo,{filters:s,members:n,tags:r,index:l,onChange:i,onOpenBoardSettings:c}),e[1]=s,e[2]=l,e[3]=n,e[4]=i,e[5]=c,e[6]=r,e[7]=u):u=e[7];let f;e[8]!==s||e[9]!==l||e[10]!==i||e[11]!==o?(f=gf(s,l)&&a.jsx("button",{type:"button",onClick:()=>i(yl),className:"ml-1 text-xs font-medium text-muted-foreground transition-colors hover:text-foreground",children:o("taskBoard.taskFilters.clearButton")}),e[8]=s,e[9]=l,e[10]=i,e[11]=o,e[12]=f):f=e[12];let h;return e[13]!==u||e[14]!==f?(h=a.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[d,u,f]}),e[13]=u,e[14]=f,e[15]=h):h=e[15],h}function $f(t){const e=$.c(41),{filters:s,members:n,tags:r,index:l,onChange:i,onOpenBoardSettings:c}=t,o=J(),[d,u]=W.useState(!1),f=xf(s,l),h=f>0;let x;e[0]!==h?(x=ds(h),e[0]=h,e[1]=x):x=e[1];const m=x;let g;e[2]===Symbol.for("react.memo_cache_sentinel")?(g=a.jsx(fa,{size:14,className:"shrink-0"}),e[2]=g):g=e[2];let k;e[3]!==o?(k=o("taskBoard.taskFilters.filterDrawerButtonLabel"),e[3]=o,e[4]=k):k=e[4];let y;e[5]!==f?(y=f>0&&a.jsx("span",{className:"ml-0.5 flex size-4 items-center justify-center rounded-full bg-foreground text-[10px] font-semibold text-background",children:f}),e[5]=f,e[6]=y):y=e[6];let v;e[7]!==k||e[8]!==y||e[9]!==m?(v=a.jsx(Uc,{asChild:!0,children:a.jsxs("button",{type:"button",className:m,children:[g,k,y]})}),e[7]=k,e[8]=y,e[9]=m,e[10]=v):v=e[10];let p;e[11]!==o?(p=o("taskBoard.taskFilters.filterDrawerTitle"),e[11]=o,e[12]=p):p=e[12];let b;e[13]!==p?(b=a.jsx(Kc,{className:"px-4 pt-4 text-base font-medium text-foreground",children:p}),e[13]=p,e[14]=b):b=e[14];let j;e[15]!==s||e[16]!==l||e[17]!==n||e[18]!==i||e[19]!==c||e[20]!==r?(j=a.jsx("div",{className:"flex flex-col gap-2 p-4",children:a.jsx(vo,{block:!0,filters:s,members:n,tags:r,index:l,onChange:i,onOpenBoardSettings:c})}),e[15]=s,e[16]=l,e[17]=n,e[18]=i,e[19]=c,e[20]=r,e[21]=j):j=e[21];let w;e[22]!==f||e[23]!==i||e[24]!==o?(w=f>0&&a.jsx(ke,{variant:"outline",className:"flex-1",onClick:()=>i(yl),children:o("taskBoard.taskFilters.clearAllButton")}),e[22]=f,e[23]=i,e[24]=o,e[25]=w):w=e[25];let S;e[26]!==o?(S=o("taskBoard.taskFilters.doneButton"),e[26]=o,e[27]=S):S=e[27];let C;e[28]!==S?(C=a.jsx(Wc,{asChild:!0,children:a.jsx(ke,{className:"flex-1",children:S})}),e[28]=S,e[29]=C):C=e[29];let T;e[30]!==w||e[31]!==C?(T=a.jsxs(Gc,{className:"flex-row gap-2",children:[w,C]}),e[30]=w,e[31]=C,e[32]=T):T=e[32];let N;e[33]!==T||e[34]!==b||e[35]!==j?(N=a.jsxs(Vc,{className:"p-0",children:[b,j,T]}),e[33]=T,e[34]=b,e[35]=j,e[36]=N):N=e[36];let _;return e[37]!==d||e[38]!==N||e[39]!==v?(_=a.jsxs(Qc,{open:d,onOpenChange:u,direction:"bottom",children:[v,N]}),e[37]=d,e[38]=N,e[39]=v,e[40]=_):_=e[40],_}function wa(){const t=$.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={strict:!1},t[0]=e):e=t[0];const s=xl(e).org;let n;t[1]===Symbol.for("react.memo_cache_sentinel")?(n={strict:!1},t[1]=n):n=t[1];const{boardOrg:r}=zi(n);return r&&r!==s?r:null}function Df(t){const e=$.c(12),{children:s}=t,{project:n}=Qe(),r=wa(),{data:l,isLoading:i}=no();if(!r)return s;if(i){let f;return e[0]===Symbol.for("react.memo_cache_sentinel")?(f=a.jsx("div",{className:"flex h-full items-center justify-center",children:a.jsx(yt,{className:"size-5 text-muted-foreground"})}),e[0]=f):f=e[0],f}let c;e[1]!==l?.orgs||e[2]!==r?(c=l?.orgs.find(f=>f.slug===r),e[1]=l?.orgs,e[2]=r,e[3]=c):c=e[3];const o=c;if(!o)return s;let d;e[4]!==o.id||e[5]!==o.name||e[6]!==o.slug?(d={id:o.id,name:o.name,slug:o.slug,logo:null},e[4]=o.id,e[5]=o.name,e[6]=o.slug,e[7]=d):d=e[7];let u;return e[8]!==s||e[9]!==n||e[10]!==d?(u=a.jsx(xc,{org:d,project:n,children:s}),e[8]=s,e[9]=n,e[10]=d,e[11]=u):u=e[11],u}function ti(){const t=$.c(5),e=J(),s=wa();if(!s)return null;let n;t[0]!==e||t[1]!==s?(n=e("taskBoard.analytics.bannerBoard",{org:s}),t[0]=e,t[1]=s,t[2]=n):n=t[2];let r;return t[3]!==n?(r=a.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:n}),t[3]=n,t[4]=r):r=t[4],r}function si(){const t=$.c(38),e=J(),s=oa(),n=xl({strict:!1}).org??"",r=wa(),{data:l}=no();if(!l?.isTaskBoardAdmin)return null;let i;t[0]!==e?(i=e("taskBoard.analytics.orgCurrent"),t[0]=e,t[1]=i):i=t[1];let c;t[2]!==n||t[3]!==i?(c={value:n,label:i},t[2]=n,t[3]=i,t[4]=c):c=t[4];let o;if(t[5]!==l.orgs||t[6]!==n||t[7]!==c){let j;t[9]!==n?(j=w=>w.slug!==n,t[9]=n,t[10]=j):j=t[10],o=[c,...l.orgs.filter(j).map(Rf)],t[5]=l.orgs,t[6]=n,t[7]=c,t[8]=o}else o=t[8];const d=o,u=r??n;let f;t[11]!==s||t[12]!==n?(f=j=>s({to:".",search:w=>({...w,boardOrg:j===n?void 0:j}),replace:!0}),t[11]=s,t[12]=n,t[13]=f):f=t[13];let h;t[14]!==e?(h=e("taskBoard.analytics.orgPickerPlaceholder"),t[14]=e,t[15]=h):h=t[15];let x;t[16]!==e?(x=e("taskBoard.analytics.orgSearch"),t[16]=e,t[17]=x):x=t[17];let m;t[18]!==e?(m=e("taskBoard.analytics.orgEmpty"),t[18]=e,t[19]=m):m=t[19];let g;t[20]!==d||t[21]!==u||t[22]!==f||t[23]!==h||t[24]!==x||t[25]!==m?(g=a.jsx(Ld,{options:d,value:u,onChange:f,width:"w-[200px]",placeholder:h,searchPlaceholder:x,emptyMessage:m}),t[20]=d,t[21]=u,t[22]=f,t[23]=h,t[24]=x,t[25]=m,t[26]=g):g=t[26];let k;t[27]!==n?(k={org:n},t[27]=n,t[28]=k):k=t[28];let y;t[29]===Symbol.for("react.memo_cache_sentinel")?(y=a.jsx(Dc,{size:16}),t[29]=y):y=t[29];let v;t[30]!==e?(v=e("taskBoard.analytics.openAnalytics"),t[30]=e,t[31]=v):v=t[31];let p;t[32]!==v||t[33]!==k?(p=a.jsx(ke,{size:"sm",variant:"outline",asChild:!0,children:a.jsxs(kc,{to:"/$org/taskboard-analytics",params:k,children:[y,v]})}),t[32]=v,t[33]=k,t[34]=p):p=t[34];let b;return t[35]!==p||t[36]!==g?(b=a.jsxs(a.Fragment,{children:[g,p]}),t[35]=p,t[36]=g,t[37]=b):b=t[37],b}function Rf(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function Sa(t){const e=$.c(11),{size:s,className:n}=t,r=s===void 0?16:s;let l;e[0]!==n?(l=F("inline-flex shrink-0 items-center justify-center rounded-full",n),e[0]=n,e[1]=l):l=e[1];let i;e[2]!==r?(i={width:r,height:r,backgroundColor:`${bc}26`},e[2]=r,e[3]=i):i=e[3];const c=r*.6,o=r*.6;let d;e[4]!==c||e[5]!==o?(d=a.jsx("img",{src:yc,alt:"Reviewer",style:{width:c,height:o}}),e[4]=c,e[5]=o,e[6]=d):d=e[6];let u;return e[7]!==l||e[8]!==i||e[9]!==d?(u=a.jsx("span",{className:l,style:i,children:d}),e[7]=l,e[8]=i,e[9]=d,e[10]=u):u=e[10],u}function zf(t){const e=$.c(30),{editor:s}=t,n=J(),[r,l]=W.useState(!1),[i,c]=W.useState(""),[o,d]=W.useState(!1);let u;e[0]!==s?(u=s.isActive("link"),e[0]=s,e[1]=u):u=e[1];const f=u;let h;e[2]!==s||e[3]!==r?(h=()=>{if(r){l(!1);return}const S=s.getAttributes("link").href;c(typeof S=="string"?S:""),d(!1),l(!0)},e[2]=s,e[3]=r,e[4]=h):h=e[4];const x=h;let m;e[5]!==s?(m=()=>{s.chain().focus().extendMarkRange("link").unsetLink().run(),l(!1)},e[5]=s,e[6]=m):m=e[6];const g=m;let k;e[7]!==i||e[8]!==s||e[9]!==g?(k=()=>{const S=vd(i);if(S===""){g();return}if(!wd(S)){d(!0);return}s.chain().focus().extendMarkRange("link").setLink({href:S}).run(),l(!1)},e[7]=i,e[8]=s,e[9]=g,e[10]=k):k=e[10];const y=k;let v;e[11]!==n?(v=n("markdownEditor.link"),e[11]=n,e[12]=v):v=e[12];let p;e[13]===Symbol.for("react.memo_cache_sentinel")?(p=a.jsx(Au,{size:14}),e[13]=p):p=e[13];let b;e[14]!==f||e[15]!==v||e[16]!==x?(b=a.jsx(ct,{active:f,label:v,onClick:x,children:p}),e[14]=f,e[15]=v,e[16]=x,e[17]=b):b=e[17];let j;e[18]!==f||e[19]!==y||e[20]!==i||e[21]!==s||e[22]!==o||e[23]!==r||e[24]!==g||e[25]!==n?(j=r&&a.jsxs("div",{className:"absolute left-0 top-full z-20 mt-1.5 flex w-64 items-center gap-0.5 rounded-md border bg-popover p-1 shadow-md",onBlur:S=>{S.currentTarget.contains(S.relatedTarget)||l(!1)},children:[a.jsx("input",{autoFocus:!0,type:"text","aria-label":n("markdownEditor.linkInputAriaLabel"),"aria-invalid":o,placeholder:n("markdownEditor.linkPlaceholder"),value:i,onChange:S=>{c(S.target.value),d(!1)},onKeyDown:S=>{S.key==="Enter"?(S.preventDefault(),y()):S.key==="Escape"&&(S.preventDefault(),l(!1),s.chain().focus().run())},className:F("h-7 min-w-0 flex-1 rounded bg-transparent px-2 text-sm text-foreground placeholder:text-muted-foreground focus:outline-none",o&&"text-destructive")}),a.jsx(ct,{active:!1,label:n("markdownEditor.linkApply"),onClick:y,children:a.jsx(Ct,{size:14})}),f&&a.jsx(ct,{active:!1,label:n("markdownEditor.linkRemove"),onClick:g,children:a.jsx($u,{size:14})})]}),e[18]=f,e[19]=y,e[20]=i,e[21]=s,e[22]=o,e[23]=r,e[24]=g,e[25]=n,e[26]=j):j=e[26];let w;return e[27]!==b||e[28]!==j?(w=a.jsxs("div",{className:"relative",children:[b,j]}),e[27]=b,e[28]=j,e[29]=w):w=e[29],w}const Gl=()=>{const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=a.jsx("div",{className:"mx-0.5 h-4 w-px bg-border"}),t[0]=e):e=t[0],e},ni=t=>{const e=$.c(2),{children:s}=t;let n;return e[0]!==s?(n=a.jsx("span",{className:"text-[11px] font-semibold leading-none",children:s}),e[0]=s,e[1]=n):n=e[1],n},wo=[1,2,3],Ef=({editor:t,state:e})=>t.isEditable&&!e.selection.empty&&!t.isActive("image")&&!t.isActive("attachment")&&!t.isActive("codeBlock");function If(t){const e=$.c(20),{editor:s}=t,n=J(),[r,l]=W.useState(null);let i;e[0]!==s?(i={editor:s,selector:Lf},e[0]=s,e[1]=i):i=e[1];const c=su(i);let o;e[2]!==n?(o=n("markdownEditor.heading1"),e[2]=n,e[3]=o):o=e[3];let d;e[4]!==n?(d=n("markdownEditor.heading2"),e[4]=n,e[5]=d):d=e[5];let u;e[6]!==n?(u=n("markdownEditor.heading3"),e[6]=n,e[7]=u):u=e[7];let f;e[8]!==o||e[9]!==d||e[10]!==u?(f={1:o,2:d,3:u},e[8]=o,e[9]=d,e[10]=u,e[11]=f):f=e[11];const h=f;let x;e[12]!==s||e[13]!==h||e[14]!==r||e[15]!==c||e[16]!==n?(x=r&&a.jsxs(xu,{editor:s,shouldShow:Ef,appendTo:r,className:"flex items-center gap-0.5 rounded-lg border border-border bg-popover p-1 shadow-md","aria-label":n("markdownEditor.toolbarAriaLabel"),children:[a.jsx(ct,{active:c.bold,label:n("markdownEditor.bold"),onClick:()=>s.chain().focus().toggleBold().run(),children:a.jsx(Rc,{size:14})}),a.jsx(ct,{active:c.italic,label:n("markdownEditor.italic"),onClick:()=>s.chain().focus().toggleItalic().run(),children:a.jsx(zc,{size:14})}),a.jsx(ct,{active:c.strike,label:n("markdownEditor.strikethrough"),onClick:()=>s.chain().focus().toggleStrike().run(),children:a.jsx(Ec,{size:14})}),a.jsx(ct,{active:c.code,label:n("markdownEditor.code"),onClick:()=>s.chain().focus().toggleCode().run(),children:a.jsx(Ic,{size:14})}),a.jsx(Gl,{}),wo.map((g,k)=>a.jsx(ct,{active:c.headings[k]??!1,label:h[g],onClick:()=>s.chain().focus().toggleHeading({level:g}).run(),children:a.jsx(ni,{children:`H${g}`})},g)),a.jsx(Gl,{}),a.jsx(ct,{active:c.bulletList,label:n("markdownEditor.bulletList"),onClick:()=>s.chain().focus().toggleBulletList().run(),children:a.jsx(Hi,{size:14})}),a.jsx(ct,{active:c.orderedList,label:n("markdownEditor.orderedList"),onClick:()=>s.chain().focus().toggleOrderedList().run(),children:a.jsx(ni,{children:"1."})}),a.jsx(ct,{active:c.blockquote,label:n("markdownEditor.quote"),onClick:()=>s.chain().focus().toggleBlockquote().run(),children:a.jsx(Lc,{size:14})}),a.jsx(Gl,{}),a.jsx(zf,{editor:s})]}),e[12]=s,e[13]=h,e[14]=r,e[15]=c,e[16]=n,e[17]=x):x=e[17];let m;return e[18]!==x?(m=a.jsx("div",{ref:l,className:"relative z-20",children:x}),e[18]=x,e[19]=m):m=e[19],m}function Lf(t){const{editor:e}=t;return{bold:e.isActive("bold"),italic:e.isActive("italic"),strike:e.isActive("strike"),code:e.isActive("code"),headings:wo.map(s=>e.isActive("heading",{level:s})),bulletList:e.isActive("bulletList"),orderedList:e.isActive("orderedList"),blockquote:e.isActive("blockquote")}}function Ca(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var us=Ca();function So(t){us=t}var Xt={exec:()=>null};function me(t,e=""){let s=typeof t=="string"?t:t.source,n={replace:(r,l)=>{let i=typeof l=="string"?l:l.source;return i=i.replace(qe.caret,"$1"),s=s.replace(r,i),n},getRegex:()=>new RegExp(s,e)};return n}var Mf=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),qe={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i"),blockquoteBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}>`)},Pf=/^(?:[ \t]*(?:\n|$))+/,Ff=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,Of=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,zr=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Hf=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Na=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,Co=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,No=me(Co).replace(/bull/g,Na).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),qf=me(Co).replace(/bull/g,Na).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),Ta=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Uf=/^[^\n]+/,Ba=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Kf=me(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Ba).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Wf=me(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Na).getRegex(),jl="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",_a=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Gf=me("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",_a).replace("tag",jl).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),To=me(Ta).replace("hr",zr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",jl).getRegex(),Vf=me(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",To).getRegex(),Aa={blockquote:Vf,code:Ff,def:Kf,fences:Of,heading:Hf,hr:zr,html:Gf,lheading:No,list:Wf,newline:Pf,paragraph:To,table:Xt,text:Uf},ri=me("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",zr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",jl).getRegex(),Qf={...Aa,lheading:qf,table:ri,paragraph:me(Ta).replace("hr",zr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",ri).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",jl).getRegex()},Yf={...Aa,html:me(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",_a).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Xt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:me(Ta).replace("hr",zr).replace("heading",` *#{1,6} *[^
|
|
3
|
+
]`).replace("lheading",No).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Zf=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Xf=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Bo=/^( {2,}|\\)\n(?!\s*$)/,Jf=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,yr=/[\p{P}\p{S}]/u,vl=/[\s\p{P}\p{S}]/u,$a=/[^\s\p{P}\p{S}]/u,eh=me(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,vl).getRegex(),_o=/(?!~)[\p{P}\p{S}]/u,th=/(?!~)[\s\p{P}\p{S}]/u,sh=/(?:[^\s\p{P}\p{S}]|~)/u,nh=me(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",Mf?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),Ao=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,rh=me(Ao,"u").replace(/punct/g,yr).getRegex(),lh=me(Ao,"u").replace(/punct/g,_o).getRegex(),$o="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",ah=me($o,"gu").replace(/notPunctSpace/g,$a).replace(/punctSpace/g,vl).replace(/punct/g,yr).getRegex(),ih=me($o,"gu").replace(/notPunctSpace/g,sh).replace(/punctSpace/g,th).replace(/punct/g,_o).getRegex(),oh=me("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,$a).replace(/punctSpace/g,vl).replace(/punct/g,yr).getRegex(),ch=me(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,yr).getRegex(),dh="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",uh=me(dh,"gu").replace(/notPunctSpace/g,$a).replace(/punctSpace/g,vl).replace(/punct/g,yr).getRegex(),fh=me(/\\(punct)/,"gu").replace(/punct/g,yr).getRegex(),hh=me(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),ph=me(_a).replace("(?:-->|$)","-->").getRegex(),mh=me("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",ph).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),fl=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/,gh=me(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label",fl).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Do=me(/^!?\[(label)\]\[(ref)\]/).replace("label",fl).replace("ref",Ba).getRegex(),Ro=me(/^!?\[(ref)\](?:\[\])?/).replace("ref",Ba).getRegex(),xh=me("reflink|nolink(?!\\()","g").replace("reflink",Do).replace("nolink",Ro).getRegex(),li=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Da={_backpedal:Xt,anyPunctuation:fh,autolink:hh,blockSkip:nh,br:Bo,code:Xf,del:Xt,delLDelim:Xt,delRDelim:Xt,emStrongLDelim:rh,emStrongRDelimAst:ah,emStrongRDelimUnd:oh,escape:Zf,link:gh,nolink:Ro,punctuation:eh,reflink:Do,reflinkSearch:xh,tag:mh,text:Jf,url:Xt},kh={...Da,link:me(/^!?\[(label)\]\((.*?)\)/).replace("label",fl).getRegex(),reflink:me(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",fl).getRegex()},sa={...Da,emStrongRDelimAst:ih,emStrongLDelim:lh,delLDelim:ch,delRDelim:uh,url:me(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",li).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:me(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",li).getRegex()},bh={...sa,br:me(Bo).replace("{2,}","*").getRegex(),text:me(sa.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Xr={normal:Aa,gfm:Qf,pedantic:Yf},vr={normal:Da,gfm:sa,breaks:bh,pedantic:kh},yh={"&":"&","<":"<",">":">",'"':""","'":"'"},ai=t=>yh[t];function mt(t,e){if(e){if(qe.escapeTest.test(t))return t.replace(qe.escapeReplace,ai)}else if(qe.escapeTestNoEncode.test(t))return t.replace(qe.escapeReplaceNoEncode,ai);return t}function ii(t){try{t=encodeURI(t).replace(qe.percentDecode,"%")}catch{return null}return t}function oi(t,e){let s=t.replace(qe.findPipe,(l,i,c)=>{let o=!1,d=i;for(;--d>=0&&c[d]==="\\";)o=!o;return o?"|":" |"}),n=s.split(qe.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;r<n.length;r++)n[r]=n[r].trim().replace(qe.slashPipe,"|");return n}function wr(t,e,s){let n=t.length;if(n===0)return"";let r=0;for(;r<n&&t.charAt(n-r-1)===e;)r++;return t.slice(0,n-r)}function jh(t,e){if(t.indexOf(e[1])===-1)return-1;let s=0;for(let n=0;n<t.length;n++)if(t[n]==="\\")n++;else if(t[n]===e[0])s++;else if(t[n]===e[1]&&(s--,s<0))return n;return s>0?-2:-1}function vh(t,e=0){let s=e,n="";for(let r of t)if(r===" "){let l=4-s%4;n+=" ".repeat(l),s+=l}else n+=r,s++;return n}function ci(t,e,s,n,r){let l=e.href,i=e.title||null,c=t[1].replace(r.other.outputLinkReplace,"$1");n.state.inLink=!0;let o={type:t[0].charAt(0)==="!"?"image":"link",raw:s,href:l,title:i,text:c,tokens:n.inlineTokens(c)};return n.state.inLink=!1,o}function wh(t,e,s){let n=t.match(s.other.indentCodeCompensation);if(n===null)return e;let r=n[1];return e.split(`
|
|
4
|
+
`).map(l=>{let i=l.match(s.other.beginningSpace);if(i===null)return l;let[c]=i;return c.length>=r.length?l.slice(r.length):l}).join(`
|
|
5
|
+
`)}var hl=class{options;rules;lexer;constructor(t){this.options=t||us}space(t){let e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){let e=this.rules.block.code.exec(t);if(e){let s=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?s:wr(s,`
|
|
6
|
+
`)}}}fences(t){let e=this.rules.block.fences.exec(t);if(e){let s=e[0],n=wh(s,e[3]||"",this.rules);return{type:"code",raw:s,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:n}}}heading(t){let e=this.rules.block.heading.exec(t);if(e){let s=e[2].trim();if(this.rules.other.endingHash.test(s)){let n=wr(s,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(s=n.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:s,tokens:this.lexer.inline(s)}}}hr(t){let e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:wr(e[0],`
|
|
7
|
+
`)}}blockquote(t){let e=this.rules.block.blockquote.exec(t);if(e){let s=wr(e[0],`
|
|
8
|
+
`).split(`
|
|
9
|
+
`),n="",r="",l=[];for(;s.length>0;){let i=!1,c=[],o;for(o=0;o<s.length;o++)if(this.rules.other.blockquoteStart.test(s[o]))c.push(s[o]),i=!0;else if(!i)c.push(s[o]);else break;s=s.slice(o);let d=c.join(`
|
|
10
|
+
`),u=d.replace(this.rules.other.blockquoteSetextReplace,`
|
|
11
|
+
$1`).replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}
|
|
12
|
+
${d}`:d,r=r?`${r}
|
|
13
|
+
${u}`:u;let f=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(u,l,!0),this.lexer.state.top=f,s.length===0)break;let h=l.at(-1);if(h?.type==="code")break;if(h?.type==="blockquote"){let x=h,m=x.raw+`
|
|
14
|
+
`+s.join(`
|
|
15
|
+
`),g=this.blockquote(m);l[l.length-1]=g,n=n.substring(0,n.length-x.raw.length)+g.raw,r=r.substring(0,r.length-x.text.length)+g.text;break}else if(h?.type==="list"){let x=h,m=x.raw+`
|
|
16
|
+
`+s.join(`
|
|
17
|
+
`),g=this.list(m);l[l.length-1]=g,n=n.substring(0,n.length-h.raw.length)+g.raw,r=r.substring(0,r.length-x.raw.length)+g.raw,s=m.substring(l.at(-1).raw.length).split(`
|
|
18
|
+
`);continue}}return{type:"blockquote",raw:n,tokens:l,text:r}}}list(t){let e=this.rules.block.list.exec(t);if(e){let s=e[1].trim(),n=s.length>1,r={type:"list",raw:"",ordered:n,start:n?+s.slice(0,-1):"",loose:!1,items:[]};s=n?`\\d{1,9}\\${s.slice(-1)}`:`\\${s}`,this.options.pedantic&&(s=n?s:"[*+-]");let l=this.rules.other.listItemRegex(s),i=!1;for(;t;){let o=!1,d="",u="";if(!(e=l.exec(t))||this.rules.block.hr.test(t))break;d=e[0],t=t.substring(d.length);let f=vh(e[2].split(`
|
|
19
|
+
`,1)[0],e[1].length),h=t.split(`
|
|
20
|
+
`,1)[0],x=!f.trim(),m=0;if(this.options.pedantic?(m=2,u=f.trimStart()):x?m=e[1].length+1:(m=f.search(this.rules.other.nonSpaceChar),m=m>4?1:m,u=f.slice(m),m+=e[1].length),x&&this.rules.other.blankLine.test(h)&&(d+=h+`
|
|
21
|
+
`,t=t.substring(h.length+1),o=!0),!o){let g=this.rules.other.nextBulletRegex(m),k=this.rules.other.hrRegex(m),y=this.rules.other.fencesBeginRegex(m),v=this.rules.other.headingBeginRegex(m),p=this.rules.other.htmlBeginRegex(m),b=this.rules.other.blockquoteBeginRegex(m);for(;t;){let j=t.split(`
|
|
22
|
+
`,1)[0],w;if(h=j,this.options.pedantic?(h=h.replace(this.rules.other.listReplaceNesting," "),w=h):w=h.replace(this.rules.other.tabCharGlobal," "),y.test(h)||v.test(h)||p.test(h)||b.test(h)||g.test(h)||k.test(h))break;if(w.search(this.rules.other.nonSpaceChar)>=m||!h.trim())u+=`
|
|
23
|
+
`+w.slice(m);else{if(x||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||y.test(f)||v.test(f)||k.test(f))break;u+=`
|
|
24
|
+
`+h}x=!h.trim(),d+=j+`
|
|
25
|
+
`,t=t.substring(j.length+1),f=w.slice(m)}}r.loose||(i?r.loose=!0:this.rules.other.doubleBlankLine.test(d)&&(i=!0)),r.items.push({type:"list_item",raw:d,task:!!this.options.gfm&&this.rules.other.listIsTask.test(u),loose:!1,text:u,tokens:[]}),r.raw+=d}let c=r.items.at(-1);if(c)c.raw=c.raw.trimEnd(),c.text=c.text.trimEnd();else return;r.raw=r.raw.trimEnd();for(let o of r.items){if(this.lexer.state.top=!1,o.tokens=this.lexer.blockTokens(o.text,[]),o.task){if(o.text=o.text.replace(this.rules.other.listReplaceTask,""),o.tokens[0]?.type==="text"||o.tokens[0]?.type==="paragraph"){o.tokens[0].raw=o.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),o.tokens[0].text=o.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let u=this.lexer.inlineQueue.length-1;u>=0;u--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[u].src)){this.lexer.inlineQueue[u].src=this.lexer.inlineQueue[u].src.replace(this.rules.other.listReplaceTask,"");break}}let d=this.rules.other.listTaskCheckbox.exec(o.raw);if(d){let u={type:"checkbox",raw:d[0]+" ",checked:d[0]!=="[ ]"};o.checked=u.checked,r.loose?o.tokens[0]&&["paragraph","text"].includes(o.tokens[0].type)&&"tokens"in o.tokens[0]&&o.tokens[0].tokens?(o.tokens[0].raw=u.raw+o.tokens[0].raw,o.tokens[0].text=u.raw+o.tokens[0].text,o.tokens[0].tokens.unshift(u)):o.tokens.unshift({type:"paragraph",raw:u.raw,text:u.raw,tokens:[u]}):o.tokens.unshift(u)}}if(!r.loose){let d=o.tokens.filter(f=>f.type==="space"),u=d.length>0&&d.some(f=>this.rules.other.anyLine.test(f.raw));r.loose=u}}if(r.loose)for(let o of r.items){o.loose=!0;for(let d of o.tokens)d.type==="text"&&(d.type="paragraph")}return r}}html(t){let e=this.rules.block.html.exec(t);if(e)return{type:"html",block:!0,raw:e[0],pre:e[1]==="pre"||e[1]==="script"||e[1]==="style",text:e[0]}}def(t){let e=this.rules.block.def.exec(t);if(e){let s=e[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=e[2]?e[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=e[3]?e[3].substring(1,e[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):e[3];return{type:"def",tag:s,raw:e[0],href:n,title:r}}}table(t){let e=this.rules.block.table.exec(t);if(!e||!this.rules.other.tableDelimiter.test(e[2]))return;let s=oi(e[1]),n=e[2].replace(this.rules.other.tableAlignChars,"").split("|"),r=e[3]?.trim()?e[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
|
26
|
+
`):[],l={type:"table",raw:e[0],header:[],align:[],rows:[]};if(s.length===n.length){for(let i of n)this.rules.other.tableAlignRight.test(i)?l.align.push("right"):this.rules.other.tableAlignCenter.test(i)?l.align.push("center"):this.rules.other.tableAlignLeft.test(i)?l.align.push("left"):l.align.push(null);for(let i=0;i<s.length;i++)l.header.push({text:s[i],tokens:this.lexer.inline(s[i]),header:!0,align:l.align[i]});for(let i of r)l.rows.push(oi(i,l.header.length).map((c,o)=>({text:c,tokens:this.lexer.inline(c),header:!1,align:l.align[o]})));return l}}lheading(t){let e=this.rules.block.lheading.exec(t);if(e){let s=e[1].trim();return{type:"heading",raw:e[0],depth:e[2].charAt(0)==="="?1:2,text:s,tokens:this.lexer.inline(s)}}}paragraph(t){let e=this.rules.block.paragraph.exec(t);if(e){let s=e[1].charAt(e[1].length-1)===`
|
|
27
|
+
`?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:s,tokens:this.lexer.inline(s)}}}text(t){let e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){let e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){let e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){let e=this.rules.inline.link.exec(t);if(e){let s=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(s)){if(!this.rules.other.endAngleBracket.test(s))return;let l=wr(s.slice(0,-1),"\\");if((s.length-l.length)%2===0)return}else{let l=jh(e[2],"()");if(l===-2)return;if(l>-1){let i=(e[0].indexOf("!")===0?5:4)+e[1].length+l;e[2]=e[2].substring(0,l),e[0]=e[0].substring(0,i).trim(),e[3]=""}}let n=e[2],r="";if(this.options.pedantic){let l=this.rules.other.pedanticHrefTitle.exec(n);l&&(n=l[1],r=l[3])}else r=e[3]?e[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(s)?n=n.slice(1):n=n.slice(1,-1)),ci(e,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:r&&r.replace(this.rules.inline.anyPunctuation,"$1")},e[0],this.lexer,this.rules)}}reflink(t,e){let s;if((s=this.rules.inline.reflink.exec(t))||(s=this.rules.inline.nolink.exec(t))){let n=(s[2]||s[1]).replace(this.rules.other.multipleSpaceGlobal," "),r=e[n.toLowerCase()];if(!r){let l=s[0].charAt(0);return{type:"text",raw:l,text:l}}return ci(s,r,s[0],this.lexer,this.rules)}}emStrong(t,e,s=""){let n=this.rules.inline.emStrongLDelim.exec(t);if(!(!n||!n[1]&&!n[2]&&!n[3]&&!n[4]||n[4]&&s.match(this.rules.other.unicodeAlphaNumeric))&&(!(n[1]||n[3])||!s||this.rules.inline.punctuation.exec(s))){let r=[...n[0]].length-1,l,i,c=r,o=0,d=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(d.lastIndex=0,e=e.slice(-1*t.length+r);(n=d.exec(e))!==null;){if(l=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!l)continue;if(i=[...l].length,n[3]||n[4]){c+=i;continue}else if((n[5]||n[6])&&r%3&&!((r+i)%3)){o+=i;continue}if(c-=i,c>0)continue;i=Math.min(i,i+c+o);let u=[...n[0]][0].length,f=t.slice(0,r+n.index+u+i);if(Math.min(r,i)%2){let x=f.slice(1,-1);return{type:"em",raw:f,text:x,tokens:this.lexer.inlineTokens(x)}}let h=f.slice(2,-2);return{type:"strong",raw:f,text:h,tokens:this.lexer.inlineTokens(h)}}}}codespan(t){let e=this.rules.inline.code.exec(t);if(e){let s=e[2].replace(this.rules.other.newLineCharGlobal," "),n=this.rules.other.nonSpaceChar.test(s),r=this.rules.other.startingSpaceChar.test(s)&&this.rules.other.endingSpaceChar.test(s);return n&&r&&(s=s.substring(1,s.length-1)),{type:"codespan",raw:e[0],text:s}}}br(t){let e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t,e,s=""){let n=this.rules.inline.delLDelim.exec(t);if(n&&(!n[1]||!s||this.rules.inline.punctuation.exec(s))){let r=[...n[0]].length-1,l,i,c=r,o=this.rules.inline.delRDelim;for(o.lastIndex=0,e=e.slice(-1*t.length+r);(n=o.exec(e))!==null;){if(l=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!l||(i=[...l].length,i!==r))continue;if(n[3]||n[4]){c+=i;continue}if(c-=i,c>0)continue;i=Math.min(i,i+c);let d=[...n[0]][0].length,u=t.slice(0,r+n.index+d+i),f=u.slice(r,-r);return{type:"del",raw:u,text:f,tokens:this.lexer.inlineTokens(f)}}}}autolink(t){let e=this.rules.inline.autolink.exec(t);if(e){let s,n;return e[2]==="@"?(s=e[1],n="mailto:"+s):(s=e[1],n=s),{type:"link",raw:e[0],text:s,href:n,tokens:[{type:"text",raw:s,text:s}]}}}url(t){let e;if(e=this.rules.inline.url.exec(t)){let s,n;if(e[2]==="@")s=e[0],n="mailto:"+s;else{let r;do r=e[0],e[0]=this.rules.inline._backpedal.exec(e[0])?.[0]??"";while(r!==e[0]);s=e[0],e[1]==="www."?n="http://"+e[0]:n=e[0]}return{type:"link",raw:e[0],text:s,href:n,tokens:[{type:"text",raw:s,text:s}]}}}inlineText(t){let e=this.rules.inline.text.exec(t);if(e){let s=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:s}}}},dt=class na{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||us,this.options.tokenizer=this.options.tokenizer||new hl,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let s={other:qe,block:Xr.normal,inline:vr.normal};this.options.pedantic?(s.block=Xr.pedantic,s.inline=vr.pedantic):this.options.gfm&&(s.block=Xr.gfm,this.options.breaks?s.inline=vr.breaks:s.inline=vr.gfm),this.tokenizer.rules=s}static get rules(){return{block:Xr,inline:vr}}static lex(e,s){return new na(s).lex(e)}static lexInline(e,s){return new na(s).inlineTokens(e)}lex(e){e=e.replace(qe.carriageReturn,`
|
|
28
|
+
`),this.blockTokens(e,this.tokens);for(let s=0;s<this.inlineQueue.length;s++){let n=this.inlineQueue[s];this.inlineTokens(n.src,n.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,s=[],n=!1){for(this.tokenizer.lexer=this,this.options.pedantic&&(e=e.replace(qe.tabCharGlobal," ").replace(qe.spaceLine,""));e;){let r;if(this.options.extensions?.block?.some(i=>(r=i.call({lexer:this},e,s))?(e=e.substring(r.raw.length),s.push(r),!0):!1))continue;if(r=this.tokenizer.space(e)){e=e.substring(r.raw.length);let i=s.at(-1);r.raw.length===1&&i!==void 0?i.raw+=`
|
|
29
|
+
`:s.push(r);continue}if(r=this.tokenizer.code(e)){e=e.substring(r.raw.length);let i=s.at(-1);i?.type==="paragraph"||i?.type==="text"?(i.raw+=(i.raw.endsWith(`
|
|
30
|
+
`)?"":`
|
|
31
|
+
`)+r.raw,i.text+=`
|
|
32
|
+
`+r.text,this.inlineQueue.at(-1).src=i.text):s.push(r);continue}if(r=this.tokenizer.fences(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.heading(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.hr(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.blockquote(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.list(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.html(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.def(e)){e=e.substring(r.raw.length);let i=s.at(-1);i?.type==="paragraph"||i?.type==="text"?(i.raw+=(i.raw.endsWith(`
|
|
33
|
+
`)?"":`
|
|
34
|
+
`)+r.raw,i.text+=`
|
|
35
|
+
`+r.raw,this.inlineQueue.at(-1).src=i.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title},s.push(r));continue}if(r=this.tokenizer.table(e)){e=e.substring(r.raw.length),s.push(r);continue}if(r=this.tokenizer.lheading(e)){e=e.substring(r.raw.length),s.push(r);continue}let l=e;if(this.options.extensions?.startBlock){let i=1/0,c=e.slice(1),o;this.options.extensions.startBlock.forEach(d=>{o=d.call({lexer:this},c),typeof o=="number"&&o>=0&&(i=Math.min(i,o))}),i<1/0&&i>=0&&(l=e.substring(0,i+1))}if(this.state.top&&(r=this.tokenizer.paragraph(l))){let i=s.at(-1);n&&i?.type==="paragraph"?(i.raw+=(i.raw.endsWith(`
|
|
36
|
+
`)?"":`
|
|
37
|
+
`)+r.raw,i.text+=`
|
|
38
|
+
`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=i.text):s.push(r),n=l.length!==e.length,e=e.substring(r.raw.length);continue}if(r=this.tokenizer.text(e)){e=e.substring(r.raw.length);let i=s.at(-1);i?.type==="text"?(i.raw+=(i.raw.endsWith(`
|
|
39
|
+
`)?"":`
|
|
40
|
+
`)+r.raw,i.text+=`
|
|
41
|
+
`+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=i.text):s.push(r);continue}if(e){let i="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(i);break}else throw new Error(i)}}return this.state.top=!0,s}inline(e,s=[]){return this.inlineQueue.push({src:e,tokens:s}),s}inlineTokens(e,s=[]){this.tokenizer.lexer=this;let n=e,r=null;if(this.tokens.links){let o=Object.keys(this.tokens.links);if(o.length>0)for(;(r=this.tokenizer.rules.inline.reflinkSearch.exec(n))!==null;)o.includes(r[0].slice(r[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,r.index)+"["+"a".repeat(r[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(r=this.tokenizer.rules.inline.anyPunctuation.exec(n))!==null;)n=n.slice(0,r.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let l;for(;(r=this.tokenizer.rules.inline.blockSkip.exec(n))!==null;)l=r[2]?r[2].length:0,n=n.slice(0,r.index+l)+"["+"a".repeat(r[0].length-l-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let i=!1,c="";for(;e;){i||(c=""),i=!1;let o;if(this.options.extensions?.inline?.some(u=>(o=u.call({lexer:this},e,s))?(e=e.substring(o.raw.length),s.push(o),!0):!1))continue;if(o=this.tokenizer.escape(e)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.tag(e)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.link(e)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(o.raw.length);let u=s.at(-1);o.type==="text"&&u?.type==="text"?(u.raw+=o.raw,u.text+=o.text):s.push(o);continue}if(o=this.tokenizer.emStrong(e,n,c)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.codespan(e)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.br(e)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.del(e,n,c)){e=e.substring(o.raw.length),s.push(o);continue}if(o=this.tokenizer.autolink(e)){e=e.substring(o.raw.length),s.push(o);continue}if(!this.state.inLink&&(o=this.tokenizer.url(e))){e=e.substring(o.raw.length),s.push(o);continue}let d=e;if(this.options.extensions?.startInline){let u=1/0,f=e.slice(1),h;this.options.extensions.startInline.forEach(x=>{h=x.call({lexer:this},f),typeof h=="number"&&h>=0&&(u=Math.min(u,h))}),u<1/0&&u>=0&&(d=e.substring(0,u+1))}if(o=this.tokenizer.inlineText(d)){e=e.substring(o.raw.length),o.raw.slice(-1)!=="_"&&(c=o.raw.slice(-1)),i=!0;let u=s.at(-1);u?.type==="text"?(u.raw+=o.raw,u.text+=o.text):s.push(o);continue}if(e){let u="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(u);break}else throw new Error(u)}}return s}},pl=class{options;parser;constructor(t){this.options=t||us}space(t){return""}code({text:t,lang:e,escaped:s}){let n=(e||"").match(qe.notSpaceStart)?.[0],r=t.replace(qe.endingNewline,"")+`
|
|
42
|
+
`;return n?'<pre><code class="language-'+mt(n)+'">'+(s?r:mt(r,!0))+`</code></pre>
|
|
43
|
+
`:"<pre><code>"+(s?r:mt(r,!0))+`</code></pre>
|
|
44
|
+
`}blockquote({tokens:t}){return`<blockquote>
|
|
45
|
+
${this.parser.parse(t)}</blockquote>
|
|
46
|
+
`}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:e}){return`<h${e}>${this.parser.parseInline(t)}</h${e}>
|
|
47
|
+
`}hr(t){return`<hr>
|
|
48
|
+
`}list(t){let e=t.ordered,s=t.start,n="";for(let i=0;i<t.items.length;i++){let c=t.items[i];n+=this.listitem(c)}let r=e?"ol":"ul",l=e&&s!==1?' start="'+s+'"':"";return"<"+r+l+`>
|
|
49
|
+
`+n+"</"+r+`>
|
|
50
|
+
`}listitem(t){return`<li>${this.parser.parse(t.tokens)}</li>
|
|
51
|
+
`}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox"> '}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>
|
|
52
|
+
`}table(t){let e="",s="";for(let r=0;r<t.header.length;r++)s+=this.tablecell(t.header[r]);e+=this.tablerow({text:s});let n="";for(let r=0;r<t.rows.length;r++){let l=t.rows[r];s="";for(let i=0;i<l.length;i++)s+=this.tablecell(l[i]);n+=this.tablerow({text:s})}return n&&(n=`<tbody>${n}</tbody>`),`<table>
|
|
53
|
+
<thead>
|
|
54
|
+
`+e+`</thead>
|
|
55
|
+
`+n+`</table>
|
|
56
|
+
`}tablerow({text:t}){return`<tr>
|
|
57
|
+
${t}</tr>
|
|
58
|
+
`}tablecell(t){let e=this.parser.parseInline(t.tokens),s=t.header?"th":"td";return(t.align?`<${s} align="${t.align}">`:`<${s}>`)+e+`</${s}>
|
|
59
|
+
`}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${mt(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:e,tokens:s}){let n=this.parser.parseInline(s),r=ii(t);if(r===null)return n;t=r;let l='<a href="'+t+'"';return e&&(l+=' title="'+mt(e)+'"'),l+=">"+n+"</a>",l}image({href:t,title:e,text:s,tokens:n}){n&&(s=this.parser.parseInline(n,this.parser.textRenderer));let r=ii(t);if(r===null)return mt(s);t=r;let l=`<img src="${t}" alt="${mt(s)}"`;return e&&(l+=` title="${mt(e)}"`),l+=">",l}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:mt(t.text)}},Ra=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}checkbox({raw:t}){return t}},ut=class ra{options;renderer;textRenderer;constructor(e){this.options=e||us,this.options.renderer=this.options.renderer||new pl,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Ra}static parse(e,s){return new ra(s).parse(e)}static parseInline(e,s){return new ra(s).parseInline(e)}parse(e){this.renderer.parser=this;let s="";for(let n=0;n<e.length;n++){let r=e[n];if(this.options.extensions?.renderers?.[r.type]){let i=r,c=this.options.extensions.renderers[i.type].call({parser:this},i);if(c!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(i.type)){s+=c||"";continue}}let l=r;switch(l.type){case"space":{s+=this.renderer.space(l);break}case"hr":{s+=this.renderer.hr(l);break}case"heading":{s+=this.renderer.heading(l);break}case"code":{s+=this.renderer.code(l);break}case"table":{s+=this.renderer.table(l);break}case"blockquote":{s+=this.renderer.blockquote(l);break}case"list":{s+=this.renderer.list(l);break}case"checkbox":{s+=this.renderer.checkbox(l);break}case"html":{s+=this.renderer.html(l);break}case"def":{s+=this.renderer.def(l);break}case"paragraph":{s+=this.renderer.paragraph(l);break}case"text":{s+=this.renderer.text(l);break}default:{let i='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(i),"";throw new Error(i)}}}return s}parseInline(e,s=this.renderer){this.renderer.parser=this;let n="";for(let r=0;r<e.length;r++){let l=e[r];if(this.options.extensions?.renderers?.[l.type]){let c=this.options.extensions.renderers[l.type].call({parser:this},l);if(c!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(l.type)){n+=c||"";continue}}let i=l;switch(i.type){case"escape":{n+=s.text(i);break}case"html":{n+=s.html(i);break}case"link":{n+=s.link(i);break}case"image":{n+=s.image(i);break}case"checkbox":{n+=s.checkbox(i);break}case"strong":{n+=s.strong(i);break}case"em":{n+=s.em(i);break}case"codespan":{n+=s.codespan(i);break}case"br":{n+=s.br(i);break}case"del":{n+=s.del(i);break}case"text":{n+=s.text(i);break}default:{let c='Token with "'+i.type+'" type was not found.';if(this.options.silent)return console.error(c),"";throw new Error(c)}}}return n}},Cr=class{options;block;constructor(t){this.options=t||us}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens","emStrongMask"]);static passThroughHooksRespectAsync=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}emStrongMask(t){return t}provideLexer(t=this.block){return t?dt.lex:dt.lexInline}provideParser(t=this.block){return t?ut.parse:ut.parseInline}},Sh=class{defaults=Ca();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=ut;Renderer=pl;TextRenderer=Ra;Lexer=dt;Tokenizer=hl;Hooks=Cr;constructor(...t){this.use(...t)}walkTokens(t,e){let s=[];for(let n of t)switch(s=s.concat(e.call(this,n)),n.type){case"table":{let r=n;for(let l of r.header)s=s.concat(this.walkTokens(l.tokens,e));for(let l of r.rows)for(let i of l)s=s.concat(this.walkTokens(i.tokens,e));break}case"list":{let r=n;s=s.concat(this.walkTokens(r.items,e));break}default:{let r=n;this.defaults.extensions?.childTokens?.[r.type]?this.defaults.extensions.childTokens[r.type].forEach(l=>{let i=r[l].flat(1/0);s=s.concat(this.walkTokens(i,e))}):r.tokens&&(s=s.concat(this.walkTokens(r.tokens,e)))}}return s}use(...t){let e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(s=>{let n={...s};if(n.async=this.defaults.async||n.async||!1,s.extensions&&(s.extensions.forEach(r=>{if(!r.name)throw new Error("extension name required");if("renderer"in r){let l=e.renderers[r.name];l?e.renderers[r.name]=function(...i){let c=r.renderer.apply(this,i);return c===!1&&(c=l.apply(this,i)),c}:e.renderers[r.name]=r.renderer}if("tokenizer"in r){if(!r.level||r.level!=="block"&&r.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let l=e[r.level];l?l.unshift(r.tokenizer):e[r.level]=[r.tokenizer],r.start&&(r.level==="block"?e.startBlock?e.startBlock.push(r.start):e.startBlock=[r.start]:r.level==="inline"&&(e.startInline?e.startInline.push(r.start):e.startInline=[r.start]))}"childTokens"in r&&r.childTokens&&(e.childTokens[r.name]=r.childTokens)}),n.extensions=e),s.renderer){let r=this.defaults.renderer||new pl(this.defaults);for(let l in s.renderer){if(!(l in r))throw new Error(`renderer '${l}' does not exist`);if(["options","parser"].includes(l))continue;let i=l,c=s.renderer[i],o=r[i];r[i]=(...d)=>{let u=c.apply(r,d);return u===!1&&(u=o.apply(r,d)),u||""}}n.renderer=r}if(s.tokenizer){let r=this.defaults.tokenizer||new hl(this.defaults);for(let l in s.tokenizer){if(!(l in r))throw new Error(`tokenizer '${l}' does not exist`);if(["options","rules","lexer"].includes(l))continue;let i=l,c=s.tokenizer[i],o=r[i];r[i]=(...d)=>{let u=c.apply(r,d);return u===!1&&(u=o.apply(r,d)),u}}n.tokenizer=r}if(s.hooks){let r=this.defaults.hooks||new Cr;for(let l in s.hooks){if(!(l in r))throw new Error(`hook '${l}' does not exist`);if(["options","block"].includes(l))continue;let i=l,c=s.hooks[i],o=r[i];Cr.passThroughHooks.has(l)?r[i]=d=>{if(this.defaults.async&&Cr.passThroughHooksRespectAsync.has(l))return(async()=>{let f=await c.call(r,d);return o.call(r,f)})();let u=c.call(r,d);return o.call(r,u)}:r[i]=(...d)=>{if(this.defaults.async)return(async()=>{let f=await c.apply(r,d);return f===!1&&(f=await o.apply(r,d)),f})();let u=c.apply(r,d);return u===!1&&(u=o.apply(r,d)),u}}n.hooks=r}if(s.walkTokens){let r=this.defaults.walkTokens,l=s.walkTokens;n.walkTokens=function(i){let c=[];return c.push(l.call(this,i)),r&&(c=c.concat(r.call(this,i))),c}}this.defaults={...this.defaults,...n}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return dt.lex(t,e??this.defaults)}parser(t,e){return ut.parse(t,e??this.defaults)}parseMarkdown(t){return(e,s)=>{let n={...s},r={...this.defaults,...n},l=this.onError(!!r.silent,!!r.async);if(this.defaults.async===!0&&n.async===!1)return l(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof e>"u"||e===null)return l(new Error("marked(): input parameter is undefined or null"));if(typeof e!="string")return l(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));if(r.hooks&&(r.hooks.options=r,r.hooks.block=t),r.async)return(async()=>{let i=r.hooks?await r.hooks.preprocess(e):e,c=await(r.hooks?await r.hooks.provideLexer(t):t?dt.lex:dt.lexInline)(i,r),o=r.hooks?await r.hooks.processAllTokens(c):c;r.walkTokens&&await Promise.all(this.walkTokens(o,r.walkTokens));let d=await(r.hooks?await r.hooks.provideParser(t):t?ut.parse:ut.parseInline)(o,r);return r.hooks?await r.hooks.postprocess(d):d})().catch(l);try{r.hooks&&(e=r.hooks.preprocess(e));let i=(r.hooks?r.hooks.provideLexer(t):t?dt.lex:dt.lexInline)(e,r);r.hooks&&(i=r.hooks.processAllTokens(i)),r.walkTokens&&this.walkTokens(i,r.walkTokens);let c=(r.hooks?r.hooks.provideParser(t):t?ut.parse:ut.parseInline)(i,r);return r.hooks&&(c=r.hooks.postprocess(c)),c}catch(i){return l(i)}}}onError(t,e){return s=>{if(s.message+=`
|
|
60
|
+
Please report this to https://github.com/markedjs/marked.`,t){let n="<p>An error occurred:</p><pre>"+mt(s.message+"",!0)+"</pre>";return e?Promise.resolve(n):n}if(e)return Promise.reject(s);throw s}}},rs=new Sh;function je(t,e){return rs.parse(t,e)}je.options=je.setOptions=function(t){return rs.setOptions(t),je.defaults=rs.defaults,So(je.defaults),je};je.getDefaults=Ca;je.defaults=us;je.use=function(...t){return rs.use(...t),je.defaults=rs.defaults,So(je.defaults),je};je.walkTokens=function(t,e){return rs.walkTokens(t,e)};je.parseInline=rs.parseInline;je.Parser=ut;je.parser=ut.parse;je.Renderer=pl;je.TextRenderer=Ra;je.Lexer=dt;je.lexer=dt.lex;je.Tokenizer=hl;je.Hooks=Cr;je.parse=je;je.options;je.setOptions;je.use;je.walkTokens;je.parseInline;ut.parse;dt.lex;const Ch=/\n[^\S\n]*(?:\n[^\S\n]*)+$/;function Nh(t){return t.flatMap((e,s)=>{var n;if(e.type==="space"||((n=t[s+1])===null||n===void 0?void 0:n.type)==="space")return[e];const r=(e.raw||"").match(Ch);return r?[{...e,raw:(e.raw||"").slice(0,-r[0].length)},{type:"space",raw:r[0]}]:[e]})}function Th(t,e){const s=e.split(`
|
|
61
|
+
`).flatMap(n=>[n,""]).map(n=>`${t}${n}`).join(`
|
|
62
|
+
`);return s.slice(0,s.length-1)}function Bh(t,e){const s=[];return Array.from(t.entries()).forEach(([n,r])=>{if(!e){s.push(n);return}(e.marks||[]).find(l=>l.type===n&&_r(l.attrs,r.attrs))||s.push(n)}),s}function _h(t,e){const s=[];return Array.from(e.entries()).forEach(([n,r])=>{const l=t.get(n);(!l||!_r(l.attrs,r.attrs))&&s.push({type:n,mark:r})}),s}function Ah(t,e,s,n){const r=!s,l=s&&(!s.marks||s.marks.length===0),i=s&&s.marks&&!n(e,new Map(s.marks.map(o=>[o.type,o]))),c=[];return(r||l||i)&&(s&&s.marks?Array.from(t.entries()).reverse().forEach(([o,d])=>{s.marks.find(u=>u.type===o&&_r(u.attrs,d.attrs))||c.push(o)}):(r||l)&&c.push(...Array.from(t.keys()).reverse())),c}function $h(t,e){let s="";return Array.from(t.keys()).reverse().forEach(n=>{const r=e(n,t.get(n));r&&(s=r+s)}),t.clear(),s}function Dh(t,e,s){let n="";return Array.from(t.entries()).forEach(([r,l])=>{const i=s(r,l);i&&(n+=i),e.set(r,l)}),n}function Vl(t){const e=(t.raw||t.text||"").match(/^(\s*)[-+*]\s+\[([ xX])\]\s+/);return e?{isTask:!0,checked:e[2].toLowerCase()==="x",indentLevel:e[1].length}:{isTask:!1,indentLevel:0}}function Jr(t,e){return typeof t!="string"?"json":e}const Rh=new Set(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","menu","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","search","section","select","slot","small","source","span","strong","style","sub","summary","sup","svg","circle","clippath","defs","ellipse","foreignobject","g","image","line","lineargradient","mask","path","polygon","polyline","radialgradient","rect","stop","switch","symbol","textpath","tspan","use","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"]),zh=/<\/?([a-zA-Z][\w-]*)/g;function Eh(t){const e=[];let s;for(;(s=zh.exec(t))!==null;)e.push(s[1].toLowerCase());return e}function Ih(t){const e=t.toLowerCase();return e.includes("-")?!1:!Rh.has(e)}function Lh(t,e){return Eh(t).some(s=>Ih(s)?!e.has(s):!1)}var di=class{constructor(t){var e,s,n,r,l;this.activeParseLexer=null,this.extensionRanks=new Map,this.baseExtensions=[],this.extensions=[],this.codeTypes=new Set,this.schemaParseDomTagsCache=null,this.inlineNodeTypesCache=null,this.lastParseResult=null,this.markedInstance=(e=t?.marked)!==null&&e!==void 0?e:je,this.indentStyle=(s=t==null||(n=t.indentation)===null||n===void 0?void 0:n.style)!==null&&s!==void 0?s:"space",this.indentSize=(r=t==null||(l=t.indentation)===null||l===void 0?void 0:l.size)!==null&&r!==void 0?r:2,this.baseExtensions=t?.extensions||[],t?.markedOptions&&typeof this.markedInstance.setOptions=="function"&&this.markedInstance.setOptions(t.markedOptions),this.registry=new Map,this.nodeTypeRegistry=new Map,t?.extensions&&(this.baseExtensions=t.extensions,nu(ru(t.extensions)).forEach(i=>this.registerExtension(i)))}get instance(){return this.markedInstance}get indentCharacter(){return this.indentStyle==="space"?" ":" "}get indentString(){return this.indentCharacter.repeat(this.indentSize)}hasMarked(){return!!this.markedInstance}registerExtension(t){var e,s;this.extensions.push(t);const n=uo(Zt(t,"code")),r=t.name;n&&this.codeTypes.add(r),this.extensionRanks.has(r)||this.extensionRanks.set(r,this.extensionRanks.size);const l=Zt(t,"markdownTokenName")||r,i=Zt(t,"parseMarkdown"),c=Zt(t,"renderMarkdown"),o=Zt(t,"markdownTokenizer"),d=(e=Zt(t,"markdownOptions"))!==null&&e!==void 0?e:null,u={tokenName:l,nodeName:r,parseMarkdown:i,renderMarkdown:c,isIndenting:(s=d?.indentsContent)!==null&&s!==void 0?s:!1,htmlReopen:d?.htmlReopen,tokenizer:o};if(l&&i){const f=this.registry.get(l)||[];f.push(u),this.registry.set(l,f)}if(c){const f=this.nodeTypeRegistry.get(r)||[];f.push(u),this.nodeTypeRegistry.set(r,f)}o&&this.hasMarked()&&this.registerTokenizer(o)}createLexer(){return new this.markedInstance.Lexer(this.markedInstance.defaults)}createTokenizerHelpers(t){return{inlineTokens:e=>t.inlineTokens(e),blockTokens:e=>t.blockTokens(e)}}tokenizeInline(t){var e;return((e=this.activeParseLexer)!==null&&e!==void 0?e:this.createLexer()).inlineTokens(t)}registerTokenizer(t){if(!this.hasMarked())return;const{name:e,start:s,level:n="inline",tokenize:r}=t,l=this.createTokenizerHelpers.bind(this),i=this.createLexer.bind(this);let c;s?c=typeof s=="function"?s:d=>d.indexOf(s):c=d=>{const u=r(d,[],this.createTokenizerHelpers(this.createLexer()));return u&&u.raw?d.indexOf(u.raw):-1};const o={name:e,level:n,start:c,tokenizer(d,u){const f=this.lexer?l(this.lexer):l(i()),h=r(d,u,f);if(h&&h.type)return{...h,type:h.type||e,raw:h.raw||"",tokens:h.tokens||[]}},childTokens:[]};this.markedInstance.use({extensions:[o]})}getHandlersForToken(t){try{return this.registry.get(t)||[]}catch{return[]}}getHandlerForToken(t){const e=this.getHandlersForToken(t);if(e.length>0)return e[0];const s=this.getHandlersForNodeType(t);return s.length>0?s[0]:void 0}getHandlersForNodeType(t){try{return this.nodeTypeRegistry.get(t)||[]}catch{return[]}}serialize(t){if(!t)return"";const e=this.renderNodes(t,t);return this.isEmptyOutput(e)?"":e}isEmptyOutput(t){return!t||t.trim()===""?!0:t.replace(/ /g,"").replace(/\u00A0/g,"").trim()===""}parse(t){if(!this.hasMarked())throw new Error("No marked instance available for parsing");const e=this.activeParseLexer,s=this.createLexer();this.activeParseLexer=s;try{const n=s.lex(t);return{type:"doc",content:this.parseTokens(n,!0)}}finally{this.activeParseLexer=e}}parseTokens(t,e=!1){const s=e?Nh(t):t,n=s.reduce((i,c,o)=>(c.type!=="space"&&i.push(o),i),[]);let r=-1,l=0;return s.flatMap((i,c)=>{for(;l<n.length&&n[l]<c;)r=n[l],l+=1;if(e&&i.type==="space"){var o;const u=(o=n[l])!==null&&o!==void 0?o:-1;return this.createImplicitEmptyParagraphsFromSpace(i,r,u)}const d=this.parseToken(i,e);return d===null?[]:Array.isArray(d)?d:[d]})}createImplicitEmptyParagraphsFromSpace(t,e,s){const n=this.countParagraphSeparators(t.raw||"");if(n===0)return[];const r=Math.max(n-(e===-1||s===-1?0:1),0);return Array.from({length:r},()=>({type:"paragraph",content:[]}))}countParagraphSeparators(t){return(t.replace(/\r\n/g,`
|
|
63
|
+
`).match(/\n\n/g)||[]).length}parseToken(t,e=!1){if(!t.type)return null;if(t.type==="list")return this.parseListToken(t);const s=this.getHandlersForToken(t.type),n=this.createParseHelpers();if(s.find(r=>{if(!r.parseMarkdown)return!1;const l=r.parseMarkdown(t,n),i=this.normalizeParseResult(l);return i&&(!Array.isArray(i)||i.length>0)?(this.lastParseResult=i,!0):!1})&&this.lastParseResult){const r=this.lastParseResult;return this.lastParseResult=null,r}return this.parseFallbackToken(t,e)}parseListToken(t){if(!t.items||t.items.length===0)return this.parseTokenWithHandlers(t);const e=t.items.some(c=>Vl(c).isTask),s=t.items.some(c=>!Vl(c).isTask);if(!e||!s||this.getHandlersForToken("taskList").length===0)return this.parseTokenWithHandlers(t);const n=[];let r=[],l=null;for(let c=0;c<t.items.length;c+=1){const o=t.items[c],{isTask:d,checked:u,indentLevel:f}=Vl(o);let h=o;if(d){const m=(o.raw||o.text||"").split(`
|
|
64
|
+
`),g=m[0].match(/^\s*[-+*]\s+\[([ xX])\]\s+(.*)$/),k=g?g[2]:"";let y=[];if(m.length>1&&m.slice(1).join(`
|
|
65
|
+
`).trim()){const v=m.slice(1),p=v.filter(b=>b.trim());if(p.length>0){const b=Math.min(...p.map(w=>w.length-w.trimStart().length)),j=v.map(w=>w.trim()?w.slice(b):"").join(`
|
|
66
|
+
`).trim();j&&(y=this.markedInstance.lexer(`${j}
|
|
67
|
+
`))}}h={type:"taskItem",raw:"",mainContent:k,indentLevel:f,checked:u??!1,text:k,tokens:this.tokenizeInline(k),nestedTokens:y}}const x=d?"taskList":"list";l!==x?(r.length>0&&n.push({type:l,items:r}),r=[h],l=x):r.push(h)}r.length>0&&n.push({type:l,items:r});const i=[];for(let c=0;c<n.length;c+=1){const o=n[c],d={...t,type:o.type,items:o.items},u=this.parseToken(d);u&&(Array.isArray(u)?i.push(...u):i.push(u))}return i.length>0?i:null}parseTokenWithHandlers(t){if(!t.type)return null;const e=this.getHandlersForToken(t.type),s=this.createParseHelpers();if(e.find(n=>{if(!n.parseMarkdown)return!1;const r=n.parseMarkdown(t,s),l=this.normalizeParseResult(r);return l&&(!Array.isArray(l)||l.length>0)?(this.lastParseResult=l,!0):!1})&&this.lastParseResult){const n=this.lastParseResult;return this.lastParseResult=null,n}return this.parseFallbackToken(t)}createParseHelpers(){return{parseInline:t=>this.parseInlineTokens(t),tokenizeInline:t=>this.tokenizeInline(t),parseChildren:t=>this.parseTokens(t),parseBlockChildren:t=>this.parseTokens(t,!0),createTextNode:(t,e)=>({type:"text",text:t,marks:e||void 0}),createNode:(t,e,s)=>{const n={type:t,attrs:e||void 0,content:s||void 0};return(!e||Object.keys(e).length===0)&&delete n.attrs,n},applyMark:(t,e,s)=>({mark:t,content:e,attrs:s&&Object.keys(s).length>0?s:void 0})}}escapeRegex(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}parseInlineTokens(t){const e=[];for(let i=0;i<t.length;i+=1){const c=t[i];if(c.type==="text")e.push({type:"text",text:Ga(c.text||"")});else if(c.type==="escape")e.push({type:"text",text:c.text||""});else if(c.type==="html"){var s,n;const o=((s=(n=c.raw)!==null&&n!==void 0?n:c.text)!==null&&s!==void 0?s:"").toString(),d=/^<\/[\s]*[\w-]+/i.test(o),u=o.match(/^<[\s]*([\w-]+)(\s|>|\/|$)/i);if(!d&&u&&!/\/>$/.test(o)){const h=u[1],x=this.escapeRegex(h),m=new RegExp(`^<\\/\\s*${x}\\b`,"i");let g=-1;const k=[o];for(let y=i+1;y<t.length;y+=1){var r,l;const v=t[y],p=((r=(l=v.raw)!==null&&l!==void 0?l:v.text)!==null&&r!==void 0?r:"").toString();if(k.push(p),v.type==="html"&&m.test(p)){g=y;break}}if(g!==-1){const y=k.join(""),v={type:"html",raw:y,text:y,block:!1},p=this.parseHTMLToken(v);if(p){const b=this.normalizeParseResult(p);Array.isArray(b)?e.push(...b):b&&e.push(b)}i=g;continue}}const f=this.parseHTMLToken(c);if(f){const h=this.normalizeParseResult(f);Array.isArray(h)?e.push(...h):h&&e.push(h)}}else if(c.type){const o=this.getHandlerForToken(c.type);if(o&&o.parseMarkdown){const d=this.createParseHelpers(),u=o.parseMarkdown(c,d);if(this.isMarkResult(u)){const f=this.applyMarkToContent(u.mark,u.content,u.attrs);e.push(...f)}else{const f=this.normalizeParseResult(u);Array.isArray(f)?e.push(...f):f&&e.push(f)}}else c.tokens&&e.push(...this.parseInlineTokens(c.tokens))}}for(let i=e.length-1;i>0;i-=1){const c=e[i],o=e[i-1];if(c.type==="text"&&o.type==="text"){const d=c.marks||[],u=o.marks||[];lu(d,u)&&(o.text=(o.text||"")+(c.text||""),e.splice(i,1))}}return e}applyMarkToContent(t,e,s){return e.map(n=>{if(n.type==="text"){const r=n.marks||[],l=s?{type:t,attrs:s}:{type:t};return{...n,marks:[...r,l]}}return{...n,content:n.content?this.applyMarkToContent(t,n.content,s):void 0}})}isMarkResult(t){return t&&typeof t=="object"&&"mark"in t}normalizeParseResult(t){return t?this.isMarkResult(t)?t.content:t:null}parseFallbackToken(t,e=!1){switch(t.type){case"paragraph":return{type:"paragraph",content:t.tokens?this.parseInlineTokens(t.tokens):[]};case"heading":return{type:"heading",attrs:{level:t.depth||1},content:t.tokens?this.parseInlineTokens(t.tokens):[]};case"text":return{type:"text",text:Ga(t.text||"")};case"html":return this.parseHTMLToken(t);case"escape":return{type:"text",text:t.text||""};case"space":return null;default:return t.tokens?this.parseTokens(t.tokens,e):null}}parseHTMLToken(t){const e=t.text||t.raw||"";if(!e.trim())return null;if(this.isUnrecognizedHtml(e))return this.htmlAsLiteralText(e,!!t.block);if(typeof window>"u"||typeof window.DOMParser>"u")return this.htmlAsLiteralText(e,!!t.block);try{const s=au(e,this.baseExtensions);if(s.type==="doc"&&s.content){if(t.block)return s.content;const n=this.toInlineContent(s.content);return n.length>0?n:null}return s}catch(s){throw new Error(`Failed to parse HTML in markdown: ${s}`)}}toInlineContent(t){const e=this.getInlineNodeTypes();return t.flatMap(s=>s.type&&e.has(s.type)?[s]:s.content?this.toInlineContent(s.content):[])}getInlineNodeTypes(){if(this.inlineNodeTypesCache)return this.inlineNodeTypesCache;const t=new Set(["text"]);try{const e=Va(this.baseExtensions);Object.values(e.nodes).forEach(s=>{s.isInline&&t.add(s.name)})}catch{}return this.inlineNodeTypesCache=t,t}isUnrecognizedHtml(t){return Lh(t,this.getSchemaParseDomTags())}getSchemaParseDomTags(){if(this.schemaParseDomTagsCache)return this.schemaParseDomTagsCache;const t=new Set;try{const e=Va(this.baseExtensions),s=n=>{const r=n?.parseDOM;Array.isArray(r)&&r.forEach(l=>{if(typeof l?.tag=="string"){const i=l.tag.match(/^[a-zA-Z][\w-]*/);i&&t.add(i[0].toLowerCase())}})};Object.values(e.nodes).forEach(n=>s(n.spec)),Object.values(e.marks).forEach(n=>s(n.spec))}catch{}return this.schemaParseDomTagsCache=t,t}htmlAsLiteralText(t,e){const s=t.replace(/\s+$/,"");return s?e?{type:"paragraph",content:[{type:"text",text:s}]}:{type:"text",text:s}:null}encodeTextForMarkdown(t,e,s){return s?.type!=null&&this.codeTypes.has(s.type)||(e.marks||[]).some(n=>this.codeTypes.has(typeof n=="string"?n:n.type))?t:this.escapeMarkdownSyntax(iu(t))}escapeMarkdownSyntax(t){return t.replace(/([\\`*_[\]~])/g,"\\$1")}renderNodeToMarkdown(t,e,s=0,n=0,r={}){var l;if(t.type==="text")return this.encodeTextForMarkdown(t.text||"",t,e);if(!t.type)return"";const i=this.getHandlerForToken(t.type);if(!i)return"";const c=Array.isArray(e?.content)&&s>0?e.content[s-1]:void 0,o={renderChildren:(u,f)=>{const h=i.isIndenting?n+1:n;return!Array.isArray(u)&&u.content?this.renderNodes(u.content,t,f||"",s,h):this.renderNodes(u,t,f||"",s,h)},renderChild:(u,f)=>{const h=i.isIndenting?n+1:n;return this.renderNodeToMarkdown(u,t,f,h)},indent:u=>this.indentString+u,wrapInBlock:Th},d={index:s,level:n,parentType:e?.type,previousNode:c,meta:{parentAttrs:e?.attrs,...r}};return((l=i.renderMarkdown)===null||l===void 0?void 0:l.call(i,t,o,d))||""}renderNodes(t,e,s="",n=0,r=0){return Array.isArray(t)?this.renderNodesWithMarkBoundaries(t,e,s,r):t.type?this.renderNodeToMarkdown(t,e,n,r):""}renderNodesWithMarkBoundaries(t,e,s="",n=0){const r=[],l=new Map,i=new Set,c=new Map;return t.forEach((o,d)=>{const u=d<t.length-1?t[d+1]:null;if(o.type)if(o.type==="text"){let f=this.encodeTextForMarkdown(o.text||"",o,e);const h=new Map((o.marks||[]).map(j=>[j.type,j])),x=this.getMarksToOpenForSerialization(l,h,u),m=Bh(h,u),g=m.filter(j=>l.has(j)),k=g.length>0&&x.length>0;let y="";if(m.length>0&&!k){const j=f.match(/(\s+)$/);j&&(y=j[1],f=f.slice(0,-y.length))}k||m.slice().reverse().forEach(j=>{if(!l.has(j))return;const w=h.get(j),S=this.getMarkClosing(j,w,c.get(j));S&&(f+=S),l.has(j)&&(l.delete(j),c.delete(j))});let v="";if(x.length>0){const j=f.match(/^(\s+)/);j&&(v=j[1],f=f.slice(v.length))}x.forEach(({type:j,mark:w})=>{const S=i.has(j)?"html":"markdown",C=this.getMarkOpening(j,w,S);C&&(f=C+f),c.set(j,S),i.delete(j)}),k||x.slice().reverse().forEach(({type:j,mark:w})=>{l.set(j,w)}),f=v+f;let p;if(k){const j=new Set((u?.marks||[]).map(C=>C.type));x.forEach(({type:C})=>{j.has(C)&&this.getHtmlReopenTags(C)&&i.add(C)});const w=Array.from(l.keys()),S=g.slice().sort((C,T)=>w.indexOf(T)-w.indexOf(C));p=[...x.map(C=>C.type),...S]}else p=Ah(l,h,u,this.markSetsEqual.bind(this));let b="";if(p.length>0){const j=f.match(/(\s+)$/);j&&(b=j[1],f=f.slice(0,-b.length))}p.forEach(j=>{var w;const S=(w=l.get(j))!==null&&w!==void 0?w:h.get(j),C=this.getMarkClosing(j,S,c.get(j));C&&(f+=C),l.delete(j),c.delete(j)}),f+=b,f+=y,r.push(f)}else{const f=new Set((o.marks||[]).map(y=>y.type)),h=new Map,x=new Map;l.forEach((y,v)=>{if(f.has(v)){var p;h.set(v,y),x.set(v,(p=c.get(v))!==null&&p!==void 0?p:"markdown")}});const m=$h(l,(y,v)=>this.getMarkClosing(y,v,c.get(y)));c.clear();const g=this.renderNodeToMarkdown(o,e,d,n),k=o.type==="hardBreak"?"":Dh(h,l,(y,v)=>{var p;const b=(p=x.get(y))!==null&&p!==void 0?p:"markdown";return c.set(y,b),this.getMarkOpening(y,v,b)});r.push(m+g+k)}}),r.join(s)}getMarkOpening(t,e,s="markdown"){if(s==="html"){var n;return((n=this.getHtmlReopenTags(t))===null||n===void 0?void 0:n.open)||""}const r=this.getHandlersForNodeType(t),l=r.length>0?r[0]:void 0;if(!l||!l.renderMarkdown)return"";const i="__TIPTAP_MARKDOWN_PLACEHOLDER__",c={type:t,attrs:e.attrs||{},content:[{type:"text",text:i}]};try{const o=l.renderMarkdown(c,{renderChildren:()=>i,renderChild:()=>i,indent:u=>u,wrapInBlock:(u,f)=>u+f},{index:0,level:0,parentType:"text",meta:{}}),d=o.indexOf(i);return d>=0?o.substring(0,d):""}catch(o){throw new Error(`Failed to get mark opening for ${t}: ${o}`)}}getMarkClosing(t,e,s="markdown"){if(s==="html"){var n;return((n=this.getHtmlReopenTags(t))===null||n===void 0?void 0:n.close)||""}const r=this.getHandlersForNodeType(t),l=r.length>0?r[0]:void 0;if(!l||!l.renderMarkdown)return"";const i="__TIPTAP_MARKDOWN_PLACEHOLDER__",c={type:t,attrs:e.attrs||{},content:[{type:"text",text:i}]};try{const o=l.renderMarkdown(c,{renderChildren:()=>i,renderChild:()=>i,indent:f=>f,wrapInBlock:(f,h)=>f+h},{index:0,level:0,parentType:"text",meta:{}}),d=o.indexOf(i),u=d+33;return d>=0?o.substring(u):""}catch(o){throw new Error(`Failed to get mark closing for ${t}: ${o}`)}}getHtmlReopenTags(t){const e=this.getHandlersForNodeType(t),s=e.length>0?e[0]:void 0;return s?.htmlReopen}markSetsEqual(t,e){return t.size!==e.size?!1:Array.from(t.entries()).every(([s,n])=>{const r=e.get(s);return r&&_r(n.attrs,r.attrs)})}getMarksToOpenForSerialization(t,e,s){const n=_h(t,e);if(n.length<=1)return n;const r=s?.marks||[],l=(d,u)=>r.some(f=>f.type===d&&_r(f.attrs,u)),i=(d,u)=>{var f,h;const x=(f=this.extensionRanks.get(d.type))!==null&&f!==void 0?f:Number.MAX_SAFE_INTEGER,m=(h=this.extensionRanks.get(u.type))!==null&&h!==void 0?h:Number.MAX_SAFE_INTEGER;return x!==m?m-x:d.type.localeCompare(u.type)},c=n.filter(d=>!l(d.type,d.mark.attrs)).sort(i),o=n.filter(d=>l(d.type,d.mark.attrs)).sort(i);return[...c,...o]}};const zo=ba.create({name:"markdown",addOptions(){return{indentation:{style:"space",size:2},marked:void 0,markedOptions:{}}},addCommands(){return{setContent:(t,e)=>{if(!e?.contentType)return wt.setContent(t,e);if(Jr(t,e?.contentType)!=="markdown"||!this.editor.markdown)return wt.setContent(t,e);const s=this.editor.markdown.parse(t);return wt.setContent(s,e)},insertContent:(t,e)=>{if(!e?.contentType)return wt.insertContent(t,e);if(Jr(t,e?.contentType)!=="markdown"||!this.editor.markdown)return wt.insertContent(t,e);const s=this.editor.markdown.parse(t);return wt.insertContent(s,e)},insertContentAt:(t,e,s)=>{if(!s?.contentType)return wt.insertContentAt(t,e,s);if(Jr(e,s?.contentType)!=="markdown"||!this.editor.markdown)return wt.insertContentAt(t,e,s);const n=this.editor.markdown.parse(e);return wt.insertContentAt(t,n,s)}}},addStorage(){return{manager:new di({indentation:this.options.indentation,marked:this.options.marked,markedOptions:this.options.markedOptions,extensions:[]})}},onBeforeCreate(){var t;if(this.editor.markdown){console.error("[tiptap][markdown]: There is already a `markdown` property on the editor instance. This might lead to unexpected behavior.");return}if(this.storage.manager=new di({indentation:this.options.indentation,marked:this.options.marked,markedOptions:this.options.markedOptions,extensions:this.editor.extensionManager.baseExtensions}),this.editor.markdown=this.storage.manager,this.editor.getMarkdown=()=>this.storage.manager.serialize(this.editor.getJSON()),!this.editor.options.contentType||Jr(this.editor.options.content,this.editor.options.contentType)!=="markdown")return;if(!this.editor.markdown)throw new Error('[tiptap][markdown]: The `contentType` option is set to "markdown", but the Markdown extension is not added to the editor. Please add the Markdown extension to use this feature.');if(this.editor.options.content===void 0||typeof this.editor.options.content!="string")throw new Error('[tiptap][markdown]: The `contentType` option is set to "markdown", but the initial content is not a string. Please provide the initial content as a markdown string.');const e=this.editor.markdown.parse(this.editor.options.content);!((t=e.content)===null||t===void 0)&&t.length&&(this.editor.options.content=e)}});function ml(t){return t==="left"||t==="right"||t==="center"?t:null}function Mh(t){const e=(t.style.textAlign||"").trim().toLowerCase(),s=(t.getAttribute("align")||"").trim().toLowerCase();return ml(e||s)}function Ph(t){return ml(t?.align)}function Eo(){return{default:null,parseHTML:t=>Mh(t),renderHTML:t=>t.align?{style:`text-align: ${t.align}`}:{}}}function Fh(t){var e;const s=t.parentElement,n=t.closest("table");if(!s||!n)return null;const r=Array.from(s.children).indexOf(t),l=(e=n.querySelectorAll("colgroup > col")[r])===null||e===void 0?void 0:e.getAttribute("width");return l?[parseInt(l,10)]:null}function Io(t){const e=t.getAttribute("colwidth");return e?e.split(",").map(s=>parseInt(s,10)):Fh(t)}const Oh=/[ \t\r\n\f]+/g;function Lo(t){var e;return t.children.length>0?!1:((e=t.textContent)!==null&&e!==void 0?e:"").replace(Oh,"")===""}function Mo(t){const e=t.createAndFill();if(!e)throw new Error(`[tiptap error]: "${t.name}" has no default content to backfill.`);return e.content}const Hh=cs.create({name:"tableCell",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:Io},align:Eo()}},tableRole:"cell",isolating:!0,parseHTML(){return[{tag:"td",getAttrs:t=>Lo(t)?{}:!1,getContent:(t,e)=>Mo(e.nodes[this.name])},{tag:"td"}]},renderHTML({HTMLAttributes:t}){return["td",Nt(this.options.HTMLAttributes,t),0]}}),qh=cs.create({name:"tableHeader",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:Io},align:Eo()}},tableRole:"header_cell",isolating:!0,parseHTML(){return[{tag:"th",getAttrs:t=>Lo(t)?{}:!1,getContent:(t,e)=>Mo(e.nodes[this.name])},{tag:"th"}]},renderHTML({HTMLAttributes:t}){return["th",Nt(this.options.HTMLAttributes,t),0]}}),Uh=cs.create({name:"tableRow",addOptions(){return{HTMLAttributes:{}}},content:"(tableCell | tableHeader)*",tableRole:"row",parseHTML(){return[{tag:"tr"}]},renderHTML({HTMLAttributes:t}){return["tr",Nt(this.options.HTMLAttributes,t),0]}});function la(t,e){return e?["width",`${Math.max(e,t)}px`]:["min-width",`${t}px`]}function ui(t,e,s,n,r,l){let i=0,c=!0,o=e.firstChild;const d=t.firstChild;if(d!==null)for(let h=0,x=0;h<d.childCount;h+=1){const{colspan:m,colwidth:g}=d.child(h).attrs;for(let k=0;k<m;k+=1,x+=1){const y=r===x?l:g&&g[k],v=y?`${y}px`:"";if(i+=y||n,y||(c=!1),o){if(o.style.width!==v){const[p,b]=la(n,y);o.style.setProperty(p,b)}o=o.nextSibling}else{const p=document.createElement("col"),[b,j]=la(n,y);p.style.setProperty(b,j),e.appendChild(p)}}}for(;o;){var u;const h=o.nextSibling;(u=o.parentNode)===null||u===void 0||u.removeChild(o),o=h}const f=t.attrs.style&&typeof t.attrs.style=="string"&&/\bwidth\s*:/i.test(t.attrs.style);c&&!f?(s.style.width=`${i}px`,s.style.minWidth=""):(s.style.width="",s.style.minWidth=`${i}px`)}var Kh=class{constructor(t,e,s,n={}){this.node=t,this.cellMinWidth=e,this.dom=document.createElement("div"),this.dom.className="tableWrapper",this.table=this.dom.appendChild(document.createElement("table"));for(const[r,l]of Object.entries(n))l!=null&&(r==="style"?this.table.style.cssText=String(l):this.table.setAttribute(r,String(l)));t.attrs.style&&(this.table.style.cssText=t.attrs.style),this.colgroup=this.table.appendChild(document.createElement("colgroup")),ui(t,this.colgroup,this.table,e),this.contentDOM=this.table.appendChild(document.createElement("tbody"))}update(t){return t.type!==this.node.type?!1:(this.node=t,ui(t,this.colgroup,this.table,this.cellMinWidth),!0)}ignoreMutation(t){const e=t.target,s=this.dom.contains(e),n=this.contentDOM.contains(e);return!!(s&&!n&&(t.type==="attributes"||t.type==="childList"||t.type==="characterData"))}};function Wh(t,e,s,n){let r=0,l=!0;const i=[],c=t.firstChild;if(!c)return{};for(let u=0,f=0;u<c.childCount;u+=1){const{colspan:h,colwidth:x}=c.child(u).attrs;for(let m=0;m<h;m+=1,f+=1){const g=s===f?n:x&&x[m];r+=g||e,g||(l=!1);const[k,y]=la(e,g);i.push(["col",{style:`${k}: ${y}`}])}}const o=l?`${r}px`:"",d=l?"":`${r}px`;return{colgroup:["colgroup",{},...i],tableWidth:o,tableMinWidth:d}}function fi(t,e){return t.createAndFill()}function Gh(t){if(t.cached.tableNodeTypes)return t.cached.tableNodeTypes;const e={};return Object.keys(t.nodes).forEach(s=>{const n=t.nodes[s];n.spec.tableRole&&(e[n.spec.tableRole]=n)}),t.cached.tableNodeTypes=e,e}function Vh(t,e,s,n,r){const l=Gh(t),i=[],c=[];for(let d=0;d<s;d+=1){const u=fi(l.cell);if(u&&c.push(u),n){const f=fi(l.header_cell);f&&i.push(f)}}const o=[];for(let d=0;d<e;d+=1)o.push(l.row.createChecked(null,n&&d===0?i:c));return l.table.createChecked(null,o)}function Qh(t){return t instanceof go}const el=({editor:t})=>{const{selection:e}=t.state;if(!Qh(e))return!1;let s=0;const n=ul(e.ranges[0].$from,r=>r.type.name==="table");return n?.node.descendants(r=>{if(r.type.name==="table")return!1;["tableCell","tableHeader"].includes(r.type.name)&&(s+=1)}),s!==e.ranges.length?!1:(t.commands.deleteTable(),!0)};function hi(t,e){const s=t.mapping.map(e),n=ul(t.selection.$from,i=>i.type.name==="table");if(n?.pos===s)return;const r=t.doc.nodeAt(s);if(!r)return;const l=s+r.nodeSize-1;t.setSelection(fo.near(t.doc.resolve(l),-1))}function Yh(t){let e="",s=0;for(;s<t.length;){if(t[s]==="\\"&&s+1<t.length){e+=t[s]+t[s+1],s+=2;continue}if(t[s]!=="`"){e+=t[s++];continue}let n=0;for(;s+n<t.length&&t[s+n]==="`";)n+=1;let r=s+n,l=!1;for(;r<t.length;){if(t[r]!=="`"){r+=1;continue}let i=0;for(;r+i<t.length&&t[r+i]==="`";)i+=1;if(i===n){const c=t.slice(s+n,r);e+=t.slice(s,s+n)+c.replace(/\\\||\|/g,o=>o==="|"?"\\|":o)+t.slice(r,r+n),s=r+n,l=!0;break}r+=i}l||(e+=t.slice(s,s+n),s+=n)}return e}function Zh(t){return t.split(`
|
|
68
|
+
`).map(e=>!e.includes("|")||!e.includes("`")?e:Yh(e)).join(`
|
|
69
|
+
`)}function Xh(t){return(t||"").replace(/\s+/g," ").trim()}function Jh(t,e,s={}){var n;const r=(n=s.cellLineSeparator)!==null&&n!==void 0?n:"";if(!t||!t.content||t.content.length===0)return"";const l=[];t.content.forEach(m=>{const g=[];m.content&&m.content.forEach(k=>{let y="";k.content&&Array.isArray(k.content)&&k.content.length>1?y=k.content.map(j=>e.renderChildren(j)).join(r):y=k.content?e.renderChildren(k.content):"";const v=Xh(y.split(r).join(`
|
|
70
|
+
`).replace(/[ \t]*\r?\n[ \t]*/g,"<br>")),p=k.type==="tableHeader",b=Ph(k.attrs);g.push({text:v,isHeader:p,align:b})}),l.push(g)});const i=l.reduce((m,g)=>Math.max(m,g.length),0);if(i===0)return"";const c=Array.from({length:i}).fill(0);l.forEach(m=>{for(let k=0;k<i;k+=1){var g;const y=(((g=m[k])===null||g===void 0?void 0:g.text)||"").length;y>c[k]&&(c[k]=y),c[k]<3&&(c[k]=3)}});const o=(m,g)=>m+" ".repeat(Math.max(0,g-m.length)),d=l[0],u=d.some(m=>m.isHeader),f=Array.from({length:i}).fill(null);l.forEach(m=>{for(let k=0;k<i;k+=1){var g;!f[k]&&(!((g=m[k])===null||g===void 0)&&g.align)&&(f[k]=m[k].align)}});let h=`
|
|
71
|
+
`;const x=Array.from({length:i}).map((m,g)=>u&&d[g]&&d[g].text||"");return h+=`| ${x.map((m,g)=>o(m,c[g])).join(" | ")} |
|
|
72
|
+
`,h+=`| ${c.map((m,g)=>{const k=Math.max(3,m),y=f[g];return y==="left"?`:${"-".repeat(k)}`:y==="right"?`${"-".repeat(k)}:`:y==="center"?`:${"-".repeat(k)}:`:"-".repeat(k)}).join(" | ")} |
|
|
73
|
+
`,(u?l.slice(1):l).forEach(m=>{h+=`| ${Array.from({length:i}).fill(0).map((g,k)=>o(m[k]&&m[k].text||"",c[k])).join(" | ")} |
|
|
74
|
+
`}),h}const e1=cs.create({name:"table",addOptions(){return{HTMLAttributes:{},resizable:!1,renderWrapper:!1,handleWidth:5,cellMinWidth:25,View:Kh,lastColumnResizable:!0,allowTableNodeSelection:!1}},content:"tableRow+",tableRole:"table",isolating:!0,group:"block",parseHTML(){return[{tag:"table"}]},renderHTML({node:t,HTMLAttributes:e}){const{colgroup:s,tableWidth:n,tableMinWidth:r}=Wh(t,this.options.cellMinWidth),l=e.style;function i(){return l||(n?`width: ${n}`:`min-width: ${r}`)}const c=["table",Nt(this.options.HTMLAttributes,e,{style:i()}),s,["tbody",0]];return this.options.renderWrapper?["div",{class:"tableWrapper"},c]:c},parseMarkdown:(t,e)=>{const s=[],n=Array.isArray(t.align)?t.align:[];if(t.header){const r=[];t.header.forEach((l,i)=>{var c;const o=ml((c=n[i])!==null&&c!==void 0?c:l.align),d=o?{align:o}:{};r.push(e.createNode("tableHeader",d,[{type:"paragraph",content:e.parseInline(l.tokens)}]))}),s.push(e.createNode("tableRow",{},r))}return t.rows&&t.rows.forEach(r=>{const l=[];r.forEach((i,c)=>{var o;const d=ml((o=n[c])!==null&&o!==void 0?o:i.align),u=d?{align:d}:{};l.push(e.createNode("tableCell",u,[{type:"paragraph",content:e.parseInline(i.tokens)}]))}),s.push(e.createNode("tableRow",{},l))}),e.createNode("table",void 0,s)},renderMarkdown:(t,e)=>Jh(t,e),markdownTokenizer:{name:"table",level:"block",start:t=>{const e=t.split(`
|
|
75
|
+
`);if(e.length<2)return-1;const s=e[1];return!/^[ \t|:]*-[ \t|:-]*$/.test(s)||!s.includes("|")?-1:e[0].includes("|")?0:-1},tokenize(t,e,s){const n=t.indexOf(`
|
|
76
|
+
|
|
77
|
+
`),r=n>=0?t.slice(0,n):t,l=r.split(`
|
|
78
|
+
`);if(l.length<2)return;const i=l[1];if(!/^[ \t|:]*-[ \t|:-]*$/.test(i)||!i.includes("|"))return;const c=Zh(r);if(c===r)return;const o=s.blockTokens(c)[0];if(o?.type!=="table"||!o.raw)return;const d=o.raw.split(`
|
|
79
|
+
`).length,u=t.split(`
|
|
80
|
+
`).slice(0,d).join(`
|
|
81
|
+
`);return{...o,raw:u}}},addCommands(){return{insertTable:({rows:t=3,cols:e=3,withHeaderRow:s=!0}={})=>({tr:n,dispatch:r,editor:l})=>{const i=Vh(l.schema,t,e,s);if(r){const c=n.selection.from+1;n.replaceSelectionWith(i).scrollIntoView().setSelection(fo.near(n.doc.resolve(c)))}return!0},addColumnBefore:()=>({state:t,dispatch:e})=>_u(t,e),addColumnAfter:()=>({state:t,dispatch:e})=>Bu(t,e),deleteColumn:()=>({state:t,dispatch:e})=>{const s=ul(t.selection.$from,n=>n.type.name==="table");return Tu(t,e&&(n=>{s&&hi(n,s.pos),e(n)}))},addRowBefore:()=>({state:t,dispatch:e})=>Nu(t,e),addRowAfter:()=>({state:t,dispatch:e})=>Cu(t,e),deleteRow:()=>({state:t,dispatch:e})=>{const s=ul(t.selection.$from,n=>n.type.name==="table");return Su(t,e&&(n=>{s&&hi(n,s.pos),e(n)}))},deleteTable:()=>({state:t,dispatch:e})=>wu(t,e),mergeCells:()=>({state:t,dispatch:e})=>Ya(t,e),splitCell:()=>({state:t,dispatch:e})=>Za(t,e),toggleHeaderColumn:()=>({state:t,dispatch:e})=>Xa("column")(t,e),toggleHeaderRow:()=>({state:t,dispatch:e})=>Xa("row")(t,e),toggleHeaderCell:()=>({state:t,dispatch:e})=>vu(t,e),mergeOrSplit:()=>({state:t,dispatch:e})=>Ya(t,e)?!0:Za(t,e),setCellAttribute:(t,e)=>({state:s,dispatch:n})=>ju(t,e)(s,n),goToNextCell:()=>({state:t,dispatch:e})=>Qa(1)(t,e),goToPreviousCell:()=>({state:t,dispatch:e})=>Qa(-1)(t,e),fixTables:()=>({state:t,dispatch:e})=>(e&&yu(t),!0),setCellSelection:t=>({tr:e,dispatch:s})=>{if(s){const n=go.create(e.doc,t.anchorCell,t.headCell);e.setSelection(n)}return!0}}},addKeyboardShortcuts(){return{Tab:()=>this.editor.commands.goToNextCell()?!0:this.editor.can().addRowAfter()?this.editor.chain().addRowAfter().goToNextCell().run():!1,"Shift-Tab":()=>this.editor.commands.goToPreviousCell(),Backspace:el,"Mod-Backspace":el,Delete:el,"Mod-Delete":el}},addProseMirrorPlugins(){return[...this.options.resizable&&this.editor.isEditable?[ku({handleWidth:this.options.handleWidth,cellMinWidth:this.options.cellMinWidth,defaultCellMinWidth:this.options.cellMinWidth,View:this.options.View,lastColumnResizable:this.options.lastColumnResizable})]:[],bu({allowTableNodeSelection:this.options.allowTableNodeSelection})]},addNodeView(){const t=this.options.resizable&&this.editor.isEditable,e=this.options.View;return t||!e?null:({node:s,view:n,HTMLAttributes:r})=>{const l=Nt(this.options.HTMLAttributes,r);return new e(s,this.options.cellMinWidth,n,l)}},extendNodeSchema(t){const e={name:t.name,options:t.options,storage:t.storage};return{tableRole:uo(Zt(t,"tableRole",e))}}}),t1=ba.create({name:"tableKit",addExtensions(){const t=[];return this.options.table!==!1&&t.push(e1.configure(this.options.table)),this.options.tableCell!==!1&&t.push(Hh.configure(this.options.tableCell)),this.options.tableHeader!==!1&&t.push(qh.configure(this.options.tableHeader)),this.options.tableRow!==!1&&t.push(Uh.configure(this.options.tableRow)),t}});function s1(t){const e=$.c(25),{node:s,selected:n,editor:r,deleteNode:l}=t,i=J(),c=typeof s.attrs.href=="string"?s.attrs.href:"",o=typeof s.attrs.name=="string"?s.attrs.name:"";let d;e[0]!==o||e[1]!==i?(d=o||i("markdownEditor.fileNameFallback"),e[0]=o,e[1]=i,e[2]=d):d=e[2];const u=d,f=n&&"ring-2 ring-ring ring-offset-2 ring-offset-background";let h;e[3]!==f?(h=F("mx-0.5 inline-flex max-w-full select-none items-center gap-1.5 rounded-lg border border-border bg-card px-2 py-1 align-middle text-sm text-foreground",f),e[3]=f,e[4]=h):h=e[4];let x;e[5]===Symbol.for("react.memo_cache_sentinel")?(x=a.jsx(zu,{size:14,className:"shrink-0 text-muted-foreground"}),e[5]=x):x=e[5];let m;e[6]!==u?(m=a.jsx("span",{className:"min-w-0 truncate",children:u}),e[6]=u,e[7]=m):m=e[7];let g;e[8]!==u||e[9]!==i?(g=i("markdownEditor.downloadFile",{name:u}),e[8]=u,e[9]=i,e[10]=g):g=e[10];let k;e[11]===Symbol.for("react.memo_cache_sentinel")?(k=a.jsx(Ru,{size:14}),e[11]=k):k=e[11];let y;e[12]!==c||e[13]!==u||e[14]!==g?(y=a.jsx("a",{href:c,download:u,"aria-label":g,onMouseDown:r1,className:"shrink-0 rounded-md p-0.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:k}),e[12]=c,e[13]=u,e[14]=g,e[15]=y):y=e[15];let v;e[16]!==l||e[17]!==r.isEditable||e[18]!==i?(v=r.isEditable&&a.jsx("button",{type:"button","aria-label":i("markdownEditor.removeFile"),onMouseDown:n1,onClick:l,className:"shrink-0 classic:rounded-md compact:rounded-lg p-0.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:a.jsx(Ht,{size:14})}),e[16]=l,e[17]=r.isEditable,e[18]=i,e[19]=v):v=e[19];let p;return e[20]!==h||e[21]!==m||e[22]!==y||e[23]!==v?(p=a.jsxs(ja,{as:"span",className:h,children:[x,m,y,v]}),e[20]=h,e[21]=m,e[22]=y,e[23]=v,e[24]=p):p=e[24],p}function n1(t){return t.preventDefault()}function r1(t){return t.preventDefault()}function l1(t){return t.replace(/([[\]])/g,"\\$1")}const a1=cs.create({name:"attachment",group:"inline",inline:!0,atom:!0,draggable:!0,addAttributes(){return{href:{default:null,parseHTML:t=>t.getAttribute("href"),renderHTML:t=>t.href?{href:t.href}:{}},name:{default:null,parseHTML:t=>t.getAttribute("data-name")||t.textContent,renderHTML:t=>t.name?{"data-name":t.name}:{}}}},parseHTML(){return[{tag:"a[data-attachment]"}]},renderHTML({HTMLAttributes:t,node:e}){return["a",Nt(t,{"data-attachment":""}),typeof e.attrs.name=="string"?e.attrs.name:""]},renderMarkdown:t=>{const e=typeof t.attrs?.href=="string"?t.attrs.href:"",s=typeof t.attrs?.name=="string"?t.attrs.name:"";return`[${l1(s)}](${e})`},addNodeView(){return ya(s1)}});function i1(t){const e=$.c(5),{node:s,selected:n}=t,r=typeof s.attrs.name=="string"?s.attrs.name:"",l=n&&"ring-2 ring-ring";let i;e[0]!==l?(i=F("select-none rounded px-1 font-medium text-primary","bg-primary/10",l),e[0]=l,e[1]=i):i=e[1];let c;return e[2]!==r||e[3]!==i?(c=a.jsxs(ja,{as:"span","data-testid":"mention-chip",className:i,children:["@",r]}),e[2]=r,e[3]=i,e[4]=c):c=e[4],c}const Po=cs.create({name:"mention",group:"inline",inline:!0,atom:!0,selectable:!0,addAttributes(){return{id:{default:null,parseHTML:t=>t.getAttribute("data-mention-id"),renderHTML:t=>t.id?{"data-mention-id":t.id}:{}},name:{default:null,parseHTML:t=>t.getAttribute("data-mention-name"),renderHTML:t=>t.name?{"data-mention-name":t.name}:{}}}},parseHTML(){return[{tag:"span[data-mention-id]"}]},renderHTML({HTMLAttributes:t,node:e}){return["span",Nt(t),`@${typeof e.attrs.name=="string"?e.attrs.name:""}`]},renderMarkdown:t=>{const e=typeof t.attrs?.id=="string"?t.attrs.id:"",s=typeof t.attrs?.name=="string"?t.attrs.name:"";return e?eu(e,s):`@${s}`},addNodeView(){return ya(i1)}}),o1="studio.mention-members.",aa=new Map;function pi(t){const e=aa.get(t);if(e)return e;try{const s=localStorage.getItem(t);if(!s)return;const n=JSON.parse(s);if(!Array.isArray(n))return;const r=n.filter(l=>!!l&&typeof l.id=="string"&&typeof l.name=="string");return aa.set(t,r),r}catch{return}}function c1(t,e){aa.set(t,e);try{localStorage.setItem(t,JSON.stringify(e))}catch{}}function d1(t,e){if(!t?.length)return e;const s=new Map(t.map(n=>[n.id,n]));return e.map(n=>{const r=s.get(n.id);return r&&r.name===n.name&&r.email===n.email&&r.image===n.image?r:n})}function u1(t){return t.map(e=>({id:e.userId,name:e.user?.name?.trim()||e.user?.email?.trim()||"",email:e.user?.email??"",image:e.user?.image??null})).filter(e=>!!e.name).sort((e,s)=>e.name.localeCompare(s.name))}function f1(t){const e=$.c(17),{locator:s}=Qe(),n=Eu(),r=`${o1}${s}`;let l;e[0]!==s?(l=ft.mentionMembers(s),e[0]=s,e[1]=l):l=e[1];let i;e[2]!==r?(i=()=>pi(r),e[2]=r,e[3]=i):i=e[3];let c;e[4]!==n||e[5]!==r?(c=async()=>{const x=await n.organization.listMembers(),m=d1(pi(r),u1(x?.data?.members??[]));return c1(r,m),m},e[4]=n,e[5]=r,e[6]=c):c=e[6];let o;e[7]!==t||e[8]!==l||e[9]!==i||e[10]!==c?(o={queryKey:l,enabled:t,staleTime:0,placeholderData:i,queryFn:c},e[7]=t,e[8]=l,e[9]=i,e[10]=c,e[11]=o):o=e[11];const d=xr(o);let u;e[12]!==d.data?(u=d.data??[],e[12]=d.data,e[13]=u):u=e[13];const f=d.isFetching&&!d.data;let h;return e[14]!==u||e[15]!==f?(h={members:u,loading:f},e[14]=u,e[15]=f,e[16]=h):h=e[16],h}const mi={query:"",range:null,rect:null,editor:null};class Fo{state=mi;listeners=new Set;dismissal=null;latched=!1;subscribe=e=>(this.listeners.add(e),()=>this.listeners.delete(e));getSnapshot=()=>this.state;set(e){this.state=e;for(const s of this.listeners)s()}close(){this.latched=!1,this.set(mi)}}const wl=new ou("markdownEditorMention");function h1(t,e,s){t.chain().focus().insertContentAt(e,[{type:"mention",attrs:{id:s.id,name:s.name}},{type:"text",text:" "}]).run(),xo(t.view,wl)}function p1(t,e,s){const n=Math.min(e+s,t.content.size);return e>=n?"":t.textBetween(e,n,"","")}function Oo(t,e){const s=e.getSnapshot().range??void 0;s&&s.to>s.from&&(e.dismissal={from:s.from,text:t.state.doc.textBetween(s.from,s.to,"")}),xo(t.view,wl)}function Ho(t){return ba.create({name:"mentionSuggestion",addProseMirrorPlugins(){const e={editor:this.editor,char:"@",pluginKey:wl,allowedPrefixes:[" ",`
|
|
82
|
+
`],allow:({state:s,range:n})=>{const r=t.dismissal;return r?n.from===r.from&&p1(s.doc,r.from,r.text.length)===r.text?!1:(t.dismissal=null,!0):!0},items:()=>[],render:()=>({onStart:s=>{t.set({query:s.query,range:s.range,rect:s.clientRect??null,editor:s.editor})},onUpdate:s=>{t.set({query:s.query,range:s.range,rect:s.clientRect??null,editor:s.editor})},onKeyDown:({event:s})=>s.key==="Escape"?(Oo(this.editor,t),t.close(),!0):!1,onExit:()=>{t.latched||t.close()}})};return[Du(e)]}})}const gi=256,m1=40,xi=280,g1=140;function qo(t){const e=$.c(4),{store:s}=t,n=W.useSyncExternalStore(s.subscribe,s.getSnapshot),r=n.range!==null;let l;return e[0]!==r||e[1]!==n||e[2]!==s?(l=r?a.jsx(x1,{store:s,state:n}):null,e[0]=r,e[1]=n,e[2]=s,e[3]=l):l=e[3],l}function x1({store:t,state:e}){const s=J(),{members:n,loading:r}=f1(!0),[l,i]=W.useState(e.query),[c,o]=W.useState(null),d=k1(e.editor),u=d.getBoundingClientRect(),f=d===document.body?new DOMRect(0,0,window.innerWidth,window.innerHeight):u,h=e.rect?.()??new DOMRect(0,0,0,0),x=f.bottom-h.bottom,m=x<xi&&h.top-f.top>x,g=(m?h.top-f.top:x)-8,k=Math.min(xi,Math.max(g,g1))-m1,y={position:"absolute",width:gi,left:Math.min(h.left,f.right-gi-8)-u.left,...m?{bottom:u.bottom-h.top+6}:{top:h.bottom-u.top+6}},v=()=>{e.editor&&Oo(e.editor,t),t.close()},p=j=>{const w=j.relatedTarget;if((!w||e.editor?.view.dom.contains(w)===!0)&&t.latched){c?.focus();return}v()},b=j=>{!e.editor||!e.range||(h1(e.editor,e.range,j),t.close())};return Ei.createPortal(a.jsx("div",{style:y,"data-testid":"mention-menu",className:"z-50 overflow-hidden rounded-lg border border-border bg-popover shadow-md",children:a.jsxs(os,{onKeyDown:j=>{j.key==="Escape"&&(j.preventDefault(),v(),e.editor?.commands.focus())},children:[a.jsx(ls,{ref:o,autoFocus:!0,onFocus:()=>{t.latched=!0},value:l,onValueChange:i,placeholder:s("markdownEditor.mentionSearch"),onBlur:p}),a.jsxs(is,{style:{maxHeight:k},children:[r?a.jsx("div",{className:"flex items-center justify-center py-6",children:a.jsx(yt,{size:"sm"})}):a.jsx(as,{children:s("markdownEditor.mentionEmpty")}),n.map(j=>a.jsxs(He,{value:`${j.name} ${j.email}`,onSelect:()=>b(j),onMouseDown:w=>w.preventDefault(),className:"gap-2",children:[a.jsx(Fe,{url:j.image??void 0,fallback:Oe(j.name),shape:"circle",size:"xs"}),a.jsx("span",{className:"min-w-0 flex-1 truncate",children:j.name})]},j.id))]})]})}),d)}function k1(t){const e=t?.view.dom.closest('[role="dialog"]');return e instanceof HTMLElement?e:document.body}const b1=/(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/,y1=cs.create({name:"image",addOptions(){return{inline:!1,allowBase64:!1,HTMLAttributes:{},resize:!1}},inline(){return this.options.inline},group(){return this.options.inline?"inline":"block"},draggable:!0,addAttributes(){return{src:{default:null},alt:{default:null},title:{default:null},width:{default:null},height:{default:null}}},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])'}]},renderHTML({HTMLAttributes:t}){return["img",Nt(this.options.HTMLAttributes,t)]},parseMarkdown:(t,e)=>e.createNode("image",{src:t.href,title:t.title,alt:t.text}),renderMarkdown:t=>{var e,s,n,r,l,i;const c=(e=(s=t.attrs)===null||s===void 0?void 0:s.src)!==null&&e!==void 0?e:"",o=(n=(r=t.attrs)===null||r===void 0?void 0:r.alt)!==null&&n!==void 0?n:"",d=(l=(i=t.attrs)===null||i===void 0?void 0:i.title)!==null&&l!==void 0?l:"";return d?``:``},addNodeView(){if(!this.options.resize||!this.options.resize.enabled||typeof document>"u")return null;const{directions:t,minWidth:e,minHeight:s,alwaysPreserveAspectRatio:n}=this.options.resize,r=new Set(["src","width","height"]);return({node:l,getPos:i,HTMLAttributes:c,editor:o})=>{const d=document.createElement("img");d.draggable=!1;const u=Nt(this.options.HTMLAttributes,c);Object.entries(u).forEach(([y,v])=>{if(v!=null)switch(y){case"src":case"width":case"height":break;default:d.setAttribute(y,v)}}),u.src!==null&&(d.src=u.src);let f={...c};const h=y=>{if(typeof y=="string"&&y!==""){d.getAttribute("src")!==y&&(d.src=y);return}d.hasAttribute("src")&&d.removeAttribute("src"),d.src!==""&&(d.src="")};h(c.src);const x=y=>{if(y.type!==l.type)return!1;const v=o.extensionManager.attributes.filter(b=>b.type===y.type.name),p=uu(y,v);return Object.keys(f).forEach(b=>{!r.has(b)&&!(b in p)&&d.removeAttribute(b)}),Object.entries(p).forEach(([b,j])=>{r.has(b)||(j!=null?d.setAttribute(b,j):d.removeAttribute(b))}),h(p.src),f=p,!0},m=new du({element:d,editor:o,node:l,getPos:i,onResize:(y,v)=>{d.style.width=`${y}px`,d.style.height=`${v}px`},onCommit:(y,v)=>{const p=i();p!==void 0&&this.editor.chain().setNodeSelection(p).updateAttributes(this.name,{width:y,height:v}).run()},onUpdate:x,options:{directions:t,min:{width:e,height:s},preserveAspectRatio:n===!0}}),g=m.dom,k=()=>{g.style.visibility="",g.style.pointerEvents=""};return g.style.visibility="hidden",g.style.pointerEvents="none",d.complete&&d.naturalWidth>0?k():(d.onload=k,d.onerror=k),m}},addCommands(){return{setImage:t=>({commands:e})=>e.insertContent({type:this.name,attrs:t})}},addInputRules(){return[cu({find:b1,type:this.type,getAttributes:t=>{const[,,e,s,n]=t;return{src:s,alt:e,title:n}}})]}});var j1=y1;function v1(t){const e=$.c(16),{node:s,selected:n,editor:r,deleteNode:l}=t,i=J(),c=typeof s.attrs.src=="string"?s.attrs.src:"",o=typeof s.attrs.alt=="string"?s.attrs.alt:"";let d;e[0]!==o||e[1]!==i?(d=o||i("markdownEditor.imageAltFallback"),e[0]=o,e[1]=i,e[2]=d):d=e[2];const u=n&&"ring-2 ring-ring ring-offset-2 ring-offset-background";let f;e[3]!==u?(f=F("max-h-[420px] max-w-full rounded-lg border border-border object-contain",u),e[3]=u,e[4]=f):f=e[4];let h;e[5]!==c||e[6]!==d||e[7]!==f?(h=a.jsx("img",{src:c,alt:d,draggable:!1,className:f}),e[5]=c,e[6]=d,e[7]=f,e[8]=h):h=e[8];let x;e[9]!==l||e[10]!==r.isEditable||e[11]!==i?(x=r.isEditable&&a.jsx("button",{type:"button","aria-label":i("markdownEditor.removeImage"),onMouseDown:w1,onClick:l,className:"absolute right-2 top-2 flex size-7 items-center justify-center classic:rounded-md compact:rounded-lg border border-border bg-card text-muted-foreground opacity-0 shadow-sm transition-opacity hover:text-foreground focus-visible:opacity-100 group-hover/image:opacity-100",children:a.jsx(Ht,{size:14})}),e[9]=l,e[10]=r.isEditable,e[11]=i,e[12]=x):x=e[12];let m;return e[13]!==h||e[14]!==x?(m=a.jsxs(ja,{className:"group/image relative my-3 w-fit max-w-full",children:[h,x]}),e[13]=h,e[14]=x,e[15]=m):m=e[15],m}function w1(t){return t.preventDefault()}const S1=j1.extend({addNodeView(){return ya(v1)}}).configure({inline:!1,allowBase64:!1}),ia="uploads",C1="editor-images",Uo="editor-files",N1=new RegExp(`^/api/[^/]+/fs/${ia}/read$`),ki="http://relative.invalid";function T1(t){let e;try{e=new URL(t,ki)}catch{return!1}return e.origin!==ki||!N1.test(e.pathname)?!1:(e.searchParams.get("path")??"").startsWith(`${Uo}/`)}const B1={openOnClick:!1,autolink:!0,HTMLAttributes:{rel:"noopener noreferrer",target:"_blank"}},_1=fu.extend({parseMarkdown:(t,e)=>{const s=typeof t.href=="string"?t.href:"";if(T1(s))return e.createNode("attachment",{href:s,name:t.text??""});const n=tu(s);return n?e.createNode("mention",{id:n,name:(t.text??"").replace(/^@/,"")}):e.applyMark("link",e.parseInline(t.tokens??[]),{href:s,title:t.title||null})}});function A1(t="",e){return[ho.configure({heading:{levels:[1,2,3]},underline:!1,link:!1}),_1.configure(B1),ko.configure({placeholder:t}),t1,hu,pu.configure({nested:!0}),S1,a1,Po,...e?[Ho(e)]:[],zo.configure({markedOptions:{breaks:!0}})]}const $1=/^(\s*)([-*+]|\d+[.)])\s+\S/,D1=/^\s*(```|~~~)/,R1=/^\s+(?![-*+>#]|\d+[.)]\s)\S/;function z1(t){const e=[];let s=!1,n=!1;for(const r of t.split(`
|
|
83
|
+
`)){if(D1.test(r)){s=!s,n=!1,e.push(r);continue}if(s){e.push(r);continue}if($1.test(r)){n=!0,e.push(r);continue}if(!r.trim()){n=!1,e.push(r);continue}if(n&&R1.test(r)){e[e.length-1]=`${e[e.length-1]} ${r.trim()}`;continue}n=!1,e.push(r)}return e.join(`
|
|
84
|
+
`)}const E1=10,I1=25,L1={"image/png":".png","image/jpeg":".jpg","image/gif":".gif","image/webp":".webp","image/avif":".avif","image/svg+xml":".svg"};function M1(t){return t.name.match(/\.[a-z0-9]{1,8}$/i)?.[0]??L1[t.type]??(za(t)?".png":"")}function za(t){return t.type.startsWith("image/")}function P1(){const t=J(),{upload:e}=Iu(ia),s=Lu(ia),[n,r]=W.useState(0);return{uploadFile:async i=>{const c=za(i),o=c?E1:I1;if(i.size>o*1024*1024)return Je.error(t("markdownEditor.fileTooLarge",{name:i.name,max:String(o)})),null;const d=c?C1:Uo,u=`${crypto.randomUUID()}${M1(i)}`;r(f=>f+1);try{return await e.mutateAsync({dir:d,files:[new File([i],u,{type:i.type})]}),s(`${d}/${u}`)}catch{return Je.error(t("markdownEditor.uploadFailed",{name:i.name})),null}finally{r(f=>f-1)}},pending:n}}const F1=["outline-none","min-h-[200px] sm:min-h-[320px]","[&>*:first-child]:mt-0 [&>*:last-child]:mb-0","[&_p]:my-3 [&_p]:leading-[1.5]","[&_h1]:my-3 [&_h1]:text-xl [&_h1]:font-semibold [&_h1]:leading-[1.5] [&_h1]:text-foreground","[&_h2]:my-3 [&_h2]:text-lg [&_h2]:font-semibold [&_h2]:leading-[1.5] [&_h2]:text-foreground","[&_h3]:my-3 [&_h3]:text-base [&_h3]:font-semibold [&_h3]:leading-[1.5] [&_h3]:text-foreground","[&_ul]:my-3 [&_ul]:list-disc [&_ul]:pl-5","[&_ol]:my-3 [&_ol]:list-decimal [&_ol]:pl-5","[&_li]:my-0.5 [&_li>p]:my-0","[&_blockquote]:my-2 [&_blockquote]:border-l-2 [&_blockquote]:border-border [&_blockquote]:pl-3 [&_blockquote]:text-muted-foreground","[&_code]:rounded [&_code]:bg-muted [&_code]:px-1 [&_code]:py-0.5 [&_code]:font-mono [&_code]:text-[0.85em]","[&_pre]:my-3 [&_pre]:overflow-x-auto [&_pre]:rounded-lg [&_pre]:bg-muted [&_pre]:p-3 [&_pre]:font-mono [&_pre]:text-[13px]","[&_pre_code]:bg-transparent [&_pre_code]:p-0","[&_a]:text-primary [&_a]:underline [&_a]:underline-offset-2","[&_hr]:my-4 [&_hr]:border-border","[&_strong]:font-semibold [&_strong]:text-foreground","[&_table]:my-3 [&_table]:w-full [&_table]:table-fixed [&_table]:border-collapse","[&_th]:border [&_th]:border-border [&_th]:bg-muted [&_th]:p-2 [&_th]:text-left [&_th]:font-semibold","[&_td]:border [&_td]:border-border [&_td]:p-2 [&_td]:align-top","[&_th>p]:my-0 [&_td>p]:my-0","[&_ul[data-type=taskList]]:my-3 [&_ul[data-type=taskList]]:list-none [&_ul[data-type=taskList]]:pl-0","[&_li[data-type=taskItem]]:flex [&_li[data-type=taskItem]]:items-start [&_li[data-type=taskItem]]:gap-2","[&_li[data-type=taskItem]>label]:mt-1 [&_li[data-type=taskItem]>label]:shrink-0","[&_li[data-type=taskItem]>div]:min-w-0 [&_li[data-type=taskItem]>div>p]:my-0"].join(" "),O1=["[&_p.is-editor-empty:first-child::before]:content-[attr(data-placeholder)]","[&_p.is-editor-empty:first-child::before]:text-muted-foreground/50","[&_p.is-editor-empty:first-child::before]:float-left","[&_p.is-editor-empty:first-child::before]:h-0","[&_p.is-editor-empty:first-child::before]:pointer-events-none"].join(" ");function bi(t,e,s,n){const r=t.state.schema.nodes[s];if(!r)return e;const l=t.state.tr.replaceWith(e,e,r.create(n)),i=l.mapping.map(e,1);return l.setSelection(mu.near(l.doc.resolve(i))),t.dispatch(l),t.state.selection.to}function H1({defaultValue:t,onChange:e,placeholder:s,editable:n=!0}){const r=J(),{uploadFile:l,pending:i}=P1(),[c]=W.useState(()=>new Fo),o=W.useRef(null),d=W.useRef(e),u=W.useRef(l);d.current=e,u.current=l;const f=(m,g,k)=>g.length===0?!1:((async()=>{let y=k;for(const v of g){const p=await u.current(v);p&&(y=za(v)?bi(m,y,"image",{src:p,alt:v.name}):bi(m,y,"attachment",{href:p,name:v.name}))}})(),!0),h=po({extensions:A1(s,c),content:z1(t),contentType:"markdown",editable:n,editorProps:{attributes:{role:"textbox","aria-label":s??"","aria-multiline":"true",class:F(F1,O1)},handlePaste:(m,g)=>{const k=Array.from(g.clipboardData?.files??[]);return k.length===0?!1:(g.stopPropagation(),f(m,k,m.state.selection.to))},handleDrop:(m,g,k,y)=>{if(y)return!1;const v=Array.from(g.dataTransfer?.files??[]);if(v.length===0)return!1;const p=m.posAtCoords({left:g.clientX,top:g.clientY})?.pos;return p===void 0?!1:(g.stopPropagation(),f(m,v,p))}},onUpdate:({editor:m,transaction:g})=>{g.docChanged&&d.current(m.getMarkdown())}});if(!h)return null;const x=m=>{!m||m.length===0||f(h.view,Array.from(m),h.state.selection.to)};return a.jsxs("div",{className:"flex flex-col",children:[a.jsx(If,{editor:h}),a.jsx(qo,{store:c}),a.jsx(mo,{editor:h,className:"text-[15px] text-muted-foreground"}),a.jsxs("div",{className:"mt-4 flex items-center gap-2 text-xs text-muted-foreground",children:[n&&a.jsx(ke,{type:"button",variant:"ghost",size:"icon-sm","aria-label":r("markdownEditor.attachFile"),onClick:()=>o.current?.click(),children:a.jsx(Mc,{size:14})}),i>0&&a.jsxs("span",{className:"inline-flex items-center gap-1.5","aria-live":"polite",role:"status",children:[a.jsx(yt,{className:"size-3"}),i===1?r("markdownEditor.uploading"):r("markdownEditor.uploadingCount",{count:String(i)})]})]}),a.jsx("input",{ref:o,type:"file",multiple:!0,className:"hidden",onChange:m=>{x(m.target.files),m.target.value=""}})]})}const q1="claude-subscription";function U1(t){const e=(t??[]).filter(s=>s.costUsd!==null);return e.length===0?null:{total:e.reduce((s,n)=>s+(n.costUsd??0),0),runCount:e.length,onSubscription:e.every(s=>s.costProvider===q1)}}function K1(t,e){const s=t.state==="open"&&!t.merged,n=t.mergeable===!1,r=t.checksStatus!=="failing";return{isOpen:s,hasConflict:n,showShip:e&&s&&r&&!n,showResolveConflict:e&&s&&n}}function Ko(t){if(t.status!=="completed")return!1;const e=t.conclusion;return e==="success"||e==="neutral"||e==="skipped"}function W1(t,e,s){return t!=="failing"||s||e.length===0?null:{passed:e.filter(Ko).length,total:e.length}}function G1(t,e){return new URL(e,t).toString()}function Wo(t){for(let e=t.length-1;e>=0;e--){const s=t[e];if(!s||s.action!=="status_changed")continue;if(typeof s.data?.retry=="number")return null;const n=s.data?.reason;return typeof n!="string"?null:Mu(n.replace(/^Error:\s*/,""))}return null}function V1({orgSlug:t,repo:e,repositories:s,returnTo:n}){const r=`/api/${encodeURIComponent(t)}/git-providers/github`,l=e?s.find(c=>c.path===e)?.accountId:null;if(!l)return{url:`${r}/install?returnTo=${encodeURIComponent(n)}`,ownerOnly:!1,owner:null};const i=e?.includes("/")?e.split("/")[0]:null;return{url:`${r}/accounts/${encodeURIComponent(l)}/manage`,ownerOnly:i!==null,owner:i}}const yi=()=>0;function Q1(t){const{orgSlug:e,itemId:s,onPrs:n}=t,r=W.useRef(n);r.current=n;const l=W.useRef(null),i=W.useRef(""),c=`${e}:${s??""}`;(!l.current||i.current!==c)&&(i.current=c,l.current=o=>{if(!e||!s)return()=>{};const d=u=>{let f;try{f=JSON.parse(u.data)}catch{return}f.data?.id!==s||!Array.isArray(f.data.prs)||(r.current(f.data.prs),o())};return Hu.subscribe(e,d)}),W.useSyncExternalStore(l.current,yi,yi)}const Go=1440*60*1e3,Y1=40;function Vo(t){try{const e=window.localStorage.getItem(Ii.taskBoardPrs(t));return e?JSON.parse(e):{}}catch{return{}}}function Z1(t){const e=Date.now(),s=Object.entries(t).filter(([,n])=>e-n.updatedAt<=Go);for(s.sort(([,n],[,r])=>n.updatedAt-r.updatedAt);s.length>Y1;)s.shift();return Object.fromEntries(s)}function ji(t,e){if(typeof window>"u")return null;const s=Vo(t)[e];return!s||Date.now()-s.updatedAt>Go?null:s}function X1(t,e,s){if(!(typeof window>"u"))try{const n=Vo(t);n[e]={data:s,updatedAt:Date.now()},window.localStorage.setItem(Ii.taskBoardPrs(t),JSON.stringify(Z1(n)))}catch{}}const J1=6e4,ep=2e3,tp=t=>t.state===null;function Qo(t){const e=$.c(25),{org:s,locator:n}=Qe(),r=Ut(),l=$r();let i;e[0]!==t||e[1]!==n||e[2]!==l?(i=m=>{l.setQueryData(ft.taskBoardItemPrs(n,t??""),m)},e[0]=t,e[1]=n,e[2]=l,e[3]=i):i=e[3];let c;e[4]!==t||e[5]!==s.slug||e[6]!==i?(c={orgSlug:s.slug,itemId:t,onPrs:i},e[4]=t,e[5]=s.slug,e[6]=i,e[7]=c):c=e[7],Q1(c);let o;e[8]!==t||e[9]!==n?(o=ft.taskBoardItemPrs(n,t??""),e[8]=t,e[9]=n,e[10]=o):o=e[10];const d=!!t;let u,f;e[11]!==t||e[12]!==n?(u=()=>t?ji(n,t)?.data??void 0:void 0,f=()=>t?ji(n,t)?.updatedAt:void 0,e[11]=t,e[12]=n,e[13]=u,e[14]=f):(u=e[13],f=e[14]);let h;e[15]!==t||e[16]!==n||e[17]!==r?(h=async()=>{const{prs:m}=await r.call("TASK_BOARD_ITEM_PRS_GET",{taskBoardItemId:t});return X1(n,t,m),m},e[15]=t,e[16]=n,e[17]=r,e[18]=h):h=e[18];let x;return e[19]!==o||e[20]!==d||e[21]!==u||e[22]!==f||e[23]!==h?(x={queryKey:o,enabled:d,refetchInterval:sp,initialData:u,initialDataUpdatedAt:f,queryFn:h},e[19]=o,e[20]=d,e[21]=u,e[22]=f,e[23]=h,e[24]=x):x=e[24],xr(x)}function sp(t){return t.state.data?.some(tp)?ep:J1}function np(t){const e=$.c(10),{locator:s}=Qe(),n=Ut();let r;e[0]!==s||e[1]!==t?(r=ft.previewProbe(s,t??""),e[0]=s,e[1]=t,e[2]=r):r=e[2];const l=!!t;let i;e[3]!==n||e[4]!==t?(i=()=>n.call("TASK_BOARD_PREVIEW_PROBE",{url:t}),e[3]=n,e[4]=t,e[5]=i):i=e[5];let c;return e[6]!==r||e[7]!==l||e[8]!==i?(c={queryKey:r,enabled:l,staleTime:0,gcTime:0,retry:!1,queryFn:i},e[6]=r,e[7]=l,e[8]=i,e[9]=c):c=e[9],xr(c)}function Ea(t){const e=$.c(10),{locator:s}=Qe(),n=Ut();let r;e[0]!==t||e[1]!==s?(r=ft.taskBoardActivity(s,t??""),e[0]=t,e[1]=s,e[2]=r):r=e[2];const l=!!t;let i;e[3]!==t||e[4]!==n?(i=async()=>(await n.call("TASK_BOARD_ACTIVITY_LIST",{taskBoardItemId:t})).activity,e[3]=t,e[4]=n,e[5]=i):i=e[5];let c;return e[6]!==r||e[7]!==l||e[8]!==i?(c={queryKey:r,enabled:l,queryFn:i},e[6]=r,e[7]=l,e[8]=i,e[9]=c):c=e[9],xr(c)}function rp(t){const e=$.c(10),{locator:s}=Qe(),n=Ut(),r=$r();let l;e[0]!==t||e[1]!==n?(l=async()=>await n.call("TASK_BOARD_PROMOTE_TO_PRODUCTION",{taskBoardItemId:t}),e[0]=t,e[1]=n,e[2]=l):l=e[2];let i;e[3]!==t||e[4]!==s||e[5]!==r?(i=()=>{r.invalidateQueries({queryKey:ft.taskBoardItemPrs(s,t)}),r.invalidateQueries({queryKey:ft.taskBoardActivity(s,t)})},e[3]=t,e[4]=s,e[5]=r,e[6]=i):i=e[6];let c;return e[7]!==l||e[8]!==i?(c={mutationFn:l,onSuccess:i},e[7]=l,e[8]=i,e[9]=c):c=e[9],fr(c)}function lp(t){const e=$.c(10),{locator:s}=Qe(),n=Ut(),r=$r();let l;e[0]!==t||e[1]!==n?(l=async o=>await n.call("TASK_BOARD_RESOLVE_CONFLICT",{id:t,prNumber:o}),e[0]=t,e[1]=n,e[2]=l):l=e[2];let i;e[3]!==t||e[4]!==s||e[5]!==r?(i=()=>{r.invalidateQueries({queryKey:ft.taskBoardItemPrs(s,t)}),r.invalidateQueries({queryKey:ft.taskBoardActivity(s,t)})},e[3]=t,e[4]=s,e[5]=r,e[6]=i):i=e[6];let c;return e[7]!==l||e[8]!==i?(c={mutationFn:l,onSuccess:i},e[7]=l,e[8]=i,e[9]=c):c=e[9],fr(c)}function Yo(t){return t?gd:[]}function ap(t,e,s){return e.length===0?!0:xd(t,e,{cycleStartedAt:s})}function ip(t,e){if(e.length===0)return null;const s=e.map(l=>t.find(i=>i.reviewer===l)),n=s.filter(l=>l?.verdict==="approved"),r={passed:n.length,total:e.length};return s.some(l=>l?.verdict==="changes_requested")?{...r,tone:"danger"}:n.length===0?{...r,tone:"danger"}:n.length<e.length?{...r,tone:"pending"}:{...r,tone:"ok"}}function op(t){return t==="in_review"||t==="approved"}const cp=[],dp=[];function Zo(t,e){const s=$.c(4),n=e===void 0?cp:e,r=Uu();let l;if(s[0]!==r||s[1]!==n||s[2]!==t){const i=Wu(r);l=Zc(i,[...t.map(up),...n]),s[0]=r,s[1]=n,s[2]=t,s[3]=l}else l=s[3];return l}function up(t){return t.repo}function Ia(t){const e=$.c(57),{members:s,onSelect:n}=t,r=J();let l;e[0]!==r?(l=r("taskBoard.taskDialog.assignToPlaceholder"),e[0]=r,e[1]=l):l=e[1];let i;e[2]!==r?(i=r("taskBoard.taskDialog.assignToPlaceholder"),e[2]=r,e[3]=i):i=e[3];let c;e[4]!==l||e[5]!==i?(c=a.jsx(ls,{placeholder:l,"aria-label":i,className:"h-9"}),e[4]=l,e[5]=i,e[6]=c):c=e[6];let o;e[7]!==r?(o=r("taskBoard.taskDialog.noMembersFound"),e[7]=r,e[8]=o):o=e[8];let d;e[9]!==o?(d=a.jsx(as,{children:o}),e[9]=o,e[10]=d):d=e[10];let u;e[11]!==r?(u=r("taskBoard.taskDialog.superAgentLabel"),e[11]=r,e[12]=u):u=e[12];let f;e[13]!==n?(f=()=>n(ye),e[13]=n,e[14]=f):f=e[14];let h;e[15]===Symbol.for("react.memo_cache_sentinel")?(h=a.jsx(Ve,{size:16}),e[15]=h):h=e[15];let x;e[16]!==r?(x=r("taskBoard.taskDialog.superAgentLabel"),e[16]=r,e[17]=x):x=e[17];let m;e[18]!==x?(m=a.jsx("span",{className:"truncate",children:x}),e[18]=x,e[19]=m):m=e[19];let g;e[20]!==m||e[21]!==u||e[22]!==f?(g=a.jsxs(He,{value:u,onSelect:f,className:"gap-2",children:[h,m]}),e[20]=m,e[21]=u,e[22]=f,e[23]=g):g=e[23];let k;e[24]!==r?(k=r("taskBoard.taskDialog.unassignedLabel"),e[24]=r,e[25]=k):k=e[25];let y;e[26]!==n?(y=()=>n(null),e[26]=n,e[27]=y):y=e[27];let v;e[28]===Symbol.for("react.memo_cache_sentinel")?(v=a.jsx(ss,{size:16,className:"text-muted-foreground"}),e[28]=v):v=e[28];let p;e[29]!==r?(p=r("taskBoard.taskDialog.unassignedLabel"),e[29]=r,e[30]=p):p=e[30];let b;e[31]!==p?(b=a.jsx("span",{className:"truncate",children:p}),e[31]=p,e[32]=b):b=e[32];let j;e[33]!==k||e[34]!==y||e[35]!==b?(j=a.jsxs(He,{value:k,onSelect:y,className:"gap-2",children:[v,b]}),e[33]=k,e[34]=y,e[35]=b,e[36]=j):j=e[36];let w;e[37]!==g||e[38]!==j?(w=a.jsxs(et,{children:[g,j]}),e[37]=g,e[38]=j,e[39]=w):w=e[39];let S;e[40]!==r?(S=r("taskBoard.taskDialog.membersGroupHeading"),e[40]=r,e[41]=S):S=e[41];let C;if(e[42]!==s||e[43]!==n){let D;e[45]!==n?(D=A=>a.jsxs(He,{value:A.user?.name??A.userId,onSelect:()=>n(A.userId),className:"gap-2",children:[a.jsx(Fe,{url:A.user?.image??void 0,fallback:Oe(A.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate",children:A.user?.name??A.userId})]},A.userId),e[45]=n,e[46]=D):D=e[46],C=s.map(D),e[42]=s,e[43]=n,e[44]=C}else C=e[44];let T;e[47]!==S||e[48]!==C?(T=a.jsx(et,{heading:S,children:C}),e[47]=S,e[48]=C,e[49]=T):T=e[49];let N;e[50]!==w||e[51]!==T||e[52]!==d?(N=a.jsxs(is,{children:[d,w,T]}),e[50]=w,e[51]=T,e[52]=d,e[53]=N):N=e[53];let _;return e[54]!==N||e[55]!==c?(_=a.jsxs(os,{children:[c,N]}),e[54]=N,e[55]=c,e[56]=_):_=e[56],_}function fp({tags:t,selectedIds:e,defaultColor:s,onToggle:n,onCreate:r,onDelete:l}){const i=J(),[c,o]=W.useState(""),[d,u]=W.useState(!1),[f,h]=W.useState(s),x=c.trim(),m=t.some(k=>k.name.toLowerCase()===x.toLowerCase()),g=async()=>{if(!(!x||m||d)){u(!0);try{await r(x,f),o("")}finally{u(!1)}}};return a.jsxs(os,{children:[a.jsx(ls,{value:c,onValueChange:o,placeholder:i("taskBoard.taskDialog.tagFilterPlaceholder"),"aria-label":i("taskBoard.taskDialog.tagFilterPlaceholder"),className:"h-9"}),a.jsxs(is,{children:[x&&!m?a.jsx(et,{children:a.jsxs("div",{className:"flex items-center gap-1",children:[a.jsx("input",{type:"color",value:f,onChange:k=>h(k.target.value),"aria-label":i("taskBoard.taskDialog.pickTagColorAriaLabel"),className:"ml-2 size-4 shrink-0 cursor-pointer appearance-none rounded-full border-0 bg-transparent p-0 [&::-moz-color-swatch]:rounded-full [&::-moz-color-swatch]:border-0 [&::-webkit-color-swatch]:rounded-full [&::-webkit-color-swatch]:border-0 [&::-webkit-color-swatch-wrapper]:p-0"}),a.jsxs(He,{value:`create-${x}`,disabled:d,onSelect:g,className:"flex-1 gap-2",children:[a.jsx(ts,{size:16,className:"text-muted-foreground"}),a.jsx("span",{className:"truncate",children:i("taskBoard.taskDialog.createTagOption",{name:x})})]})]})}):a.jsx(as,{children:i("taskBoard.taskDialog.noTagsFound")}),a.jsx(et,{children:t.map(k=>{const y=e.includes(k.id);return a.jsxs(He,{value:k.name,onSelect:()=>n(k.id),className:"group gap-2",children:[a.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:qt(k.color)}}),a.jsx("span",{className:"flex-1 truncate",children:k.name}),a.jsx("button",{type:"button","aria-label":i("taskBoard.taskDialog.deleteTagAriaLabel",{name:k.name}),className:"flex size-5 shrink-0 items-center justify-center classic:rounded-sm compact:rounded-lg text-muted-foreground opacity-0 hover:bg-background hover:text-destructive focus-visible:opacity-100 group-hover:opacity-100",onClick:v=>{v.stopPropagation(),l(k.id)},children:a.jsx(da,{size:13})}),y&&a.jsx(Ct,{size:14,className:"shrink-0 text-foreground"})]},k.id)})})]})]})}function hp(t){if(!t)return[];const e=[],s=new Set,n=(i,c)=>{s.has(i)||(s.add(i),e.push({url:i,label:c.trim()||i}))},r=t.replace(/!\[[^\]]*\]\([^)]*\)/g,"");for(const i of r.matchAll(/\[([^\]]*)\]\((https?:\/\/[^)\s]+)[^)]*\)/g))n(i[2]??"",i[1]??"");const l=r.replace(/\[[^\]]*\]\([^)]*\)/g,"");for(const i of l.matchAll(/https?:\/\/[^\s)]+/g))n(i[0],i[0]);return e}function pp(t){return{id:t.threadId,title:t.title,status:t.status,created_at:t.createdAt,virtual_mcp_id:t.virtualMcpId}}function mp(t){const e=$.c(5),{title:s}=t;let n;e[0]!==s?(n=a.jsx(Vu,{className:"shrink-0 border-b border-border px-5 pb-5 pt-6 md:px-6",children:a.jsx(Qu,{className:"truncate text-sm leading-snug",children:s})}),e[0]=s,e[1]=n):n=e[1];let r;e[2]===Symbol.for("react.memo_cache_sentinel")?(r=a.jsx("div",{className:"flex flex-1 items-center justify-center"}),e[2]=r):r=e[2];let l;return e[3]!==n?(l=a.jsxs(a.Fragment,{children:[n,r]}),e[3]=n,e[4]=l):l=e[4],l}function gp(t){const e=$.c(12),{thread:s}=t,{org:n,locator:r}=Qe();let l;e[0]!==n.id||e[1]!==n.slug?(l={connectionId:jc,orgId:n.id,orgSlug:n.slug},e[0]=n.id,e[1]=n.slug,e[2]=l):l=e[2];const i=Ju(l),c=yo(),o=Ku(),{data:d}=pa();let u;e[3]!==s?(u=pp(s),e[3]=s,e[4]=u):u=e[4];let f;return e[5]!==i||e[6]!==c||e[7]!==r||e[8]!==d||e[9]!==u||e[10]!==o?(f=a.jsx(Xu,{thread:u,client:i,locator:r,connections:c,virtualMcps:o,members:d,meta:!1}),e[5]=i,e[6]=c,e[7]=r,e[8]=d,e[9]=u,e[10]=o,e[11]=f):f=e[11],f}function xp(t){const e=$.c(11),{thread:s,onClose:n}=t,r=J(),l=!!s;let i;e[0]!==n?(i=u=>!u&&n(),e[0]=n,e[1]=i):i=e[1];let c;e[2]!==r||e[3]!==s?(c=s&&a.jsx(W.Suspense,{fallback:a.jsx(mp,{title:s.title??r("taskBoard.taskDialog.superAgentDefaultName")}),children:a.jsx(gp,{thread:s})}),e[2]=r,e[3]=s,e[4]=c):c=e[4];let o;e[5]!==c?(o=a.jsx(Yu,{"data-testid":"task-thread-sheet",className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:c}),e[5]=c,e[6]=o):o=e[6];let d;return e[7]!==l||e[8]!==i||e[9]!==o?(d=a.jsx(Zu,{open:l,onOpenChange:i,children:o}),e[7]=l,e[8]=i,e[9]=o,e[10]=d):d=e[10],d}const kp=["[&_p.is-editor-empty:first-child::before]:content-[attr(data-placeholder)]","[&_p.is-editor-empty:first-child::before]:text-muted-foreground","[&_p.is-editor-empty:first-child::before]:float-left","[&_p.is-editor-empty:first-child::before]:h-0","[&_p.is-editor-empty:first-child::before]:pointer-events-none"].join(" ");function bp(t){const e=$.c(24),{placeholder:s,onSubmit:n,onEmptyChange:r,ref:l,className:i}=t,[c]=W.useState(yp);let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=ho.configure({heading:!1,bulletList:!1,orderedList:!1,listItem:!1,blockquote:!1,codeBlock:!1,horizontalRule:!1,link:!1,underline:!1}),e[0]=o):o=e[0];let d;e[1]!==c?(d=Ho(c),e[1]=c,e[2]=d):d=e[2];let u;e[3]!==s?(u=ko.configure({placeholder:s}),e[3]=s,e[4]=u):u=e[4];let f;e[5]!==d||e[6]!==u?(f=[o,Po,d,u,zo],e[5]=d,e[6]=u,e[7]=f):f=e[7];let h;e[8]===Symbol.for("react.memo_cache_sentinel")?(h=F("outline-none text-sm leading-relaxed text-foreground",kp),e[8]=h):h=e[8];let x;e[9]!==s?(x={role:"textbox","aria-label":s,"aria-multiline":"true",class:h},e[9]=s,e[10]=x):x=e[10];let m;e[11]!==r?(m=j=>{const{editor:w}=j;return r(w.isEmpty)},e[11]=r,e[12]=m):m=e[12];const g=po({extensions:f,editorProps:{attributes:x,handleKeyDown:(j,w)=>w.key!=="Enter"||w.shiftKey||wl.getState(j.state)?.active?!1:(w.preventDefault(),k(),!0)},onUpdate:m});function k(){if(!g)return;const j=g.getMarkdown().trim();j&&(n(j),g.commands.clearContent(),r(!0))}let y;e[13]!==g?.commands||e[14]!==k?(y=()=>({submit:k,focus:()=>g?.commands.focus()}),e[13]=g?.commands,e[14]=k,e[15]=y):y=e[15],W.useImperativeHandle(l,y);let v;e[16]!==i||e[17]!==g?(v=a.jsx(mo,{editor:g,className:i}),e[16]=i,e[17]=g,e[18]=v):v=e[18];let p;e[19]!==c?(p=a.jsx(qo,{store:c}),e[19]=c,e[20]=p):p=e[20];let b;return e[21]!==p||e[22]!==v?(b=a.jsxs(a.Fragment,{children:[v,p]}),e[21]=p,e[22]=v,e[23]=b):b=e[23],b}function yp(){return new Fo}function jp(t){const e=$.c(40),{thread:s,me:n,onReply:r,onDelete:l,onToggleResolved:i}=t,c=J(),[o,d]=W.useState(!1);if(s.resolved&&!o){let v;e[0]===Symbol.for("react.memo_cache_sentinel")?(v=()=>d(!0),e[0]=v):v=e[0];let p;e[1]===Symbol.for("react.memo_cache_sentinel")?(p=a.jsx(Pc,{size:16,className:"shrink-0 text-muted-foreground"}),e[1]=p):p=e[1];let b;e[2]!==c||e[3]!==s?(b=wp(s,c),e[2]=c,e[3]=s,e[4]=b):b=e[4];let j;e[5]!==b?(j=a.jsx("span",{className:"min-w-0 flex-1 truncate text-sm text-muted-foreground",children:b}),e[5]=b,e[6]=j):j=e[6];let w;e[7]===Symbol.for("react.memo_cache_sentinel")?(w=a.jsx(tf,{size:16,className:"shrink-0 text-muted-foreground"}),e[7]=w):w=e[7];let S;return e[8]!==j?(S=a.jsxs("button",{type:"button",onClick:v,className:"flex w-full items-center gap-2.5 rounded-xl bg-card px-4 py-3 text-left card-shadow transition-colors hover:bg-muted/60",children:[p,j,w]}),e[8]=j,e[9]=S):S=e[9],S}let u;e[10]!==c||e[11]!==s.resolved?(u=s.resolved&&a.jsxs(a.Fragment,{children:[a.jsxs("button",{type:"button",onClick:()=>d(!1),className:"flex items-center justify-between gap-2 rounded-t-xl bg-muted/40 px-4 py-2.5 text-left text-sm text-muted-foreground transition-colors hover:text-foreground",children:[c("taskBoard.taskDialog.commentCollapseThread"),a.jsx(Ht,{size:14,"aria-hidden":!0})]}),a.jsx(Ql,{})]}),e[10]=c,e[11]=s.resolved,e[12]=u):u=e[12];let f;e[13]!==n||e[14]!==l||e[15]!==s?(f=vi(s,n)?()=>l(s.id):void 0,e[13]=n,e[14]=l,e[15]=s,e[16]=f):f=e[16];let h;e[17]!==i||e[18]!==f||e[19]!==s?(h=a.jsx(wi,{comment:s,onDelete:f,resolved:s.resolved,onToggleResolved:i}),e[17]=i,e[18]=f,e[19]=s,e[20]=h):h=e[20];let x;if(e[21]!==n||e[22]!==l||e[23]!==s.replies){let v;e[25]!==n||e[26]!==l?(v=(p,b)=>a.jsxs(W.Fragment,{children:[a.jsx(Ql,{inset:b>0}),a.jsx(wi,{comment:p,onDelete:vi(p,n)?()=>l(p.id):void 0,isReply:!0})]},p.id),e[25]=n,e[26]=l,e[27]=v):v=e[27],x=s.replies.map(v),e[21]=n,e[22]=l,e[23]=s.replies,e[24]=x}else x=e[24];let m;e[28]===Symbol.for("react.memo_cache_sentinel")?(m=a.jsx(Ql,{}),e[28]=m):m=e[28];let g;e[29]!==c?(g=c("taskBoard.taskDialog.commentReplyPlaceholder"),e[29]=c,e[30]=g):g=e[30];let k;e[31]!==n||e[32]!==r||e[33]!==g?(k=a.jsx(Jo,{variant:"reply",placeholder:g,author:n,onSubmit:r}),e[31]=n,e[32]=r,e[33]=g,e[34]=k):k=e[34];let y;return e[35]!==u||e[36]!==h||e[37]!==x||e[38]!==k?(y=a.jsxs("div",{className:"flex flex-col rounded-xl bg-card card-shadow",children:[u,h,x,m,k]}),e[35]=u,e[36]=h,e[37]=x,e[38]=k,e[39]=y):y=e[39],y}function vi(t,e){return t.author.id===e.id||t.author.isAgent===!0}const vp=new Intl.ListFormat(void 0,{style:"long",type:"conjunction"});function wp(t,e){const s=[t,...t.replies],n=vp.format([...new Set(s.map(r=>r.author.name))]);return s.length===1?e("taskBoard.taskDialog.commentResolvedSummaryOne",{names:n}):e("taskBoard.taskDialog.commentResolvedSummaryMany",{count:s.length,names:n})}function Sp(t){const e=$.c(6),{me:s,onSubmit:n}=t,r=J();let l;e[0]!==r?(l=r("taskBoard.taskDialog.commentPlaceholder"),e[0]=r,e[1]=l):l=e[1];let i;return e[2]!==s||e[3]!==n||e[4]!==l?(i=a.jsx(Jo,{variant:"root",placeholder:l,author:s,onSubmit:n}),e[2]=s,e[3]=n,e[4]=l,e[5]=i):i=e[5],i}function Ql(t){const e=$.c(4),{inset:s}=t,n=s&&"ml-12";let r;e[0]!==n?(r=F("h-px bg-border/50",n),e[0]=n,e[1]=r):r=e[1];let l;return e[2]!==r?(l=a.jsx("span",{className:r}),e[2]=r,e[3]=l):l=e[3],l}function wi(t){const e=$.c(28),{comment:s,isReply:n,resolved:r,onDelete:l,onToggleResolved:i}=t;let c;e[0]!==s.author?(c=a.jsx(Xo,{author:s.author}),e[0]=s.author,e[1]=c):c=e[1];let o;e[2]!==s.author.name?(o=a.jsx("span",{className:"text-sm font-medium text-foreground",children:s.author.name}),e[2]=s.author.name,e[3]=o):o=e[3];let d;e[4]!==s.createdAt?(d=ma(new Date(s.createdAt)),e[4]=s.createdAt,e[5]=d):d=e[5];let u;e[6]!==d?(u=a.jsx("span",{className:"text-sm text-muted-foreground",children:d}),e[6]=d,e[7]=u):u=e[7];let f;e[8]!==l||e[9]!==i||e[10]!==r?(f=(l||i)&&a.jsx(Cp,{resolved:r,onDelete:l,onToggleResolved:i}),e[8]=l,e[9]=i,e[10]=r,e[11]=f):f=e[11];let h;e[12]!==c||e[13]!==o||e[14]!==u||e[15]!==f?(h=a.jsxs("div",{className:"flex items-center gap-2",children:[c,o,u,f]}),e[12]=c,e[13]=o,e[14]=u,e[15]=f,e[16]=h):h=e[16];const x=n&&"pl-8";let m;e[17]!==x?(m=F("text-sm leading-relaxed text-foreground [&_li]:text-sm [&_p]:text-sm",x),e[17]=x,e[18]=m):m=e[18];let g;e[19]!==s.body||e[20]!==s.id?(g=a.jsx(co,{id:s.id,text:s.body}),e[19]=s.body,e[20]=s.id,e[21]=g):g=e[21];let k;e[22]!==m||e[23]!==g?(k=a.jsx("div",{className:m,children:g}),e[22]=m,e[23]=g,e[24]=k):k=e[24];let y;return e[25]!==k||e[26]!==h?(y=a.jsxs("div",{className:"group flex flex-col gap-1.5 p-4",children:[h,k]}),e[25]=k,e[26]=h,e[27]=y):y=e[27],y}function Cp(t){const e=$.c(18),{resolved:s,onDelete:n,onToggleResolved:r}=t,l=J();let i;e[0]!==l?(i=l("taskBoard.taskDialog.commentActionsAriaLabel"),e[0]=l,e[1]=i):i=e[1];let c;e[2]===Symbol.for("react.memo_cache_sentinel")?(c=a.jsx(pr,{size:16}),e[2]=c):c=e[2];let o;e[3]!==i?(o=a.jsx(Ke,{asChild:!0,children:a.jsx("button",{type:"button","aria-label":i,className:"ml-auto flex size-7 shrink-0 items-center justify-center classic:rounded-md compact:rounded-lg text-muted-foreground opacity-0 transition-colors hover:bg-muted hover:text-foreground focus-visible:opacity-100 group-hover:opacity-100 data-[state=open]:opacity-100",children:c})}),e[3]=i,e[4]=o):o=e[4];let d;e[5]!==r||e[6]!==s||e[7]!==l?(d=r&&a.jsxs(a.Fragment,{children:[a.jsxs(Ce,{onSelect:r,children:[a.jsx(Ct,{size:16}),l(s?"taskBoard.taskDialog.commentUnresolveThread":"taskBoard.taskDialog.commentResolveThread")]}),a.jsx(ca,{})]}),e[5]=r,e[6]=s,e[7]=l,e[8]=d):d=e[8];let u;e[9]!==n||e[10]!==l?(u=n&&a.jsxs(Ce,{variant:"destructive",onSelect:n,children:[a.jsx(da,{size:16}),l("taskBoard.taskDialog.commentDelete")]}),e[9]=n,e[10]=l,e[11]=u):u=e[11];let f;e[12]!==d||e[13]!==u?(f=a.jsxs(We,{align:"end",className:"w-48",children:[d,u]}),e[12]=d,e[13]=u,e[14]=f):f=e[14];let h;return e[15]!==o||e[16]!==f?(h=a.jsxs(Ge,{children:[o,f]}),e[15]=o,e[16]=f,e[17]=h):h=e[17],h}function Xo(t){const e=$.c(6),{author:s}=t;if(s.isAgent){let i;return e[0]===Symbol.for("react.memo_cache_sentinel")?(i=a.jsx(Ve,{size:24}),e[0]=i):i=e[0],i}const n=s.image??void 0;let r;e[1]!==s.name?(r=Oe(s.name),e[1]=s.name,e[2]=r):r=e[2];let l;return e[3]!==n||e[4]!==r?(l=a.jsx(Fe,{url:n,fallback:r,shape:"circle",size:"xs"}),e[3]=n,e[4]=r,e[5]=l):l=e[5],l}function Jo(t){const e=$.c(27),{variant:s,placeholder:n,author:r,onSubmit:l}=t,i=J(),c=W.useRef(null),[o,d]=W.useState(!0);let u;e[0]===Symbol.for("react.memo_cache_sentinel")?(u=()=>c.current?.submit(),e[0]=u):u=e[0];const f=u,h=s==="root"&&"min-h-10";let x;e[1]!==h?(x=F("w-full [&_.tiptap]:outline-none",h),e[1]=h,e[2]=x):x=e[2];let m;e[3]!==l||e[4]!==n||e[5]!==x?(m=a.jsx(bp,{ref:c,placeholder:n,onSubmit:l,onEmptyChange:d,className:x}),e[3]=l,e[4]=n,e[5]=x,e[6]=m):m=e[6];const g=m;let k;e[7]!==i?(k=i("taskBoard.taskDialog.commentSubmitAriaLabel"),e[7]=i,e[8]=k):k=e[8];let y;e[9]===Symbol.for("react.memo_cache_sentinel")?(y=a.jsx(ef,{size:16}),e[9]=y):y=e[9];let v;e[10]!==o||e[11]!==k?(v=a.jsx("button",{type:"button",disabled:o,onClick:f,"aria-label":k,className:"flex size-7 shrink-0 cursor-pointer items-center justify-center classic:rounded-md compact:rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:pointer-events-none disabled:opacity-40",children:y}),e[10]=o,e[11]=k,e[12]=v):v=e[12];const p=v;let b;e[13]===Symbol.for("react.memo_cache_sentinel")?(b=()=>c.current?.focus(),e[13]=b):b=e[13];const j=b;if(s==="root"){let T;e[14]!==p?(T=a.jsx("div",{className:"flex items-center justify-end",children:p}),e[14]=p,e[15]=T):T=e[15];let N;return e[16]!==T||e[17]!==g?(N=a.jsxs("div",{"data-testid":"new-comment-composer",onClick:j,className:"relative flex cursor-text flex-col gap-1 rounded-xl bg-card p-3 card-shadow",children:[g,T]}),e[16]=T,e[17]=g,e[18]=N):N=e[18],N}let w;e[19]!==r?(w=a.jsx("span",{className:"mt-0.5 shrink-0",children:a.jsx(Xo,{author:r})}),e[19]=r,e[20]=w):w=e[20];let S;e[21]!==g?(S=a.jsx("div",{className:"min-w-0 flex-1 pt-0.5",children:g}),e[21]=g,e[22]=S):S=e[22];let C;return e[23]!==p||e[24]!==S||e[25]!==w?(C=a.jsxs("div",{"data-testid":"reply-composer",onClick:j,className:"relative flex cursor-text items-start gap-2 p-3",children:[w,S,p]}),e[23]=p,e[24]=S,e[25]=w,e[26]=C):C=e[26],C}function Np(t){const e=t.filter(n=>!n.parentId).map(n=>({...n,replies:[]})),s=new Map(e.map(n=>[n.id,n]));for(const n of t)n.parentId&&s.get(n.parentId)?.replies.push(n);return e}function Tp(t){const e=$.c(36),{locator:s}=Qe(),n=Ut(),r=$r();let l;e[0]!==t||e[1]!==s?(l=ft.taskBoardComments(s,t??""),e[0]=t,e[1]=s,e[2]=l):l=e[2];const i=l,c=!!t;let o;e[3]!==t||e[4]!==n?(o=async()=>Np((await n.call("TASK_BOARD_COMMENT_LIST",{taskBoardItemId:t})).comments),e[3]=t,e[4]=n,e[5]=o):o=e[5];let d;e[6]!==i||e[7]!==c||e[8]!==o?(d={queryKey:i,enabled:c,queryFn:o},e[6]=i,e[7]=c,e[8]=o,e[9]=d):d=e[9];const u=xr(d);let f;e[10]!==r||e[11]!==i?(f=()=>r.invalidateQueries({queryKey:i}),e[10]=r,e[11]=i,e[12]=f):f=e[12];const h=f;let x;e[13]!==t||e[14]!==n?(x=C=>n.call("TASK_BOARD_COMMENT_CREATE",{taskBoardItemId:t,...C}),e[13]=t,e[14]=n,e[15]=x):x=e[15];let m;e[16]!==h||e[17]!==x?(m={mutationFn:x,onSuccess:h},e[16]=h,e[17]=x,e[18]=m):m=e[18];const g=fr(m);let k;e[19]!==n?(k=C=>n.call("TASK_BOARD_COMMENT_UPDATE",C),e[19]=n,e[20]=k):k=e[20];let y;e[21]!==h||e[22]!==k?(y={mutationFn:k,onSuccess:h},e[21]=h,e[22]=k,e[23]=y):y=e[23];const v=fr(y);let p;e[24]!==n?(p=C=>n.call("TASK_BOARD_COMMENT_DELETE",{id:C}),e[24]=n,e[25]=p):p=e[25];let b;e[26]!==h||e[27]!==p?(b={mutationFn:p,onSuccess:h},e[26]=h,e[27]=p,e[28]=b):b=e[28];const j=fr(b);let w;e[29]!==u.data?(w=u.data??[],e[29]=u.data,e[30]=w):w=e[30];let S;return e[31]!==g||e[32]!==j||e[33]!==v||e[34]!==w?(S={threads:w,post:g,setResolved:v,remove:j},e[31]=g,e[32]=j,e[33]=v,e[34]=w,e[35]=S):S=e[35],S}function Bp(t){const e=$.c(24),{locator:s}=Qe(),n=Ut(),r=$r();let l;e[0]!==t||e[1]!==s?(l=ft.notificationSubscribers(s,t??""),e[0]=t,e[1]=s,e[2]=l):l=e[2];const i=l,c=!!t;let o;e[3]!==t||e[4]!==n?(o=async()=>(await n.call("NOTIFICATION_SUBSCRIPTION_LIST",{taskBoardItemId:t})).userIds,e[3]=t,e[4]=n,e[5]=o):o=e[5];let d;e[6]!==i||e[7]!==c||e[8]!==o?(d={queryKey:i,enabled:c,queryFn:o},e[6]=i,e[7]=c,e[8]=o,e[9]=d):d=e[9];const u=xr(d);let f;e[10]!==t||e[11]!==n?(f=y=>n.call("NOTIFICATION_SUBSCRIPTION_SET",{taskBoardItemId:t,subscribed:y}),e[10]=t,e[11]=n,e[12]=f):f=e[12];let h;e[13]!==r||e[14]!==i?(h=()=>r.invalidateQueries({queryKey:i}),e[13]=r,e[14]=i,e[15]=h):h=e[15];let x;e[16]!==f||e[17]!==h?(x={mutationFn:f,onSuccess:h},e[16]=f,e[17]=h,e[18]=x):x=e[18];const m=fr(x);let g;e[19]!==u.data?(g=u.data??[],e[19]=u.data,e[20]=g):g=e[20];let k;return e[21]!==m||e[22]!==g?(k={subscriberIds:g,setSubscribed:m},e[21]=m,e[22]=g,e[23]=k):k=e[23],k}const _p=3;function Ap(t){const e=$.c(23),{itemId:s,members:n}=t,r=J(),{data:l}=Li.useSession(),i=l?.user?.id,{subscriberIds:c,setSubscribed:o}=Bp(s);let d;e[0]!==i||e[1]!==c?(d=!!i&&c.includes(i),e[0]=i,e[1]=c,e[2]=d):d=e[2];const u=d;let f;if(e[3]!==s||e[4]!==n||e[5]!==i||e[6]!==o||e[7]!==u||e[8]!==c||e[9]!==r){const h=new Map(n.map(Rp)),x=i?h.get(i):void 0;let m;e[11]!==i?(m=S=>S!==i,e[11]=i,e[12]=m):m=e[12];const g=c.filter(m).map(S=>h.get(S)).filter(Dp),k=[...u&&x?[x]:[],...g],y=k.slice(0,_p),v=k.length-y.length,p=!s||o.isPending;let b;e[13]!==o||e[14]!==u?(b=()=>o.mutate(!u),e[13]=o,e[14]=u,e[15]=b):b=e[15];let j;e[16]!==u||e[17]!==r?(j=r(u?"taskBoard.taskDialog.unsubscribe":"taskBoard.taskDialog.subscribe"),e[16]=u,e[17]=r,e[18]=j):j=e[18];let w;e[19]!==p||e[20]!==b||e[21]!==j?(w=a.jsx(ke,{type:"button",variant:"ghost",size:"sm",disabled:p,onClick:b,className:"h-7 px-2 text-sm font-normal text-muted-foreground",children:j}),e[19]=p,e[20]=b,e[21]=j,e[22]=w):w=e[22],f=a.jsxs("div",{className:"flex items-center gap-2",children:[w,y.length>0&&a.jsxs("span",{className:"inline-flex items-center",title:k.map(S=>S.user?.name??r("taskBoard.taskDialog.someoneLabel")).join(", "),children:[y.map($p),v>0&&a.jsxs("span",{className:"-ml-2 inline-flex size-6 items-center justify-center rounded-full bg-muted text-[10px] font-medium text-muted-foreground ring-2 ring-background",children:["+",v]})]})]}),e[3]=s,e[4]=n,e[5]=i,e[6]=o,e[7]=u,e[8]=c,e[9]=r,e[10]=f}else f=e[10];return f}function $p(t){return a.jsx(Fe,{url:t.user?.image??void 0,fallback:Oe(t.user?.name),shape:"circle",size:"xs",className:"-ml-2 ring-2 ring-background first:ml-0"},t.userId)}function Dp(t){return!!t}function Rp(t){return[t.userId,t]}function La(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),23,59,59).toISOString()}function ec(t){if(!t)return null;const e=new Date(t);return Number.isNaN(e.getTime())?null:e}const Si=560,zp=2e3,tc=new Intl.DateTimeFormat(void 0,{month:"short",day:"numeric"}),St="inline-flex h-9 items-center justify-start gap-2 rounded-lg border border-border px-3 text-sm font-medium text-foreground transition-colors hover:bg-muted sm:border-transparent",Ci=4,Ni=1,Sr="opacity-50";function Ep(t){const e=$.c(22),{threads:s}=t,n=J();let r,l,i,c,o,d;if(e[0]!==n||e[1]!==s){d=Symbol.for("react.early_return_sentinel");e:{const h=U1(s);if(!h){d=null;break e}const{total:x,runCount:m,onSubscription:g}=h,k=m===1,y=g?k?"taskBoard.taskDialog.costTooltipSubscriptionSingular":"taskBoard.taskDialog.costTooltipSubscriptionPlural":k?"taskBoard.taskDialog.costTooltipSingular":"taskBoard.taskDialog.costTooltipPlural";e[8]===Symbol.for("react.memo_cache_sentinel")?(i=F(St,"cursor-default hover:bg-transparent"),e[8]=i):i=e[8];const v=String(m);e[9]!==n||e[10]!==v||e[11]!==y?(c=n(y,{runs:v}),e[9]=n,e[10]=v,e[11]=y,e[12]=c):c=e[12],e[13]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(Xd,{size:16,className:"shrink-0 text-muted-foreground"}),e[13]=o):o=e[13],r="tabular-nums",l=n("taskBoard.taskDialog.costEstimatePrefix",{amount:x.toLocaleString(void 0,{style:"currency",currency:"USD"})})}e[0]=n,e[1]=s,e[2]=r,e[3]=l,e[4]=i,e[5]=c,e[6]=o,e[7]=d}else r=e[2],l=e[3],i=e[4],c=e[5],o=e[6],d=e[7];if(d!==Symbol.for("react.early_return_sentinel"))return d;let u;e[14]!==r||e[15]!==l?(u=a.jsx("span",{className:r,children:l}),e[14]=r,e[15]=l,e[16]=u):u=e[16];let f;return e[17]!==i||e[18]!==c||e[19]!==o||e[20]!==u?(f=a.jsxs("div",{className:i,title:c,children:[o,u]}),e[17]=i,e[18]=c,e[19]=o,e[20]=u,e[21]=f):f=e[21],f}function nl(t){const e=$.c(7),{label:s,children:n}=t;let r;e[0]!==s?(r=a.jsx("span",{className:"px-3 text-sm font-medium text-muted-foreground opacity-[0.74]",children:s}),e[0]=s,e[1]=r):r=e[1];let l;e[2]!==n?(l=a.jsx("div",{className:"flex flex-wrap gap-2 sm:flex-col sm:items-start sm:gap-1",children:n}),e[2]=n,e[3]=l):l=e[3];let i;return e[4]!==r||e[5]!==l?(i=a.jsxs("div",{className:"flex flex-col gap-2",children:[r,l]}),e[4]=r,e[5]=l,e[6]=i):i=e[6],i}function Ip(t){const e=$.c(7),{item:s}=t,n=J(),{data:r}=Qo(s.id);if(!r||r.length===0)return null;let l;e[0]!==n?(l=n("taskBoard.taskDialog.reviewsLabel"),e[0]=n,e[1]=l):l=e[1];let i;e[2]!==r?(i=r.map(Lp),e[2]=r,e[3]=i):i=e[3];let c;return e[4]!==l||e[5]!==i?(c=a.jsx(nl,{label:l,children:i}),e[4]=l,e[5]=i,e[6]=c):c=e[6],c}function Lp(t){return a.jsx(ke,{asChild:!0,variant:"ghost",className:"h-9 w-full justify-start gap-2 px-3 font-medium",children:a.jsxs("a",{href:t.url,target:"_blank",rel:"noreferrer",title:t.title?`#${t.number} ${t.title}`:t.url,children:[a.jsx(sl,{size:16,className:"shrink-0"}),a.jsx("span",{className:"min-w-0 flex-1 truncate text-left",children:t.title??`#${t.number}`})]})},t.url)}function sc(t){const e=$.c(11),{label:s,action:n,children:r}=t;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=a.jsx(Kt,{size:14,className:"shrink-0 transition-transform group-data-[state=closed]:-rotate-90"}),e[0]=l):l=e[0];let i;e[1]!==s?(i=a.jsxs(Qd,{className:"group flex w-fit items-center gap-2 text-sm text-muted-foreground transition-colors hover:text-foreground",children:[s,l]}),e[1]=s,e[2]=i):i=e[2];let c;e[3]!==n||e[4]!==i?(c=a.jsxs("div",{className:"flex min-h-7 items-center justify-between gap-2",children:[i,n]}),e[3]=n,e[4]=i,e[5]=c):c=e[5];let o;e[6]!==r?(o=a.jsx(Yd,{className:"-mx-2 -mb-2",children:a.jsx("div",{className:"px-2 pb-2",children:r})}),e[6]=r,e[7]=o):o=e[7];let d;return e[8]!==c||e[9]!==o?(d=a.jsxs(Zd,{defaultOpen:!0,className:"flex flex-col gap-2",children:[c,o]}),e[8]=c,e[9]=o,e[10]=d):d=e[10],d}function nc(t){const e=$.c(454),{chrome:s,open:n,onClose:r,item:l,defaultStatus:i,defaultRepo:c,onSubmit:o,onDelete:d,onClone:u,onArchive:f,onOpenPreview:h,onNewChat:x,onAutoFix:m,onRerun:g,isSaving:k}=t,y=n===void 0?!0:n,v=Mi(),p=J(),{org:b}=Qe();let j;e[0]===Symbol.for("react.memo_cache_sentinel")?(j={strict:!1},e[0]=j):j=e[0];const{agentId:w}=xl(j),{data:S}=pa(),C=S?.data?.members??[],T=xa("delivery_lanes_enabled"),{handleCopy:N,copied:_}=Wl(),{handleCopy:D,copied:A}=Wl(),{handleCopy:L,copied:z}=Wl(),{data:P}=ga();let E;e[1]!==P?(E=P===void 0?[]:P,e[1]=P,e[2]=E):E=e[2];const I=E,V=Fd(),Q=Od();let Y;e[3]===Symbol.for("react.memo_cache_sentinel")?(Y={slug:"mcp-github"},e[3]=Y):Y=e[3];const se=yo(Y);let H;e[4]!==se?(H=Gu(se),e[4]=se,e[5]=H):H=e[5];const q=Zo(dp,H),Z=Yi(q),X=l?.title??"",re=l?.description??"",G=l?.status??i??kd[0],ne=l?.priority??"medium",ce=l?.type??bd,ue=l?.assigneeId??null,oe=l?.repo??c??null,R=l?.dueDate;let O;e[6]!==R?(O=ec(R),e[6]=R,e[7]=O):O=e[7];let fe;e[8]!==l?.tags?(fe=l?.tags.map(Op)??[],e[8]=l?.tags,e[9]=fe):fe=e[9];let de;e[10]!==G||e[11]!==ne||e[12]!==ce||e[13]!==ue||e[14]!==oe||e[15]!==O||e[16]!==fe||e[17]!==X||e[18]!==re?(de={title:X,description:re,status:G,priority:ne,type:ce,assigneeId:ue,repo:oe,dueDate:O,tagIds:fe},e[10]=G,e[11]=ne,e[12]=ce,e[13]=ue,e[14]=oe,e[15]=O,e[16]=fe,e[17]=X,e[18]=re,e[19]=de):de=e[19];const[be,Ne]=W.useState(de),{title:le,description:xe,status:ae,priority:Te,assigneeId:U,repo:K,dueDate:he}=be;let ve;e[20]!==q||e[21]!==K?(ve=K?Nr(K,q):void 0,e[20]=q,e[21]=K,e[22]=ve):ve=e[22];const ge=ve,Ae=be.type,Be=be.tagIds,[Ee,Ye]=W.useState(!1),[$e,Tt]=W.useState(!1),Ze=$e&&!Ee;let De;e[23]===Symbol.for("react.memo_cache_sentinel")?(De=M=>{if(!M)return;const pe=()=>Tt(M.scrollHeight>Si);pe();const Se=new ResizeObserver(pe);return Se.observe(M),()=>Se.disconnect()},e[23]=De):De=e[23];const Bt=De,[_t,jr]=W.useState(!1),[At,Lr]=W.useState(!1),[hs,Wt]=W.useState(!1),[tt,$t]=W.useState(null);let Dt;e[24]!==l?.threads||e[25]!==tt?(Dt=l?.threads.find(M=>M.threadId===tt)??null,e[24]=l?.threads,e[25]=tt,e[26]=Dt):Dt=e[26];const Rt=Dt,jt=W.useRef(be),st=W.useRef(null),ps=W.useRef(o);let nt;e[27]===Symbol.for("react.memo_cache_sentinel")?(nt=()=>{st.current=null;const M=jt.current;M.title.trim()&&ps.current({title:M.title.trim(),description:M.description.trim()||null,status:M.status,priority:M.priority,type:M.type,assigneeId:M.assigneeId,repo:M.repo,dueDate:M.dueDate?La(M.dueDate):null,tagIds:M.tagIds})},e[27]=nt):nt=e[27];const Pe=nt;let zt;e[28]!==Pe||e[29]!==l||e[30]!==o?(zt=(M,pe)=>{const Se=pe===void 0?!1:pe,ze={...jt.current,...M};jt.current=ze,ps.current=o,Ne(ze),l&&(st.current&&clearTimeout(st.current),Se?st.current=setTimeout(Pe,zp):Pe())},e[28]=Pe,e[29]=l,e[30]=o,e[31]=zt):zt=e[31];const ie=zt;let rt;e[32]!==Pe?(rt=()=>{st.current&&(clearTimeout(st.current),Pe())},e[32]=Pe,e[33]=rt):rt=e[33];const Ie=rt;let lt;e[34]===Symbol.for("react.memo_cache_sentinel")?(lt=()=>{st.current&&(clearTimeout(st.current),st.current=null)},e[34]=lt):lt=e[34];const Gt=lt;let at;e[35]!==Ie||e[36]!==r?(at=()=>{Ie(),r()},e[35]=Ie,e[36]=r,e[37]=at):at=e[37];const Re=at;let it;e[38]!==Ie?(it=M=>{if(M)return()=>Ie()},e[38]=Ie,e[39]=it):it=e[39];const ht=it;let vt;e[40]!==Re?(vt=M=>{if(!M)return;const pe=Se=>{if(Se.key!=="Escape"||Se.defaultPrevented||document.querySelector('[data-radix-popper-content-wrapper], [role="dialog"][data-state="open"]'))return;const ze=Se.target;if(ze instanceof HTMLElement&&(ze.isContentEditable||ze instanceof HTMLInputElement||ze instanceof HTMLTextAreaElement)){ze.blur();return}Re()};return document.addEventListener("keydown",pe),()=>document.removeEventListener("keydown",pe)},e[40]=Re,e[41]=vt):vt=e[41];const B=vt;let te;e[42]!==V||e[43]!==ie?(te=async(M,pe)=>{const Se=await V.mutateAsync({name:M,color:pe});ie({tagIds:[...jt.current.tagIds,Se.id]})},e[42]=V,e[43]=ie,e[44]=te):te=e[44];const we=te;let Me;e[45]!==Q||e[46]!==ie?(Me=M=>{Q.mutate(M),ie({tagIds:jt.current.tagIds.filter(pe=>pe!==M)})},e[45]=Q,e[46]=ie,e[47]=Me):Me=e[47];const ot=Me,Ue=U===ye,ms=l&&m&&(ae==="triage"||ae==="todo")&&!Ue,gs=l&&g&&l.assigneeId===ye;let Mr;e[48]!==l||e[49]!==b?(Mr=l?Zi(b.slug,l.keySeq):null,e[48]=l,e[49]=b,e[50]=Mr):Mr=e[50];const pt=Mr;let Pr;e[51]!==U?(Pr=M=>M.userId===U,e[51]=U,e[52]=Pr):Pr=e[52];const Vt=C.find(Pr),Xe=l?.assignedBy?C.find(M=>M.userId===l.assignedBy):void 0,Fr=l?C.find(M=>M.userId===l.createdBy):void 0;let Or;e[53]!==ae?(Or=Zl(ae),e[53]=ae,e[54]=Or):Or=e[54];const Cl=Or.icon;let _e,xs,ks,bs,ys,js,Et,vs,ws,Ss,Cs,Ns,It,Ts,Lt;if(e[55]!==w||e[56]!==s||e[57]!==Re||e[58]!==v||e[59]!==_||e[60]!==L||e[61]!==D||e[62]!==xe||e[63]!==Ie||e[64]!==N||e[65]!==z||e[66]!==k||e[67]!==l||e[68]!==pt||e[69]!==A||e[70]!==f||e[71]!==m||e[72]!==u||e[73]!==d||e[74]!==x||e[75]!==g||e[76]!==b||e[77]!==ie||e[78]!==ms||e[79]!==gs||e[80]!==ae||e[81]!==p||e[82]!==le){_e=!!l&&Jl(l);let M;e[98]!==k||e[99]!==l||e[100]!==p?(M=l&&k&&a.jsx("span",{className:"mr-1 text-sm text-muted-foreground",children:p("taskBoard.taskDialog.savingLabel")}),e[98]=k,e[99]=l,e[100]=p,e[101]=M):M=e[101];let pe;e[102]!==v||e[103]!==l||e[104]!==p?(pe=l?.externalUrl&&a.jsx(Jt,{asChild:!0,variant:v?"secondary":"ghost",label:p("taskBoard.taskDialog.openInTrackerAriaLabel"),children:a.jsx("a",{href:l.externalUrl,target:"_blank",rel:"noreferrer",children:a.jsx(Br,{size:16})})}),e[102]=v,e[103]=l,e[104]=p,e[105]=pe):pe=e[105];let Se;e[106]!==w||e[107]!==v||e[108]!==_||e[109]!==D||e[110]!==xe||e[111]!==N||e[112]!==l||e[113]!==A||e[114]!==f||e[115]!==m||e[116]!==u||e[117]!==d||e[118]!==x||e[119]!==g||e[120]!==b||e[121]!==ms||e[122]!==gs||e[123]!==ae||e[124]!==p?(Se=l&&a.jsxs(a.Fragment,{children:[a.jsx(Jt,{variant:v?"secondary":"ghost",label:p("taskBoard.taskDialog.shareAriaLabel"),onClick:()=>{D(`${window.location.origin}${Xi(b.slug,l,w)}`),Je.success(p("taskBoard.taskDialog.linkCopied"))},children:A?a.jsx(Ct,{size:16}):a.jsx(Fc,{size:16})}),a.jsxs(Ge,{modal:!1,children:[a.jsx(Ke,{asChild:!0,children:a.jsx(ke,{variant:v?"secondary":"ghost",size:"icon-sm","aria-label":p("taskBoard.taskDialog.moreActionsAriaLabel"),children:a.jsx(pr,{size:16})})}),a.jsxs(We,{align:"end",className:"w-48",children:[x&&a.jsxs(Ce,{onSelect:x,children:[a.jsx(Fi,{size:16}),p("taskBoard.taskDialog.newChatButton")]}),ms&&a.jsxs(Ce,{onSelect:m,children:[a.jsx(al,{size:16}),p("taskBoard.taskBoard.autoFix")]}),gs&&a.jsxs(Ce,{onSelect:g,children:[a.jsx(kl,{size:16}),p("taskBoard.taskBoard.rerun")]}),(x||ms||gs)&&a.jsx(ca,{}),xe&&a.jsxs(Ce,{onSelect:()=>N(xe),children:[_?a.jsx(Ct,{size:16}):a.jsx(Jd,{size:16}),p("taskBoard.taskDialog.copyDescription")]}),u&&a.jsxs(Ce,{onSelect:u,children:[a.jsx(Oc,{size:16}),p("taskBoard.taskDialog.cloneTask")]}),f&&ae!=="archived"&&a.jsxs(Ce,{onSelect:()=>{Gt(),f()},children:[a.jsx(vc,{size:16}),p("taskBoard.taskDialog.archiveTask")]}),d&&a.jsxs(Ce,{variant:"destructive",onSelect:()=>{Gt(),d()},children:[a.jsx(da,{size:16}),p("taskBoard.taskDialog.deleteTask")]})]})]})]}),e[106]=w,e[107]=v,e[108]=_,e[109]=D,e[110]=xe,e[111]=N,e[112]=l,e[113]=A,e[114]=f,e[115]=m,e[116]=u,e[117]=d,e[118]=x,e[119]=g,e[120]=b,e[121]=ms,e[122]=gs,e[123]=ae,e[124]=p,e[125]=Se):Se=e[125];let ze;e[126]!==s||e[127]!==Re||e[128]!==v||e[129]!==p?(ze=s==="dialog"&&a.jsx(Jt,{variant:v?"secondary":"ghost",label:p("taskBoard.taskDialog.closeAriaLabel"),onClick:Re,children:a.jsx(Ht,{size:16})}),e[126]=s,e[127]=Re,e[128]=v,e[129]=p,e[130]=ze):ze=e[130];let Mt;e[131]!==M||e[132]!==pe||e[133]!==Se||e[134]!==ze?(Mt=a.jsxs("div",{className:"flex items-center gap-2",children:[M,pe,Se,ze]}),e[131]=M,e[132]=pe,e[133]=Se,e[134]=ze,e[135]=Mt):Mt=e[135];const Vr=Mt;let Qr;e[136]!==Vr||e[137]!==s||e[138]!==Re||e[139]!==v||e[140]!==L||e[141]!==z||e[142]!==pt||e[143]!==p?(Qr=v&&s==="page"?a.jsxs(a.Fragment,{children:[a.jsx(Ft.Breadcrumbs,{items:[{key:"tasks",label:p("taskBoard.taskDetail.breadcrumbTasks"),onClick:Re}]}),a.jsx(Ft.Title,{children:pt??p("taskBoard.taskDetail.breadcrumbTask")}),a.jsx(Ft.Actions,{children:Vr})]}):a.jsxs("div",{className:"flex shrink-0 items-center justify-between gap-2 px-6 pb-4 pt-6 sm:px-8",children:[s==="page"?a.jsx(Hd,{className:"-ml-2",children:a.jsxs(qd,{className:"text-[15px]",children:[a.jsx(Ka,{children:a.jsx(Ud,{asChild:!0,className:"rounded-md px-2 py-1 text-muted-foreground hover:bg-accent",children:a.jsx("button",{type:"button",onClick:Re,children:p("taskBoard.taskDetail.breadcrumbTasks")})})}),a.jsx(Kd,{}),a.jsx(Ka,{children:a.jsx(Wd,{className:"px-2 py-1",children:pt??p("taskBoard.taskDetail.breadcrumbTask")})})]})}):pt?a.jsxs(ke,{variant:"ghost",size:"sm",title:pt,"aria-label":p("taskBoard.taskDialog.copyIdAriaLabel"),className:"-ml-2 gap-2 px-2 text-[15px] text-muted-foreground hover:text-foreground",onClick:()=>{L(pt),Je.success(p("taskBoard.taskDialog.idCopied"))},children:[z?a.jsx(Ct,{size:16}):a.jsx(Oa,{size:16}),pt]}):a.jsxs("span",{"aria-hidden":!0,className:"flex h-7 items-center gap-2 text-[15px] text-muted-foreground opacity-50",children:[a.jsx(Oa,{size:16}),"–"]}),Vr]}),e[136]=Vr,e[137]=s,e[138]=Re,e[139]=v,e[140]=L,e[141]=z,e[142]=pt,e[143]=p,e[144]=Qr):Qr=e[144];const Yr=Qr;e[145]!==s||e[146]!==Yr?(Lt=s==="page"?a.jsx("div",{className:"mx-auto w-full max-w-[1040px]",children:Yr}):Yr,e[145]=s,e[146]=Yr,e[147]=Lt):Lt=e[147],Ts="flex min-h-0 flex-1 flex-col overflow-y-auto";const Kl=s==="page"&&"mx-auto w-full max-w-[1040px]";e[148]!==Kl?(It=F("flex flex-col sm:flex-row",Kl),e[148]=Kl,e[149]=It):It=e[149],Ns="flex min-w-0 flex-col gap-2 p-6 sm:flex-1 sm:p-8 sm:pt-6",xs=Fp,ks=le,bs=Zr=>{_e||(ie({title:Zr.target.value},!0),Zr.target.style.height="auto",Zr.target.style.height=`${Zr.target.scrollHeight}px`)},ys=Pp,js=Ie,e[150]!==p?(Et=p("taskBoard.taskDialog.taskTitlePlaceholder"),e[150]=p,e[151]=Et):Et=e[151],vs=!0,ws=1,Ss=_e,Cs=F("w-full resize-none overflow-hidden border-0 bg-transparent text-2xl font-semibold leading-snug text-foreground outline-none placeholder:text-foreground/30",_e&&"cursor-default"),e[55]=w,e[56]=s,e[57]=Re,e[58]=v,e[59]=_,e[60]=L,e[61]=D,e[62]=xe,e[63]=Ie,e[64]=N,e[65]=z,e[66]=k,e[67]=l,e[68]=pt,e[69]=A,e[70]=f,e[71]=m,e[72]=u,e[73]=d,e[74]=x,e[75]=g,e[76]=b,e[77]=ie,e[78]=ms,e[79]=gs,e[80]=ae,e[81]=p,e[82]=le,e[83]=_e,e[84]=xs,e[85]=ks,e[86]=bs,e[87]=ys,e[88]=js,e[89]=Et,e[90]=vs,e[91]=ws,e[92]=Ss,e[93]=Cs,e[94]=Ns,e[95]=It,e[96]=Ts,e[97]=Lt}else _e=e[83],xs=e[84],ks=e[85],bs=e[86],ys=e[87],js=e[88],Et=e[89],vs=e[90],ws=e[91],Ss=e[92],Cs=e[93],Ns=e[94],It=e[95],Ts=e[96],Lt=e[97];let Bs;e[152]!==xs||e[153]!==ks||e[154]!==bs||e[155]!==ys||e[156]!==js||e[157]!==Et||e[158]!==vs||e[159]!==ws||e[160]!==Ss||e[161]!==Cs?(Bs=a.jsx("textarea",{ref:xs,value:ks,onChange:bs,onKeyDown:ys,onBlur:js,placeholder:Et,autoFocus:vs,rows:ws,readOnly:Ss,className:Cs}),e[152]=xs,e[153]=ks,e[154]=bs,e[155]=ys,e[156]=js,e[157]=Et,e[158]=vs,e[159]=ws,e[160]=Ss,e[161]=Cs,e[162]=Bs):Bs=e[162];let _s;e[163]!==_e||e[164]!==p?(_s=_e&&a.jsxs("p",{className:"mb-3 mt-1 flex items-center gap-1.5 text-xs text-muted-foreground",children:[a.jsx(wc,{size:12}),p("taskBoard.taskDialog.reportsContentLocked")]}),e[163]=_e,e[164]=p,e[165]=_s):_s=e[165];let As;e[166]!==Bs||e[167]!==_s?(As=a.jsxs("div",{children:[Bs,_s]}),e[166]=Bs,e[167]=_s,e[168]=As):As=e[168];let $s;e[169]!==l||e[170]!==g||e[171]!==b?($s=l&&a.jsx(fm,{item:l,orgSlug:b.slug,onRerun:g}),e[169]=l,e[170]=g,e[171]=b,e[172]=$s):$s=e[172];const Nl=Ze&&"overflow-hidden";let Ds;e[173]!==Nl?(Ds=F("relative",Nl),e[173]=Nl,e[174]=Ds):Ds=e[174];let Rs;e[175]!==Ze?(Rs=Ze?{maxHeight:Si}:void 0,e[175]=Ze,e[176]=Rs):Rs=e[176];let Hr;e[177]===Symbol.for("react.memo_cache_sentinel")?(Hr=()=>Ye(!0),e[177]=Hr):Hr=e[177];let zs;e[178]!==ie?(zs=M=>ie({description:M},!0),e[178]=ie,e[179]=zs):zs=e[179];let Es;e[180]!==p?(Es=p("taskBoard.taskDialog.descriptionPlaceholder"),e[180]=p,e[181]=Es):Es=e[181];const Tl=!_e;let Is;e[182]!==xe||e[183]!==zs||e[184]!==Es||e[185]!==Tl?(Is=a.jsx("div",{ref:Bt,"data-testid":"task-description",children:a.jsx(H1,{defaultValue:xe,onChange:zs,placeholder:Es,editable:Tl})}),e[182]=xe,e[183]=zs,e[184]=Es,e[185]=Tl,e[186]=Is):Is=e[186];let Ls;e[187]!==Ze?(Ls=Ze&&a.jsx("div",{"aria-hidden":!0,className:"pointer-events-none absolute inset-x-0 bottom-0 h-16 bg-gradient-to-t from-background to-transparent"}),e[187]=Ze,e[188]=Ls):Ls=e[188];let Ms;e[189]!==Ie||e[190]!==Ds||e[191]!==Rs||e[192]!==Is||e[193]!==Ls?(Ms=a.jsxs("div",{className:Ds,style:Rs,onFocusCapture:Hr,onBlurCapture:Ie,children:[Is,Ls]}),e[189]=Ie,e[190]=Ds,e[191]=Rs,e[192]=Is,e[193]=Ls,e[194]=Ms):Ms=e[194];let Ps;e[195]!==Ee||e[196]!==$e||e[197]!==p?(Ps=$e&&a.jsxs(ke,{type:"button",variant:"ghost",size:"sm",className:"mt-2 w-fit text-muted-foreground hover:text-foreground",onClick:()=>Ye(Mp),children:[a.jsx(Kt,{size:14,className:F("transition-transform",Ee&&"rotate-180")}),p(Ee?"taskBoard.taskDialog.showLess":"taskBoard.taskDialog.showMore")]}),e[195]=Ee,e[196]=$e,e[197]=p,e[198]=Ps):Ps=e[198];let Fs;e[199]!==Ms||e[200]!==Ps?(Fs=a.jsxs("div",{className:"flex flex-col py-6",children:[Ms,Ps]}),e[199]=Ms,e[200]=Ps,e[201]=Fs):Fs=e[201];let Os;e[202]!==l?(Os=l&&a.jsx("div",{className:"py-4",children:a.jsx("hr",{className:"border-border"})}),e[202]=l,e[203]=Os):Os=e[203];const Bl=l&&a.jsxs("div",{className:"flex flex-col gap-8",children:[a.jsx(em,{item:l,description:xe,onOpenPreview:h}),a.jsx(nm,{item:l,members:C,startedBy:Xe??Vt,onOpenThread:M=>$t(M.threadId)})]});let Hs;e[204]!==Fs||e[205]!==Os||e[206]!==Bl?(Hs=a.jsxs("div",{className:"flex flex-col",children:[Fs,Os,Bl]}),e[204]=Fs,e[205]=Os,e[206]=Bl,e[207]=Hs):Hs=e[207];let qs;e[208]!==Ns||e[209]!==As||e[210]!==$s||e[211]!==Hs?(qs=a.jsxs("div",{className:Ns,children:[As,$s,Hs]}),e[208]=Ns,e[209]=As,e[210]=$s,e[211]=Hs,e[212]=qs):qs=e[212];const pc="flex w-full shrink-0 flex-col gap-8 border-t border-border p-6 sm:sticky sm:top-0 sm:max-h-dvh sm:w-[300px] sm:self-start sm:overflow-y-auto sm:border-t-0";let Us;e[213]!==l?(Us=l&&a.jsx(Ip,{item:l}),e[213]=l,e[214]=Us):Us=e[214];let Ks;e[215]!==p?(Ks=p("taskBoard.taskDialog.propertiesLabel"),e[215]=p,e[216]=Ks):Ks=e[216];let Ws;e[217]!==l||e[218]!==ae?(Ws=F(l?Ji({...l,status:ae}):Zl(ae).iconClassName),e[217]=l,e[218]=ae,e[219]=Ws):Ws=e[219];let Gs;e[220]!==Cl||e[221]!==Ws?(Gs=a.jsx(Cl,{size:16,className:Ws}),e[220]=Cl,e[221]=Ws,e[222]=Gs):Gs=e[222];let Vs;e[223]!==ae||e[224]!==p?(Vs=Tr(ae,p),e[223]=ae,e[224]=p,e[225]=Vs):Vs=e[225];let Qs;e[226]!==Gs||e[227]!==Vs.label?(Qs=a.jsx(Ke,{asChild:!0,children:a.jsxs("button",{type:"button",className:St,children:[Gs,Vs.label]})}),e[226]=Gs,e[227]=Vs.label,e[228]=Qs):Qs=e[228];let Ys;if(e[229]!==T||e[230]!==ie||e[231]!==p){let M;e[233]!==ie||e[234]!==p?(M=pe=>{const{label:Se,visual:ze}=Tr(pe,p),Mt=ze.icon;return a.jsxs(Ce,{onSelect:()=>ie({status:pe}),className:"gap-2",children:[a.jsx(Mt,{size:16,className:ze.iconClassName}),Se]},pe)},e[233]=ie,e[234]=p,e[235]=M):M=e[235],Ys=eo(T).map(M),e[229]=T,e[230]=ie,e[231]=p,e[232]=Ys}else Ys=e[232];let Zs;e[236]!==Ys?(Zs=a.jsx(We,{align:"start",className:"w-44",children:Ys}),e[236]=Ys,e[237]=Zs):Zs=e[237];let Xs;e[238]!==Qs||e[239]!==Zs?(Xs=a.jsxs(Ge,{children:[Qs,Zs]}),e[238]=Qs,e[239]=Zs,e[240]=Xs):Xs=e[240];let Js;e[241]!==_e||e[242]!==p?(Js=_e?p("taskBoard.taskDialog.reportsContentLocked"):void 0,e[241]=_e,e[242]=p,e[243]=Js):Js=e[243];const _l=_e&&"cursor-default opacity-60";let en;e[244]!==_l?(en=F(St,_l),e[244]=_l,e[245]=en):en=e[245];const Al=Ot[Ae].icon;let qr;e[246]!==Al?(qr=a.jsx(Al,{size:16}),e[246]=Al,e[247]=qr):qr=e[247];const $l=qr,Dl=Ot[Ae];let tn;e[248]!==p||e[249]!==Dl.labelKey?(tn=p(Dl.labelKey),e[248]=p,e[249]=Dl.labelKey,e[250]=tn):tn=e[250];let sn;e[251]!==_e||e[252]!==Js||e[253]!==en||e[254]!==$l||e[255]!==tn?(sn=a.jsx(Ke,{asChild:!0,children:a.jsxs("button",{type:"button",disabled:_e,title:Js,className:en,children:[$l,tn]})}),e[251]=_e,e[252]=Js,e[253]=en,e[254]=$l,e[255]=tn,e[256]=sn):sn=e[256];let nn;e[257]!==ie||e[258]!==p?(nn=to.map(M=>{const pe=Ot[M].icon;return a.jsxs(Ce,{onSelect:()=>ie({type:M}),children:[a.jsx(pe,{size:16}),p(Ot[M].labelKey)]},M)}),e[257]=ie,e[258]=p,e[259]=nn):nn=e[259];let rn;e[260]!==nn?(rn=a.jsx(We,{align:"start",className:"w-44",children:nn}),e[260]=nn,e[261]=rn):rn=e[261];let ln;e[262]!==sn||e[263]!==rn?(ln=a.jsxs(Ge,{children:[sn,rn]}),e[262]=sn,e[263]=rn,e[264]=ln):ln=e[264];let an;e[265]!==_e||e[266]!==p?(an=_e?p("taskBoard.taskDialog.reportsContentLocked"):void 0,e[265]=_e,e[266]=p,e[267]=an):an=e[267];const Rl=Te==="none"&&Sr,zl=_e&&"cursor-default opacity-60";let on;e[268]!==Rl||e[269]!==zl?(on=F(St,Rl,zl),e[268]=Rl,e[269]=zl,e[270]=on):on=e[270];let cn;e[271]!==Te||e[272]!==p?(cn=Te==="none"?a.jsxs(a.Fragment,{children:[a.jsx(pr,{size:16}),p("taskBoard.taskDialog.setPriorityButton")]}):a.jsxs(a.Fragment,{children:[a.jsx("span",{className:F("size-2 rounded-full",Le[Te].dotClassName)}),p(Le[Te].labelKey)]}),e[271]=Te,e[272]=p,e[273]=cn):cn=e[273];let dn;e[274]!==_e||e[275]!==an||e[276]!==on||e[277]!==cn?(dn=a.jsx(Ke,{asChild:!0,children:a.jsx("button",{type:"button",disabled:_e,title:an,className:on,children:cn})}),e[274]=_e,e[275]=an,e[276]=on,e[277]=cn,e[278]=dn):dn=e[278];let un;e[279]!==ie||e[280]!==p?(un=br.map(M=>a.jsxs(Ce,{onSelect:()=>ie({priority:M}),children:[a.jsx("span",{className:F("size-2 rounded-full",Le[M].dotClassName)}),p(Le[M].labelKey)]},M)),e[279]=ie,e[280]=p,e[281]=un):un=e[281];let fn;e[282]!==un?(fn=a.jsx(We,{align:"start",className:"w-40",children:un}),e[282]=un,e[283]=fn):fn=e[283];let hn;e[284]!==dn||e[285]!==fn?(hn=a.jsxs(Ge,{children:[dn,fn]}),e[284]=dn,e[285]=fn,e[286]=hn):hn=e[286];const El=l&&a.jsx("div",{className:"inline-flex h-9 items-center justify-start gap-2 px-3 text-sm font-medium text-foreground",title:p("taskBoard.taskDialog.createdByLabel"),children:Jl(l)?a.jsxs(a.Fragment,{children:[a.jsx(al,{size:16,className:"text-muted-foreground"}),p("taskBoard.taskDialog.createdBySystemLabel")]}):Fr?a.jsxs(a.Fragment,{children:[a.jsx(Fe,{url:Fr.user?.image??void 0,fallback:Oe(Fr.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate",children:Fr.user?.name??p("taskBoard.taskDialog.unknownCreatorLabel")})]}):a.jsxs(a.Fragment,{children:[a.jsx(ss,{size:16,className:"text-muted-foreground"}),p("taskBoard.taskDialog.unknownCreatorLabel")]})}),Il=!U&&Sr;let pn;e[287]!==Il?(pn=F(St,Il),e[287]=Il,e[288]=pn):pn=e[288];let mn;e[289]!==Xe||e[290]!==Vt||e[291]!==Ue||e[292]!==p?(mn=Ue&&Xe?a.jsxs(a.Fragment,{children:[a.jsxs("span",{className:"hidden items-center gap-2 sm:flex",children:[a.jsx(Fe,{url:Xe.user?.image??void 0,fallback:Oe(Xe.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate",children:Xe.user?.name??p("taskBoard.taskDialog.superAgentDefaultName")})]}),a.jsxs("span",{className:"flex items-center gap-2 sm:hidden",children:[a.jsxs("span",{className:"inline-flex items-center",children:[a.jsx(Fe,{url:Xe.user?.image??void 0,fallback:Oe(Xe.user?.name),shape:"circle",size:"2xs",className:"-mr-1.5 ring-2 ring-background"}),a.jsx(Ve,{size:16,className:"ring-2 ring-background"})]}),p("taskBoard.taskDialog.superAgentLabel")]})]}):Ue?a.jsxs(a.Fragment,{children:[a.jsx(Ve,{size:16}),p("taskBoard.taskDialog.superAgentLabel")]}):Vt?a.jsxs(a.Fragment,{children:[a.jsx(Fe,{url:Vt.user?.image??void 0,fallback:Oe(Vt.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate",children:Vt.user?.name??p("taskBoard.taskDialog.unassignedLabel")})]}):a.jsxs(a.Fragment,{children:[a.jsx(Oi,{size:16,className:"text-muted-foreground"}),p("taskBoard.taskDialog.assignButton")]}),e[289]=Xe,e[290]=Vt,e[291]=Ue,e[292]=p,e[293]=mn):mn=e[293];let gn;e[294]!==pn||e[295]!==mn?(gn=a.jsx(gt,{asChild:!0,children:a.jsx("button",{type:"button",className:pn,children:mn})}),e[294]=pn,e[295]=mn,e[296]=gn):gn=e[296];let xn;e[297]!==l?.assigneeId||e[298]!==g||e[299]!==ie?(xn=M=>{if(Lr(!1),M===ye&&l?.assigneeId===ye){g?.();return}ie({assigneeId:M})},e[297]=l?.assigneeId,e[298]=g,e[299]=ie,e[300]=xn):xn=e[300];let kn;e[301]!==C||e[302]!==xn?(kn=a.jsx(kt,{align:"start",className:"w-56 p-0",children:a.jsx(Ia,{members:C,onSelect:xn})}),e[301]=C,e[302]=xn,e[303]=kn):kn=e[303];let bn;e[304]!==At||e[305]!==gn||e[306]!==kn?(bn=a.jsxs(bt,{open:At,onOpenChange:Lr,modal:!0,children:[gn,kn]}),e[304]=At,e[305]=gn,e[306]=kn,e[307]=bn):bn=e[307];let yn;e[308]!==Xe||e[309]!==Ue||e[310]!==p?(yn=Ue&&Xe&&a.jsxs("div",{className:"relative mt-1.5 hidden items-center pl-5 sm:flex",children:[a.jsx("span",{className:"absolute -top-1.5 left-5 h-[calc(50%+0.375rem)] w-2.5 rounded-bl-md border-b border-l border-border"}),a.jsxs("span",{className:F(St,"pointer-events-none"),children:[a.jsx(Ve,{size:16}),p("taskBoard.taskDialog.superAgentLabel")]})]}),e[308]=Xe,e[309]=Ue,e[310]=p,e[311]=yn):yn=e[311];let jn;e[312]!==bn||e[313]!==yn?(jn=a.jsxs("div",{className:"flex flex-col",children:[bn,yn]}),e[312]=bn,e[313]=yn,e[314]=jn):jn=e[314];const Ll=!he&&Sr;let vn;e[315]!==Ll?(vn=F(St,Ll),e[315]=Ll,e[316]=vn):vn=e[316];let Ur;e[317]===Symbol.for("react.memo_cache_sentinel")?(Ur=a.jsx(xt,{size:16,className:"text-muted-foreground"}),e[317]=Ur):Ur=e[317];let wn;e[318]!==he||e[319]!==p?(wn=he?tc.format(he):p("taskBoard.taskDialog.dueDateLabel"),e[318]=he,e[319]=p,e[320]=wn):wn=e[320];let Sn;e[321]!==vn||e[322]!==wn?(Sn=a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:vn,children:[Ur,wn]})}),e[321]=vn,e[322]=wn,e[323]=Sn):Sn=e[323];const Ml=he??void 0;let Cn;e[324]!==ie?(Cn=M=>{ie({dueDate:M??null}),M&&jr(!1)},e[324]=ie,e[325]=Cn):Cn=e[325];let Nn;e[326]!==Ml||e[327]!==Cn?(Nn=a.jsx(kt,{className:"w-auto p-0",align:"start",children:a.jsx(ka,{mode:"single",selected:Ml,onSelect:Cn,initialFocus:!0})}),e[326]=Ml,e[327]=Cn,e[328]=Nn):Nn=e[328];let Tn;e[329]!==_t||e[330]!==Sn||e[331]!==Nn?(Tn=a.jsxs(bt,{open:_t,onOpenChange:jr,children:[Sn,Nn]}),e[329]=_t,e[330]=Sn,e[331]=Nn,e[332]=Tn):Tn=e[332];const Pl=l?.threads;let Bn;e[333]!==Pl?(Bn=a.jsx(Ep,{threads:Pl}),e[333]=Pl,e[334]=Bn):Bn=e[334];let _n;e[335]!==jn||e[336]!==Tn||e[337]!==Bn||e[338]!==Ks||e[339]!==Xs||e[340]!==ln||e[341]!==hn||e[342]!==El?(_n=a.jsxs(nl,{label:Ks,children:[Xs,ln,hn,El,jn,Tn,Bn]}),e[335]=jn,e[336]=Tn,e[337]=Bn,e[338]=Ks,e[339]=Xs,e[340]=ln,e[341]=hn,e[342]=El,e[343]=_n):_n=e[343];let An;e[344]!==p?(An=p("taskBoard.taskDialog.labelsLabel"),e[344]=p,e[345]=An):An=e[345];let $n;e[346]!==I||e[347]!==ie||e[348]!==p||e[349]!==Be?($n=Be.length===0?a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:F(St,Sr),children:[a.jsx(ll,{size:16}),p("taskBoard.taskDialog.tagsButton")]})}):a.jsxs("div",{className:"flex flex-wrap items-center gap-1.5 sm:px-3",children:[Be.map(M=>{const pe=I.find(Se=>Se.id===M);return pe?a.jsxs("div",{className:"inline-flex items-center gap-1.5 rounded-md border border-border px-2 py-1 text-sm font-medium text-foreground transition-colors hover:bg-muted",children:[a.jsxs("button",{type:"button",onClick:()=>Wt(!0),className:"inline-flex items-center gap-1.5",children:[a.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:qt(pe.color)}}),a.jsx("span",{className:"truncate",children:pe.name})]}),a.jsx("button",{type:"button","aria-label":p("taskBoard.taskDialog.removeTagAriaLabel",{name:pe.name}),className:"-mr-0.5 flex size-3.5 items-center justify-center classic:rounded-sm compact:rounded-lg text-muted-foreground hover:bg-background hover:text-foreground",onClick:()=>{ie({tagIds:Be.filter(Se=>Se!==M)})},children:a.jsx(Ht,{size:10})})]},M):null}),a.jsx(gt,{asChild:!0,children:a.jsx("button",{type:"button","aria-label":p("taskBoard.taskDialog.addTagButton"),className:"flex size-7 items-center justify-center classic:rounded-md compact:rounded-lg border border-border text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:a.jsx(ts,{size:14})})})]}),e[346]=I,e[347]=ie,e[348]=p,e[349]=Be,e[350]=$n):$n=e[350];let Dn;e[351]!==I.length?(Dn=yd(I.length),e[351]=I.length,e[352]=Dn):Dn=e[352];let Rn;e[353]!==ie||e[354]!==Be?(Rn=M=>ie({tagIds:Be.includes(M)?Be.filter(pe=>pe!==M):[...Be,M]}),e[353]=ie,e[354]=Be,e[355]=Rn):Rn=e[355];let zn;e[356]!==we||e[357]!==ot||e[358]!==I||e[359]!==Dn||e[360]!==Rn||e[361]!==Be?(zn=a.jsx(kt,{align:"start",className:"w-56 p-0",children:a.jsx(fp,{tags:I,selectedIds:Be,defaultColor:Dn,onToggle:Rn,onCreate:we,onDelete:ot})}),e[356]=we,e[357]=ot,e[358]=I,e[359]=Dn,e[360]=Rn,e[361]=Be,e[362]=zn):zn=e[362];let En;e[363]!==$n||e[364]!==zn||e[365]!==hs?(En=a.jsxs(bt,{open:hs,onOpenChange:Wt,modal:!0,children:[$n,zn]}),e[363]=$n,e[364]=zn,e[365]=hs,e[366]=En):En=e[366];let In;e[367]!==An||e[368]!==En?(In=a.jsx(nl,{label:An,children:En}),e[367]=An,e[368]=En,e[369]=In):In=e[369];const Fl=nl;let Ln;e[370]!==p?(Ln=p("taskBoard.taskDialog.projectLabel"),e[370]=p,e[371]=Ln):Ln=e[371];const Ol=Ge,Hl=!K&&Sr;let Mn;e[372]!==Hl?(Mn=F(St,"max-w-full",Hl),e[372]=Hl,e[373]=Mn):Mn=e[373];let Pn;e[374]!==ge?(Pn=a.jsx(es,{entry:ge}),e[374]=ge,e[375]=Pn):Pn=e[375];let Fn;e[376]!==K||e[377]!==ge?.title||e[378]!==p?(Fn=ge?.title??K??p("taskBoard.taskDialog.projectButton"),e[376]=K,e[377]=ge?.title,e[378]=p,e[379]=Fn):Fn=e[379];let On;e[380]!==Fn?(On=a.jsx("span",{className:"min-w-0 truncate text-left",children:Fn}),e[380]=Fn,e[381]=On):On=e[381];let Hn;e[382]!==Mn||e[383]!==Pn||e[384]!==On?(Hn=a.jsx(Ke,{asChild:!0,children:a.jsxs("button",{type:"button",className:Mn,children:[Pn,On]})}),e[382]=Mn,e[383]=Pn,e[384]=On,e[385]=Hn):Hn=e[385];const ql=We,mc="start",gc="w-64";let qn;e[386]!==ie?(qn=()=>ie({repo:null}),e[386]=ie,e[387]=qn):qn=e[387];let Un;e[388]!==p?(Un=p("taskBoard.taskDialog.noProject"),e[388]=p,e[389]=Un):Un=e[389];let Kn;e[390]!==qn||e[391]!==Un?(Kn=a.jsx(Ce,{onSelect:qn,children:Un}),e[390]=qn,e[391]=Un,e[392]=Kn):Kn=e[392];let Kr;e[393]!==ie?(Kr=M=>a.jsx(Ce,{className:"gap-2",onSelect:()=>ie({repo:M.repo}),children:a.jsx(va,{entry:M})},M.id),e[393]=ie,e[394]=Kr):Kr=e[394];const Ul=Z.map(Kr);let Wn;e[395]!==ql||e[396]!==Kn||e[397]!==Ul?(Wn=a.jsxs(ql,{align:mc,className:gc,children:[Kn,Ul]}),e[395]=ql,e[396]=Kn,e[397]=Ul,e[398]=Wn):Wn=e[398];let Gn;e[399]!==Ol||e[400]!==Hn||e[401]!==Wn?(Gn=a.jsxs(Ol,{children:[Hn,Wn]}),e[399]=Ol,e[400]=Hn,e[401]=Wn,e[402]=Gn):Gn=e[402];let Vn;e[403]!==Fl||e[404]!==Ln||e[405]!==Gn?(Vn=a.jsx(Fl,{label:Ln,children:Gn}),e[403]=Fl,e[404]=Ln,e[405]=Gn,e[406]=Vn):Vn=e[406];let Qn;e[407]!==_n||e[408]!==In||e[409]!==Vn||e[410]!==Us?(Qn=a.jsxs("div",{className:pc,children:[Us,_n,In,Vn]}),e[407]=_n,e[408]=In,e[409]=Vn,e[410]=Us,e[411]=Qn):Qn=e[411];let Yn;e[412]!==Qn||e[413]!==It||e[414]!==qs?(Yn=a.jsxs("div",{className:It,children:[qs,Qn]}),e[412]=Qn,e[413]=It,e[414]=qs,e[415]=Yn):Yn=e[415];let Zn;e[416]!==Yn||e[417]!==Ts?(Zn=a.jsx("div",{className:Ts,children:Yn}),e[416]=Yn,e[417]=Ts,e[418]=Zn):Zn=e[418];let Xn;e[419]!==$t?(Xn=()=>$t(null),e[419]=$t,e[420]=Xn):Xn=e[420];let Jn;e[421]!==Rt||e[422]!==Xn?(Jn=a.jsx(xp,{thread:Rt,onClose:Xn}),e[421]=Rt,e[422]=Xn,e[423]=Jn):Jn=e[423];let er;e[424]!==Pe||e[425]!==k||e[426]!==l||e[427]!==p||e[428]!==le?(er=!l&&a.jsx("div",{className:"flex h-16 items-center justify-end border-t border-border px-4",children:a.jsxs(ke,{size:"sm",disabled:!le.trim()||k,onClick:Pe,children:[a.jsx(ts,{size:16}),p("taskBoard.taskDialog.createTaskButton")]})}),e[424]=Pe,e[425]=k,e[426]=l,e[427]=p,e[428]=le,e[429]=er):er=e[429];let Wr;e[430]!==Zn||e[431]!==Jn||e[432]!==er||e[433]!==Lt?(Wr=a.jsxs(a.Fragment,{children:[Lt,Zn,Jn,er]}),e[430]=Zn,e[431]=Jn,e[432]=er,e[433]=Lt,e[434]=Wr):Wr=e[434];const tr=Wr;if(s==="page"){let M;e[435]!==B||e[436]!==ht?(M=Se=>{const ze=B(Se),Mt=ht(Se);return()=>{ze?.(),Mt?.()}},e[435]=B,e[436]=ht,e[437]=M):M=e[437];let pe;return e[438]!==tr||e[439]!==M?(pe=a.jsx("div",{ref:M,"data-testid":"task-detail",className:"flex min-h-0 flex-1 flex-col overflow-hidden",children:tr}),e[438]=tr,e[439]=M,e[440]=pe):pe=e[440],pe}let sr;e[441]!==Re?(sr=M=>!M&&Re(),e[441]=Re,e[442]=sr):sr=e[442];let nr;e[443]!==p?(nr=p("taskBoard.taskDialog.newTaskTitle"),e[443]=p,e[444]=nr):nr=e[444];let rr;e[445]!==nr?(rr=a.jsx(ol,{className:"sr-only",children:nr}),e[445]=nr,e[446]=rr):rr=e[446];let lr;e[447]!==tr||e[448]!==rr?(lr=a.jsxs(cl,{className:"flex max-h-[92vh] flex-col gap-0 overflow-hidden rounded-2xl p-0 sm:h-[90vh] sm:max-h-[820px] sm:max-w-[1040px]",closeButtonClassName:"hidden",children:[rr,tr]}),e[447]=tr,e[448]=rr,e[449]=lr):lr=e[449];let Gr;return e[450]!==y||e[451]!==sr||e[452]!==lr?(Gr=a.jsx(dl,{open:y,onOpenChange:sr,children:lr}),e[450]=y,e[451]=sr,e[452]=lr,e[453]=Gr):Gr=e[453],Gr}function Mp(t){return!t}function Pp(t){t.key==="Enter"&&t.preventDefault()}function Fp(t){t&&(t.style.height="auto",t.style.height=`${t.scrollHeight}px`)}function Op(t){return t.id}function Hp(t){const e=$.c(2);let s;return e[0]!==t?(s=a.jsx(nc,{...t,chrome:"dialog"}),e[0]=t,e[1]=s):s=e[1],s}function qp(t){const e=$.c(2);let s;return e[0]!==t?(s=a.jsx(nc,{...t,chrome:"page"}),e[0]=t,e[1]=s):s=e[1],s}function Up(t,e){switch(t.status){case"failed":return ed(t.failureKind)?{label:t.failureKind==="superseded"?e("taskBoard.taskDialog.threadStatusSuperseded"):e("taskBoard.taskDialog.threadStatusEndedAfterDelivery"),className:"text-muted-foreground",icon:ns}:{label:e("taskBoard.taskDialog.threadStatusError"),className:"text-destructive",icon:Hc};case"requires_action":return{label:e("taskBoard.taskDialog.threadStatusNeedsInput"),className:"text-warning",icon:bl};case"in_progress":return{label:e("taskBoard.taskDialog.threadStatusRunning"),className:"text-primary",icon:ua,spin:!0};case"completed":return{label:e("taskBoard.taskDialog.threadStatusCompleted"),className:"text-success",icon:kr};case"expired":return{label:e("taskBoard.taskDialog.threadStatusExpired"),className:"text-muted-foreground",icon:ns};default:return t.status}}function Kp(t){const e=$.c(28),{thread:s,startedBy:n,onOpen:r}=t,l=J();let i;if(e[0]!==r||e[1]!==n||e[2]!==l||e[3]!==s){const c=s.status?Up({...s,status:s.status},l):null,o=s.lastMessage;let d;e[5]!==s.title?(d=jd(s.title,"reviewer"),e[5]=s.title,e[6]=d):d=e[6];const u=d;let f;e[7]!==r||e[8]!==s?(f=()=>r?.(s),e[7]=r,e[8]=s,e[9]=f):f=e[9];let h;e[10]!==u?(h=u?a.jsx(Sa,{size:16,className:"shrink-0"}):a.jsx(Ve,{size:16,className:"shrink-0"}),e[10]=u,e[11]=h):h=e[11];let x;e[12]!==l||e[13]!==s.title?(x=s.title||l("taskBoard.taskDialog.superAgentDefaultName"),e[12]=l,e[13]=s.title,e[14]=x):x=e[14];let m;e[15]!==x?(m=a.jsx("span",{className:"truncate text-sm font-medium text-foreground",children:x}),e[15]=x,e[16]=m):m=e[16];let g;e[17]!==n||e[18]!==l?(g=n&&a.jsxs(a.Fragment,{children:[a.jsx("span",{className:"shrink-0 text-sm text-muted-foreground/50",children:l("taskBoard.taskDialog.startedByLabel")}),a.jsx(Fe,{url:n.user?.image??void 0,fallback:Oe(n.user?.name),shape:"circle",size:"2xs"}),a.jsx("span",{className:"truncate text-sm text-foreground",children:n.user?.name??l("taskBoard.taskDialog.someoneLabel")})]}),e[17]=n,e[18]=l,e[19]=g):g=e[19];let k;e[20]!==r||e[21]!==l?(k=r&&a.jsxs("span",{className:"ml-auto flex shrink-0 items-center gap-1 text-xs text-muted-foreground/60 group-hover:text-foreground",children:[l("taskBoard.taskDialog.openThreadHint"),a.jsx(Dr,{size:14})]}),e[20]=r,e[21]=l,e[22]=k):k=e[22];let y;e[23]!==h||e[24]!==m||e[25]!==g||e[26]!==k?(y=a.jsxs("div",{className:"flex items-center gap-2",children:[h,m,g,k]}),e[23]=h,e[24]=m,e[25]=g,e[26]=k,e[27]=y):y=e[27],i=a.jsxs("button",{type:"button",disabled:!r,onClick:f,className:"group flex w-full flex-col gap-2 rounded-xl bg-card p-4 text-left card-shadow transition-colors enabled:hover:bg-muted/60 disabled:cursor-default",children:[y,c&&a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsxs("span",{className:F("flex shrink-0 items-center gap-1.5",c.className),children:[c.spin?a.jsx(yt,{className:"size-[15px]",label:c.label}):a.jsx(c.icon,{size:15}),a.jsx("span",{className:"text-sm",children:c.label})]}),o&&a.jsx("span",{className:"min-w-0 flex-1 truncate text-sm text-muted-foreground",children:o})]})]}),e[0]=r,e[1]=n,e[2]=l,e[3]=s,e[4]=i}else i=e[4];return i}function Wp(t,e){return t.merged?{label:e("taskBoard.taskDialog.prStateMerged"),className:"text-special",icon:oo}:t.state==="closed"?{label:e("taskBoard.taskDialog.prStateClosed"),className:"text-destructive",icon:sl}:t.draft?{label:e("taskBoard.taskDialog.prStateDraft"),className:"text-muted-foreground",icon:sl}:{label:e("taskBoard.taskDialog.prStateOpen"),className:"text-success",icon:sl}}function Gp(t,e){switch(t){case"passing":return{label:e("taskBoard.taskDialog.prChecksPassing"),className:"text-success",icon:kr};case"failing":return{label:e("taskBoard.taskDialog.prChecksFailing"),className:"text-destructive",icon:ns};case"pending":return{label:e("taskBoard.taskDialog.prChecksPending"),className:"text-warning",icon:ua};default:return null}}const Vp=new Set(["failure","cancelled","timed_out","action_required","startup_failure","stale"]);function Qp(t){if(t.status!=="completed")return{icon:ua,className:"text-warning",spin:!0};const e=t.conclusion;return e&&Vp.has(e)?{icon:ns,className:"text-destructive",spin:!1}:Ko(t)?{icon:kr,className:"text-success",spin:!1}:{icon:bl,className:"text-muted-foreground",spin:!1}}function Yp(t){const e=$.c(46),{url:s,routes:n}=t,r=J(),{data:l,isPending:i,isError:c}=np(s),o=l?.available??!1;if(i){let T;e[0]===Symbol.for("react.memo_cache_sentinel")?(T=a.jsx(yt,{className:"size-[14px]"}),e[0]=T):T=e[0];let N;e[1]!==r?(N=r("taskBoard.taskDialog.previewLabel"),e[1]=r,e[2]=N):N=e[2];let _;return e[3]!==N?(_=a.jsxs(ke,{type:"button",variant:"outline",size:"sm",className:"gap-1.5",disabled:!0,children:[T,N]}),e[3]=N,e[4]=_):_=e[4],_}if(!o||c){let T;e[5]!==r?(T=r("taskBoard.taskDialog.previewUnavailableTitle"),e[5]=r,e[6]=T):T=e[6];let N;e[7]===Symbol.for("react.memo_cache_sentinel")?(N=a.jsx(ea,{size:14}),e[7]=N):N=e[7];let _;e[8]!==r?(_=r("taskBoard.taskDialog.previewUnavailable"),e[8]=r,e[9]=_):_=e[9];let D;return e[10]!==T||e[11]!==_?(D=a.jsxs(ke,{type:"button",variant:"outline",size:"sm",className:"gap-1.5",disabled:!0,title:T,children:[N,_]}),e[10]=T,e[11]=_,e[12]=D):D=e[12],D}const d=n.length>0&&"rounded-r-none";let u;e[13]!==d?(u=F("gap-1.5",d),e[13]=d,e[14]=u):u=e[14];let f;e[15]===Symbol.for("react.memo_cache_sentinel")?(f=a.jsx(ea,{size:14}),e[15]=f):f=e[15];let h;e[16]!==r?(h=r("taskBoard.taskDialog.previewLabel"),e[16]=r,e[17]=h):h=e[17];let x;e[18]===Symbol.for("react.memo_cache_sentinel")?(x=a.jsx(Br,{size:12}),e[18]=x):x=e[18];let m;e[19]!==h||e[20]!==s?(m=a.jsxs("a",{href:s,target:"_blank",rel:"noreferrer",children:[f,h,x]}),e[19]=h,e[20]=s,e[21]=m):m=e[21];let g;e[22]!==u||e[23]!==m?(g=a.jsx(ke,{asChild:!0,type:"button",variant:"outline",size:"sm",className:u,children:m}),e[22]=u,e[23]=m,e[24]=g):g=e[24];const k=g;if(n.length===0)return k;let y;e[25]!==r?(y=r("taskBoard.taskDialog.previewRoutesLabel"),e[25]=r,e[26]=y):y=e[26];let v;e[27]!==r?(v=r("taskBoard.taskDialog.previewRoutesLabel"),e[27]=r,e[28]=v):v=e[28];let p;e[29]===Symbol.for("react.memo_cache_sentinel")?(p=a.jsx(Kt,{size:14}),e[29]=p):p=e[29];let b;e[30]!==y||e[31]!==v?(b=a.jsx(Ke,{asChild:!0,children:a.jsx(ke,{type:"button",variant:"outline",size:"sm",className:"rounded-l-none border-l-0 px-1.5","aria-label":y,title:v,children:p})}),e[30]=y,e[31]=v,e[32]=b):b=e[32];let j;if(e[33]!==n||e[34]!==s){let T;e[36]!==s?(T=N=>a.jsx(Ce,{asChild:!0,children:a.jsx("a",{href:G1(s,N),target:"_blank",rel:"noreferrer",className:"font-mono text-xs",children:N})},N),e[36]=s,e[37]=T):T=e[37],j=n.map(T),e[33]=n,e[34]=s,e[35]=j}else j=e[35];let w;e[38]!==j?(w=a.jsx(We,{align:"start",children:j}),e[38]=j,e[39]=w):w=e[39];let S;e[40]!==b||e[41]!==w?(S=a.jsxs(Ge,{children:[b,w]}),e[40]=b,e[41]=w,e[42]=S):S=e[42];let C;return e[43]!==k||e[44]!==S?(C=a.jsxs("div",{className:"flex items-center",children:[k,S]}),e[43]=k,e[44]=S,e[45]=C):C=e[45],C}function Zp(t){const e=$.c(54),{pr:s,routes:n,revalidating:r,previewThread:l,reviewsReady:i,shipPending:c,resolvePending:o,onShip:d,onResolveConflict:u,onOpenPreview:f}=t,h=J(),[x,m]=W.useState(!1);let g;if(e[0]!==x||e[1]!==f||e[2]!==u||e[3]!==d||e[4]!==s||e[5]!==l||e[6]!==o||e[7]!==r||e[8]!==i||e[9]!==n||e[10]!==c||e[11]!==h){const k=Wp(s,h),y=Gp(s.checksStatus,h);let v;e[13]!==s||e[14]!==i?(v=K1(s,i),e[13]=s,e[14]=i,e[15]=v):v=e[15];const{isOpen:p,hasConflict:b,showShip:j,showResolveConflict:w}=v,S=!!l||!!s.previewUrl||j||w,C=s.checks??[],T=C.length>0||y!=null,N=C.length>0,_=W1(s.checksStatus,C,x),D=_?{label:h("taskBoard.taskDialog.prChecksScore",_),className:"text-warning",icon:ns}:y,A=r&&"revalidating-ring";let L;e[16]!==A?(L=F("flex flex-col gap-3 rounded-xl bg-card p-3 card-shadow",A),e[16]=A,e[17]=L):L=e[17];const z=pf(s.url)?.repo.provider??"github";let P;e[18]!==z?(P=a.jsx(Ou,{provider:z,className:"size-4 shrink-0 text-foreground"}),e[18]=z,e[19]=P):P=e[19];const E=s.title??`${s.repoOwner}/${s.repoName}`;let I;e[20]!==E?(I=a.jsx("span",{className:"min-w-0 flex-1 truncate text-sm text-foreground",children:E}),e[20]=E,e[21]=I):I=e[21];const V=F("flex shrink-0 items-center gap-1 text-xs font-medium",k.className);let Q;e[22]!==k?(Q=a.jsx(k.icon,{size:13}),e[22]=k,e[23]=Q):Q=e[23];let Y;e[24]!==k||e[25]!==Q||e[26]!==V?(Y=a.jsxs("span",{className:V,children:[Q,k.label]}),e[24]=k,e[25]=Q,e[26]=V,e[27]=Y):Y=e[27];let se;e[28]===Symbol.for("react.memo_cache_sentinel")?(se=a.jsx(Br,{size:12,className:"text-muted-foreground/60 group-hover:text-foreground"}),e[28]=se):se=e[28];let H;e[29]!==s.number||e[30]!==s.url?(H=a.jsxs("a",{href:s.url,target:"_blank",rel:"noreferrer",title:s.url,className:"group flex shrink-0 items-center gap-1 rounded-md px-2 py-1 text-xs font-medium text-muted-foreground transition-colors hover:bg-muted",children:["#",s.number,se]}),e[29]=s.number,e[30]=s.url,e[31]=H):H=e[31];let ee;e[32]!==Y||e[33]!==H||e[34]!==P||e[35]!==I?(ee=a.jsxs("div",{className:"flex items-center gap-3",children:[P,I,Y,H]}),e[32]=Y,e[33]=H,e[34]=P,e[35]=I,e[36]=ee):ee=e[36];let q;e[37]!==b||e[38]!==p||e[39]!==h?(q=b&&p&&a.jsxs("div",{className:"flex items-center gap-1.5 text-xs font-medium text-warning",children:[a.jsx(ns,{size:13,className:"shrink-0"}),h("taskBoard.taskDialog.prConflict")]}),e[37]=b,e[38]=p,e[39]=h,e[40]=q):q=e[40];let Z;e[41]!==S||e[42]!==f||e[43]!==u||e[44]!==d||e[45]!==s.previewUrl||e[46]!==l||e[47]!==o||e[48]!==n||e[49]!==c||e[50]!==w||e[51]!==j||e[52]!==h?(Z=S&&a.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[l&&a.jsxs(ke,{type:"button",variant:"outline",size:"sm",className:"gap-1.5",title:h("taskBoard.taskDialog.openPreviewTitle"),onClick:()=>f?.(l),children:[a.jsx(Fi,{size:13}),h("taskBoard.taskDialog.openPreviewButton")]}),s.previewUrl&&a.jsx(Yp,{url:s.previewUrl,routes:n}),j&&a.jsx(ke,{type:"button",variant:"success",size:"sm",disabled:c,onClick:d,children:h("taskBoard.taskDialog.shipToProductionButton")}),w&&a.jsxs(ke,{type:"button",variant:"warning",size:"sm",className:"gap-1.5",disabled:o,title:h("taskBoard.taskDialog.resolveConflictTitle"),onClick:u,children:[a.jsx(oo,{size:13}),h("taskBoard.taskDialog.resolveConflictButton")]})]}),e[41]=S,e[42]=f,e[43]=u,e[44]=d,e[45]=s.previewUrl,e[46]=l,e[47]=o,e[48]=n,e[49]=c,e[50]=w,e[51]=j,e[52]=h,e[53]=Z):Z=e[53],g=a.jsxs("div",{className:L,children:[ee,q,Z,T&&a.jsxs("div",{className:"border-t border-border pt-2 text-xs",children:[a.jsxs("button",{type:"button",disabled:!N,onClick:()=>m(Xp),className:"flex w-full items-center gap-1.5 font-medium disabled:cursor-default",children:[D?a.jsx(D.icon,{size:13,className:D.className}):a.jsx(kr,{size:13,className:"text-muted-foreground"}),a.jsx("span",{className:F(D?.className??"text-muted-foreground"),children:D?.label??h("taskBoard.taskDialog.prChecksLabel")}),N&&a.jsx(Dr,{size:14,className:F("ml-auto text-muted-foreground/60 transition-transform",x&&"rotate-90")})]}),x&&a.jsx("div",{className:"mt-2 flex flex-col gap-2",children:C.map((X,re)=>{const G=Qp(X),ne=`${X.name}-${re}`;return a.jsxs("div",{className:"rounded-md bg-muted/40 p-2",children:[a.jsxs("div",{className:"flex items-center gap-2",children:[G.spin?a.jsx(yt,{className:F("size-[13px]",G.className)}):a.jsx(G.icon,{size:13,className:F("shrink-0",G.className)}),a.jsx("span",{className:"min-w-0 flex-1 truncate font-medium text-foreground",children:X.name}),X.detailsUrl&&a.jsx("a",{href:X.detailsUrl,target:"_blank",rel:"noreferrer",className:"shrink-0 text-muted-foreground/60 hover:text-foreground",children:a.jsx(Br,{size:12})})]}),X.summary&&a.jsx("div",{className:"mt-1.5 max-h-64 overflow-auto text-muted-foreground",children:a.jsx(co,{id:`${s.url}-${ne}`,text:X.summary})})]},ne)})})]})]}),e[0]=x,e[1]=f,e[2]=u,e[3]=d,e[4]=s,e[5]=l,e[6]=o,e[7]=r,e[8]=i,e[9]=n,e[10]=c,e[11]=h,e[12]=g}else g=e[12];return g}function Xp(t){return!t}function Jp(){const t=$.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx(ar,{className:"size-4 shrink-0 rounded"}),a.jsx(ar,{className:"h-4 min-w-0 flex-1"}),a.jsx(ar,{className:"h-4 w-16 shrink-0"}),a.jsx(ar,{className:"h-4 w-10 shrink-0"})]}),t[0]=e):e=t[0];let s;return t[1]===Symbol.for("react.memo_cache_sentinel")?(s=a.jsxs("div",{className:"flex flex-col gap-3 rounded-xl bg-card p-3 card-shadow",children:[e,a.jsxs("div",{className:"flex gap-2",children:[a.jsx(ar,{className:"h-7 w-20"}),a.jsx(ar,{className:"h-7 w-28"})]})]}),t[1]=s):s=t[1],s}function em(t){const e=$.c(56),{item:s,description:n,onOpenPreview:r}=t,l=J(),{data:i,isLoading:c,isFetching:o}=Qo(s.id),{data:d}=Ea(s.id),u=ro(),f=rp(s.id),h=lp(s.id);let x,m,g,k,y,v;if(e[0]!==d||e[1]!==n||e[2]!==s.previewRoutes||e[3]!==s.reviewCycleStartedAt||e[4]!==s.status||e[5]!==s.threads||e[6]!==r||e[7]!==f||e[8]!==i||e[9]!==o||e[10]!==c||e[11]!==h||e[12]!==u||e[13]!==l){v=Symbol.for("react.early_return_sentinel");e:{const j=hp(n),w=c&&!i;if(!w&&(!i||i.length===0)&&j.length===0){v=null;break e}let S;e[20]!==d||e[21]!==s.reviewCycleStartedAt||e[22]!==s.status||e[23]!==u?(S=op(s.status)&&ap(d??[],Yo(u),s.reviewCycleStartedAt),e[20]=d,e[21]=s.reviewCycleStartedAt,e[22]=s.status,e[23]=u,e[24]=S):S=e[24];const C=S;let T;e[25]!==f||e[26]!==l?(T=()=>f.mutate(void 0,{onSuccess:z=>z?.merged?Je.success(l("taskBoard.taskDialog.shipSuccess")):Je.error(l("taskBoard.taskDialog.shipError")),onError:()=>Je.error(l("taskBoard.taskDialog.shipError"))}),e[25]=f,e[26]=l,e[27]=T):T=e[27];const N=T;let _;e[28]!==h||e[29]!==l?(_=z=>h.mutate(z,{onSuccess:()=>Je.success(l("taskBoard.taskDialog.resolveConflictSuccess")),onError:()=>Je.error(l("taskBoard.taskDialog.resolveConflictError"))}),e[28]=h,e[29]=l,e[30]=_):_=e[30];const D=_;let A;e[31]!==s.threads||e[32]!==r?(A=r?s.threads.find(sm):void 0,e[31]=s.threads,e[32]=r,e[33]=A):A=e[33];const L=A;x=sc,e[34]!==l?(y=l("taskBoard.taskDialog.linksLabel"),e[34]=l,e[35]=y):y=e[35],m="flex flex-col gap-1",e[36]!==s.previewRoutes||e[37]!==w||e[38]!==r||e[39]!==D||e[40]!==N||e[41]!==L||e[42]!==f||e[43]!==i||e[44]!==o||e[45]!==h||e[46]!==C?(g=w?a.jsx(Jp,{}):(i??[]).map(z=>a.jsx(Zp,{pr:z,routes:s.previewRoutes??[],revalidating:o,previewThread:L,reviewsReady:C,shipPending:f.isPending,resolvePending:h.isPending,onShip:N,onResolveConflict:()=>D(z.number),onOpenPreview:r},z.url)),e[36]=s.previewRoutes,e[37]=w,e[38]=r,e[39]=D,e[40]=N,e[41]=L,e[42]=f,e[43]=i,e[44]=o,e[45]=h,e[46]=C,e[47]=g):g=e[47],k=j.map(tm)}e[0]=d,e[1]=n,e[2]=s.previewRoutes,e[3]=s.reviewCycleStartedAt,e[4]=s.status,e[5]=s.threads,e[6]=r,e[7]=f,e[8]=i,e[9]=o,e[10]=c,e[11]=h,e[12]=u,e[13]=l,e[14]=x,e[15]=m,e[16]=g,e[17]=k,e[18]=y,e[19]=v}else x=e[14],m=e[15],g=e[16],k=e[17],y=e[18],v=e[19];if(v!==Symbol.for("react.early_return_sentinel"))return v;let p;e[48]!==m||e[49]!==g||e[50]!==k?(p=a.jsxs("div",{className:m,children:[g,k]}),e[48]=m,e[49]=g,e[50]=k,e[51]=p):p=e[51];let b;return e[52]!==x||e[53]!==y||e[54]!==p?(b=a.jsx(x,{label:y,children:p}),e[52]=x,e[53]=y,e[54]=p,e[55]=b):b=e[55],b}function tm(t){return a.jsxs("a",{href:t.url,target:"_blank",rel:"noreferrer",className:"group flex items-center gap-2 rounded-md px-1 py-1.5 transition-colors hover:bg-muted",children:[a.jsx(ea,{size:15,className:"shrink-0 text-muted-foreground"}),a.jsx("span",{className:"min-w-0 flex-1 truncate text-sm text-foreground",children:t.label}),a.jsx(Br,{size:13,className:"shrink-0 text-muted-foreground/50 group-hover:text-foreground"})]},t.url)}function sm(t){return t.hasPreview&&t.virtualMcpId}function nm(t){const e=$.c(7),{item:s,members:n,startedBy:r,onOpenThread:l}=t,i=J(),{data:c}=Ea(s.id),{data:o}=Li.useSession(),d=new Map(n.map(om)),u={id:o?.user?.id??"me",name:o?.user?.name??i("taskBoard.taskDialog.commentYouLabel"),image:o?.user?.image},f=Tp(s.id),h=p=>{if(p===ye)return{id:p,name:i("taskBoard.taskDialog.superAgentLabel"),isAgent:!0};if(p===u.id)return u;const b=d.get(p);return{id:p,name:b?.user?.name??p,image:b?.user?.image}},x=f.threads.map(p=>({id:p.id,author:h(p.authorId),body:p.body,createdAt:p.createdAt,resolved:p.resolved,replies:p.replies.map(b=>({id:b.id,author:h(b.authorId),body:b.body,createdAt:b.createdAt,replies:[]}))})),m=[...(c??[]).filter(Xc).map(im),...s.threads.filter(Jc).map(am),...x.map(lm)].sort(rm),g=[];for(const p of m){if(p.kind==="thread"){g.push({type:"thread",thread:p.thread});continue}if(p.kind==="comment"){g.push({type:"comment",comment:p.comment});continue}const b=g[g.length-1];b?.type==="timeline"?b.items.push(p.activity):g.push({type:"timeline",items:[p.activity]})}let k;e[0]!==i?(k=i("taskBoard.taskDialog.activityLabel"),e[0]=i,e[1]=k):k=e[1];let y;e[2]!==s.id||e[3]!==n?(y=a.jsx(Ap,{itemId:s.id,members:n}),e[2]=s.id,e[3]=n,e[4]=y):y=e[4];let v;return e[5]!==f.post?(v=p=>f.post.mutate({body:p}),e[5]=f.post,e[6]=v):v=e[6],a.jsx(sc,{label:k,action:y,children:a.jsxs("div",{className:"flex flex-col gap-5",children:[a.jsx(Sp,{me:u,onSubmit:v}),g.map((p,b)=>p.type==="timeline"?a.jsx(dm,{items:p.items,memberByUserId:d},`timeline-${b}`):p.type==="comment"?a.jsx(jp,{thread:p.comment,me:u,onReply:j=>f.post.mutate({body:j,parentId:p.comment.id}),onDelete:j=>f.remove.mutate(j),onToggleResolved:()=>f.setResolved.mutate({id:p.comment.id,resolved:!p.comment.resolved})},`comment-${p.comment.id}`):a.jsx(Kp,{thread:p.thread,startedBy:r,onOpen:l},`thread-${p.thread.threadId}`))]})})}function rm(t,e){return e.at-t.at}function lm(t){return{kind:"comment",at:new Date(t.createdAt).getTime(),comment:t}}function am(t){return{kind:"thread",at:new Date(t.createdAt).getTime(),thread:t}}function im(t){return{kind:"activity",at:new Date(t.occurredAt).getTime(),activity:t}}function om(t){return[t.userId,t]}function Qt(t){const e=$.c(7),{icon:s,label:n}=t;let r;e[0]!==s?(r=a.jsx("span",{className:"ml-1 mr-1 inline-flex h-[1lh] items-center align-top",children:s}),e[0]=s,e[1]=r):r=e[1];let l;e[2]!==n?(l=a.jsx("span",{className:"mr-1",children:n}),e[2]=n,e[3]=l):l=e[3];let i;return e[4]!==r||e[5]!==l?(i=a.jsxs(a.Fragment,{children:[r,l]}),e[4]=r,e[5]=l,e[6]=i):i=e[6],i}const gl="\0";function tl(t){return`${gl}${t}${gl}`}function Yt(t,e){return t.split(new RegExp(`${gl}(\\w+)${gl}`)).map((s,n)=>a.jsx(W.Fragment,{children:n%2===0?s:e[s]},n))}function dr(t,e){return e(t==="qa"?"taskBoard.taskDialog.qaAgentLabel":t==="code_review"?"taskBoard.taskDialog.codeReviewerLabel":"taskBoard.taskDialog.reviewerLabel")}function cm(t,e,s){const n=h=>{const x=typeof h=="string"?td[h]:void 0;if(!x)return String(h??"");const m=x.icon;return a.jsx(Qt,{icon:a.jsx(m,{size:14,className:x.iconClassName}),label:e(x.labelKey)})},r=h=>{const x=typeof h=="string"?Le[h]:void 0;return x?a.jsx(Qt,{icon:a.jsx("span",{className:F("size-2 rounded-full",x.dotClassName)}),label:e(x.labelKey)}):String(h??"")},l=h=>{const x=ec(typeof h=="string"?h:null);return x?a.jsx(Qt,{icon:a.jsx(xt,{size:14,className:"text-muted-foreground"}),label:tc.format(x)}):""},i=h=>!Array.isArray(h)||h.length===0?null:h.map((x,m)=>{const g=x;return a.jsx(Qt,{icon:a.jsx("span",{className:"size-2 rounded-full",style:{backgroundColor:qt(g.color)}}),label:g.name??""},g.id??m)}),c=h=>{if(h===ye)return a.jsx(Qt,{icon:a.jsx(Ve,{size:14}),label:e("taskBoard.taskDialog.superAgentLabel")});const x=typeof h=="string"?s.get(h):void 0;return a.jsx(Qt,{icon:a.jsx(Fe,{url:x?.user?.image??void 0,fallback:Oe(x?.user?.name),shape:"circle",size:"2xs"}),label:x?.user?.name??e("taskBoard.taskDialog.someoneLabel")})},o=h=>a.jsx(Qt,{icon:a.jsx(Sa,{size:14}),label:dr(h,e)}),d=t.data,u=tl("from"),f=tl("to");switch(t.action){case"created":return e("taskBoard.taskDialog.activityCreated");case"status_changed":{const h=Wo([{action:"status_changed",data:d}])?.message??"";return typeof d.retry=="number"?e("taskBoard.taskDialog.activityRetryScheduled",{attempt:String(d.retry),of:String(d.of??d.retry),reason:h}):typeof d.retriesSpent=="number"&&d.retriesSpent>0?Yt(e("taskBoard.taskDialog.activityRetriesExhausted",{to:f,count:String(d.retriesSpent),reason:h}),{to:n(d.to)}):Yt(d.from?e("taskBoard.taskDialog.activityMovedFromTo",{from:u,to:f}):e("taskBoard.taskDialog.activityMovedTo",{to:f}),{from:n(d.from),to:n(d.to)})}case"assignee_changed":return d.to==null?e("taskBoard.taskDialog.activityUnassigned"):Yt(e(d.to===ye?"taskBoard.taskDialog.activityDelegated":"taskBoard.taskDialog.activityAssigned",{name:tl("name")}),{name:c(d.to)});case"type_changed":return d.from?e("taskBoard.taskDialog.activityTypeFromTo",{from:u,to:f}):e("taskBoard.taskDialog.activityTypeSet",{to:f});case"priority_changed":return d.to==="none"?e("taskBoard.taskDialog.activityPriorityCleared"):Yt(!d.from||d.from==="none"?e("taskBoard.taskDialog.activityPrioritySet",{to:f}):e("taskBoard.taskDialog.activityPriorityFromTo",{from:u,to:f}),{from:r(d.from),to:r(d.to)});case"due_date_changed":return d.to==null?e("taskBoard.taskDialog.activityDueDateCleared"):Yt(d.from==null?e("taskBoard.taskDialog.activityDueDateSet",{to:f}):e("taskBoard.taskDialog.activityDueDateFromTo",{from:u,to:f}),{from:l(d.from),to:l(d.to)});case"title_changed":return e("taskBoard.taskDialog.activityRenamed",{to:String(d.to??"")});case"description_changed":return e("taskBoard.taskDialog.activityDescriptionUpdated");case"tags_changed":return!Array.isArray(d.to)||d.to.length===0?e("taskBoard.taskDialog.activityTagsCleared"):Yt(e("taskBoard.taskDialog.activityTagsSet",{to:f}),{to:i(d.to)});case"review_requested":return Yt(e("taskBoard.taskDialog.activityDelegated",{name:tl("name")}),{name:o(d.reviewer)});case"review_approved":return typeof d.notes=="string"&&d.notes.trim()?e("taskBoard.taskDialog.activityReviewApprovedWithNotes",{reviewer:dr(d.reviewer,e),notes:d.notes}):e("taskBoard.taskDialog.activityReviewApproved",{reviewer:dr(d.reviewer,e)});case"review_changes_requested":return typeof d.notes=="string"&&d.notes.trim()?e("taskBoard.taskDialog.activityReviewChangesRequestedWithNotes",{reviewer:dr(d.reviewer,e),notes:d.notes}):e("taskBoard.taskDialog.activityReviewChangesRequested",{reviewer:dr(d.reviewer,e)});case"review_verdict_requested":return e("taskBoard.taskDialog.activityReviewVerdictRequested",{reviewer:dr(d.reviewer,e)});case"merge_conflict_resolution":return e("taskBoard.taskDialog.activityMergeConflictResolution");case"merge_failed":{const h=typeof d.detail=="string"?d.detail:"";switch(d.reason){case"no_pr":return e("taskBoard.taskDialog.activityMergeFailedNoPr");case"checks_failing":return e("taskBoard.taskDialog.activityMergeFailedChecksFailing");case"no_connection":return h?e("taskBoard.taskDialog.activityMergeFailedNoConnection",{detail:h}):e("taskBoard.taskDialog.activityMergeFailed");case"rate_limited":return e("taskBoard.taskDialog.activityMergeFailedRateLimited");case"conflict":return e("taskBoard.taskDialog.activityMergeFailedConflict");case"refused":return h?e("taskBoard.taskDialog.activityMergeFailedRefused",{detail:h}):e("taskBoard.taskDialog.activityMergeFailed");default:return h?e("taskBoard.taskDialog.activityMergeFailedError",{detail:h}):e("taskBoard.taskDialog.activityMergeFailed")}}default:{const h=t.action;return String(h)}}}function Ti(t){return!t||t===ye}function dm(t){const e=$.c(29),{items:s,memberByUserId:n}=t,r=J(),[l,i]=W.useState(!1);let c;e[0]!==n||e[1]!==r?(c=v=>Ti(v)?r("taskBoard.taskDialog.superAgentLabel"):n.get(v)?.user?.name??r("taskBoard.taskDialog.someoneLabel"),e[0]=n,e[1]=r,e[2]=c):c=e[2];const o=c;let d;e[3]!==n?(d=v=>{if(Ti(v))return a.jsx("span",{className:"z-10 flex size-4 shrink-0 items-center justify-center bg-background",children:a.jsx(Ve,{size:16})});const p=n.get(v);return a.jsx("span",{className:"z-10 shrink-0 rounded-full bg-background",children:a.jsx(Fe,{url:p?.user?.image??void 0,fallback:Oe(p?.user?.name),shape:"circle",size:"2xs"})})},e[3]=n,e[4]=d):d=e[4];const u=d,f=s.length>Ci&&!l;let h;e[5]!==f||e[6]!==s?(h=f?s.slice(0,Ni):s,e[5]=f,e[6]=s,e[7]=h):h=e[7];const x=h;let m;e[8]!==x.length?(m=x.length>1&&a.jsx("span",{"aria-hidden":!0,className:"absolute bottom-3 left-2 top-3 w-px bg-border"}),e[8]=x.length,e[9]=m):m=e[9];let g;if(e[10]!==u||e[11]!==o||e[12]!==n||e[13]!==r||e[14]!==x){let v;e[16]!==u||e[17]!==o||e[18]!==n||e[19]!==r?(v=p=>a.jsxs("div",{className:"relative flex items-center gap-2.5",children:[u(p.actorId),a.jsxs("span",{className:"min-w-0 truncate text-xs text-muted-foreground",children:[o(p.actorId)," ",cm(p,r,n),a.jsxs("span",{className:"text-muted-foreground/60",children:[" · ",ma(new Date(p.occurredAt))]})]})]},p.id),e[16]=u,e[17]=o,e[18]=n,e[19]=r,e[20]=v):v=e[20],g=x.map(v),e[10]=u,e[11]=o,e[12]=n,e[13]=r,e[14]=x,e[15]=g}else g=e[15];let k;e[21]!==l||e[22]!==s.length||e[23]!==r?(k=s.length>Ci&&a.jsxs("button",{type:"button",onClick:()=>i(um),className:"relative flex items-center gap-2.5 text-left",children:[a.jsx("span",{className:"z-10 flex size-4 shrink-0 items-center justify-center rounded-full bg-background text-muted-foreground/60",children:a.jsx(pr,{size:14})}),a.jsx("span",{className:"text-xs text-muted-foreground/60 hover:text-foreground",children:l?r("taskBoard.taskDialog.timelineFoldLess"):r("taskBoard.taskDialog.timelineFoldMore",{count:String(s.length-Ni)})})]}),e[21]=l,e[22]=s.length,e[23]=r,e[24]=k):k=e[24];let y;return e[25]!==m||e[26]!==g||e[27]!==k?(y=a.jsxs("div",{className:"relative flex flex-col gap-4",children:[m,g,k]}),e[25]=m,e[26]=g,e[27]=k,e[28]=y):y=e[28],y}function um(t){return!t}function fm(t){const e=$.c(59),{item:s,orgSlug:n,onRerun:r}=t,l=J(),{data:i}=Ea(s.id),{data:c}=bo();let o;e[0]!==i?(o=i??[],e[0]=i,e[1]=o):o=e[1];let d;e[2]!==o?(d=Wo(o),e[2]=o,e[3]=d):d=e[3];const u=d;if(!u)return null;const f=u.code===Ja.githubNotAuthenticated,h=u.code===Ja.githubConnectionMissing;let x,m,g,k,y,v,p,b,j,w;if(e[4]!==h||e[5]!==u.message||e[6]!==s||e[7]!==f||e[8]!==n||e[9]!==c||e[10]!==l){m=V1({orgSlug:n,repo:s.repo,repositories:c??[],returnTo:Xi(n,s)}),x=Gd,w="destructive",g="mt-2 flex-col",b="flex items-start gap-3",e[21]===Symbol.for("react.memo_cache_sentinel")?(j=a.jsx(ns,{}),e[21]=j):j=e[21],k="flex flex-col gap-1";let A;e[22]!==l?(A=l("taskBoard.taskDialog.runFailedTitle"),e[22]=l,e[23]=A):A=e[23],e[24]!==A?(y=a.jsx(Vd,{children:A}),e[24]=A,e[25]=y):y=e[25];let L;e[26]!==h||e[27]!==u.message||e[28]!==f||e[29]!==l?(L=h?l("taskBoard.taskDialog.runFailedGithubMissing"):f?l("taskBoard.taskDialog.runFailedGithubAuth"):u.message,e[26]=h,e[27]=u.message,e[28]=f,e[29]=l,e[30]=L):L=e[30],e[31]!==L?(v=a.jsx(Wa,{children:L}),e[31]=L,e[32]=v):v=e[32],p=f&&m.ownerOnly&&m.owner&&a.jsx(Wa,{children:l("taskBoard.taskDialog.runFailedGithubOwnerOnly",{owner:m.owner})}),e[4]=h,e[5]=u.message,e[6]=s,e[7]=f,e[8]=n,e[9]=c,e[10]=l,e[11]=x,e[12]=m,e[13]=g,e[14]=k,e[15]=y,e[16]=v,e[17]=p,e[18]=b,e[19]=j,e[20]=w}else x=e[11],m=e[12],g=e[13],k=e[14],y=e[15],v=e[16],p=e[17],b=e[18],j=e[19],w=e[20];let S;e[33]!==k||e[34]!==y||e[35]!==v||e[36]!==p?(S=a.jsxs("div",{className:k,children:[y,v,p]}),e[33]=k,e[34]=y,e[35]=v,e[36]=p,e[37]=S):S=e[37];let C;e[38]!==S||e[39]!==b||e[40]!==j?(C=a.jsxs("div",{className:b,children:[j,S]}),e[38]=S,e[39]=b,e[40]=j,e[41]=C):C=e[41];let T;e[42]!==h||e[43]!==f||e[44]!==m||e[45]!==l?(T=(f||h)&&a.jsx(ke,{size:"sm",asChild:!0,children:a.jsx("a",{href:m.url,children:l(h?"taskBoard.taskDialog.runFailedLinkRepo":"taskBoard.taskDialog.runFailedReconnect")})}),e[42]=h,e[43]=f,e[44]=m,e[45]=l,e[46]=T):T=e[46];let N;e[47]!==r||e[48]!==l?(N=r&&a.jsxs(ke,{size:"sm",variant:"outline",onClick:r,children:[a.jsx(kl,{size:14}),l("taskBoard.taskBoard.rerun")]}),e[47]=r,e[48]=l,e[49]=N):N=e[49];let _;e[50]!==T||e[51]!==N?(_=a.jsxs("div",{className:"mt-3 flex flex-wrap items-center gap-2 self-start",children:[T,N]}),e[50]=T,e[51]=N,e[52]=_):_=e[52];let D;return e[53]!==x||e[54]!==g||e[55]!==C||e[56]!==_||e[57]!==w?(D=a.jsxs(x,{variant:w,className:g,children:[C,_]}),e[53]=x,e[54]=g,e[55]=C,e[56]=_,e[57]=w,e[58]=D):D=e[58],D}const hm=["taskBoard.subscriptionPaywall.trialBenefitMonitoring","taskBoard.subscriptionPaywall.trialBenefitAutoFix","taskBoard.subscriptionPaywall.trialBenefitRuns"],pm="https://decoims.com/image?src=decocms%2F7263a67f-fb83-410b-a5f2-e54e87deaaac%2Freport-kanban.png&quality=original&fit=cover";function mm(t){const e=$.c(83),{kind:s,onOpenChange:n}=t,r=J(),{mutate:l,isPending:i}=sf("ORGANIZATION_BILLING_CHECKOUT_START","taskBoard.subscriptionPaywall.checkoutError");if(s==="trial_exhausted"){let b;e[0]!==r?(b=r("taskBoard.subscriptionPaywall.previewAlt"),e[0]=r,e[1]=b):b=e[1];let j;e[2]!==b?(j=a.jsx("div",{className:"overflow-hidden rounded-xl bg-muted",children:a.jsx("img",{src:pm,alt:b,className:"h-[160px] w-full object-cover object-left-top"})}),e[2]=b,e[3]=j):j=e[3];let w;e[4]!==r?(w=r("taskBoard.subscriptionPaywall.trialTitle"),e[4]=r,e[5]=w):w=e[5];let S;e[6]!==w?(S=a.jsx(ol,{className:"text-xl font-semibold text-foreground",children:w}),e[6]=w,e[7]=S):S=e[7];let C;e[8]!==r?(C=hm.map(X=>a.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[a.jsx(kr,{size:18,className:"mt-0.5 shrink-0 text-success","aria-hidden":!0}),a.jsx("span",{className:"leading-snug text-foreground",children:r(X)})]},X)),e[8]=r,e[9]=C):C=e[9];let T;e[10]!==C?(T=a.jsx("ul",{className:"flex flex-col gap-3",children:C}),e[10]=C,e[11]=T):T=e[11];let N;e[12]!==r?(N=r("taskBoard.subscriptionPaywall.trialPrice"),e[12]=r,e[13]=N):N=e[13];let _;e[14]!==N?(_=a.jsx("span",{className:"text-2xl font-semibold text-foreground",children:N}),e[14]=N,e[15]=_):_=e[15];let D;e[16]!==r?(D=r("taskBoard.subscriptionPaywall.trialPricePeriod"),e[16]=r,e[17]=D):D=e[17];let A;e[18]!==D?(A=a.jsx("span",{className:"text-sm text-muted-foreground",children:D}),e[18]=D,e[19]=A):A=e[19];let L;e[20]!==A||e[21]!==_?(L=a.jsxs("div",{className:"flex items-baseline gap-1.5",children:[_,A]}),e[20]=A,e[21]=_,e[22]=L):L=e[22];let z;e[23]!==n?(z=()=>n(!1),e[23]=n,e[24]=z):z=e[24];let P;e[25]!==r?(P=r("taskBoard.subscriptionPaywall.notNowButton"),e[25]=r,e[26]=P):P=e[26];let E;e[27]!==i||e[28]!==z||e[29]!==P?(E=a.jsx(ke,{variant:"ghost",onClick:z,disabled:i,className:"order-2 w-full sm:order-none sm:w-auto",children:P}),e[27]=i,e[28]=z,e[29]=P,e[30]=E):E=e[30];let I;e[31]!==n||e[32]!==l?(I=()=>l(void 0,{onSuccess:()=>n(!1)}),e[31]=n,e[32]=l,e[33]=I):I=e[33];let V;e[34]!==i?(V=i&&a.jsx(yt,{className:"size-4"}),e[34]=i,e[35]=V):V=e[35];let Q;e[36]!==r?(Q=r("taskBoard.subscriptionPaywall.subscribeButton"),e[36]=r,e[37]=Q):Q=e[37];let Y;e[38]!==i||e[39]!==I||e[40]!==V||e[41]!==Q?(Y=a.jsxs(ke,{disabled:i,onClick:I,className:"order-1 w-full gap-2 sm:order-none sm:w-auto",children:[V,Q]}),e[38]=i,e[39]=I,e[40]=V,e[41]=Q,e[42]=Y):Y=e[42];let se;e[43]!==E||e[44]!==Y?(se=a.jsxs("div",{className:"flex w-full flex-col gap-2 sm:w-auto sm:flex-row sm:items-center",children:[E,Y]}),e[43]=E,e[44]=Y,e[45]=se):se=e[45];let H;e[46]!==L||e[47]!==se?(H=a.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",children:[L,se]}),e[46]=L,e[47]=se,e[48]=H):H=e[48];let ee;e[49]!==H||e[50]!==S||e[51]!==T?(ee=a.jsxs("div",{className:"flex flex-col gap-6 px-3 pb-3 pt-7",children:[S,T,H]}),e[49]=H,e[50]=S,e[51]=T,e[52]=ee):ee=e[52];let q;e[53]!==j||e[54]!==ee?(q=a.jsxs(cl,{className:"gap-0 p-3 sm:max-w-[440px]",closeButtonClassName:"z-10 classic:rounded-full bg-background/70 p-1 text-foreground backdrop-blur transition-colors hover:bg-background",children:[j,ee]}),e[53]=j,e[54]=ee,e[55]=q):q=e[55];let Z;return e[56]!==n||e[57]!==q?(Z=a.jsx(dl,{open:!0,onOpenChange:n,children:q}),e[56]=n,e[57]=q,e[58]=Z):Z=e[58],Z}let c;e[59]!==s||e[60]!==r?(c=s?{monthly_exhausted:{title:r("taskBoard.subscriptionPaywall.monthlyTitle"),description:r("taskBoard.subscriptionPaywall.monthlyDescription")},runs_exhausted:{title:r("taskBoard.subscriptionPaywall.runsTitle"),description:r("taskBoard.subscriptionPaywall.runsDescription")}}[s]:null,e[59]=s,e[60]=r,e[61]=c):c=e[61];const o=c,d=!!s,u=o?.title;let f;e[62]!==u?(f=a.jsx(ol,{children:u}),e[62]=u,e[63]=f):f=e[63];const h=o?.description;let x;e[64]!==h?(x=a.jsx(lo,{children:h}),e[64]=h,e[65]=x):x=e[65];let m;e[66]!==f||e[67]!==x?(m=a.jsxs(ao,{children:[f,x]}),e[66]=f,e[67]=x,e[68]=m):m=e[68];let g;e[69]!==n?(g=()=>n(!1),e[69]=n,e[70]=g):g=e[70];let k;e[71]!==r?(k=r("taskBoard.subscriptionPaywall.dismissButton"),e[71]=r,e[72]=k):k=e[72];let y;e[73]!==g||e[74]!==k?(y=a.jsx(io,{children:a.jsx(ke,{variant:"ghost",onClick:g,children:k})}),e[73]=g,e[74]=k,e[75]=y):y=e[75];let v;e[76]!==y||e[77]!==m?(v=a.jsxs(cl,{className:"sm:max-w-[440px]",children:[m,y]}),e[76]=y,e[77]=m,e[78]=v):v=e[78];let p;return e[79]!==n||e[80]!==v||e[81]!==d?(p=a.jsx(dl,{open:d,onOpenChange:n,children:v}),e[79]=n,e[80]=v,e[81]=d,e[82]=p):p=e[82],p}const gm=new Set(["completed","failed","expired"]);function xm(t){return t.threads.some(e=>e.status!==null&&!gm.has(e.status))}function km(t){const e=$.c(43),{items:s,pending:n,onOpenChange:r,onConfirm:l}=t,i=J(),c=s.length;let o;e[0]!==s?(o=s.some(xm),e[0]=s,e[1]=o):o=e[1];const d=o,u=c>0;let f;e[2]!==c||e[3]!==i?(f=c>1?i("taskBoard.rerun.titleMany",{count:c}):i("taskBoard.rerun.title"),e[2]=c,e[3]=i,e[4]=f):f=e[4];let h;e[5]!==f?(h=a.jsx(ol,{children:f}),e[5]=f,e[6]=h):h=e[6];let x;e[7]!==c||e[8]!==i||e[9]!==d?(x=c>1?i("taskBoard.rerun.descriptionMany",{count:c}):i(d?"taskBoard.rerun.descriptionTakeover":"taskBoard.rerun.description"),e[7]=c,e[8]=i,e[9]=d,e[10]=x):x=e[10];let m;e[11]!==x?(m=a.jsx(lo,{children:x}),e[11]=x,e[12]=m):m=e[12];let g;e[13]!==h||e[14]!==m?(g=a.jsxs(ao,{children:[h,m]}),e[13]=h,e[14]=m,e[15]=g):g=e[15];let k;e[16]!==r?(k=()=>r(!1),e[16]=r,e[17]=k):k=e[17];let y;e[18]!==i?(y=i("taskBoard.rerun.cancel"),e[18]=i,e[19]=y):y=e[19];let v;e[20]!==n||e[21]!==k||e[22]!==y?(v=a.jsx(ke,{variant:"outline",onClick:k,disabled:n,children:y}),e[20]=n,e[21]=k,e[22]=y,e[23]=v):v=e[23];let p;e[24]!==n?(p=n&&a.jsx(yt,{className:"size-4"}),e[24]=n,e[25]=p):p=e[25];let b;e[26]!==i?(b=i("taskBoard.rerun.confirm"),e[26]=i,e[27]=b):b=e[27];let j;e[28]!==l||e[29]!==n||e[30]!==p||e[31]!==b?(j=a.jsxs(ke,{onClick:l,disabled:n,children:[p,b]}),e[28]=l,e[29]=n,e[30]=p,e[31]=b,e[32]=j):j=e[32];let w;e[33]!==v||e[34]!==j?(w=a.jsxs(io,{children:[v,j]}),e[33]=v,e[34]=j,e[35]=w):w=e[35];let S;e[36]!==w||e[37]!==g?(S=a.jsxs(cl,{className:"max-w-md",children:[g,w]}),e[36]=w,e[37]=g,e[38]=S):S=e[38];let C;return e[39]!==r||e[40]!==S||e[41]!==u?(C=a.jsx(dl,{open:u,onOpenChange:r,children:S}),e[39]=r,e[40]=S,e[41]=u,e[42]=C):C=e[42],C}const Bi=380,bm=90,_i=5,ym="cubic-bezier(0.22, 0.61, 0.36, 1)";function jm(t,e,s,n=!0){const r=W.useRef(new Map),l=W.useRef(new Map),i=W.useRef(!1);W.useLayoutEffect(()=>{const c=t.current;if(!c)return;if(!n){i.current=!0;return}const o=i.current;i.current=!1;const d=c.querySelectorAll("[data-flip-id]"),u=new Map,f=r.current;r.current=u;const h=typeof window<"u"&&window.matchMedia?.("(prefers-reduced-motion: reduce)").matches,x=[];for(const b of d){const j=b.dataset.flipId;if(!j)continue;const w=b.getBoundingClientRect(),S=b.dataset.flipLane;if(u.set(j,{rect:w,lane:S}),!s||o)continue;const C=f.get(j);if(!C)continue;const T=C.rect.left-w.left,N=C.rect.top-w.top;(T||N)&&x.push({el:b,dx:T,dy:N,lane:C.lane!==S})}if(!s||h||x.length===0)return;const m=l.current,g=b=>{b instanceof HTMLElement&&(m.set(b,(m.get(b)??0)+1),b.style.overflow="visible")},k=b=>{if(!(b instanceof HTMLElement))return;const j=(m.get(b)??1)-1;if(j>0){m.set(b,j);return}m.delete(b),b.style.overflow=""};for(const b of x){const j=b.lane?` rotate(${b.dx>0?_i:-_i}deg)`:"";b.el.style.transition="none",b.el.style.transform=`translate(${b.dx}px, ${b.dy}px)${j}`,b.lane&&(b.el.style.zIndex="10",g(b.el.closest("[data-lane-scroll]")))}let y=0;const v=[],p=requestAnimationFrame(()=>{for(const b of x){const j=b.lane?y++*bm:0;b.el.style.transition=`transform ${Bi}ms ${ym} ${j}ms`,b.el.style.transform="",v.push(window.setTimeout(()=>{b.el.style.transition="",b.el.style.transform="",b.el.style.zIndex="",b.lane&&k(b.el.closest("[data-lane-scroll]"))},Bi+j+30))}});return()=>{cancelAnimationFrame(p);for(const b of v)clearTimeout(b);for(const b of x)b.el.style.transition="",b.el.style.transform="",b.el.style.zIndex="",b.lane&&k(b.el.closest("[data-lane-scroll]"))}},[e,t,s,n])}function vm(t,e=[]){const s=[[`# Task: ${t.title}`,t.description?.trim()].filter(Boolean).join(`
|
|
85
|
+
|
|
86
|
+
`)];if(e.length>0){const n=e.map(r=>{const l=r.merged?"merged":r.state??(r.draft?"draft":"open"),i=r.title?.trim()||`${r.repoOwner}/${r.repoName}`;return`- #${r.number} ${i} [${l}] ${r.url}`});s.push(["## Linked pull requests",...n].join(`
|
|
87
|
+
`))}if(t.threads.length>0){const n=t.threads.map(r=>{const l=r.title?.trim()||"Untitled chat";return r.status?`- ${l} [${r.status}]`:`- ${l}`});s.push(["## Other chats on this task",...n].join(`
|
|
88
|
+
`))}return s.join(`
|
|
89
|
+
|
|
90
|
+
`)}const wm=["assignee","priority","due","tags","project"];function rc(t,e){return wm.filter(s=>{switch(s){case"assignee":return t.assignee!==null;case"priority":return t.priority!==null;case"due":return t.due!==null;case"tags":return t.tags.length>0;case"project":return Rr(t.project,e);default:return s}})}function Sm(t,e){switch(e){case"assignee":return{...t,assignee:null};case"priority":return{...t,priority:null};case"due":return{...t,due:null};case"tags":return{...t,tags:[]};case"project":return{...t,project:null};default:return e}}function lc(t){const e=$.c(4),{priority:s}=t,n=Le[s];let r;e[0]!==n.dotClassName?(r=F("size-2 shrink-0 rounded-full",n.dotClassName),e[0]=n.dotClassName,e[1]=r):r=e[1];let l;return e[2]!==r?(l=a.jsx("span",{className:r}),e[2]=r,e[3]=l):l=e[3],l}function ac(t){const e=$.c(4),{color:s}=t;let n;e[0]!==s?(n=qt(s),e[0]=s,e[1]=n):n=e[1];let r;return e[2]!==n?(r=a.jsx("span",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:n}}),e[2]=n,e[3]=r):r=e[3],r}function ic(t){const e=$.c(91),{members:s,tags:n,index:r}=t,l=J();let i;e[0]!==s||e[1]!==l?(i=R=>s.find(O=>O.userId===R)?.user?.name??l("taskBoard.taskFilters.assigneeMember"),e[0]=s,e[1]=l,e[2]=i):i=e[2];const c=i;let o;e[3]!==l?(o=l("taskBoard.taskFilters.assigneeLabel"),e[3]=l,e[4]=o):o=e[4];let d;e[5]===Symbol.for("react.memo_cache_sentinel")?(d=a.jsx(ss,{size:14,className:"shrink-0"}),e[5]=d):d=e[5];let u;e[6]!==l?(u=l("taskBoard.taskFilters.assigneeUnassigned"),e[6]=l,e[7]=u):u=e[7];let f;e[8]===Symbol.for("react.memo_cache_sentinel")?(f=a.jsx(ss,{size:14,className:"shrink-0 text-muted-foreground"}),e[8]=f):f=e[8];let h;e[9]!==u?(h={id:mr,label:u,glyph:f,apply:Im,isSelected:Em},e[9]=u,e[10]=h):h=e[10];let x;e[11]!==l?(x=l("taskBoard.taskFilters.assigneeSuperAgent"),e[11]=l,e[12]=x):x=e[12];let m;e[13]===Symbol.for("react.memo_cache_sentinel")?(m=a.jsx(Ve,{size:14}),e[13]=m):m=e[13];let g;e[14]!==x?(g={id:ye,label:x,glyph:m,apply:zm,isSelected:Rm},e[14]=x,e[15]=g):g=e[15];let k;e[16]!==s||e[17]!==h||e[18]!==g?(k=[h,g,...s.map(Dm)],e[16]=s,e[17]=h,e[18]=g,e[19]=k):k=e[19];let y;e[20]!==c||e[21]!==l?(y=R=>R.assignee===mr?l("taskBoard.taskFilters.assigneeUnassigned"):R.assignee===ye?l("taskBoard.taskFilters.assigneeSuperAgent"):R.assignee?c(R.assignee):"",e[20]=c,e[21]=l,e[22]=y):y=e[22];let v;e[23]!==k||e[24]!==y||e[25]!==o?(v={id:"assignee",label:o,icon:d,options:k,valueLabel:y,valueGlyph:$m},e[23]=k,e[24]=y,e[25]=o,e[26]=v):v=e[26];const p=v;let b;e[27]!==l?(b=l("taskBoard.taskFilters.priorityLabel"),e[27]=l,e[28]=b):b=e[28];let j;e[29]===Symbol.for("react.memo_cache_sentinel")?(j=a.jsx(Gi,{size:14,className:"shrink-0"}),e[29]=j):j=e[29];let w;e[30]!==l?(w=br.map(R=>({id:R,label:l(Le[R].labelKey),glyph:a.jsx(lc,{priority:R}),apply:O=>({...O,priority:R}),isSelected:O=>O.priority===R})),e[30]=l,e[31]=w):w=e[31];let S;e[32]!==l?(S=R=>R.priority?l(Le[R.priority].labelKey):"",e[32]=l,e[33]=S):S=e[33];let C;e[34]!==b||e[35]!==w||e[36]!==S?(C={id:"priority",label:b,icon:j,options:w,valueLabel:S,valueGlyph:Am},e[34]=b,e[35]=w,e[36]=S,e[37]=C):C=e[37];const T=C;let N;e[38]!==l?(N=l("taskBoard.taskFilters.dueDateLabel"),e[38]=l,e[39]=N):N=e[39];let _;e[40]===Symbol.for("react.memo_cache_sentinel")?(_=a.jsx(xt,{size:14,className:"shrink-0"}),e[40]=_):_=e[40];let D;e[41]!==l?(D=Qi.map(R=>({id:R,label:l(il(R)),glyph:a.jsx(xt,{size:14,className:F("shrink-0",R==="overdue"?"text-destructive":"text-muted-foreground")}),apply:O=>({...O,due:R}),isSelected:O=>O.due===R})),e[41]=l,e[42]=D):D=e[42];let A;e[43]!==l?(A=R=>R.due?l(il(R.due)):"",e[43]=l,e[44]=A):A=e[44];let L;e[45]!==N||e[46]!==D||e[47]!==A?(L={id:"due",label:N,icon:_,options:D,valueLabel:A,valueGlyph:_m},e[45]=N,e[46]=D,e[47]=A,e[48]=L):L=e[48];const z=L;let P;e[49]!==l?(P=l("taskBoard.taskFilters.tagsLabel"),e[49]=l,e[50]=P):P=e[50];let E;e[51]===Symbol.for("react.memo_cache_sentinel")?(E=a.jsx(ll,{size:14,className:"shrink-0"}),e[51]=E):E=e[51];let I;e[52]!==n?(I=n.map(Bm),e[52]=n,e[53]=I):I=e[53];let V;e[54]!==l||e[55]!==n?(V=R=>R.tags.length===1?n.find(O=>O.id===R.tags[0])?.name??l("taskBoard.taskFilters.tagsLabel"):l("taskBoard.taskFilters.tagsSelectedCount",{count:R.tags.length}),e[54]=l,e[55]=n,e[56]=V):V=e[56];let Q;e[57]!==n?(Q=R=>R.tags.length===1?a.jsx(ac,{color:n.find(O=>O.id===R.tags[0])?.color}):a.jsx(ll,{size:14,className:"shrink-0"}),e[57]=n,e[58]=Q):Q=e[58];let Y;e[59]!==P||e[60]!==I||e[61]!==V||e[62]!==Q?(Y={id:"tags",label:P,icon:E,multi:!0,options:I,valueLabel:V,valueGlyph:Q},e[59]=P,e[60]=I,e[61]=V,e[62]=Q,e[63]=Y):Y=e[63];const se=Y;let H;e[64]!==l?(H=l("taskBoard.taskFilters.projectLabel"),e[64]=l,e[65]=H):H=e[65];let ee;e[66]===Symbol.for("react.memo_cache_sentinel")?(ee=a.jsx(es,{entry:void 0}),e[66]=ee):ee=e[66];let q;e[67]!==l?(q=l("taskBoard.taskFilters.projectNone"),e[67]=l,e[68]=q):q=e[68];let Z;e[69]===Symbol.for("react.memo_cache_sentinel")?(Z=a.jsx(es,{entry:void 0}),e[69]=Z):Z=e[69];let X;e[70]!==q?(X={id:gr,label:q,glyph:Z,apply:Tm,isSelected:Nm},e[70]=q,e[71]=X):X=e[71];let re;e[72]!==r.entries||e[73]!==X?(re=[X,...r.entries.map(Cm)],e[72]=r.entries,e[73]=X,e[74]=re):re=e[74];let G;e[75]!==r||e[76]!==l?(G=R=>R.project===gr?l("taskBoard.taskFilters.projectNone"):R.project?Nr(R.project,r)?.title??R.project:"",e[75]=r,e[76]=l,e[77]=G):G=e[77];let ne;e[78]!==r?(ne=R=>a.jsx(es,{entry:R.project?Nr(R.project,r):void 0}),e[78]=r,e[79]=ne):ne=e[79];let ce;e[80]!==H||e[81]!==re||e[82]!==G||e[83]!==ne?(ce={id:"project",label:H,icon:ee,options:re,valueLabel:G,valueGlyph:ne},e[80]=H,e[81]=re,e[82]=G,e[83]=ne,e[84]=ce):ce=e[84];const ue=ce;let oe;return e[85]!==p||e[86]!==z||e[87]!==T||e[88]!==ue||e[89]!==se?(oe=[p,T,z,se,ue],e[85]=p,e[86]=z,e[87]=T,e[88]=ue,e[89]=se,e[90]=oe):oe=e[90],oe}function Cm(t){return{id:t.id,label:t.title,glyph:a.jsx(es,{entry:t}),apply:e=>({...e,project:t.id}),isSelected:e=>e.project===t.id}}function Nm(t){return t.project===gr}function Tm(t){return{...t,project:gr}}function Bm(t){return{id:t.id,label:t.name,glyph:a.jsx(ac,{color:t.color}),apply:e=>({...e,tags:e.tags.includes(t.id)?e.tags.filter(s=>s!==t.id):[...e.tags,t.id]}),isSelected:e=>e.tags.includes(t.id)}}function _m(){return a.jsx(xt,{size:14,className:"shrink-0"})}function Am(t){return t.priority?a.jsx(lc,{priority:t.priority}):null}function $m(t){return t.assignee===ye?a.jsx(Ve,{size:14}):a.jsx(ss,{size:14,className:"shrink-0"})}function Dm(t){return{id:t.userId,label:t.user?.name??t.userId,glyph:a.jsx(Fe,{url:t.user?.image??void 0,fallback:Oe(t.user?.name),shape:"circle",size:"2xs"}),apply:e=>({...e,assignee:t.userId}),isSelected:e=>e.assignee===t.userId}}function Rm(t){return t.assignee===ye}function zm(t){return{...t,assignee:ye}}function Em(t){return t.assignee===mr}function Im(t){return{...t,assignee:mr}}function Ma(t){const e=$.c(5),{count:s}=t,n=J();let r;e[0]!==s||e[1]!==n?(r=n("taskBoard.viewControls.matchCount",{count:s}),e[0]=s,e[1]=n,e[2]=r):r=e[2];let l;return e[3]!==r?(l=a.jsx("span",{className:"ml-auto shrink-0 text-xs text-muted-foreground",children:r}),e[3]=r,e[4]=l):l=e[4],l}function Ar(t){const e=$.c(2),{children:s}=t;let n;return e[0]!==s?(n=a.jsx("span",{className:"flex size-4 shrink-0 items-center justify-center",children:s}),e[0]=s,e[1]=n):n=e[1],n}function Lm(t){const e=$.c(22),{field:s,open:n,countFor:r,onSelect:l}=t;let i;e[0]!==s.icon?(i=a.jsx(Ar,{children:s.icon}),e[0]=s.icon,e[1]=i):i=e[1];let c;e[2]!==s.label?(c=a.jsx("span",{className:"truncate",children:s.label}),e[2]=s.label,e[3]=c):c=e[3];let o;e[4]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(Dr,{size:12,className:"ml-auto shrink-0 text-muted-foreground/60"}),e[4]=o):o=e[4];let d;e[5]!==s.label||e[6]!==i||e[7]!==c?(d=a.jsx(Yc,{asChild:!0,children:a.jsxs(He,{value:s.label,children:[i,c,o]})}),e[5]=s.label,e[6]=i,e[7]=c,e[8]=d):d=e[8];let u;if(e[9]!==r||e[10]!==s.options||e[11]!==l){let x;e[13]!==r||e[14]!==l?(x=m=>a.jsx(Fm,{option:m,count:r(m),onSelect:()=>l(m)},m.id),e[13]=r,e[14]=l,e[15]=x):x=e[15],u=s.options.map(x),e[9]=r,e[10]=s.options,e[11]=l,e[12]=u}else u=e[12];let f;e[16]!==u?(f=a.jsx(kt,{side:"right",align:"start",alignOffset:-5,className:"max-h-72 w-64 overflow-y-auto p-1",onOpenAutoFocus:Pm,onCloseAutoFocus:Mm,children:u}),e[16]=u,e[17]=f):f=e[17];let h;return e[18]!==n||e[19]!==d||e[20]!==f?(h=a.jsxs(bt,{open:n,children:[d,f]}),e[18]=n,e[19]=d,e[20]=f,e[21]=h):h=e[21],h}function Mm(t){return t.preventDefault()}function Pm(t){return t.preventDefault()}function Fm(t){const e=$.c(12),{option:s,count:n,onSelect:r}=t;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=F(Wi({highlight:"hover"})),e[0]=l):l=e[0];let i;e[1]!==s.glyph?(i=a.jsx(Ar,{children:s.glyph}),e[1]=s.glyph,e[2]=i):i=e[2];let c;e[3]!==s.label?(c=a.jsx("span",{className:"truncate",children:s.label}),e[3]=s.label,e[4]=c):c=e[4];let o;e[5]!==n?(o=a.jsx(Ma,{count:n}),e[5]=n,e[6]=o):o=e[6];let d;return e[7]!==r||e[8]!==i||e[9]!==c||e[10]!==o?(d=a.jsxs("button",{type:"button",className:l,onClick:r,children:[i,c,o]}),e[7]=r,e[8]=i,e[9]=c,e[10]=o,e[11]=d):d=e[11],d}function Om(t){const e=$.c(19),{field:s,option:n,count:r,onSelect:l}=t,i=`${s.label} ${n.label}`;let c;e[0]!==s.icon?(c=a.jsx(Ar,{children:s.icon}),e[0]=s.icon,e[1]=c):c=e[1];let o;e[2]!==s.label?(o=a.jsx("span",{className:"shrink-0 text-muted-foreground",children:s.label}),e[2]=s.label,e[3]=o):o=e[3];let d;e[4]===Symbol.for("react.memo_cache_sentinel")?(d=a.jsx(Dr,{size:12,className:"shrink-0 text-muted-foreground/60"}),e[4]=d):d=e[4];let u;e[5]!==n.glyph?(u=a.jsx(Ar,{children:n.glyph}),e[5]=n.glyph,e[6]=u):u=e[6];let f;e[7]!==n.label?(f=a.jsx("span",{className:"truncate",children:n.label}),e[7]=n.label,e[8]=f):f=e[8];let h;e[9]!==r?(h=a.jsx(Ma,{count:r}),e[9]=r,e[10]=h):h=e[10];let x;return e[11]!==l||e[12]!==i||e[13]!==c||e[14]!==o||e[15]!==u||e[16]!==f||e[17]!==h?(x=a.jsxs(He,{value:i,onSelect:l,children:[c,o,d,u,f,h]}),e[11]=l,e[12]=i,e[13]=c,e[14]=o,e[15]=u,e[16]=f,e[17]=h,e[18]=x):x=e[18],x}const Hm=new Set(["ArrowDown","ArrowUp","ArrowRight"]);function qm(t){const e=$.c(50),{filters:s,items:n,index:r,fields:l,onChange:i,onClose:c}=t,o=J(),[d,u]=W.useState(""),[f,h]=W.useState(""),[x,m]=W.useState(!1);let g;e[0]!==s||e[1]!==i||e[2]!==c?(g=(L,z)=>{i(z.apply(s)),L.multi||c()},e[0]=s,e[1]=i,e[2]=c,e[3]=g):g=e[3];const k=g;let y;e[4]!==s||e[5]!==r||e[6]!==n?(y=L=>n.filter(z=>ha(z,L.apply(s),r)).length,e[4]=s,e[5]=r,e[6]=n,e[7]=y):y=e[7];const v=y;let p,b,j,w,S,C,T,N,_;if(e[8]!==f||e[9]!==x||e[10]!==v||e[11]!==l||e[12]!==d||e[13]!==k||e[14]!==o){const L=l.filter(Um);b=os,C=f,T=h,e[24]===Symbol.for("react.memo_cache_sentinel")?(N=I=>{Hm.has(I.key)&&m(!0)},e[24]=N):N=e[24];let z;e[25]!==o?(z=o("taskBoard.viewControls.addFilter"),e[25]=o,e[26]=z):z=e[26];let P;e[27]!==o?(P=o("taskBoard.viewControls.addFilter"),e[27]=o,e[28]=P):P=e[28],e[29]!==d||e[30]!==z||e[31]!==P?(_=a.jsx(ls,{size:"sm",value:d,onValueChange:u,placeholder:z,"aria-label":P,className:"h-9"}),e[29]=d,e[30]=z,e[31]=P,e[32]=_):_=e[32],p=is,e[33]===Symbol.for("react.memo_cache_sentinel")?(j=()=>m(!0),e[33]=j):j=e[33];let E;e[34]!==o?(E=o("taskBoard.viewControls.noMatches"),e[34]=o,e[35]=E):E=e[35],e[36]!==E?(w=a.jsx(as,{children:E}),e[36]=E,e[37]=w):w=e[37],S=d.trim()===""?a.jsx(et,{children:L.map(I=>a.jsx(Lm,{field:I,open:x&&f===I.label,countFor:v,onSelect:V=>k(I,V)},I.id))}):a.jsx(et,{children:L.flatMap(I=>I.options.map(V=>a.jsx(Om,{field:I,option:V,count:v(V),onSelect:()=>k(I,V)},`${I.id}:${V.id}`)))}),e[8]=f,e[9]=x,e[10]=v,e[11]=l,e[12]=d,e[13]=k,e[14]=o,e[15]=p,e[16]=b,e[17]=j,e[18]=w,e[19]=S,e[20]=C,e[21]=T,e[22]=N,e[23]=_}else p=e[15],b=e[16],j=e[17],w=e[18],S=e[19],C=e[20],T=e[21],N=e[22],_=e[23];let D;e[38]!==p||e[39]!==j||e[40]!==w||e[41]!==S?(D=a.jsxs(p,{onPointerMove:j,children:[w,S]}),e[38]=p,e[39]=j,e[40]=w,e[41]=S,e[42]=D):D=e[42];let A;return e[43]!==b||e[44]!==D||e[45]!==C||e[46]!==T||e[47]!==N||e[48]!==_?(A=a.jsxs(b,{value:C,onValueChange:T,onKeyDown:N,children:[_,D]}),e[43]=b,e[44]=D,e[45]=C,e[46]=T,e[47]=N,e[48]=_,e[49]=A):A=e[49],A}function Um(t){return t.options.length>0}function oc(t){const e=$.c(14);let s,n;e[0]!==t?({trigger:n,...s}=t,e[0]=t,e[1]=s,e[2]=n):(s=e[1],n=e[2]);const[r,l]=W.useState(!1);let i;e[3]!==n?(i=a.jsx(gt,{asChild:!0,children:n}),e[3]=n,e[4]=i):i=e[4];let c;e[5]!==s||e[6]!==r?(c=r&&a.jsx(qm,{...s,onClose:()=>l(!1)}),e[5]=s,e[6]=r,e[7]=c):c=e[7];let o;e[8]!==c?(o=a.jsx(kt,{align:"end",className:"w-72 p-0",children:c}),e[8]=c,e[9]=o):o=e[9];let d;return e[10]!==r||e[11]!==i||e[12]!==o?(d=a.jsxs(bt,{open:r,onOpenChange:l,children:[i,o]}),e[10]=r,e[11]=i,e[12]=o,e[13]=d):d=e[13],d}function Km(t){const e=$.c(20),{filters:s,items:n,members:r,tags:l,index:i,onChange:c}=t,o=J();let d;e[0]!==i||e[1]!==r||e[2]!==l?(d={members:r,tags:l,index:i},e[0]=i,e[1]=r,e[2]=l,e[3]=d):d=e[3];const u=ic(d);let f;e[4]!==s||e[5]!==i?(f=rc(s,i),e[4]=s,e[5]=i,e[6]=f):f=e[6];const h=f.length>0;let x;e[7]!==o?(x=o("taskBoard.viewControls.filterLabel"),e[7]=o,e[8]=x):x=e[8];let m;e[9]===Symbol.for("react.memo_cache_sentinel")?(m=a.jsx(fa,{}),e[9]=m):m=e[9];let g;e[10]!==h||e[11]!==x?(g=a.jsx(Jt,{label:x,tooltipSide:"bottom",variant:"secondary","aria-pressed":h,children:m}),e[10]=h,e[11]=x,e[12]=g):g=e[12];let k;return e[13]!==u||e[14]!==s||e[15]!==i||e[16]!==n||e[17]!==c||e[18]!==g?(k=a.jsx(oc,{filters:s,items:n,index:i,fields:u,onChange:c,trigger:g}),e[13]=u,e[14]=s,e[15]=i,e[16]=n,e[17]=c,e[18]=g,e[19]=k):k=e[19],k}function Wm(t){const e=$.c(29),{field:s,filters:n,items:r,index:l,onChange:i,onClose:c}=t;let o;if(e[0]!==s.label||e[1]!==s.multi||e[2]!==s.options||e[3]!==n||e[4]!==l||e[5]!==r||e[6]!==i||e[7]!==c){let d;e[9]!==n?(d=b=>b.isSelected(n),e[9]=n,e[10]=d):d=e[10];const u=s.options.filter(d);let f;e[11]!==n?(f=b=>!b.isSelected(n),e[11]=n,e[12]=f):f=e[12];const h=s.options.filter(f);let x;e[13]!==s.multi||e[14]!==n||e[15]!==i||e[16]!==c?(x=b=>{i(b.apply(n)),s.multi||c()},e[13]=s.multi,e[14]=n,e[15]=i,e[16]=c,e[17]=x):x=e[17];const m=x;let g;e[18]!==n||e[19]!==l||e[20]!==r||e[21]!==m?(g=(b,j)=>a.jsxs("button",{type:"button",className:F(Wi({highlight:"hover"})),onClick:()=>m(b),children:[a.jsx(Ar,{children:b.glyph}),a.jsx("span",{className:"truncate",children:b.label}),j?a.jsx(Ma,{count:r.filter(w=>ha(w,b.apply(n),l)).length}):a.jsx(Ct,{size:14,className:"ml-auto shrink-0"})]},b.id),e[18]=n,e[19]=l,e[20]=r,e[21]=m,e[22]=g):g=e[22];const k=g;let y;e[23]!==s.label?(y=a.jsx("p",{className:"px-2 py-1.5 text-xs font-medium text-muted-foreground",children:s.label}),e[23]=s.label,e[24]=y):y=e[24];let v;e[25]!==k?(v=b=>k(b,!1),e[25]=k,e[26]=v):v=e[26];let p;e[27]!==k?(p=b=>k(b,!0),e[27]=k,e[28]=p):p=e[28],o=a.jsxs("div",{className:"flex max-h-72 flex-col overflow-y-auto p-1",children:[y,u.map(v),u.length>0&&h.length>0&&a.jsx(ta,{className:"my-1"}),h.map(p)]}),e[0]=s.label,e[1]=s.multi,e[2]=s.options,e[3]=n,e[4]=l,e[5]=r,e[6]=i,e[7]=c,e[8]=o}else o=e[8];return o}function Gm(t){const e=$.c(22),{field:s,filters:n,items:r,index:l,onChange:i}=t,[c,o]=W.useState(!1);let d;e[0]!==s||e[1]!==n?(d=s.valueGlyph(n),e[0]=s,e[1]=n,e[2]=d):d=e[2];let u;e[3]!==s||e[4]!==n?(u=s.valueLabel(n),e[3]=s,e[4]=n,e[5]=u):u=e[5];let f;e[6]!==d||e[7]!==u?(f=a.jsx(gt,{asChild:!0,children:a.jsxs("button",{type:"button",className:"flex h-full max-w-[12rem] items-center gap-1.5 truncate px-2.5 text-foreground hover:bg-accent",children:[d,u]})}),e[6]=d,e[7]=u,e[8]=f):f=e[8];let h;e[9]!==s||e[10]!==n||e[11]!==l||e[12]!==r||e[13]!==i||e[14]!==c?(h=c&&a.jsx(Wm,{field:s,filters:n,items:r,index:l,onChange:i,onClose:()=>o(!1)}),e[9]=s,e[10]=n,e[11]=l,e[12]=r,e[13]=i,e[14]=c,e[15]=h):h=e[15];let x;e[16]!==h?(x=a.jsx(kt,{align:"start",className:"w-64 p-0",children:h}),e[16]=h,e[17]=x):x=e[17];let m;return e[18]!==c||e[19]!==f||e[20]!==x?(m=a.jsxs(bt,{open:c,onOpenChange:o,children:[f,x]}),e[18]=c,e[19]=f,e[20]=x,e[21]=m):m=e[21],m}function Vm(t){const e=$.c(38),{filters:s,items:n,members:r,tags:l,index:i,onChange:c}=t,o=J();let d;e[0]!==i||e[1]!==r||e[2]!==l?(d={members:r,tags:l,index:i},e[0]=i,e[1]=r,e[2]=l,e[3]=d):d=e[3];const u=ic(d);let f,h,x;if(e[4]!==u||e[5]!==s||e[6]!==i||e[7]!==n||e[8]!==c||e[9]!==o){x=Symbol.for("react.early_return_sentinel");e:{const w=rc(s,i);if(w.length===0){x=null;break e}f="mx-3 flex h-11 shrink-0 items-center gap-2 overflow-x-auto rounded-xl border border-border px-2 no-scrollbar",h=w.map(S=>{const C=u.find(T=>T.id===S);return C?a.jsxs(lf,{variant:"outline",size:"segmented",children:[a.jsxs("span",{className:"flex h-full items-center gap-1.5 px-2.5 text-foreground",children:[C.icon,C.label]}),a.jsx(ta,{orientation:"vertical"}),a.jsx("span",{className:"px-2 text-muted-foreground",children:C.multi?o("taskBoard.viewControls.isAnyOf"):o("taskBoard.viewControls.is")}),a.jsx(ta,{orientation:"vertical"}),a.jsx(Gm,{field:C,filters:s,items:n,index:i,onChange:c}),a.jsx(Jt,{label:o("taskBoard.viewControls.removeFilter",{field:C.label}),size:"icon-sm",onClick:()=>c(Sm(s,S)),children:a.jsx(Ht,{})})]},S):null})}e[4]=u,e[5]=s,e[6]=i,e[7]=n,e[8]=c,e[9]=o,e[10]=f,e[11]=h,e[12]=x}else f=e[10],h=e[11],x=e[12];if(x!==Symbol.for("react.early_return_sentinel"))return x;let m;e[13]!==o?(m=o("taskBoard.viewControls.addAnotherFilter"),e[13]=o,e[14]=m):m=e[14];let g;e[15]===Symbol.for("react.memo_cache_sentinel")?(g=a.jsx(ts,{}),e[15]=g):g=e[15];let k;e[16]!==m?(k=a.jsx(Jt,{label:m,children:g}),e[16]=m,e[17]=k):k=e[17];let y;e[18]!==u||e[19]!==s||e[20]!==i||e[21]!==n||e[22]!==c||e[23]!==k?(y=a.jsx(oc,{filters:s,items:n,index:i,fields:u,onChange:c,trigger:k}),e[18]=u,e[19]=s,e[20]=i,e[21]=n,e[22]=c,e[23]=k,e[24]=y):y=e[24];let v;e[25]!==s.search||e[26]!==c?(v=()=>c({...yl,search:s.search}),e[25]=s.search,e[26]=c,e[27]=v):v=e[27];let p;e[28]!==o?(p=o("taskBoard.viewControls.clear"),e[28]=o,e[29]=p):p=e[29];let b;e[30]!==p||e[31]!==v?(b=a.jsx("div",{className:"ml-auto",children:a.jsx(ke,{variant:"ghost",size:"sm",onClick:v,children:p})}),e[30]=p,e[31]=v,e[32]=b):b=e[32];let j;return e[33]!==b||e[34]!==f||e[35]!==h||e[36]!==y?(j=a.jsxs("div",{className:f,children:[h,y,b]}),e[33]=b,e[34]=f,e[35]=h,e[36]=y,e[37]=j):j=e[37],j}function Qm(t){const e=$.c(6),{onClick:s}=t,n=J();let r;e[0]!==n?(r=n("taskBoard.taskFilters.boardSettingsLabel"),e[0]=n,e[1]=r):r=e[1];const l=r;let i;e[2]===Symbol.for("react.memo_cache_sentinel")?(i=a.jsx(Vi,{}),e[2]=i):i=e[2];let c;return e[3]!==l||e[4]!==s?(c=a.jsx(Jt,{label:l,tooltipSide:"bottom",variant:"secondary",onClick:s,children:i}),e[3]=l,e[4]=s,e[5]=c):c=e[5],c}const Ym=["overdue","today","week","none"],ur=t=>typeof t=="string"&&t!==""?t:null;function Zm(t){const e=ur(t.priority),s=ur(t.due),n=ur(t.tags);return{layout:t.view==="list"?"list":"board",filters:{search:ur(t.q)??"",assignee:ur(t.assignee),priority:br.includes(e)?e:null,due:Ym.includes(s)?s:null,tags:n?n.split(",").filter(Boolean):[],project:ur(t.repo)}}}function Xm(t,e){return{view:e==="list"?"list":void 0,q:t.search===""?void 0:t.search,assignee:t.assignee??void 0,priority:t.priority??void 0,due:t.due??void 0,tags:t.tags.length>0?t.tags.join(","):void 0,repo:t.project??void 0}}function Jm(t,e){const s=new Set(e.map(n=>n.id));return new Set([...t].filter(n=>s.has(n)))}function eg(){const t=$.c(16);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={strict:!1},t[0]=e):e=t[0];const s=zi(e),n=oa();let r;t[1]!==s?(r=Zm(s),t[1]=s,t[2]=r):r=t[2];const{filters:l,layout:i}=r;let c;t[3]!==n?(c=(h,x)=>n({to:".",search:m=>({...m,...Xm(h,x)}),replace:!0}),t[3]=n,t[4]=c):c=t[4];const o=c;let d;t[5]!==i||t[6]!==o?(d=h=>o(h,i),t[5]=i,t[6]=o,t[7]=d):d=t[7];let u;t[8]!==l||t[9]!==o?(u=h=>o(l,h),t[8]=l,t[9]=o,t[10]=u):u=t[10];let f;return t[11]!==l||t[12]!==i||t[13]!==d||t[14]!==u?(f={filters:l,layout:i,setFilters:d,setLayout:u},t[11]=l,t[12]=i,t[13]=d,t[14]=u,t[15]=f):f=t[15],f}Sc(()=>import("./route-Bdqr734y.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181])).catch(()=>{});const tg=new Intl.DateTimeFormat(void 0,{month:"short",day:"numeric"});function cc(t){const e=new Date(t),s=e.getTime()<Date.now();return{label:tg.format(e),overdue:s}}const fs="inline-flex items-center gap-1 rounded-full border-[length:var(--border-hairline)] border-border px-2 py-0.5 text-xs font-medium text-muted-foreground",Er=12,Ir="size-3.5",Yl=2;function sg(){const t=$.c(9),e=J();let s;t[0]===Symbol.for("react.memo_cache_sentinel")?(s=F(fs,"border-warning/50 text-warning"),t[0]=s):s=t[0];let n;t[1]!==e?(n=e("taskBoard.taskBoard.blockedBadgeTitle"),t[1]=e,t[2]=n):n=t[2];let r;t[3]===Symbol.for("react.memo_cache_sentinel")?(r=a.jsx(bl,{size:Er}),t[3]=r):r=t[3];let l;t[4]!==e?(l=e("taskBoard.taskBoard.needsInput"),t[4]=e,t[5]=l):l=t[5];let i;return t[6]!==n||t[7]!==l?(i=a.jsxs("span",{className:s,title:n,children:[r,l]}),t[6]=n,t[7]=l,t[8]=i):i=t[8],i}function ng(){const t=$.c(9),e=J();let s;t[0]===Symbol.for("react.memo_cache_sentinel")?(s=F(fs,"border-warning/50 text-warning"),t[0]=s):s=t[0];let n;t[1]!==e?(n=e("taskBoard.taskBoard.handedToHumanBadgeTitle"),t[1]=e,t[2]=n):n=t[2];let r;t[3]===Symbol.for("react.memo_cache_sentinel")?(r=a.jsx(bl,{size:Er}),t[3]=r):r=t[3];let l;t[4]!==e?(l=e("taskBoard.taskBoard.needsYou"),t[4]=e,t[5]=l):l=t[5];let i;return t[6]!==n||t[7]!==l?(i=a.jsxs("span",{className:s,title:n,children:[r,l]}),t[6]=n,t[7]=l,t[8]=i):i=t[8],i}function rg(t){const e=$.c(20),{priority:s,onChange:n}=t,r=J(),l=Le[s];let i;e[0]!==l.labelKey||e[1]!==r?(i=r(l.labelKey),e[0]=l.labelKey,e[1]=r,e[2]=i):i=e[2];const c=i,o=l.icon;let d;e[3]!==l.iconClassName?(d=F(Ir,"shrink-0",l.iconClassName),e[3]=l.iconClassName,e[4]=d):d=e[4];let u;e[5]!==l.icon||e[6]!==c||e[7]!==d?(u=a.jsx(o,{className:d,"aria-label":c}),e[5]=l.icon,e[6]=c,e[7]=d,e[8]=u):u=e[8];const f=u;if(!n){let m;return e[9]!==f||e[10]!==c?(m=a.jsx(Sl,{label:c,children:f}),e[9]=f,e[10]=c,e[11]=m):m=e[11],m}let h;e[12]!==n||e[13]!==s||e[14]!==r?(h=br.map(m=>{const g=Le[m].icon;return a.jsxs(Ce,{onSelect:()=>n(m),className:F("gap-2",m===s&&"bg-accent"),children:[a.jsx(g,{size:Er,className:F("shrink-0",Le[m].iconClassName)}),r(Le[m].labelKey)]},m)}),e[12]=n,e[13]=s,e[14]=r,e[15]=h):h=e[15];let x;return e[16]!==f||e[17]!==c||e[18]!==h?(x=a.jsx(dc,{label:c,glyph:f,children:h}),e[16]=f,e[17]=c,e[18]=h,e[19]=x):x=e[19],x}function dc(t){const e=$.c(8),{label:s,glyph:n,children:r}=t;let l;e[0]!==n||e[1]!==s?(l=a.jsx(Ke,{asChild:!0,children:a.jsx(ke,{variant:"ghost",size:"icon-sm",title:s,"aria-label":s,onClick:ig,onPointerDown:ag,className:"-m-1.5",children:n})}),e[0]=n,e[1]=s,e[2]=l):l=e[2];let i;e[3]!==r?(i=a.jsx(We,{align:"start",className:"w-36",onClick:lg,children:r}),e[3]=r,e[4]=i):i=e[4];let c;return e[5]!==l||e[6]!==i?(c=a.jsxs(Ge,{children:[l,i]}),e[5]=l,e[6]=i,e[7]=c):c=e[7],c}function lg(t){return t.stopPropagation()}function ag(t){return t.stopPropagation()}function ig(t){return t.stopPropagation()}function Sl(t){const e=$.c(7),{label:s,children:n}=t;let r;e[0]!==n?(r=a.jsx(qi,{asChild:!0,children:a.jsx("span",{className:"flex shrink-0 items-center",children:n})}),e[0]=n,e[1]=r):r=e[1];let l;e[2]!==s?(l=a.jsx(Ui,{side:"top",children:s}),e[2]=s,e[3]=l):l=e[3];let i;return e[4]!==r||e[5]!==l?(i=a.jsxs(Ki,{children:[r,l]}),e[4]=r,e[5]=l,e[6]=i):i=e[6],i}function og(t){const e=$.c(20),{type:s,onChange:n}=t,r=J(),l=Ot[s];let i;e[0]!==l.labelKey||e[1]!==r?(i=r(l.labelKey),e[0]=l.labelKey,e[1]=r,e[2]=i):i=e[2];const c=i,o=l.icon;let d;e[3]!==l.iconClassName?(d=F(Ir,"shrink-0",l.iconClassName),e[3]=l.iconClassName,e[4]=d):d=e[4];let u;e[5]!==l.icon||e[6]!==c||e[7]!==d?(u=a.jsx(o,{className:d,"aria-label":c}),e[5]=l.icon,e[6]=c,e[7]=d,e[8]=u):u=e[8];const f=u;if(!n){let m;return e[9]!==f||e[10]!==c?(m=a.jsx(Sl,{label:c,children:f}),e[9]=f,e[10]=c,e[11]=m):m=e[11],m}let h;e[12]!==n||e[13]!==r||e[14]!==s?(h=to.map(m=>{const g=Ot[m].icon;return a.jsxs(Ce,{onSelect:()=>n(m),className:F("gap-2",m===s&&"bg-accent"),children:[a.jsx(g,{size:Er,className:F("shrink-0",Ot[m].iconClassName)}),r(Ot[m].labelKey)]},m)}),e[12]=n,e[13]=r,e[14]=s,e[15]=h):h=e[15];let x;return e[16]!==f||e[17]!==c||e[18]!==h?(x=a.jsx(dc,{label:c,glyph:f,children:h}),e[16]=f,e[17]=c,e[18]=h,e[19]=x):x=e[19],x}function cg(t){const e=$.c(46),{iso:s,onChange:n}=t;let r;e[0]!==s?(r=hd(s),e[0]=s,e[1]=r):r=e[1];const l=r;let i;e[2]!==s?(i=cc(s),e[2]=s,e[3]=i):i=e[3];const{label:c}=i;let o;e[4]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(xt,{className:Ir}),e[4]=o):o=e[4];let d;e[5]!==c?(d=a.jsxs(a.Fragment,{children:[o,c]}),e[5]=c,e[6]=d):d=e[6];const u=d;let f,h,x,m,g,k,y,v,p,b;if(e[7]!==u||e[8]!==n||e[9]!==l){g=Symbol.for("react.early_return_sentinel");e:{const D=F("shrink-0 items-center gap-1.5 text-xs font-medium tabular-nums text-muted-foreground/70",l==="overdue"&&"text-destructive",l==="soon"&&"text-warning");if(!n){g=a.jsx("span",{className:F("flex",D),children:u});break e}x=Ge,h=Ke,m=!0,f=ke,k="ghost",y="sm",v=fg,p=ug,b=F("-mx-1.5 h-auto px-1.5 py-1 font-medium",D)}e[7]=u,e[8]=n,e[9]=l,e[10]=f,e[11]=h,e[12]=x,e[13]=m,e[14]=g,e[15]=k,e[16]=y,e[17]=v,e[18]=p,e[19]=b}else f=e[10],h=e[11],x=e[12],m=e[13],g=e[14],k=e[15],y=e[16],v=e[17],p=e[18],b=e[19];if(g!==Symbol.for("react.early_return_sentinel"))return g;let j;e[20]!==f||e[21]!==u||e[22]!==k||e[23]!==y||e[24]!==v||e[25]!==p||e[26]!==b?(j=a.jsx(f,{variant:k,size:y,onClick:v,onPointerDown:p,className:b,children:u}),e[20]=f,e[21]=u,e[22]=k,e[23]=y,e[24]=v,e[25]=p,e[26]=b,e[27]=j):j=e[27];let w;e[28]!==h||e[29]!==m||e[30]!==j?(w=a.jsx(h,{asChild:m,children:j}),e[28]=h,e[29]=m,e[30]=j,e[31]=w):w=e[31];let S;e[32]!==s?(S=new Date(s),e[32]=s,e[33]=S):S=e[33];let C;e[34]!==s?(C=new Date(s),e[34]=s,e[35]=C):C=e[35];let T;e[36]!==n?(T=D=>D&&n(La(D)),e[36]=n,e[37]=T):T=e[37];let N;e[38]!==S||e[39]!==C||e[40]!==T?(N=a.jsx(We,{align:"start",className:"w-auto p-0",onClick:dg,children:a.jsx(ka,{mode:"single",selected:S,defaultMonth:C,onSelect:T,initialFocus:!0})}),e[38]=S,e[39]=C,e[40]=T,e[41]=N):N=e[41];let _;return e[42]!==x||e[43]!==w||e[44]!==N?(_=a.jsxs(x,{children:[w,N]}),e[42]=x,e[43]=w,e[44]=N,e[45]=_):_=e[45],_}function dg(t){return t.stopPropagation()}function ug(t){return t.stopPropagation()}function fg(t){return t.stopPropagation()}function hg(t){const e=$.c(8),{action:s}=t;let n;e[0]!==s?(n=i=>{i.stopPropagation(),s.onClick()},e[0]=s,e[1]=n):n=e[1];let r;e[2]!==s.icon?(r=a.jsx(s.icon,{className:Ir}),e[2]=s.icon,e[3]=r):r=e[3];let l;return e[4]!==s.label||e[5]!==n||e[6]!==r?(l=a.jsxs(ke,{variant:"outline",size:"sm",onClick:n,onPointerDown:mg,ref:pg,className:"absolute -top-0.5 right-0 h-6 gap-1.5 classic:rounded-full px-2 text-xs font-medium shadow-sm pointer-events-none opacity-0 transition-opacity focus-visible:pointer-events-auto focus-visible:opacity-100 group-hover:pointer-events-auto group-hover:opacity-100",children:[r,s.label]}),e[4]=s.label,e[5]=n,e[6]=r,e[7]=l):l=e[7],l}function pg(t){return t?.parentElement?.style.setProperty("--fade-text-end",`${t.offsetWidth}px`)}function mg(t){return t.stopPropagation()}function gg(t){const e=$.c(36),{item:s,checks:n,assignee:r,assignedBy:l,members:i,onAssign:c,onPriorityChange:o,onTypeChange:d,onDueDateChange:u}=t,{org:f}=Qe();let h;e[0]!==s.keySeq||e[1]!==f.slug?(h=Zi(f.slug,s.keySeq),e[0]=s.keySeq,e[1]=f.slug,e[2]=h):h=e[2];const x=h;let m;e[3]!==s.type||e[4]!==d?(m=a.jsx(og,{type:s.type,onChange:d}),e[3]=s.type,e[4]=d,e[5]=m):m=e[5];let g;e[6]!==x?(g=a.jsx("span",{className:"text-xs font-medium tabular-nums text-muted-foreground/70",children:x}),e[6]=x,e[7]=g):g=e[7];let k;e[8]!==m||e[9]!==g?(k=a.jsxs("span",{className:"flex shrink-0 items-center gap-1.5",children:[m,g]}),e[8]=m,e[9]=g,e[10]=k):k=e[10];let y;e[11]!==s.dueDate||e[12]!==u?(y=s.dueDate&&a.jsx(cg,{iso:s.dueDate,onChange:u}),e[11]=s.dueDate,e[12]=u,e[13]=y):y=e[13];let v;e[14]!==k||e[15]!==y?(v=a.jsxs("span",{className:"flex min-w-0 items-center gap-3",children:[k,y]}),e[14]=k,e[15]=y,e[16]=v):v=e[16];let p;e[17]!==s.priority||e[18]!==o?(p=(s.priority!=="none"||o)&&a.jsx(rg,{priority:s.priority,onChange:o}),e[17]=s.priority,e[18]=o,e[19]=p):p=e[19];let b;e[20]!==n||e[21]!==s.reviewVerdicts?(b=n&&a.jsx(bg,{summary:n.summary,verdicts:s.reviewVerdicts,enabled:n.enabled}),e[20]=n,e[21]=s.reviewVerdicts,e[22]=b):b=e[22];let j;e[23]!==l||e[24]!==r||e[25]!==s||e[26]!==i||e[27]!==c?(j=a.jsx(fc,{item:s,assignee:r,assignedBy:l,members:i,onAssign:c,showDelegation:!1}),e[23]=l,e[24]=r,e[25]=s,e[26]=i,e[27]=c,e[28]=j):j=e[28];let w;e[29]!==p||e[30]!==b||e[31]!==j?(w=a.jsxs("span",{className:"flex shrink-0 items-center gap-2",children:[p,b,j]}),e[29]=p,e[30]=b,e[31]=j,e[32]=w):w=e[32];let S;return e[33]!==w||e[34]!==v?(S=a.jsxs("div",{className:"mt-auto flex shrink-0 items-center justify-between gap-2 pt-1",children:[v,w]}),e[33]=w,e[34]=v,e[35]=S):S=e[35],S}function xg(t){const e=$.c(10),{priority:s}=t,n=J(),r=Le[s];let l;e[0]!==r.labelKey||e[1]!==n?(l=n(r.labelKey),e[0]=r.labelKey,e[1]=n,e[2]=l):l=e[2];const i=l;let c;e[3]!==r.dotClassName?(c=F("size-2 shrink-0 rounded-full",r.dotClassName),e[3]=r.dotClassName,e[4]=c):c=e[4];let o;e[5]!==c?(o=a.jsx("span",{className:c}),e[5]=c,e[6]=o):o=e[6];let d;return e[7]!==i||e[8]!==o?(d=a.jsxs("span",{className:fs,title:i,children:[o,i]}),e[7]=i,e[8]=o,e[9]=d):d=e[9],d}function kg(t){const e=$.c(7),{iso:s}=t;let n,r;if(e[0]!==s){const{label:c,overdue:o}=cc(s);n=c,r=F(fs,o&&"border-destructive/50 text-destructive"),e[0]=s,e[1]=n,e[2]=r}else n=e[1],r=e[2];let l;e[3]===Symbol.for("react.memo_cache_sentinel")?(l=a.jsx(xt,{size:Er}),e[3]=l):l=e[3];let i;return e[4]!==n||e[5]!==r?(i=a.jsxs("span",{className:r,children:[l,n]}),e[4]=n,e[5]=r,e[6]=i):i=e[6],i}function uc(t){const e=$.c(8),{tag:s}=t;let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=F(fs,"text-foreground"),e[0]=n):n=e[0];let r;e[1]!==s.color?(r=qt(s.color),e[1]=s.color,e[2]=r):r=e[2];let l;e[3]!==r?(l={borderColor:r},e[3]=r,e[4]=l):l=e[4];let i;return e[5]!==l||e[6]!==s.name?(i=a.jsx("span",{className:n,style:l,children:s.name}),e[5]=l,e[6]=s.name,e[7]=i):i=e[7],i}function bg(t){const e=$.c(26),{summary:s,verdicts:n,enabled:r}=t,l=J();let i;if(e[0]!==r||e[1]!==l||e[2]!==n){let p;e[4]!==l||e[5]!==n?(p=b=>{const j=n.find(C=>C.reviewer===b),w=l("taskBoard.taskDialog.reviewerLabel"),S=j?j.verdict==="changes_requested"?l("taskBoard.taskBoard.checksChangesRequested"):l(j.verified?"taskBoard.taskBoard.checksApproved":"taskBoard.taskBoard.checksUnverified"):l("taskBoard.taskBoard.checksPending");return a.jsxs("span",{className:"flex items-center gap-1.5 whitespace-nowrap",children:[a.jsx(Sa,{size:12}),w," — ",S]},b)},e[4]=l,e[5]=n,e[6]=p):p=e[6],i=r.map(p),e[0]=r,e[1]=l,e[2]=n,e[3]=i}else i=e[3];let c;e[7]!==i?(c=a.jsx("span",{className:"flex flex-col gap-0.5",children:i}),e[7]=i,e[8]=c):c=e[8];const o=c,d=s.tone==="ok"&&"text-success",u=s.tone==="pending"&&"text-warning",f=s.tone==="danger"&&"text-destructive";let h;e[9]!==d||e[10]!==u||e[11]!==f?(h=F("flex shrink-0 items-center gap-1.5 text-xs font-medium tabular-nums",d,u,f),e[9]=d,e[10]=u,e[11]=f,e[12]=h):h=e[12];const x=String(s.passed),m=String(s.total);let g;e[13]!==l||e[14]!==x||e[15]!==m?(g=l("taskBoard.taskBoard.checksLabel",{passed:x,total:m}),e[13]=l,e[14]=x,e[15]=m,e[16]=g):g=e[16];let k;e[17]===Symbol.for("react.memo_cache_sentinel")?(k=a.jsx(kr,{className:Ir}),e[17]=k):k=e[17];let y;e[18]!==s.passed||e[19]!==s.total||e[20]!==h||e[21]!==g?(y=a.jsxs("span",{className:h,"aria-label":g,children:[k,s.passed,"/",s.total]}),e[18]=s.passed,e[19]=s.total,e[20]=h,e[21]=g,e[22]=y):y=e[22];let v;return e[23]!==o||e[24]!==y?(v=a.jsx(Sl,{label:o,children:y}),e[23]=o,e[24]=y,e[25]=v):v=e[25],v}function yg(t){const e=$.c(14),{state:s}=t,n=J(),r=s==="running",l=r?"taskBoard.taskBoard.agentRunning":"taskBoard.taskBoard.agentFailed";let i;e[0]!==n||e[1]!==l?(i=n(l),e[0]=n,e[1]=l,e[2]=i):i=e[2];const c=i;let o;e[3]!==c||e[4]!==r?(o=r?a.jsx(yt,{className:"size-3.5 text-primary",label:c}):a.jsx(Tc,{size:14,className:"shrink-0 text-destructive","aria-label":c}),e[3]=c,e[4]=r,e[5]=o):o=e[5];let d;e[6]!==c||e[7]!==o?(d=a.jsx(Sl,{label:c,children:o}),e[6]=c,e[7]=o,e[8]=d):d=e[8];let u;e[9]!==c?(u=a.jsx("span",{className:"sr-only",children:c}),e[9]=c,e[10]=u):u=e[10];let f;return e[11]!==d||e[12]!==u?(f=a.jsxs("span",{className:"mt-px flex shrink-0 items-center",children:[d,u]}),e[11]=d,e[12]=u,e[13]=f):f=e[13],f}function jg(t){const e=$.c(3),s=Yo(ro());if(t.reviewVerdicts.length===0&&t.status!=="in_review"&&!t.reviewCycleStartedAt)return null;const n=ip(t.reviewVerdicts,s);let r;return e[0]!==s||e[1]!==n?(r=n?{summary:n,enabled:s}:null,e[0]=s,e[1]=n,e[2]=r):r=e[2],r}function fc(t){const e=$.c(35),{item:s,assignee:n,assignedBy:r,members:l,onAssign:i,showDelegation:c}=t,o=c===void 0?!0:c,d=J(),[u,f]=W.useState(!1);if(s.assigneeId===ye){let b;e[0]!==r||e[1]!==d?(b=r?.user?.name?d("taskBoard.taskBoard.assignedToSuperAgentBy",{name:r.user.name}):d("taskBoard.taskBoard.assignedToSuperAgent"),e[0]=r,e[1]=d,e[2]=b):b=e[2];const j=b;if(!o){let T;return e[3]!==r||e[4]!==j?(T=r?a.jsx(Fe,{url:r.user?.image??void 0,fallback:Oe(r.user?.name),shape:"circle",size:"xs",title:j}):null,e[3]=r,e[4]=j,e[5]=T):T=e[5],T}let w;e[6]!==r?(w=r&&a.jsx(Fe,{url:r.user?.image??void 0,fallback:Oe(r.user?.name),shape:"circle",size:"xs",className:"-mr-2 ring-2 ring-background"}),e[6]=r,e[7]=w):w=e[7];let S;e[8]===Symbol.for("react.memo_cache_sentinel")?(S=a.jsx(Ve,{size:20,className:"ring-2 ring-background"}),e[8]=S):S=e[8];let C;return e[9]!==w||e[10]!==j?(C=a.jsxs("span",{className:"inline-flex items-center",title:j,children:[w,S]}),e[9]=w,e[10]=j,e[11]=C):C=e[11],C}if(n){const b=n.user?.image??void 0,j=n.user?.name;let w;e[12]!==j?(w=Oe(j),e[12]=j,e[13]=w):w=e[13];let S;return e[14]!==b||e[15]!==w?(S=a.jsx(Fe,{url:b,fallback:w,shape:"circle",size:"xs"}),e[14]=b,e[15]=w,e[16]=S):S=e[16],S}if(!i||!l?.length)return null;let h;e[17]!==d?(h=d("taskBoard.taskBoard.assignButton"),e[17]=d,e[18]=h):h=e[18];let x;e[19]!==d?(x=d("taskBoard.taskBoard.assignButton"),e[19]=d,e[20]=x):x=e[20];let m;e[21]===Symbol.for("react.memo_cache_sentinel")?(m=b=>{b.stopPropagation(),f(!0)},e[21]=m):m=e[21];let g;e[22]===Symbol.for("react.memo_cache_sentinel")?(g=a.jsx(Oi,{size:13}),e[22]=g):g=e[22];let k;e[23]!==h||e[24]!==x?(k=a.jsx(gt,{asChild:!0,children:a.jsx("button",{type:"button",title:h,"aria-label":x,onClick:m,className:"flex size-6 shrink-0 items-center justify-center rounded-full border border-dashed border-muted-foreground/40 text-muted-foreground/40 transition-colors hover:border-muted-foreground hover:text-muted-foreground",children:g})}),e[23]=h,e[24]=x,e[25]=k):k=e[25];let y;e[26]!==i?(y=b=>{i(b),f(!1)},e[26]=i,e[27]=y):y=e[27];let v;e[28]!==l||e[29]!==y?(v=a.jsx(kt,{className:"w-56 p-0",align:"end",side:"bottom",onClick:vg,children:a.jsx(Ia,{members:l,onSelect:y})}),e[28]=l,e[29]=y,e[30]=v):v=e[30];let p;return e[31]!==u||e[32]!==k||e[33]!==v?(p=a.jsxs(bt,{open:u,onOpenChange:f,children:[k,v]}),e[31]=u,e[32]=k,e[33]=v,e[34]=p):p=e[34],p}function vg(t){return t.stopPropagation()}function hx(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=a.jsx(Df,{children:a.jsx(wg,{})}),t[0]=e):e=t[0],e}function wg(){const t=$.c(101),e=Mi(),s=J(),{items:n,isLoading:r}=sd(),{data:l}=ga();let i;t[0]!==l?(i=l===void 0?[]:l,t[0]=l,t[1]=i):i=t[1];const c=i,o=nd(),d=bo();let u,f;if(t[2]!==d.data){const B=(d.data??[]).filter(Lg);u=B.length>0,f=B.map(Ig),t[2]=d.data,t[3]=u,t[4]=f}else u=t[3],f=t[4];const h=f,[x,m]=W.useState(!1);let g;t[5]!==u?(g=B=>B===ye&&!u?(m(!0),!0):!1,t[5]=u,t[6]=g):g=t[6];const k=g,[y,v]=W.useState(null),p=B=>{const te=nf(B);if(te){v(te),Fa("task_limit_banner_shown",{organization_id:le.id,kind:te});return}Je.error(B.message||s("taskBoard.taskBoard.actionError"))},b=B=>{!B||B.dataset.tracked==="true"||(B.dataset.tracked="true",Fa("task_board_opened",{organization_id:le.id}))};let j;t[7]===Symbol.for("react.memo_cache_sentinel")?(j=[],t[7]=j):j=t[7];const[w,S]=W.useState(j),C=()=>{if(w.length!==0){if(k(ye)){S([]);return}for(const B of w)o.rerun.mutate({id:B.id},{onError:te=>p(te)});S([]),G()}},{data:T}=pa();let N,_;t[8]!==T?.data?.members?(N=T?.data?.members??[],_=new Map(N.map(Eg)),t[8]=T?.data?.members,t[9]=N,t[10]=_):(N=t[9],_=t[10]);const D=_,{filters:A,setFilters:L,layout:z,setLayout:P}=eg(),E=Zo(n,h);let I;t[11]!==E?(I=Yi(E),t[11]=E,t[12]=I):I=t[12];const V=I;let Q;t[13]!==A.project||t[14]!==E?(Q=A.project?Nr(A.project,E)?.repo??null:null,t[13]=A.project,t[14]=E,t[15]=Q):Q=t[15];const Y=Q,[se]=Pi();let H;t[16]===Symbol.for("react.memo_cache_sentinel")?(H=new Set,t[16]=H):H=t[16];const[ee,q]=W.useState(H);let Z;t[17]===Symbol.for("react.memo_cache_sentinel")?(Z=B=>q(te=>{const we=new Set(te);return we.has(B)?we.delete(B):we.add(B),we}),t[17]=Z):Z=t[17];const X=Z,re=B=>q(te=>{const we=new Set(te);for(const Me of Ye)Me.status===B&&we.add(Me.id);return we}),G=()=>q(new Set),ne=B=>{L(B),G()},[ce,ue]=W.useState(!1),[oe,R]=W.useState(null),{setTaskId:O}=af(),{create:fe}=qu(),de=Ut(),{org:be,locator:Ne}=Qe(),le=be,xe=oa(),ae=()=>{xe({to:"/$org/settings/task-board",params:{org:le.slug}})};let Te;t[18]===Symbol.for("react.memo_cache_sentinel")?(Te={strict:!1},t[18]=Te):Te=t[18];const{taskKey:U}=xl(Te),K=rd(n,U)??null,he=!!U&&!K&&!r,ve=K?Ha(le.slug,K):null;let ge;t[19]!==xe||t[20]!==U?(ge=()=>{U&&xe({to:".",params:zg,search:Rg,replace:!0})},t[19]=xe,t[20]=U,t[21]=ge):ge=t[21];const Ae=ge,Be=async B=>{const te=crypto.randomUUID(),we=Nc(le.id).id,Me=await de.call("TASK_BOARD_ITEM_PRS_GET",{taskBoardItemId:B.id}).then(Dg).catch($g),ot=vm(B,Me),Ue={type:"doc",content:[{type:"paragraph",content:[gu({id:B.id,name:B.title,char:"@",kind:"task",metadata:{title:B.title,description:B.description,context:ot}}),{type:"text",text:" "}]}]};rf(sessionStorage,Ne,te,Ue);try{await fe({id:te,virtual_mcp_id:we}),await o.link.mutateAsync({id:B.id,linkThreadId:te})}catch{}O(te,we)};let Ee;t[22]!==A||t[23]!==E?(Ee=B=>ha(B,A,E),t[22]=A,t[23]=E,t[24]=Ee):Ee=t[24];const Ye=n.filter(Ee),$e=Jm(ee,Ye);let Tt;t[25]!==se?(Tt=B=>!dd.includes(B.status)||se.shownTaskBoardLanes.includes(B.status),t[25]=se,t[26]=Tt):Tt=t[26];const Ze=Ye.filter(Tt);let De;t[27]!==A||t[28]!==E||t[29]!==L?(De=B=>{const te=ud({repo:B},A.project,E);te!==A.project&&L({...A,project:te})},t[27]=A,t[28]=E,t[29]=L,t[30]=De):De=t[30];const Bt=De;let _t;t[31]===Symbol.for("react.memo_cache_sentinel")?(_t=()=>{R(null),ue(!0)},t[31]=_t):_t=t[31];const jr=_t;let At;t[32]===Symbol.for("react.memo_cache_sentinel")?(At=B=>{R(B),ue(!0)},t[32]=At):At=t[32];const Lr=At,hs=B=>{xe({to:".",params:te=>({...te,taskKey:Ha(le.slug,B)}),search:Ag})};let Wt;t[33]===Symbol.for("react.memo_cache_sentinel")?(Wt=()=>{ue(!1),R(null)},t[33]=Wt):Wt=t[33];const tt=Wt;if(r&&n.length===0){let B;return t[34]===Symbol.for("react.memo_cache_sentinel")?(B=a.jsx("div",{className:"flex flex-1 items-center justify-center",children:a.jsx(yt,{className:"size-5 text-muted-foreground"})}),t[34]=B):B=t[34],B}if(he){let B;return t[35]===Symbol.for("react.memo_cache_sentinel")?(B=a.jsx(Pa,{to:".",params:_g,search:Bg,replace:!0}),t[35]=B):B=t[35],B}if(ve&&ve!==U)return a.jsx(Pa,{to:".",params:B=>({...B,taskKey:ve}),search:Tg,replace:!0});const $t=e?a.jsxs(a.Fragment,{children:[!K&&a.jsxs(a.Fragment,{children:[a.jsx(Ft.Title,{children:s("taskBoard.taskBoard.tasksTitle")}),a.jsxs(Ft.Actions,{secondary:n.length>0&&a.jsx(a.Fragment,{children:a.jsxs("div",{className:"flex items-center gap-2",children:[a.jsx(Md,{value:A.search,onChange:B=>ne({...A,search:B}),label:s("taskBoard.taskFilters.searchLabel"),placeholder:s("taskBoard.taskFilters.searchPlaceholder"),clearLabel:s("taskBoard.taskFilters.searchClearLabel")}),a.jsx(Km,{filters:A,items:n,members:N,tags:c,index:E,onChange:ne}),a.jsx(Qm,{onClick:ae})]})}),children:[a.jsx(si,{}),a.jsxs(ke,{size:"sm",onClick:jr,children:[a.jsx(ts,{size:16}),s("taskBoard.taskBoard.newTask")]})]}),a.jsx(Cc.Toolbar.Left.Portal,{children:a.jsxs(Ft.Tabs,{children:[a.jsx(Ft.Tab,{active:z==="board","aria-label":s("taskBoard.taskBoard.layoutViewAriaLabel",{label:s("common.taskBoard.boardView")}),onClick:()=>P("board"),children:s("common.taskBoard.boardView")}),a.jsx(Ft.Tab,{active:z==="list","aria-label":s("taskBoard.taskBoard.layoutViewAriaLabel",{label:s("common.taskBoard.listView")}),onClick:()=>{P("list"),G()},children:s("common.taskBoard.listView")})]})})]}),a.jsx("div",{className:"mx-auto w-full max-w-[1680px] px-4 sm:px-8",children:a.jsx(ti,{})}),a.jsx(Vm,{filters:A,items:n,members:N,tags:c,index:E,onChange:ne})]}):a.jsx(a.Fragment,{children:a.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 pt-6 sm:px-8 sm:pt-8",children:[a.jsx("h1",{className:"text-xl font-medium text-foreground",children:s("taskBoard.taskBoard.tasksTitle")}),a.jsx(ti,{}),a.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[n.length>0&&a.jsxs(a.Fragment,{children:[a.jsx("div",{className:"sm:hidden",children:a.jsx($f,{filters:A,members:N,tags:c,index:E,onChange:ne,onOpenBoardSettings:ae})}),a.jsx("div",{className:"hidden sm:block",children:a.jsx(Af,{filters:A,members:N,tags:c,index:E,onChange:ne,onOpenBoardSettings:ae})})]}),a.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[a.jsx(si,{}),a.jsxs("div",{className:"inline-flex rounded-lg bg-muted p-0.5",children:[a.jsx($i,{active:z==="list",onClick:()=>{P("list"),G()},icon:Hi,label:s("common.taskBoard.listView")}),a.jsx($i,{active:z==="board",onClick:()=>P("board"),icon:qc,label:s("common.taskBoard.boardView")})]}),a.jsxs(ke,{size:"sm",onClick:jr,children:[a.jsx(ts,{size:16}),s("taskBoard.taskBoard.newTask")]})]})]})]})}),Dt=n.length===0?a.jsx("div",{className:"mx-auto w-full max-w-[1680px] px-4 pt-6 sm:px-8",children:a.jsx("div",{className:"rounded-xl bg-card px-4 py-12 text-center text-sm text-muted-foreground card-shadow",children:s("taskBoard.taskBoard.noTasksYet")})}):Ye.length===0?a.jsx("div",{className:"mx-auto w-full max-w-[1680px] px-4 pt-6 sm:px-8",children:a.jsxs("div",{className:"flex flex-col items-center gap-3 rounded-xl bg-card px-4 py-12 text-center text-sm text-muted-foreground card-shadow",children:[s("taskBoard.taskBoard.noTasksMatch"),a.jsx(ke,{variant:"outline",size:"sm",onClick:()=>ne(yl),children:s("taskBoard.taskBoard.clearFilters")})]})}):z==="board"?a.jsx(Pg,{visible:!K,items:Ye,members:N,memberByUserId:D,selectedIds:$e,onToggleSelect:X,onSelectAllInLane:re,onOpen:hs,onCreate:Lr,onMove:(B,te,we)=>{const Me=so(we,B.length);B.forEach((ot,Ue)=>o.update.mutate({id:ot,status:te,sortOrder:Me[Ue]}))},onAssign:(B,te)=>{k(te)||o.update.mutate({id:B,assigneeId:te},{onError:p})},onPriorityChange:(B,te)=>o.update.mutate({id:B,priority:te}),onTypeChange:(B,te)=>o.update.mutate({id:B,type:te}),onDueDateChange:(B,te)=>o.update.mutate({id:B,dueDate:te}),onAutoFix:B=>{k(ye)||o.update.mutate({id:B.id,assigneeId:ye},{onError:p})},onRerun:B=>S([B])}):a.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto px-4 pt-6 pb-16 sm:px-8",children:a.jsx("div",{className:"mx-auto flex max-w-[820px] flex-col gap-2",children:Ze.map(B=>a.jsx(Yg,{item:B,assignee:B.assigneeId?D.get(B.assigneeId):void 0,assignedBy:B.assignedBy?D.get(B.assignedBy):void 0,onOpen:()=>hs(B)},B.id))})});let Rt;t[36]!==$t||t[37]!==Dt?(Rt=a.jsxs(a.Fragment,{children:[$t,Dt]}),t[36]=$t,t[37]=Dt,t[38]=Rt):Rt=t[38];const jt=Rt,st="relative flex min-h-0 flex-1 flex-col",ps=F("flex min-h-0 flex-1 flex-col",K&&"hidden");let nt;t[39]!==jt||t[40]!==ps?(nt=a.jsx("div",{className:ps,children:jt}),t[39]=jt,t[40]=ps,t[41]=nt):nt=t[41];let Pe;t[42]!==o.create||t[43]!==o.remove||t[44]!==o.update||t[45]!==k||t[46]!==Ae||t[47]!==p||t[48]!==K||t[49]!==S||t[50]!==O||t[51]!==Be||t[52]!==s||t[53]!==Bt?(Pe=K&&a.jsx(qp,{item:K,onClose:()=>Ae(),isSaving:o.update.isPending,onSubmit:B=>{if(k(B.assigneeId)){Ae();return}const{title:te,description:we,priority:Me,...ot}=B,Ue=Jl(K)?{}:{title:te,description:we,priority:Me};o.update.mutate({id:K.id,...ot,...Ue},{onError:p})},onDelete:()=>{o.remove.mutate(K.id),Ae()},onClone:()=>{o.create.mutate({title:s("taskBoard.taskDialog.cloneTitle",{title:K.title}),description:K.description,status:K.status,priority:K.priority,repo:K.repo,dueDate:K.dueDate,tagIds:K.tags.map(Ng)}),Bt(K.repo??null),Je.success(s("taskBoard.taskDialog.cloneSuccess")),Ae()},onArchive:()=>{o.update.mutate({id:K.id,status:"archived"}),Je.success(s("taskBoard.taskDialog.archiveSuccess")),Ae()},onNewChat:()=>{Be(K)},onAutoFix:()=>{k(ye)||(o.update.mutate({id:K.id,assigneeId:ye},{onError:p}),Ae())},onRerun:()=>{Ae(),S([K])},onOpenPreview:B=>{B.virtualMcpId&&O(B.threadId,B.virtualMcpId,{panel:"site-editor"})}},K.id),t[42]=o.create,t[43]=o.remove,t[44]=o.update,t[45]=k,t[46]=Ae,t[47]=p,t[48]=K,t[49]=S,t[50]=O,t[51]=Be,t[52]=s,t[53]=Bt,t[54]=Pe):Pe=t[54];const zt=ce?`new-${oe??"default"}`:"closed",ie=oe??void 0;let rt;t[55]!==o.create||t[56]!==k||t[57]!==tt||t[58]!==Bt?(rt=B=>{if(k(B.assigneeId)){tt();return}o.create.mutate(B),Bt(B.repo??null),tt()},t[55]=o.create,t[56]=k,t[57]=tt,t[58]=Bt,t[59]=rt):rt=t[59];let Ie;t[60]!==o.create.isPending||t[61]!==Y||t[62]!==tt||t[63]!==ce||t[64]!==zt||t[65]!==ie||t[66]!==rt?(Ie=a.jsx(Hp,{open:ce,onClose:tt,defaultStatus:ie,defaultRepo:Y,isSaving:o.create.isPending,onSubmit:rt},zt),t[60]=o.create.isPending,t[61]=Y,t[62]=tt,t[63]=ce,t[64]=zt,t[65]=ie,t[66]=rt,t[67]=Ie):Ie=t[67];let lt;t[68]!==x?(lt=a.jsx(Pd,{mode:"link",open:x,onOpenChange:m}),t[68]=x,t[69]=lt):lt=t[69];let Gt;t[70]===Symbol.for("react.memo_cache_sentinel")?(Gt=B=>!B&&v(null),t[70]=Gt):Gt=t[70];let at;t[71]!==y?(at=a.jsx(mm,{kind:y,onOpenChange:Gt}),t[71]=y,t[72]=at):at=t[72];let Re;t[73]!==S?(Re=B=>!B&&S([]),t[73]=S,t[74]=Re):Re=t[74];let it;t[75]!==o.rerun.isPending||t[76]!==C||t[77]!==w||t[78]!==Re?(it=a.jsx(km,{items:w,pending:o.rerun.isPending,onOpenChange:Re,onConfirm:C}),t[75]=o.rerun.isPending,t[76]=C,t[77]=w,t[78]=Re,t[79]=it):it=t[79];let ht;t[80]!==o.removeMany||t[81]!==o.update||t[82]!==k||t[83]!==G||t[84]!==n||t[85]!==N||t[86]!==p||t[87]!==K||t[88]!==V||t[89]!==$e||t[90]!==S?(ht=$e.size>0&&!K&&a.jsx(Mg,{count:$e.size,members:N,projectEntries:V,onSetRepo:B=>{for(const te of $e)o.update.mutate({id:te,repo:B});G()},onMoveTo:B=>{for(const te of $e)o.update.mutate({id:te,status:B});G()},onSetPriority:B=>{for(const te of $e)o.update.mutate({id:te,priority:B});G()},onAddTag:B=>{for(const te of $e){const we=n.find(ot=>ot.id===te);if(!we)continue;const Me=we.tags.map(Cg);Me.includes(B)||o.update.mutate({id:te,tagIds:[...Me,B]})}G()},onAssign:B=>{if(!k(B)){for(const te of $e)o.update.mutate({id:te,assigneeId:B},{onError:p});G()}},onSetDueDate:B=>{const te=La(B);for(const we of $e)o.update.mutate({id:we,dueDate:te});G()},onAutoFix:$e.size>0&&Array.from($e).every(B=>{const te=n.find(we=>we.id===B);return te&&(te.status==="triage"||te.status==="todo")&&te.assigneeId!==ye})?()=>{if(!k(ye)){for(const B of $e)o.update.mutate({id:B,assigneeId:ye},{onError:p});G()}}:void 0,onRerun:(()=>{const B=Array.from($e).flatMap(te=>{const we=n.find(Me=>Me.id===te);return we?[we]:[]});return B.length===$e.size&&B.every(Sg)?()=>S(B):void 0})(),onDelete:()=>{o.removeMany.mutate(Array.from($e)),G()},onClear:G}),t[80]=o.removeMany,t[81]=o.update,t[82]=k,t[83]=G,t[84]=n,t[85]=N,t[86]=p,t[87]=K,t[88]=V,t[89]=$e,t[90]=S,t[91]=ht):ht=t[91];let vt;return t[92]!==nt||t[93]!==Pe||t[94]!==Ie||t[95]!==lt||t[96]!==at||t[97]!==it||t[98]!==ht||t[99]!==b?(vt=a.jsxs("div",{ref:b,className:st,children:[nt,Pe,Ie,lt,at,it,ht]}),t[92]=nt,t[93]=Pe,t[94]=Ie,t[95]=lt,t[96]=at,t[97]=it,t[98]=ht,t[99]=b,t[100]=vt):vt=t[100],vt}function Sg(t){return t.assigneeId===ye&&t.status!=="done"}function Cg(t){return t.id}function Ng(t){return t.id}function Tg(t){return t}function Bg(t){return t}function _g(t){return{...t,taskKey:void 0}}function Ag(t){return t}function $g(){return[]}function Dg(t){return t.prs}function Rg(t){return t}function zg(t){return{...t,taskKey:void 0}}function Eg(t){return[t.userId,t]}function Ig(t){return t.path}function Lg(t){return t.usable}function Mg(t){const e=$.c(104),{count:s,members:n,projectEntries:r,onSetRepo:l,onMoveTo:i,onSetPriority:c,onAddTag:o,onAssign:d,onSetDueDate:u,onAutoFix:f,onRerun:h,onDelete:x,onClear:m}=t,g=J(),{data:k}=ga();let y;e[0]!==k?(y=k===void 0?[]:k,e[0]=k,e[1]=y):y=e[1];const v=y,p=xa("delivery_lanes_enabled");let b;e[2]!==s||e[3]!==g?(b=g("taskBoard.taskBoard.selectedCount",{count:s}),e[2]=s,e[3]=g,e[4]=b):b=e[4];let j;e[5]!==b?(j=a.jsx("span",{className:"pl-1 text-sm font-medium text-foreground",children:b}),e[5]=b,e[6]=j):j=e[6];let w;e[7]!==g?(w=g("taskBoard.taskBoard.actionsButton"),e[7]=g,e[8]=w):w=e[8];let S;e[9]!==w?(S=a.jsx(Ke,{asChild:!0,children:a.jsx("button",{type:"button",className:"flex items-center gap-1.5 classic:rounded-full compact:rounded-lg border border-border px-3 py-1.5 text-sm font-medium text-foreground transition-colors hover:bg-accent",children:w})}),e[9]=w,e[10]=S):S=e[10];let C;e[11]!==g?(C=g("taskBoard.taskBoard.moveToButton"),e[11]=g,e[12]=C):C=e[12];let T;e[13]!==C?(T=a.jsx(or,{children:C}),e[13]=C,e[14]=T):T=e[14];let N;if(e[15]!==p||e[16]!==i||e[17]!==g){let le;e[19]!==i||e[20]!==g?(le=xe=>a.jsx(Ce,{onClick:()=>i(xe),children:Tr(xe,g).label},xe),e[19]=i,e[20]=g,e[21]=le):le=e[21],N=eo(p).map(le),e[15]=p,e[16]=i,e[17]=g,e[18]=N}else N=e[18];let _;e[22]!==N?(_=a.jsx(cr,{children:N}),e[22]=N,e[23]=_):_=e[23];let D;e[24]!==_||e[25]!==T?(D=a.jsxs(ir,{children:[T,_]}),e[24]=_,e[25]=T,e[26]=D):D=e[26];let A;e[27]!==g?(A=g("taskBoard.taskBoard.changePriorityButton"),e[27]=g,e[28]=A):A=e[28];let L;e[29]!==A?(L=a.jsx(or,{children:A}),e[29]=A,e[30]=L):L=e[30];let z;e[31]!==c||e[32]!==g?(z=br.map(le=>a.jsxs(Ce,{onClick:()=>c(le),children:[a.jsx("span",{className:F("size-2 rounded-full",Le[le].dotClassName)}),g(Le[le].labelKey)]},le)),e[31]=c,e[32]=g,e[33]=z):z=e[33];let P;e[34]!==z?(P=a.jsx(cr,{children:z}),e[34]=z,e[35]=P):P=e[35];let E;e[36]!==L||e[37]!==P?(E=a.jsxs(ir,{children:[L,P]}),e[36]=L,e[37]=P,e[38]=E):E=e[38];let I;e[39]!==g?(I=g("taskBoard.taskBoard.assignButton"),e[39]=g,e[40]=I):I=e[40];let V;e[41]!==I?(V=a.jsx(or,{children:I}),e[41]=I,e[42]=V):V=e[42];let Q;e[43]!==n||e[44]!==d?(Q=a.jsx(cr,{className:"w-56 p-0",children:a.jsx(Ia,{members:n,onSelect:d})}),e[43]=n,e[44]=d,e[45]=Q):Q=e[45];let Y;e[46]!==V||e[47]!==Q?(Y=a.jsxs(ir,{children:[V,Q]}),e[46]=V,e[47]=Q,e[48]=Y):Y=e[48];let se;e[49]!==l||e[50]!==r||e[51]!==g?(se=r.length>0&&a.jsxs(ir,{children:[a.jsx(or,{children:g("taskBoard.taskBoard.assignProjectButton")}),a.jsxs(cr,{className:"w-64",children:[a.jsx(Ce,{onClick:()=>l(null),children:g("taskBoard.taskDialog.noProject")}),r.map(le=>a.jsx(Ce,{className:"gap-2",onClick:()=>l(le.repo),children:a.jsx(va,{entry:le})},le.id))]})]}),e[49]=l,e[50]=r,e[51]=g,e[52]=se):se=e[52];let H;e[53]!==g?(H=g("taskBoard.taskBoard.dueDateButton"),e[53]=g,e[54]=H):H=e[54];let ee;e[55]!==H?(ee=a.jsx(or,{children:H}),e[55]=H,e[56]=ee):ee=e[56];let q;e[57]!==u?(q=a.jsx(cr,{className:"w-auto p-0",children:a.jsx(ka,{mode:"single",onSelect:le=>le&&u(le),initialFocus:!0})}),e[57]=u,e[58]=q):q=e[58];let Z;e[59]!==ee||e[60]!==q?(Z=a.jsxs(ir,{children:[ee,q]}),e[59]=ee,e[60]=q,e[61]=Z):Z=e[61];let X;e[62]!==o||e[63]!==v||e[64]!==g?(X=v.length>0&&a.jsxs(ir,{children:[a.jsx(or,{children:g("taskBoard.taskBoard.addTagButton")}),a.jsx(cr,{children:v.map(le=>a.jsxs(Ce,{onClick:()=>o(le.id),children:[a.jsx("span",{className:"size-2 rounded-full",style:{backgroundColor:qt(le.color)}}),le.name]},le.id))})]}),e[62]=o,e[63]=v,e[64]=g,e[65]=X):X=e[65];let re;e[66]===Symbol.for("react.memo_cache_sentinel")?(re=a.jsx(ca,{}),e[66]=re):re=e[66];let G;e[67]!==g?(G=g("taskBoard.taskBoard.deleteSelectedButton"),e[67]=g,e[68]=G):G=e[68];let ne;e[69]!==x||e[70]!==G?(ne=a.jsx(Ce,{variant:"destructive",onClick:x,children:G}),e[69]=x,e[70]=G,e[71]=ne):ne=e[71];let ce;e[72]!==D||e[73]!==E||e[74]!==Y||e[75]!==se||e[76]!==Z||e[77]!==X||e[78]!==ne?(ce=a.jsxs(We,{align:"center",side:"top",children:[D,E,Y,se,Z,X,re,ne]}),e[72]=D,e[73]=E,e[74]=Y,e[75]=se,e[76]=Z,e[77]=X,e[78]=ne,e[79]=ce):ce=e[79];let ue;e[80]!==ce||e[81]!==S?(ue=a.jsxs(Ge,{children:[S,ce]}),e[80]=ce,e[81]=S,e[82]=ue):ue=e[82];let oe;e[83]!==f||e[84]!==g?(oe=f&&a.jsxs("button",{type:"button",onClick:f,className:"flex items-center gap-1.5 classic:rounded-full compact:rounded-lg border border-border px-3 py-1.5 text-sm font-medium text-foreground transition-colors hover:bg-accent",children:[a.jsx(al,{size:14}),g("taskBoard.taskBoard.autoFix")]}),e[83]=f,e[84]=g,e[85]=oe):oe=e[85];let R;e[86]!==h||e[87]!==g?(R=h&&a.jsxs("button",{type:"button",onClick:h,className:"flex items-center gap-1.5 classic:rounded-full compact:rounded-lg border border-border px-3 py-1.5 text-sm font-medium text-foreground transition-colors hover:bg-accent",children:[a.jsx(kl,{size:14}),g("taskBoard.taskBoard.rerun")]}),e[86]=h,e[87]=g,e[88]=R):R=e[88];let O;e[89]!==g?(O=g("taskBoard.taskBoard.clearSelectionButton"),e[89]=g,e[90]=O):O=e[90];let fe;e[91]!==g?(fe=g("taskBoard.taskBoard.clearSelectionButton"),e[91]=g,e[92]=fe):fe=e[92];let de;e[93]===Symbol.for("react.memo_cache_sentinel")?(de=a.jsx(Ht,{size:16}),e[93]=de):de=e[93];let be;e[94]!==m||e[95]!==O||e[96]!==fe?(be=a.jsx("button",{type:"button","aria-label":O,title:fe,onClick:m,className:"flex size-8 shrink-0 items-center justify-center classic:rounded-full compact:rounded-lg text-muted-foreground transition-colors hover:bg-accent hover:text-foreground",children:de}),e[94]=m,e[95]=O,e[96]=fe,e[97]=be):be=e[97];let Ne;return e[98]!==ue||e[99]!==oe||e[100]!==R||e[101]!==be||e[102]!==j?(Ne=a.jsx("div",{className:"pointer-events-none absolute inset-x-0 bottom-6 z-20 flex justify-center",children:a.jsxs("div",{className:"pointer-events-auto flex items-center gap-2 rounded-full bg-background px-3 py-2 card-shadow",children:[j,ue,oe,R,be]})}),e[98]=ue,e[99]=oe,e[100]=R,e[101]=be,e[102]=j,e[103]=Ne):Ne=e[103],Ne}function Ai(t,e){return t.sortOrder-e.sortOrder}function Pg(t){const e=$.c(21),{items:s,members:n,memberByUserId:r,selectedIds:l,onToggleSelect:i,onSelectAllInLane:c,onOpen:o,onCreate:d,onMove:u,onAutoFix:f,onRerun:h,onAssign:x,onPriorityChange:m,onTypeChange:g,onDueDateChange:k,visible:y}=t,v=xa("delivery_lanes_enabled"),[p,b]=W.useState(null);let j;e[0]===Symbol.for("react.memo_cache_sentinel")?(j=[],e[0]=j):j=e[0];const[w,S]=W.useState(j);let C;e[1]===Symbol.for("react.memo_cache_sentinel")?(C=new Map,e[1]=C):C=e[1];const[T,N]=W.useState(C),[_,D]=Pi(),A=W.useRef(null);let L;e[2]===Symbol.for("react.memo_cache_sentinel")?(L=U=>{if(A.current=U,!U)return;const K=he=>{if(he.deltaX!==0||he.deltaY===0||U.scrollWidth<=U.clientWidth)return;for(let ge=he.target;ge&&ge!==U;ge=ge.parentElement)if(ge.hasAttribute("data-lane-scroll"))return;he.preventDefault();const ve=he.deltaMode===1?16:he.deltaMode===2?U.clientWidth:1;U.scrollLeft=U.scrollLeft+he.deltaY*ve};return U.addEventListener("wheel",K,{passive:!1}),()=>{A.current=null,U.removeEventListener("wheel",K)}},e[2]=L):L=e[2];const z=L,P=T.size>0?s.map(U=>{const K=T.get(U.id);return K?{...U,...K}:U}):s;if(T.size>0&&!p){const U=[...T].filter(K=>{const[he,ve]=K,ge=s.find(Ae=>Ae.id===he);return ge?.status===ve.status&&ge.sortOrder===ve.sortOrder});U.length>0&&N(K=>{const he=new Map(K);for(const[ve]of U)he.delete(ve);return he})}jm(A,P.map(Ug).join(","),p===null,y);const E=U=>P.filter(K=>K.status===U).sort(Ai),{lanes:I,hidden:V,hideable:Q}=ld({deliveryEnabled:v,shownLanes:_.shownTaskBoardLanes,occupied:P.map(qg)});let Y;e[3]!==D?(Y=(U,K)=>D(he=>({...he,shownTaskBoardLanes:K?[...he.shownTaskBoardLanes,U]:he.shownTaskBoardLanes.filter(ve=>ve!==U)})),e[3]=D,e[4]=Y):Y=e[4];const se=Y,H=U=>fd({overId:U,statusOf:K=>P.find(he=>he.id===K)?.status});let ee;e[5]!==l?(ee=U=>l.has(U)&&l.size>1?[U,...Array.from(l).filter(K=>K!==U)]:[U],e[5]=l,e[6]=ee):ee=e[6];const q=ee;let Z;e[7]===Symbol.for("react.memo_cache_sentinel")?(Z=(U,K,he)=>{const ve=so(he,U.length);N(ge=>{const Ae=new Map(ge);return U.forEach((Be,Ee)=>Ae.set(Be,{status:K,sortOrder:ve[Ee]})),Ae})},e[7]=Z):Z=e[7];const X=Z;let re;e[8]===Symbol.for("react.memo_cache_sentinel")?(re={activationConstraint:{distance:4}},e[8]=re):re=e[8];let G;e[9]===Symbol.for("react.memo_cache_sentinel")?(G={coordinateGetter:$d},e[9]=G):G=e[9];const ne=Sd(Ua(Nd,re),Ua(Cd,G)),ce=U=>{const K=String(U.active.id),he=H(U.over?.id),ve=P.find(Ee=>Ee.id===K);if(!he||!ve||ve.status===he)return;const ge=q(K),Ae=String(U.over?.id??""),Be=E(he).filter(Ee=>!ge.includes(Ee.id));X(ge,he,qa(Be,Ae.startsWith(Xl)?null:Ae,K))},ue=U=>{const K=String(U.active.id);b(null);const he=H(U.over?.id)??P.find(De=>De.id===K)?.status;if(!he){N(new Map);return}const ve=q(K),ge=E(he),Ae=String(U.over?.id??""),Be=ge.findIndex(De=>De.id===K),Ee=Ae.startsWith(Xl)?ge.length-1:ge.findIndex(De=>De.id===Ae),Ye=Be===-1||Ee===-1?ge:Dd(ge,Be,Ee);if(s.filter(De=>De.status===he).sort(Ai).map(Hg).join()===Ye.map(Og).join()){N(new Map);return}const Tt=Ye.slice(Ye.findIndex(De=>De.id===K)+1).find(De=>!ve.includes(De.id)),Ze=qa(ge.filter(De=>!ve.includes(De.id)),Tt?.id??null,K);X(ve,he,Ze),S(ve),u(ve,he,Ze)},oe=p?P.find(U=>U.id===p):null;let R;e[10]!==p||e[11]!==q?(R=p?q(p):[],e[10]=p,e[11]=q,e[12]=R):R=e[12];const O=R;let fe;e[13]===Symbol.for("react.memo_cache_sentinel")?(fe=U=>{b(String(U.active.id)),S([])},e[13]=fe):fe=e[13];let de;e[14]===Symbol.for("react.memo_cache_sentinel")?(de=()=>{b(null),N(new Map)},e[14]=de):de=e[14];const be=Ei.createPortal,Ne=Td,le=null,xe=oe&&a.jsxs("div",{className:"relative w-[292px] cursor-grabbing",children:[a.jsx(hc,{item:oe,assignee:oe.assigneeId?r.get(oe.assigneeId):void 0,assignedBy:oe.assignedBy?r.get(oe.assignedBy):void 0,selected:l.has(oe.id),onOpen:Fg,className:"w-full shadow-lg"}),O.length>1&&a.jsx("span",{className:"absolute -top-2 -right-2 flex h-5 min-w-5 items-center justify-center rounded-full bg-foreground px-1.5 text-[11px] font-semibold text-background",children:O.length})]});let ae;e[15]!==Ne||e[16]!==xe?(ae=a.jsx(Ne,{dropAnimation:le,children:xe}),e[15]=Ne,e[16]=xe,e[17]=ae):ae=e[17];let Te;return e[18]!==be||e[19]!==ae?(Te=be(ae,document.body),e[18]=be,e[19]=ae,e[20]=Te):Te=e[20],a.jsxs(Bd,{sensors:ne,collisionDetection:_d,onDragStart:fe,onDragOver:ce,onDragEnd:ue,onDragCancel:de,children:[a.jsx("div",{ref:z,className:"min-h-0 flex-1 overflow-x-auto",children:a.jsxs("div",{className:"mx-auto flex h-full w-full max-w-[1680px] gap-3 px-4 pt-6 sm:px-8",children:[I.map(U=>a.jsx(Wg,{status:U,items:E(U),members:n,memberByUserId:r,selectedIds:l,isTarget:oe?.status===U,hiddenIds:O,landedIds:w,onToggleSelect:i,onSelectAllInLane:c,onOpen:o,onCreate:d,onAutoFix:f,onRerun:h,onAssign:x,onPriorityChange:m,onTypeChange:g,onDueDateChange:k,onHide:Q.includes(U)?()=>se(U,!1):void 0},U)),V.length>0&&a.jsx(Kg,{statuses:V,countOf:U=>E(U).length,onShow:U=>se(U,!0)})]})}),Te]})}function Fg(){}function Og(t){return t.id}function Hg(t){return t.id}function qg(t){return t.status}function Ug(t){return`${t.id}:${t.status}`}function Kg(t){const e=$.c(19),{statuses:s,countOf:n,onShow:r}=t,l=J();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=a.jsx(Dr,{size:14,className:"shrink-0 transition-transform group-open:rotate-90"}),e[0]=i):i=e[0];let c;e[1]!==l?(c=l("taskBoard.taskBoard.hiddenColumns"),e[1]=l,e[2]=c):c=e[2];let o;e[3]!==c?(o=a.jsxs("summary",{className:"flex cursor-pointer list-none items-center gap-1.5 px-2 py-1.5 text-sm font-medium text-muted-foreground transition-colors hover:text-foreground [&::-webkit-details-marker]:hidden",children:[i,c]}),e[3]=c,e[4]=o):o=e[4];let d;if(e[5]!==n||e[6]!==r||e[7]!==s||e[8]!==l){let h;e[10]!==n||e[11]!==r||e[12]!==l?(h=x=>{const{label:m,visual:g}=Tr(x,l),k=g.icon;return a.jsxs("div",{"data-hidden-lane":x,className:"flex items-center gap-2 rounded-xl bg-background px-3 py-2.5 card-shadow",children:[a.jsx(k,{size:15,className:F("shrink-0",g.iconClassName)}),a.jsx("span",{className:"text-sm font-medium text-foreground",children:m}),a.jsx("span",{className:"ml-auto text-[11px] font-medium text-muted-foreground",children:n(x)}),a.jsxs(Ge,{children:[a.jsx(Ke,{asChild:!0,children:a.jsx("button",{type:"button","aria-label":l("taskBoard.taskBoard.laneMenuAriaLabel",{lane:m}),className:"flex size-6 shrink-0 items-center justify-center classic:rounded-md compact:rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:a.jsx(pr,{size:15})})}),a.jsx(We,{align:"end",children:a.jsx(Ce,{onClick:()=>r(x),children:l("taskBoard.taskBoard.showColumn")})})]})]},x)},e[10]=n,e[11]=r,e[12]=l,e[13]=h):h=e[13],d=s.map(h),e[5]=n,e[6]=r,e[7]=s,e[8]=l,e[9]=d}else d=e[9];let u;e[14]!==d?(u=a.jsx("div",{className:"flex flex-col gap-2 px-1 pt-1",children:d}),e[14]=d,e[15]=u):u=e[15];let f;return e[16]!==o||e[17]!==u?(f=a.jsxs("details",{className:"group h-full w-[300px] shrink-0 py-1",children:[o,u]}),e[16]=o,e[17]=u,e[18]=f):f=e[18],f}function Wg(t){const e=$.c(100),{status:s,items:n,members:r,memberByUserId:l,selectedIds:i,isTarget:c,hiddenIds:o,landedIds:d,onToggleSelect:u,onSelectAllInLane:f,onOpen:h,onCreate:x,onAutoFix:m,onRerun:g,onAssign:k,onPriorityChange:y,onTypeChange:v,onDueDateChange:p,onHide:b}=t,j=J(),{label:w,visual:S}=Tr(s,j),C=S.icon,T=`${Xl}${s}`;let N;e[0]!==T?(N={id:T},e[0]=T,e[1]=N):N=e[1];const{setNodeRef:_}=Ad(N),D=c&&"bg-muted/50";let A;e[2]!==D?(A=F("flex h-full w-[300px] shrink-0 flex-col rounded-xl py-1 transition-colors",D),e[2]=D,e[3]=A):A=e[3];const L=c?"bg-muted":"bg-background";let z;e[4]!==L?(z=F("sticky top-0 z-10 flex items-center gap-2 px-2 py-1.5 transition-colors",L),e[4]=L,e[5]=z):z=e[5];const P=15,E=F("shrink-0",S.iconClassName.replace(/\banimate-\S+\b/g,"").trim());let I;e[6]!==C||e[7]!==E?(I=a.jsx(C,{size:P,className:E}),e[6]=C,e[7]=E,e[8]=I):I=e[8];let V;e[9]!==w?(V=a.jsx("span",{className:"text-sm font-medium text-foreground",children:w}),e[9]=w,e[10]=V):V=e[10];let Q;e[11]!==n.length?(Q=a.jsx("span",{className:"rounded-md bg-muted px-1.5 text-[11px] font-medium text-muted-foreground",children:n.length}),e[11]=n.length,e[12]=Q):Q=e[12];let Y;e[13]!==w||e[14]!==j?(Y=j("taskBoard.taskBoard.laneMenuAriaLabel",{lane:w}),e[13]=w,e[14]=j,e[15]=Y):Y=e[15];let se;e[16]===Symbol.for("react.memo_cache_sentinel")?(se=a.jsx(pr,{size:15}),e[16]=se):se=e[16];let H;e[17]!==Y?(H=a.jsx(Ke,{asChild:!0,children:a.jsx("button",{type:"button","aria-label":Y,className:"ml-auto flex size-6 shrink-0 items-center justify-center classic:rounded-md compact:rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:se})}),e[17]=Y,e[18]=H):H=e[18];let ee;e[19]!==f||e[20]!==s?(ee=()=>f(s),e[19]=f,e[20]=s,e[21]=ee):ee=e[21];let q;e[22]!==j?(q=j("taskBoard.taskBoard.selectAllInLane"),e[22]=j,e[23]=q):q=e[23];let Z;e[24]!==ee||e[25]!==q?(Z=a.jsx(Ce,{onClick:ee,children:q}),e[24]=ee,e[25]=q,e[26]=Z):Z=e[26];let X;e[27]!==b||e[28]!==j?(X=b&&a.jsx(Ce,{onClick:b,children:j("taskBoard.taskBoard.hideColumn")}),e[27]=b,e[28]=j,e[29]=X):X=e[29];let re;e[30]!==Z||e[31]!==X?(re=a.jsxs(We,{align:"end",children:[Z,X]}),e[30]=Z,e[31]=X,e[32]=re):re=e[32];let G;e[33]!==H||e[34]!==re?(G=a.jsxs(Ge,{children:[H,re]}),e[33]=H,e[34]=re,e[35]=G):G=e[35];let ne;e[36]!==w||e[37]!==j?(ne=j("taskBoard.taskBoard.newTaskInLaneAriaLabel",{lane:w}),e[36]=w,e[37]=j,e[38]=ne):ne=e[38];let ce;e[39]!==w||e[40]!==j?(ce=j("taskBoard.taskBoard.newTaskInLaneTitle",{lane:w}),e[39]=w,e[40]=j,e[41]=ce):ce=e[41];let ue;e[42]!==x||e[43]!==s?(ue=()=>x(s),e[42]=x,e[43]=s,e[44]=ue):ue=e[44];let oe;e[45]===Symbol.for("react.memo_cache_sentinel")?(oe=a.jsx(ts,{size:15}),e[45]=oe):oe=e[45];let R;e[46]!==ne||e[47]!==ce||e[48]!==ue?(R=a.jsx("button",{type:"button","aria-label":ne,title:ce,onClick:ue,className:"flex size-6 shrink-0 items-center justify-center classic:rounded-md compact:rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",children:oe}),e[46]=ne,e[47]=ce,e[48]=ue,e[49]=R):R=e[49];let O;e[50]!==V||e[51]!==Q||e[52]!==G||e[53]!==R||e[54]!==z||e[55]!==I?(O=a.jsxs("div",{className:z,children:[I,V,Q,G,R]}),e[50]=V,e[51]=Q,e[52]=G,e[53]=R,e[54]=z,e[55]=I,e[56]=O):O=e[56];let fe;e[57]!==n?(fe=n.map(Gg),e[57]=n,e[58]=fe):fe=e[58];let de;if(e[59]!==o||e[60]!==n||e[61]!==d||e[62]!==l||e[63]!==r||e[64]!==k||e[65]!==m||e[66]!==p||e[67]!==h||e[68]!==y||e[69]!==g||e[70]!==u||e[71]!==v||e[72]!==i){let xe;e[74]!==o||e[75]!==d||e[76]!==l||e[77]!==r||e[78]!==k||e[79]!==m||e[80]!==p||e[81]!==h||e[82]!==y||e[83]!==g||e[84]!==u||e[85]!==v||e[86]!==i?(xe=ae=>a.jsx(Vg,{item:ae,assignee:ae.assigneeId?l.get(ae.assigneeId):void 0,assignedBy:ae.assignedBy?l.get(ae.assignedBy):void 0,members:r,selected:i.has(ae.id),hidden:o.includes(ae.id),landed:d.includes(ae.id),onToggleSelect:()=>u(ae.id),onOpen:()=>h(ae),onAutoFix:m?()=>m(ae):void 0,onRerun:g?()=>g(ae):void 0,onAssign:k?Te=>k(ae.id,Te):void 0,onPriorityChange:y?Te=>y(ae.id,Te):void 0,onTypeChange:v?Te=>v(ae.id,Te):void 0,onDueDateChange:p?Te=>p(ae.id,Te):void 0},ae.id),e[74]=o,e[75]=d,e[76]=l,e[77]=r,e[78]=k,e[79]=m,e[80]=p,e[81]=h,e[82]=y,e[83]=g,e[84]=u,e[85]=v,e[86]=i,e[87]=xe):xe=e[87],de=n.map(xe),e[59]=o,e[60]=n,e[61]=d,e[62]=l,e[63]=r,e[64]=k,e[65]=m,e[66]=p,e[67]=h,e[68]=y,e[69]=g,e[70]=u,e[71]=v,e[72]=i,e[73]=de}else de=e[73];let be;e[88]!==fe||e[89]!==de?(be=a.jsx(Rd,{items:fe,strategy:zd,children:de}),e[88]=fe,e[89]=de,e[90]=be):be=e[90];let Ne;e[91]!==_||e[92]!==s||e[93]!==be?(Ne=a.jsx("div",{ref:_,"data-lane-scroll":s,className:"flex min-h-0 flex-1 flex-col gap-3 overflow-y-auto px-1 pt-1 pb-16 [scrollbar-width:thin] [&::-webkit-scrollbar]:w-1",children:be}),e[91]=_,e[92]=s,e[93]=be,e[94]=Ne):Ne=e[94];let le;return e[95]!==s||e[96]!==O||e[97]!==Ne||e[98]!==A?(le=a.jsxs("div",{"data-lane":s,className:A,children:[O,Ne]}),e[95]=s,e[96]=O,e[97]=Ne,e[98]=A,e[99]=le):le=e[99],le}function Gg(t){return t.id}function Vg(t){const e=$.c(29);let s,n,r,l;e[0]!==t?({item:n,hidden:s,landed:r,...l}=t,e[0]=t,e[1]=s,e[2]=n,e[3]=r,e[4]=l):(s=e[1],n=e[2],r=e[3],l=e[4]);let i;e[5]!==n.id?(i={id:n.id},e[5]=n.id,e[6]=i):i=e[6];const{attributes:c,listeners:o,setNodeRef:d,transform:u,transition:f,isDragging:h}=Ed(i),x=n.id,m=n.status;let g;e[7]!==c||e[8]!==o?(g={attributes:c,listeners:o},e[7]=c,e[8]=o,e[9]=g):g=e[9];const k=r&&"animate-card-land";let y;e[10]!==k?(y=F("w-full",k),e[10]=k,e[11]=y):y=e[11];let v;e[12]!==u?(v=Id.Translate.toString(u),e[12]=u,e[13]=v):v=e[13];const p=h||s?0:void 0;let b;e[14]!==v||e[15]!==p||e[16]!==f?(b={transform:v,transition:f,opacity:p},e[14]=v,e[15]=p,e[16]=f,e[17]=b):b=e[17];let j;e[18]!==n||e[19]!==l||e[20]!==d||e[21]!==g||e[22]!==y||e[23]!==b?(j=a.jsx(hc,{...l,item:n,dragRef:d,bindings:g,className:y,style:b}),e[18]=n,e[19]=l,e[20]=d,e[21]=g,e[22]=y,e[23]=b,e[24]=j):j=e[24];let w;return e[25]!==n.id||e[26]!==n.status||e[27]!==j?(w=a.jsx("div",{className:"flex","data-flip-id":x,"data-flip-lane":m,children:j}),e[25]=n.id,e[26]=n.status,e[27]=j,e[28]=w):w=e[28],w}function hc(t){const e=$.c(71),{item:s,assignee:n,assignedBy:r,members:l,selected:i,className:c,dragRef:o,bindings:d,style:u,onToggleSelect:f,onOpen:h,onAutoFix:x,onRerun:m,onAssign:g,onPriorityChange:k,onTypeChange:y,onDueDateChange:v}=t,p=J(),b=jg(s);let j;e[0]!==s?(j=ad(s),e[0]=s,e[1]=j):j=e[1];const w=j;let S,C,T,N,_,D,A,L,z,P,E,I;if(e[2]!==d?.attributes||e[3]!==d?.listeners||e[4]!==c||e[5]!==o||e[6]!==s||e[7]!==x||e[8]!==h||e[9]!==m||e[10]!==f||e[11]!==w||e[12]!==i||e[13]!==u||e[14]!==p){C=id(s)?p("taskBoard.taskBoard.blockedBadgeTitle"):null;const re=x&&(s.status==="triage"||s.status==="todo")&&s.assigneeId!==ye,G=m&&!re&&s.assigneeId===ye&&s.status!=="done";S=re?{icon:al,label:p("taskBoard.taskBoard.autoFix"),onClick:x}:G?{icon:kl,label:p("taskBoard.taskBoard.rerun"),onClick:m}:null,L="button",z=o,P=u,E=d?.attributes,I=d?.listeners,e[27]!==h||e[28]!==f?(T=ne=>{ne.shiftKey&&f?f():h()},e[27]=h,e[28]=f,e[29]=T):T=e[29],N=F("group relative flex shrink-0 cursor-grab flex-col gap-3 rounded-xl px-3.5 pt-3.5 pb-2.5 text-left card-shadow active:cursor-grabbing",C?"bg-warning/10 hover:bg-warning/15":"bg-card hover:bg-accent/60",w==="failed"?"card-ring-destructive":C&&"card-ring-warning",i&&"bg-accent",c),A="flex items-start gap-2",D="relative min-w-0 flex-1 text-[14px] font-[450] leading-snug",_=F("block text-foreground line-clamp-2",S&&"group-hover:fade-text-end"),e[2]=d?.attributes,e[3]=d?.listeners,e[4]=c,e[5]=o,e[6]=s,e[7]=x,e[8]=h,e[9]=m,e[10]=f,e[11]=w,e[12]=i,e[13]=u,e[14]=p,e[15]=S,e[16]=C,e[17]=T,e[18]=N,e[19]=_,e[20]=D,e[21]=A,e[22]=L,e[23]=z,e[24]=P,e[25]=E,e[26]=I}else S=e[15],C=e[16],T=e[17],N=e[18],_=e[19],D=e[20],A=e[21],L=e[22],z=e[23],P=e[24],E=e[25],I=e[26];let V;e[30]!==s.title||e[31]!==_?(V=a.jsx("span",{className:_,children:s.title}),e[30]=s.title,e[31]=_,e[32]=V):V=e[32];let Q;e[33]!==S?(Q=S&&a.jsx(hg,{action:S}),e[33]=S,e[34]=Q):Q=e[34];let Y;e[35]!==V||e[36]!==Q||e[37]!==D?(Y=a.jsxs("div",{className:D,children:[V,Q]}),e[35]=V,e[36]=Q,e[37]=D,e[38]=Y):Y=e[38];let se;e[39]!==C?(se=C&&a.jsx("span",{className:"sr-only",children:C}),e[39]=C,e[40]=se):se=e[40];let H;e[41]!==w?(H=w&&a.jsx(yg,{state:w}),e[41]=w,e[42]=H):H=e[42];let ee;e[43]!==Y||e[44]!==se||e[45]!==H||e[46]!==A?(ee=a.jsxs("div",{className:A,children:[Y,se,H]}),e[43]=Y,e[44]=se,e[45]=H,e[46]=A,e[47]=ee):ee=e[47];let q;e[48]!==s.tags?(q=s.tags.length>0&&a.jsxs("div",{className:"flex flex-wrap items-center gap-x-2 gap-y-1.5",children:[s.tags.slice(0,Yl).map(Qg),s.tags.length>Yl&&a.jsxs("span",{className:fs,children:["+",s.tags.length-Yl]})]}),e[48]=s.tags,e[49]=q):q=e[49];let Z;e[50]!==r||e[51]!==n||e[52]!==b||e[53]!==s||e[54]!==l||e[55]!==g||e[56]!==v||e[57]!==k||e[58]!==y?(Z=a.jsx(gg,{item:s,checks:b,assignee:n,assignedBy:r,members:l,onAssign:g,onPriorityChange:k,onTypeChange:y,onDueDateChange:v}),e[50]=r,e[51]=n,e[52]=b,e[53]=s,e[54]=l,e[55]=g,e[56]=v,e[57]=k,e[58]=y,e[59]=Z):Z=e[59];let X;return e[60]!==T||e[61]!==N||e[62]!==ee||e[63]!==q||e[64]!==Z||e[65]!==L||e[66]!==z||e[67]!==P||e[68]!==E||e[69]!==I?(X=a.jsxs("button",{type:L,ref:z,style:P,...E,...I,onClick:T,className:N,children:[ee,q,Z]}),e[60]=T,e[61]=N,e[62]=ee,e[63]=q,e[64]=Z,e[65]=L,e[66]=z,e[67]=P,e[68]=E,e[69]=I,e[70]=X):X=e[70],X}function Qg(t){return a.jsx(uc,{tag:t},t.id)}function Yg(t){const e=$.c(38),{item:s,assignee:n,assignedBy:r,onOpen:l}=t;let i;e[0]!==s.status?(i=Zl(s.status),e[0]=s.status,e[1]=i):i=e[1];const c=i.icon;let o;e[2]!==s?(o=F("shrink-0",Ji(s)),e[2]=s,e[3]=o):o=e[3];let d;e[4]!==c||e[5]!==o?(d=a.jsx(c,{size:16,className:o}),e[4]=c,e[5]=o,e[6]=d):d=e[6];let u;e[7]!==s.title?(u=a.jsx("span",{className:"min-w-0 flex-1 truncate text-sm font-medium text-foreground",children:s.title}),e[7]=s.title,e[8]=u):u=e[8];let f;e[9]!==s?(f=od(s)&&a.jsx(sg,{}),e[9]=s,e[10]=f):f=e[10];let h;e[11]!==s?(h=cd(s)&&a.jsx(ng,{}),e[11]=s,e[12]=h):h=e[12];let x;e[13]!==s.priority?(x=s.priority!=="none"&&a.jsx("span",{className:"hidden sm:inline-flex",children:a.jsx(xg,{priority:s.priority})}),e[13]=s.priority,e[14]=x):x=e[14];let m;e[15]!==s.dueDate?(m=s.dueDate&&a.jsx("span",{className:"hidden sm:inline-flex",children:a.jsx(kg,{iso:s.dueDate})}),e[15]=s.dueDate,e[16]=m):m=e[16];let g;e[17]!==s.tags?(g=s.tags.length>0&&a.jsxs("span",{className:"hidden items-center gap-1.5 sm:inline-flex",children:[s.tags.slice(0,2).map(Zg),s.tags.length>2&&a.jsxs("span",{className:fs,children:["+",s.tags.length-2]})]}),e[17]=s.tags,e[18]=g):g=e[18];let k;e[19]!==r||e[20]!==n||e[21]!==s?(k=a.jsx(fc,{item:s,assignee:n,assignedBy:r}),e[19]=r,e[20]=n,e[21]=s,e[22]=k):k=e[22];let y;e[23]!==s.createdAt?(y=ma(new Date(s.createdAt)),e[23]=s.createdAt,e[24]=y):y=e[24];let v;e[25]!==y?(v=a.jsx("span",{className:"hidden shrink-0 text-[11px] text-muted-foreground/70 sm:inline",children:y}),e[25]=y,e[26]=v):v=e[26];let p;return e[27]!==l||e[28]!==k||e[29]!==v||e[30]!==d||e[31]!==u||e[32]!==f||e[33]!==h||e[34]!==x||e[35]!==m||e[36]!==g?(p=a.jsxs("button",{type:"button",onClick:l,className:"flex items-center gap-3 rounded-xl bg-card px-4 py-3 text-left card-shadow transition-colors hover:bg-accent/60",children:[d,u,f,h,x,m,g,k,v]}),e[27]=l,e[28]=k,e[29]=v,e[30]=d,e[31]=u,e[32]=f,e[33]=h,e[34]=x,e[35]=m,e[36]=g,e[37]=p):p=e[37],p}function Zg(t){return a.jsx(uc,{tag:t},t.id)}function $i(t){const e=$.c(14),{active:s,onClick:n,icon:r,label:l}=t,i=J();let c;e[0]!==l||e[1]!==i?(c=i("taskBoard.taskBoard.layoutViewAriaLabel",{label:l}),e[0]=l,e[1]=i,e[2]=c):c=e[2];const o=s?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground";let d;e[3]!==o?(d=F("flex items-center gap-1.5 rounded-md px-2.5 py-1.5 text-xs font-medium transition-colors",o),e[3]=o,e[4]=d):d=e[4];let u;e[5]!==r?(u=a.jsx(r,{size:14}),e[5]=r,e[6]=u):u=e[6];let f;return e[7]!==s||e[8]!==l||e[9]!==n||e[10]!==c||e[11]!==d||e[12]!==u?(f=a.jsxs("button",{type:"button",onClick:n,"aria-label":c,"aria-pressed":s,className:d,children:[u,l]}),e[7]=s,e[8]=l,e[9]=n,e[10]=c,e[11]=d,e[12]=u,e[13]=f):f=e[13],f}function px(t){const e=$.c(5),{seed:s,children:n}=t;let r;e[0]!==s?(r=()=>{const c=new Bc({defaultOptions:{queries:{staleTime:1/0,gcTime:1/0,retry:!1,refetchOnMount:!1,refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchInterval:!1}}});return s(c),c},e[0]=s,e[1]=r):r=e[1];const[l]=W.useState(r);let i;return e[2]!==n||e[3]!==l?(i=a.jsx("div",{"aria-hidden":"true",inert:!0,className:"pointer-events-none absolute inset-0 select-none overflow-hidden",children:a.jsx(_c,{fallback:null,children:a.jsx(W.Suspense,{fallback:null,children:a.jsx(Ac,{client:l,children:n})})})}),e[2]=n,e[3]=l,e[4]=i):i=e[4],i}const Di=new Date().toISOString();function Pt(t,e,s,n,r,l){return{id:t,organizationId:"preview",title:e,description:null,status:s,priority:r,type:n,assigneeId:null,assignedBy:null,repo:null,dueDate:null,sortOrder:l,keySeq:l,externalUrl:null,previewRoutes:[],source:null,retryAttempts:0,reviewCycleStartedAt:null,threads:[],tags:[],reviewVerdicts:[],createdBy:"preview",createdAt:Di,updatedBy:"preview",updatedAt:Di}}function mx(){return{items:[Pt("p1","Fix checkout shipping estimate","todo","bug","high",1),Pt("p2","Add size guide to product page","todo","feature","medium",2),Pt("p3","Compress hero images","todo","chore","low",3),Pt("p4","Rewrite category descriptions","in_progress","feature","medium",4),Pt("p5","Audit broken redirects","in_progress","chore","high",5),Pt("p6","New arrivals landing page","in_review","feature","high",6),Pt("p7","Speed up search results","done","chore","medium",7),Pt("p8","Black Friday banner","done","feature","urgent",8)],repos:[],columns:[]}}export{px as P,hx as T,mx as m};
|