ryco-cli 0.1.30 → 0.1.31
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/{AcpAdapter-DjP0IHpH.cjs → AcpAdapter-ByUp9-wk.cjs} +71 -51
- package/dist/{AcpAdapter-CKWzfB3Q.mjs → AcpAdapter-CY_ANTKu.mjs} +73 -53
- package/dist/{AcpNativeLogging-Do0LktDb.mjs → AcpNativeLogging-C7PC6imv.mjs} +30 -4
- package/dist/{AcpNativeLogging-5gTPK9Fq.cjs → AcpNativeLogging-OQeAya9d.cjs} +33 -1
- package/dist/{AcpRegistryDriver-BblCFfev.cjs → AcpRegistryDriver-CD9GN7rI.cjs} +3 -3
- package/dist/{AcpRegistryDriver-BzohT-PC.mjs → AcpRegistryDriver-DMZ5VBWJ.mjs} +4 -4
- package/dist/AzureDevOpsSourceControlProvider-5giVYoNi.mjs +2053 -0
- package/dist/AzureDevOpsSourceControlProvider-BKMXEUaN.cjs +2055 -0
- package/dist/{BitbucketSourceControlProvider-D5UVAc9z.mjs → BitbucketSourceControlProvider-BVUBsEUF.mjs} +63 -23
- package/dist/{BitbucketSourceControlProvider-Bvl_q1o2.cjs → BitbucketSourceControlProvider-BWnnrbch.cjs} +62 -22
- package/dist/{BunPTY-Dcl1Lp62.mjs → BunPTY-CMbDQ1Xb.mjs} +1 -1
- package/dist/{ClaudeDriver-DZkz0QPr.cjs → ClaudeDriver-DCrqouOR.cjs} +1373 -191
- package/dist/{ClaudeDriver-BuQ_azDw.mjs → ClaudeDriver-DVOss8cC.mjs} +1375 -193
- package/dist/{CodexDriver-6Ph2cjAW.cjs → CodexDriver-CBQPHJqU.cjs} +258 -28
- package/dist/{CodexDriver-Bi49RIL4.mjs → CodexDriver-DJoTky7Z.mjs} +261 -31
- package/dist/{CodexTextGeneration-C5TIspJA.mjs → CodexTextGeneration-BSgNgfZv.mjs} +6 -6
- package/dist/{CodexTextGeneration-sXPR9eld.cjs → CodexTextGeneration-C9MDQmZm.cjs} +7 -7
- package/dist/{CopilotDriver-Bcdpz6U_.mjs → CopilotDriver-CUkdPXcH.mjs} +78 -20
- package/dist/{CopilotDriver-D6P0xgRX.cjs → CopilotDriver-DbaMDH16.cjs} +76 -18
- package/dist/{CursorDriver-CRnDGwEv.mjs → CursorDriver-B-ZilXJB.mjs} +114 -97
- package/dist/{CursorDriver-DMJ7sGSx.cjs → CursorDriver-DKQqPbKH.cjs} +114 -97
- package/dist/{ForgejoSourceControlProvider-D4jGdaJX.cjs → ForgejoSourceControlProvider-CgpjFECj.cjs} +94 -60
- package/dist/{ForgejoSourceControlProvider-Dl_Fk3RY.mjs → ForgejoSourceControlProvider-DemMYUye.mjs} +95 -61
- package/dist/{GitHubSourceControlProvider-QMe-zymI.cjs → GitHubSourceControlProvider-C4un6hOK.cjs} +218 -119
- package/dist/{GitHubSourceControlProvider-DnwKf0ap.mjs → GitHubSourceControlProvider-CRSDYcjc.mjs} +206 -108
- package/dist/GitLabSourceControlProvider-D8W1ZLPh.cjs +2260 -0
- package/dist/GitLabSourceControlProvider-DpWkJ0M3.mjs +2258 -0
- package/dist/{GrokDriver-jy8JIvYY.cjs → GrokDriver-BQ6G_7ZZ.cjs} +6 -7
- package/dist/{GrokDriver-Bvq1jP3S.mjs → GrokDriver-Buvas9-q.mjs} +5 -6
- package/dist/{Metrics-CnmjpbWk.mjs → Metrics-C3vLS9rz.mjs} +123 -13
- package/dist/{Metrics-C0LSU8s7.cjs → Metrics-DjRPLE98.cjs} +170 -12
- package/dist/{NodePTY-D7tFWuQe.mjs → NodePTY-DgnuBruq.mjs} +1 -1
- package/dist/{OpenCodeDriver-DhyVaBMT.mjs → OpenCodeDriver-BWEZD841.mjs} +183 -49
- package/dist/{OpenCodeDriver-Bu5D19tl.cjs → OpenCodeDriver-qUiX0RLH.cjs} +183 -49
- package/dist/{SideQuestionIsolation-B-aE6aBz.mjs → SideQuestionIsolation-B1T-DsR0.mjs} +1 -1
- package/dist/{SideQuestionIsolation-CtJ4wX83.cjs → SideQuestionIsolation-BPC-Bxsz.cjs} +1 -1
- package/dist/bin.cjs +37021 -10253
- package/dist/bin.mjs +36892 -10178
- package/dist/client/assets/AccountSettings-B88Q_w9Y.js +1 -0
- package/dist/client/assets/AiFocusSettings-Bb0TrCPn.js +1 -0
- package/dist/client/assets/{AnimatedHeight-UXn4-nUd.js → AnimatedHeight-epXOsgdm.js} +1 -1
- package/dist/client/assets/AppearanceSettings-XS9WRVPU.js +1 -0
- package/dist/client/assets/AutomationsDialog-bZckh4Y3.js +1 -0
- package/dist/client/assets/AutomationsSummary-wPFZCF49.js +1 -0
- package/dist/client/assets/BranchToolbar.logic-DjzLKbbB.js +3 -0
- package/dist/client/assets/BrowserPanel-CdBLnnfz.js +1 -0
- package/dist/client/assets/ChatRightPanel-BCINd0vP.js +34 -0
- package/dist/client/assets/ChatThreadRouteView-BFZ0Si-l.js +1 -0
- package/dist/client/assets/ColorSwatchPicker-CGyo99o0.js +1 -0
- package/dist/client/assets/CommandPalette.logic-BIOMtnEQ.js +1 -0
- package/dist/client/assets/CommandPaletteDialog-Db4LH--z.js +2 -0
- package/dist/client/assets/CompositeRoot-DtnwMJKj.js +1 -0
- package/dist/client/assets/ComputerUseSettings-CkqCqDsU.js +1 -0
- package/dist/client/assets/ConnectionsSettings-B9mxExdG.js +7 -0
- package/dist/client/assets/CreatePullRequestDialog-CJ7pNCue.js +1 -0
- package/dist/client/assets/CreatePullRequestDialogHost-n4ZjdSr4.js +1 -0
- package/dist/client/assets/DiagnosticsSettings-f9rFG9re.js +2 -0
- package/dist/client/assets/DiagnosticsSettings.logic-Byf-Bu4S.js +1 -0
- package/dist/client/assets/DialogHandle-C0c_rK3I.js +1 -0
- package/dist/client/assets/{DialogPopup-NfwDyR5c.js → DialogPopup-BKW1PEEa.js} +1 -1
- package/dist/client/assets/DialogRoot-BIubqrv0.js +1 -0
- package/dist/client/assets/DialogTitle-BAX_FLoG.js +1 -0
- package/dist/client/assets/{DialogViewport-B6w_ROOE.js → DialogViewport-C2iOUx0O.js} +1 -1
- package/dist/client/assets/DiffPanel-BkqDt_SS.js +25 -0
- package/dist/client/assets/DisclosureRegion-B8556yU0.js +1 -0
- package/dist/client/assets/DraftChatThreadRouteView-BKgRKJ2w.js +1 -0
- package/dist/client/assets/{ExternalIdentityWeb.logic-BlKX8J9h.js → ExternalIdentityWeb.logic-Cu6suNrN.js} +1 -1
- package/dist/client/assets/GlassSurface-DLYYzRdP.js +1 -0
- package/dist/client/assets/HostedConnectionControls-CoVqtnrK.js +1 -0
- package/dist/client/assets/HostedHubRoot-CM2CwPUr.js +2 -0
- package/dist/client/assets/{HostedNativeAuthorizationRoute-j7oSlakZ.js → HostedNativeAuthorizationRoute-Bizmqrh_.js} +2 -2
- package/dist/client/assets/HostedNodeRenameDialog-SXWMsTO0.js +1 -0
- package/dist/client/assets/HostedRelayTrustNotice-BfTyrBi5.js +1 -0
- package/dist/client/assets/InboxStatusGlyph-BPTqzp7l.js +1 -0
- package/dist/client/assets/IntegrationsSettingsPanel-DAPvkV4i.js +1 -0
- package/dist/client/assets/KeybindingsSettings-B8g-YI2O.js +1 -0
- package/dist/client/assets/LazyBrowserPanel-Ds9cdOC_.js +2 -0
- package/dist/client/assets/McpServersSettings-Dw6G3ff3.js +6 -0
- package/dist/client/assets/MobileSheet-DfgXNWbd.js +1 -0
- package/dist/client/assets/ModelTuningDial-DQBAbuNL.js +1 -0
- package/dist/client/assets/NewWorktreeDialog-CDZAJmK6.js +4 -0
- package/dist/client/assets/NodeSecuritySettings-3MELA9ru.js +1 -0
- package/dist/client/assets/NullStore-gT_6_xZE.js +1 -0
- package/dist/client/assets/OnboardingDialog-CAAtNnJf.js +1 -0
- package/dist/client/assets/OpinionatedPluginsSettings-AiDB0Vl4.js +1 -0
- package/dist/client/assets/{PdfAttachmentPreview-C8-hT8KQ.js → PdfAttachmentPreview-BFNW2wjN.js} +2 -2
- package/dist/client/assets/{PhoneGetAppInterstitial-Zh0zpBgT.js → PhoneGetAppInterstitial-D8fwZ8E9.js} +1 -1
- package/dist/client/assets/PhoneHome-YHgHljA0.js +1 -0
- package/dist/client/assets/PhoneSettingsSurface-BVxJppvK.js +2 -0
- package/dist/client/assets/PreviewPanel-BYcEnkv9.js +643 -0
- package/dist/client/assets/ProjectScriptDialog-K34K2Kzm.js +1 -0
- package/dist/client/assets/ProjectsPage-DXnMYLjb.js +1 -0
- package/dist/client/assets/PromoteChatDialog-CAY7_wJ-.js +1 -0
- package/dist/client/assets/ProviderLimitWindow-CK04BSkM.js +1 -0
- package/dist/client/assets/ProviderUpdateLaunchNotification.logic-BMBrDDOC.js +1 -0
- package/dist/client/assets/ProvidersSettingsPanel-C85PX9Es.js +1 -0
- package/dist/client/assets/PullRequestsPage-C0rgfGwB.js +1 -0
- package/dist/client/assets/{QuitShortcutFeedback-Qs9XsuZ4.js → QuitShortcutFeedback-DSkKqETs.js} +1 -1
- package/dist/client/assets/RedactedSensitiveText-DQ0YveQd.js +1 -0
- package/dist/client/assets/RollingText-BzvpP5fa.js +1 -0
- package/dist/client/assets/RootAppShell-BYQ-eGNT.js +6 -0
- package/dist/client/assets/{Separator-B6Esv57Y.js → Separator-DpiW19Vw.js} +1 -1
- package/dist/client/assets/SettingsPage-BCFN7Ju2.js +2 -0
- package/dist/client/assets/SettingsPanels-CP6z2b1x.js +3 -0
- package/dist/client/assets/SettingsPanels.editor-D8U-TWWG.js +1 -0
- package/dist/client/assets/SettingsSelect-DEhNaz3E.js +1 -0
- package/dist/client/assets/Sidebar.logic-D_ODfSpl.js +1 -0
- package/dist/client/assets/SimulatorPanel-DCT6fZ0X.js +1 -0
- package/dist/client/assets/SourceControlSettings-DxUtvPMK.js +1 -0
- package/dist/client/assets/StatisticsPage-C9SrwtM4.js +1 -0
- package/dist/client/assets/StatisticsPanel-BMYLETs0.js +1 -0
- package/dist/client/assets/ThreadLinkList-BN5z5EpS.js +169 -0
- package/dist/client/assets/ThreadTerminalDrawer-CgIFOlR-.js +18 -0
- package/dist/client/assets/ThreadWorkspacePanel-DvXoqQPF.js +3 -0
- package/dist/client/assets/ToolbarRootContext-8FsV9Cpj.js +1 -0
- package/dist/client/assets/TraitsPicker-DcrpJahy.js +1 -0
- package/dist/client/assets/Virtualizer-CwXeUPla.js +1345 -0
- package/dist/client/assets/WorkspacePullRequestPanel-3mlcJn9G.js +1 -0
- package/dist/client/assets/WorkspaceReview-UGbCgXeK.js +2 -0
- package/dist/client/assets/{abnfDiagram-N423BO3Z-ByEe3mC0.js → abnfDiagram-N423BO3Z-DVEM6Scc.js} +1 -1
- package/dist/client/assets/{activity-CwTUF6lv.js → activity-DVCuAejY.js} +1 -1
- package/dist/client/assets/{alert-DQEkrtUJ.js → alert-FV7ZIit_.js} +1 -1
- package/dist/client/assets/alert-dialog-CgXR9tED.js +1 -0
- package/dist/client/assets/app-window-3xtwqZgI.js +1 -0
- package/dist/client/assets/appChrome-COCz-T7w.js +1 -0
- package/dist/client/assets/{appearancePreferences-nFx4MHoI.js → appearancePreferences-NnsvXwBe.js} +1 -1
- package/dist/client/assets/architecture-7GRP2DOG-DXXb_0_g.js +1 -0
- package/dist/client/assets/{architectureDiagram-T3A2C74G-Bd-yxaTr.js → architectureDiagram-T3A2C74G-B6pcKiCj.js} +1 -1
- package/dist/client/assets/{arrow-left-DUOpzEbP.js → arrow-left-Blu3LSE2.js} +1 -1
- package/dist/client/assets/{arrow-right-HOYJnPKw.js → arrow-right-CO3CH0ne.js} +1 -1
- package/dist/client/assets/arrow-up-B69gV2Bq.js +1 -0
- package/dist/client/assets/{arrow-up-right-DHnMKuVA.js → arrow-up-right-BbPGFOLA.js} +1 -1
- package/dist/client/assets/authorization-Ob6YwWiI.js +1 -0
- package/dist/client/assets/autocomplete-RVpjsrDv.js +1 -0
- package/dist/client/assets/ban-BIm2PVkE.js +1 -0
- package/dist/client/assets/{blockDiagram-VBNYF7ZC-CPDBonMC.js → blockDiagram-VBNYF7ZC-WNerGp9V.js} +1 -1
- package/dist/client/assets/{bot-DxjPA7Bw.js → bot-C9nWtaWq.js} +1 -1
- package/dist/client/assets/browserState-jt47YsqD.js +1 -0
- package/dist/client/assets/{c4Diagram-5PPSVZJV-BM6pAiqT.js → c4Diagram-5PPSVZJV-wp1ioOoM.js} +1 -1
- package/dist/client/assets/camera-C13VoW3c.js +1 -0
- package/dist/client/assets/capabilities-CfOhq009.js +1 -0
- package/dist/client/assets/channel-56r2qL2v.js +1 -0
- package/dist/client/assets/{chart-column-Cg7d41tb.js → chart-column-DRv0YtL_.js} +1 -1
- package/dist/client/assets/checkbox-CIIIY9FA.js +1 -0
- package/dist/client/assets/checks-Dw022Bvy.js +1 -0
- package/dist/client/assets/{chunk-2GRJ4B5K-DVKozJ41.js → chunk-2GRJ4B5K-DRl3ILpc.js} +1 -1
- package/dist/client/assets/{chunk-4I5QYGJK-BRoMwPkW.js → chunk-4I5QYGJK-CYTRl4bo.js} +1 -1
- package/dist/client/assets/{chunk-5RXB4S5H-DFMKyoqP.js → chunk-5RXB4S5H-VCNwRsOa.js} +1 -1
- package/dist/client/assets/{chunk-6Q2QTUOP-Ba6UENe9.js → chunk-6Q2QTUOP-DnSeKGPG.js} +1 -1
- package/dist/client/assets/{chunk-7Z6QIM7H-B87gYLWH.js → chunk-7Z6QIM7H-Cjilh9TF.js} +1 -1
- package/dist/client/assets/{chunk-GF5L2VYU-DZ840GRQ.js → chunk-GF5L2VYU-CGR7AW0t.js} +1 -1
- package/dist/client/assets/{chunk-I66GZJ75-BO6p4Aqg.js → chunk-I66GZJ75-CXSn8dDu.js} +1 -1
- package/dist/client/assets/{chunk-JQJVKLGR-5dTfVinz.js → chunk-JQJVKLGR-Dro-75lU.js} +1 -1
- package/dist/client/assets/{chunk-KBJHAD2P-BeWfBZdP.js → chunk-KBJHAD2P-BDqN2kVf.js} +1 -1
- package/dist/client/assets/{chunk-NSK5VX7P-DuRkdn5k.js → chunk-NSK5VX7P-DGo5UczH.js} +1 -1
- package/dist/client/assets/{chunk-QR6OTTB3-Duz4Y_uE.js → chunk-QR6OTTB3-RWuyWnBI.js} +1 -1
- package/dist/client/assets/{chunk-UBXNYLIW-D-z8URgN.js → chunk-UBXNYLIW-BPRzeB0w.js} +1 -1
- package/dist/client/assets/{chunk-W5SLKNZC-AGjFjjoJ.js → chunk-W5SLKNZC-DYWocTFi.js} +1 -1
- package/dist/client/assets/{chunk-WRU74C26-BgY3UiXB.js → chunk-WRU74C26-ChbB1jY3.js} +1 -1
- package/dist/client/assets/circle-stop-D8B4hRpY.js +1 -0
- package/dist/client/assets/circle-x-CNLfrTqR.js +1 -0
- package/dist/client/assets/classDiagram-JCYQIIEL-DGvmFev3.js +1 -0
- package/dist/client/assets/classDiagram-v2-OCEON4UE-DGvmFev3.js +1 -0
- package/dist/client/assets/{clipboard-copy-BWf3JuTE.js → clipboard-copy-DGi8FKNO.js} +1 -1
- package/dist/client/assets/clock-3-DmJ4_XPI.js +1 -0
- package/dist/client/assets/clock-DZIuPtNG.js +1 -0
- package/dist/client/assets/color-picker-BdBXje-a.js +1 -0
- package/dist/client/assets/columns-2-CWlMOClK.js +1 -0
- package/dist/client/assets/combobox-Dtjtf7AB.js +1 -0
- package/dist/client/assets/{cynefin-OW5HDTMX-BuOAGqlK.js → cynefin-OW5HDTMX-TuShvMuM.js} +1 -1
- package/dist/client/assets/{cynefinDiagram-MW4NZA55-DqV0Aokp.js → cynefinDiagram-MW4NZA55-B0Edt2Em.js} +1 -1
- package/dist/client/assets/{dagre-VZM6K2ZE-D_GFquDW.js → dagre-VZM6K2ZE-D-eiuqHx.js} +1 -1
- package/dist/client/assets/{data-list-BJCq3CVP.js → data-list-BAx6jBY1.js} +1 -1
- package/dist/client/assets/desktopUpdateAtoms-BjrLa3tl.js +1 -0
- package/dist/client/assets/desktopWorkspace-C2wXVBhc.js +1 -0
- package/dist/client/assets/{deviceName-C2N8ZRX3.js → deviceName-B4youG0v.js} +1 -1
- package/dist/client/assets/{diagram-7IWD3JNH-B1wlsNg2.js → diagram-7IWD3JNH-DgM6lMlR.js} +1 -1
- package/dist/client/assets/{diagram-B4RE2ZJO-D-CYoym7.js → diagram-B4RE2ZJO-CyHNDjzV.js} +1 -1
- package/dist/client/assets/{diagram-LBJQPF4R-DqJ9NCqt.js → diagram-LBJQPF4R-DDzuLIN5.js} +1 -1
- package/dist/client/assets/{diagram-Q27KOJAE-3yp1D2u4.js → diagram-Q27KOJAE-BaBvK9QB.js} +1 -1
- package/dist/client/assets/{diagram-UB23O5K3-Byp25nGC.js → diagram-UB23O5K3-CzZ2ewuZ.js} +1 -1
- package/dist/client/assets/dialogWords-Cg0YkJVg.js +1 -0
- package/dist/client/assets/diffRouteSearch-D2MKN_ah.js +1 -0
- package/dist/client/assets/disclosureMotion-cbMJn5-z.js +1 -0
- package/dist/client/assets/{download-DsYNYJeu.js → download-TvtXS4hE.js} +1 -1
- package/dist/client/assets/{ebnfDiagram-BXEA7PRR-B_IM1l6o.js → ebnfDiagram-BXEA7PRR-CL1vdOKi.js} +1 -1
- package/dist/client/assets/editorPreferences-DqKyA-2Z.js +1 -0
- package/dist/client/assets/ellipsis-CDK1dNFZ.js +1 -0
- package/dist/client/assets/ellipsis-vertical-CwzEUTwV.js +1 -0
- package/dist/client/assets/{empty-BbJHvskr.js → empty-BovKoxbn.js} +1 -1
- package/dist/client/assets/{erDiagram-JOGREHBK--OtcrCRJ.js → erDiagram-JOGREHBK-DmQR2if6.js} +1 -1
- package/dist/client/assets/eventmodeling-NTZA5JFV-D272GIcY.js +1 -0
- package/dist/client/assets/external-link-CJeVJZ7s.js +1 -0
- package/dist/client/assets/eye-BUmrXqzg.js +1 -0
- package/dist/client/assets/file-diff-BWc3mYsz.js +1 -0
- package/dist/client/assets/flowDiagram-UKHOOZJN-DLyS38Mm.js +1 -0
- package/dist/client/assets/folder-git-2-CPxg5wKP.js +1 -0
- package/dist/client/assets/folder-open-DcMymvp1.js +1 -0
- package/dist/client/assets/formatCount-B4KLI651.js +1 -0
- package/dist/client/assets/{ganttDiagram-PKOTCBZU-w0seBi3Q.js → ganttDiagram-PKOTCBZU-1q2nUL92.js} +1 -1
- package/dist/client/assets/git-pull-request-BFPwpm3c.js +1 -0
- package/dist/client/assets/{gitGraph-4MIJSDKK-BOJ0lcSW.js → gitGraph-4MIJSDKK-COtwmv2S.js} +1 -1
- package/dist/client/assets/{gitGraphDiagram-DS77QQ5N-BMfOCCYn.js → gitGraphDiagram-DS77QQ5N-ChsvaxX4.js} +1 -1
- package/dist/client/assets/{group-tVMKGp7Q.js → group-DWWn0dTx.js} +1 -1
- package/dist/client/assets/hammer-BXo-EU88.js +1 -0
- package/dist/client/assets/hostedConnectionCoordinator-BkAE-RhA.js +1 -0
- package/dist/client/assets/{index-BqZvnGNr.js → index-DARIYokI.js} +2 -2
- package/dist/client/assets/{info-A6RAGUB7-acjBTQ5o.js → info-A6RAGUB7-CI2qZ9wW.js} +1 -1
- package/dist/client/assets/{infoDiagram-6WML65LV-DB01Nc2m.js → infoDiagram-6WML65LV-BPmgcTPH.js} +1 -1
- package/dist/client/assets/{input-BDWSVClC.js → input-CCie4mm1.js} +1 -1
- package/dist/client/assets/{ishikawaDiagram-WSZJBQD7-KhZTvm-J.js → ishikawaDiagram-WSZJBQD7-LyS9p3Yg.js} +1 -1
- package/dist/client/assets/{journeyDiagram-NVQOT4AX-C3JCYk-2.js → journeyDiagram-NVQOT4AX-BYaAmN65.js} +1 -1
- package/dist/client/assets/{kanban-definition-27J2QSJJ-Dbo0C1s6.js → kanban-definition-27J2QSJJ-D-pwzqFt.js} +1 -1
- package/dist/client/assets/{key-round-CETZqe3h.js → key-round-BlrUTfxB.js} +1 -1
- package/dist/client/assets/keyboard-DlBdq6sz.js +1 -0
- package/dist/client/assets/label-ChtVI9lp.js +1 -0
- package/dist/client/assets/layers-BB-ruGvd.js +1 -0
- package/dist/client/assets/lifecycleSuggestionPolicy-0ERe_O53.js +1 -0
- package/dist/client/assets/list-checks-BkM_ZRsj.js +1 -0
- package/dist/client/assets/loader-3vQnfqIT.js +1 -0
- package/dist/client/assets/{log-out-D5-aSBAz.js → log-out-CKq9YiLY.js} +1 -1
- package/dist/client/assets/{logging-B_qXVrk6.js → logging-CCg76rgn.js} +1 -1
- package/dist/client/assets/main-Ch0bwS-M.js +9 -0
- package/dist/client/assets/main-Di0isH9D.css +2 -0
- package/dist/client/assets/{mermaid-parser.core-B6Q-3x_q.js → mermaid-parser.core-RK9ah5RM.js} +2 -2
- package/dist/client/assets/{mermaidEngine-DksLcesB.js → mermaidEngine-Dr8UsPhH.js} +3 -3
- package/dist/client/assets/message-circle-dashed-BrjwqS7-.js +1 -0
- package/dist/client/assets/messageQueueDrain-B7R7Qmq6.js +1 -0
- package/dist/client/assets/messages-square-cDTkDJv_.js +1 -0
- package/dist/client/assets/{mindmap-definition-FAOFIHXS-LaMzRxqw.js → mindmap-definition-FAOFIHXS-DVudWasx.js} +1 -1
- package/dist/client/assets/{packet-AYTQ26CC-BHhg59Si.js → packet-AYTQ26CC-DnkTsVhD.js} +1 -1
- package/dist/client/assets/panels-top-left-B7jZiLth.js +1 -0
- package/dist/client/assets/path-text-3Rfu6lt8.js +1 -0
- package/dist/client/assets/{pegDiagram-VL7TDLO6-s7l7UD9d.js → pegDiagram-VL7TDLO6-Do5PIp8B.js} +1 -1
- package/dist/client/assets/pencil-Bzg-nc6d.js +1 -0
- package/dist/client/assets/{pie-WAS4IAKB-DygX31Z9.js → pie-WAS4IAKB-B_nNQOzn.js} +1 -1
- package/dist/client/assets/{pieDiagram-7S7Q4E2Y-bb6I9TtZ.js → pieDiagram-7S7Q4E2Y-D_IG4xwA.js} +1 -1
- package/dist/client/assets/{play-DUvOxTpL.js → play-DpXXQ1qB.js} +1 -1
- package/dist/client/assets/popover-OWEv6cQz.js +48 -0
- package/dist/client/assets/presentationTier-DPVAxTK4.js +1 -0
- package/dist/client/assets/previewRouteSearch-BjZdTuSf.js +1 -0
- package/dist/client/assets/primary-Cf-xJExj.js +4 -0
- package/dist/client/assets/primitives-CxTBN7D4.js +1 -0
- package/dist/client/assets/projectCheckouts.logic-DUT4AxXr.js +1 -0
- package/dist/client/assets/projectPaths-B8aVmOZX.js +1 -0
- package/dist/client/assets/projectPreferences-CzWBItFj.js +1 -0
- package/dist/client/assets/providerCapabilities-B2YOPsLN.js +1 -0
- package/dist/client/assets/providerDriverMeta-BHHL9uw0.js +1 -0
- package/dist/client/assets/providerModels-v9PYbzRE.js +1 -0
- package/dist/client/assets/providerStatus-CDPaqb0S.js +1 -0
- package/dist/client/assets/pullRequestsModel.logic-Dv_om_C4.js +1 -0
- package/dist/client/assets/{qr-code-dbkTo07n.js → qr-code-BlbiBIwH.js} +1 -1
- package/dist/client/assets/{qr-code-D4CtBq2F.js → qr-code-DywzVgQC.js} +1 -1
- package/dist/client/assets/{quadrantDiagram-CIZ2JOQS-Cj1Y68ZF.js → quadrantDiagram-CIZ2JOQS-DY6fJyrM.js} +1 -1
- package/dist/client/assets/{radar-RG4KPBEZ-FHM3ftPp.js → radar-RG4KPBEZ-D9689I5m.js} +1 -1
- package/dist/client/assets/radio-group-DVwD6Cuy.js +1 -0
- package/dist/client/assets/{railroad-74A4TZTK-CPMn18Cm.js → railroad-74A4TZTK-DVzWbQnl.js} +1 -1
- package/dist/client/assets/railroad-abnf-HS5TGJTU-C_2P6umA.js +1 -0
- package/dist/client/assets/railroad-ebnf-LZEXJU2U-aGlR3R3z.js +1 -0
- package/dist/client/assets/railroad-peg-WCYAUIDC-DCB9oE8y.js +1 -0
- package/dist/client/assets/{railroadDiagram-AXF67PYL-DyV3SuDj.js → railroadDiagram-AXF67PYL-D1oJ6Jtl.js} +1 -1
- package/dist/client/assets/readCache-B7cDPz2O.js +1 -0
- package/dist/client/assets/{refresh-cw-CgDa2Ok_.js → refresh-cw-CRUTivd6.js} +1 -1
- package/dist/client/assets/{requirementDiagram-LRYGKXZP-_xEAGWaH.js → requirementDiagram-LRYGKXZP-7RM8iREp.js} +1 -1
- package/dist/client/assets/rotate-ccw-BE2ZCwL6.js +1 -0
- package/dist/client/assets/roving-radio-group-NMPWrDqe.js +1 -0
- package/dist/client/assets/rows-2-DDS4dGTX.js +1 -0
- package/dist/client/assets/runtime-DjjjAcTE.js +18 -0
- package/dist/client/assets/safePolygon-C1AzMRS4.js +1 -0
- package/dist/client/assets/{sankeyDiagram-W5VNT64P-Clf6oTLi.js → sankeyDiagram-W5VNT64P-C1tKAPGN.js} +1 -1
- package/dist/client/assets/{save-C8h0AMdl.js → save-OZdkPs_y.js} +1 -1
- package/dist/client/assets/scroll-area-80P7vbjw.js +1 -0
- package/dist/client/assets/{scrollEdges-BXYnwntN.js → scrollEdges-C0Oc-5qi.js} +1 -1
- package/dist/client/assets/select-Cb9FUPHD.js +1 -0
- package/dist/client/assets/separator-CO8bC7Wc.js +1 -0
- package/dist/client/assets/{sequenceDiagram-SI44F4Z6-CcYtQLSe.js → sequenceDiagram-SI44F4Z6-DGVpb7jL.js} +1 -1
- package/dist/client/assets/settings-2-PrRDu6Lc.js +1 -0
- package/dist/client/assets/settingsLayout-CRFNCk_D.js +1 -0
- package/dist/client/assets/sheet-C5DW7qVO.js +1 -0
- package/dist/client/assets/{shield-DPC4oHTi.js → shield-CBHYqlkR.js} +1 -1
- package/dist/client/assets/{shield-alert-CwH36qZb.js → shield-alert-Dc2cGwyR.js} +1 -1
- package/dist/client/assets/{shield-check-CGD7sEeF.js → shield-check-_wl7R4Js.js} +1 -1
- package/dist/client/assets/sidebar-0BBaFNm3.js +1 -0
- package/dist/client/assets/sidebarProjectFolders-BjWzbt8C.js +3 -0
- package/dist/client/assets/sidebarProjectGrouping-nQRStWrZ.js +1 -0
- package/dist/client/assets/sidebarStatusText-BBKuNies.js +1 -0
- package/dist/client/assets/sidebarUndo-Dfq1lvyF.js +1 -0
- package/dist/client/assets/{skeleton-rS3IgBob.js → skeleton-DfUe6VV_.js} +1 -1
- package/dist/client/assets/sliders-horizontal-BGXkwvKv.js +1 -0
- package/dist/client/assets/sliding-tabs-BnDSjRU3.js +39 -0
- package/dist/client/assets/{smartphone-DgVJfbv3.js → smartphone-OEAQOTdv.js} +1 -1
- package/dist/client/assets/spinner-lHRJWsym.js +1 -0
- package/dist/client/assets/square-B05NKv3e.js +1 -0
- package/dist/client/assets/{star-Cqay-Cae.js → star-C8mHmfZu.js} +1 -1
- package/dist/client/assets/{stateDiagram-OKZ733FA-DEKURpRP.js → stateDiagram-OKZ733FA-CCOAegCG.js} +1 -1
- package/dist/client/assets/stateDiagram-v2-UEYNNEHI-D60qqBed.js +1 -0
- package/dist/client/assets/storeSelectors-BichCKDC.js +1 -0
- package/dist/client/assets/surfaceMorph-BTRijmlU.js +1 -0
- package/dist/client/assets/{swimlanes-SLNWSIFB-DrR6sbi6.js → swimlanes-SLNWSIFB-CFsLYT4h.js} +1 -1
- package/dist/client/assets/swimlanesDiagram-ULZ7WXOC-D0SaJgSn.js +8 -0
- package/dist/client/assets/switch-oQc7Ifbl.js +1 -0
- package/dist/client/assets/text-wrap-DSRdSfDm.js +1 -0
- package/dist/client/assets/textarea-VyiIZ0wQ.js +1 -0
- package/dist/client/assets/threadPriorityRefreshRuntime-H656C1J_.js +1 -0
- package/dist/client/assets/ticker-CPutfhZ4.js +1 -0
- package/dist/client/assets/{timeline-definition-Z64GVDOM-bQJvmJx5.js → timeline-definition-Z64GVDOM-B4agmO7R.js} +1 -1
- package/dist/client/assets/toggle-DFqtCPt-.js +1 -0
- package/dist/client/assets/toggle-group-C5ICmqkI.js +1 -0
- package/dist/client/assets/{tokenModePresentation-BkS-mry_.js → tokenModePresentation-umDRm4k1.js} +1 -1
- package/dist/client/assets/tooltip-DbqhseXd.js +1 -0
- package/dist/client/assets/{treeView-Q6P3EWNA-D4Ex5QTp.js → treeView-Q6P3EWNA-C_S3udFB.js} +1 -1
- package/dist/client/assets/{treemap-WGGIJYW6-C4B6Y6qM.js → treemap-WGGIJYW6-B-kUSAkE.js} +1 -1
- package/dist/client/assets/undo-2-lyluTGMW.js +1 -0
- package/dist/client/assets/{unplug-B1dczi-t.js → unplug-D6iu-qlh.js} +1 -1
- package/dist/client/assets/usage-ClF-eUmy.js +1 -0
- package/dist/client/assets/useActiveIndicator-R5NWu8Fg.js +1 -0
- package/dist/client/assets/useAppSidebarCollapsed-BbMxfio5.js +1 -0
- package/dist/client/assets/useAppearancePreference-Ix13pMKy.js +1 -0
- package/dist/client/assets/useAtlassian-BYDCc9lv.js +0 -0
- package/dist/client/assets/useCheckoutResolution-CR-oOp5-.js +1 -0
- package/dist/client/assets/useDesktopRelaunchGuard-Jmh615iZ.js +1 -0
- package/dist/client/assets/useDiffFileNavigation-DeuzdD5E.js +15 -0
- package/dist/client/assets/useDiffLayout-DhcXwhBL.js +1 -0
- package/dist/client/assets/useEnvironmentSettingsTarget-DM6BRDT7.js +1 -0
- package/dist/client/assets/useFocus-CV0KIZwg.js +1 -0
- package/dist/client/assets/useGit-CUcs7h5_.js +1 -0
- package/dist/client/assets/useGitBranchSearch-CeKFtnCL.js +1 -0
- package/dist/client/assets/useHostedDraftExecutionTarget-DvQU5UOq.js +1 -0
- package/dist/client/assets/useLabelableId-CEgCRi6q.js +1 -0
- package/dist/client/assets/useLandingFlash-BfOOlFtW.js +1 -0
- package/dist/client/assets/useLogicalProjectSnapshots-CRNZke74.js +1 -0
- package/dist/client/assets/useNavigate-sQZthdyT.js +1 -0
- package/dist/client/assets/usePageLeadingInsetClass-Bf4nUvx4.js +1 -0
- package/dist/client/assets/usePhoneThreadActions-VaQ-mZex.js +1 -0
- package/dist/client/assets/usePopupHandleStore-DimKo2Yy.js +1 -0
- package/dist/client/assets/usePopupViewport-YeqX_UM3.js +1 -0
- package/dist/client/assets/usePresentationTier-B9kCQ4YH.js +1 -0
- package/dist/client/assets/useProject-Kt74Z12J.js +1 -0
- package/dist/client/assets/useProviderOptionsUpdater-CTzNh2B7.js +2 -0
- package/dist/client/assets/usePullRequestFilesViewed-D5Snmzys.js +1 -0
- package/dist/client/assets/usePullRequestsModel-DJL5HHbP.js +40 -0
- package/dist/client/assets/useScrollLock-CLZ31xsK.js +1 -0
- package/dist/client/assets/useSidebarThreadActions-n6EkLATf.js +6 -0
- package/dist/client/assets/{useStatistics-B76_r68I.js → useStatistics-DD0mYS4J.js} +14 -14
- package/dist/client/assets/{useTheme-B441xg4F.js → useTheme-Bdy-BDs-.js} +1 -1
- package/dist/client/assets/useValueChanged-DoumqMnV.js +1 -0
- package/dist/client/assets/{user-round-CLy1Qy1Y.js → user-round-BPDXr8Gq.js} +1 -1
- package/dist/client/assets/{vennDiagram-T6HMQDX7-8iiroXim.js → vennDiagram-T6HMQDX7-B1UEn_j_.js} +1 -1
- package/dist/client/assets/{vscode-icons-CJBVQtq5.js → vscode-icons-Ccy-gzFN.js} +1 -1
- package/dist/client/assets/{wardley-WFR3VGLG-DpyNUbTc.js → wardley-WFR3VGLG-gPdyDc-7.js} +1 -1
- package/dist/client/assets/{wardleyDiagram-T6FBY63Y-CI7is3QO.js → wardleyDiagram-T6FBY63Y-2aDcwOA4.js} +1 -1
- package/dist/client/assets/workspaceLifecycle-OJ1aKksw.js +3 -0
- package/dist/client/assets/workspaceMetadataProjection-CyEyJhUa.js +1 -0
- package/dist/client/assets/workspaceRouteSearch-CCavUdbH.js +1 -0
- package/dist/client/assets/{wrench-7pbbxqrZ.js → wrench-CPUCA_rn.js} +1 -1
- package/dist/client/assets/wsTransport-C88seBPA.js +15 -0
- package/dist/client/assets/{xychartDiagram-ELKLHX3M-BTEX3m2y.js → xychartDiagram-ELKLHX3M-C1_7Q-1i.js} +1 -1
- package/dist/client/favicon.svg +1 -1
- package/dist/client/index.html +1 -1
- package/dist/collectUint8StreamText-BsLSgI8i.mjs +710 -0
- package/dist/collectUint8StreamText-D5olwfpM.cjs +757 -0
- package/dist/{deviceHostWorker-L8C9wy38.mjs → deviceHostWorker-B-Dn-6An.mjs} +1 -1
- package/dist/{makeManagedServerProvider-CF776SAO.cjs → makeManagedServerProvider-B5tP7tvg.cjs} +1 -1
- package/dist/{makeManagedServerProvider-B90UKjnv.mjs → makeManagedServerProvider-B65ipCxM.mjs} +2 -2
- package/dist/resource-monitor/linux-arm64/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/ryco-resource-monitor.exe +0 -0
- package/dist/resource-monitor/win32-arm64/ryco-resource-monitor.exe +0 -0
- package/dist/resource-monitor/win32-x64/ryco-resource-monitor.exe +0 -0
- package/dist/{runtimeSession-V3RIy8Ao.mjs → runtimeSession-D_BZ-wRH.mjs} +1 -1
- package/dist/{src-CARHuYkT.cjs → src-FmeCeBJ9.cjs} +2291 -72
- package/dist/{src-CtsgPPhb.mjs → src-VTj60bUm.mjs} +1974 -61
- package/package.json +1 -1
- package/dist/AzureDevOpsSourceControlProvider-CKSvfuDS.cjs +0 -190
- package/dist/AzureDevOpsSourceControlProvider-DRWSXTml.mjs +0 -188
- package/dist/GitLabSourceControlProvider-Cj07OTBD.mjs +0 -186
- package/dist/GitLabSourceControlProvider-CvvN5pHt.cjs +0 -188
- package/dist/client/assets/AccountSettings-v6-r6gYl.js +0 -1
- package/dist/client/assets/AiFocusSettings-BVdLON0q.js +0 -1
- package/dist/client/assets/AppearanceSettings-DRChsQnN.js +0 -1
- package/dist/client/assets/BranchToolbar.logic-YN3KjVr9.js +0 -3
- package/dist/client/assets/BrowserPanel-Dxw3stFP.js +0 -1
- package/dist/client/assets/ChatRightPanel-CygpcJiF.js +0 -201
- package/dist/client/assets/ChatThreadRouteView-DYLZFHu0.js +0 -1
- package/dist/client/assets/CommandPaletteDialog-BRvBzP1R.js +0 -1
- package/dist/client/assets/CompositeRoot-BeEGGWwn.js +0 -1
- package/dist/client/assets/ComputerUseSettings-Cq8Pi0ZU.js +0 -1
- package/dist/client/assets/ConnectionsSettings-RSYtexxd.js +0 -7
- package/dist/client/assets/ContextHandoffEndpointLabel-CeGDLNA4.js +0 -4
- package/dist/client/assets/DiagnosticsSettings-CDa6MVx4.js +0 -2
- package/dist/client/assets/DialogHandle-BE7egDQQ.js +0 -1
- package/dist/client/assets/DialogRoot-C4mtzigX.js +0 -1
- package/dist/client/assets/DialogTitle-B_Q4DykI.js +0 -1
- package/dist/client/assets/DialogTrigger-BSqd4Crj.js +0 -1
- package/dist/client/assets/DraftChatThreadRouteView-JW_bXVrM.js +0 -1
- package/dist/client/assets/GlassSurface-DDG4eTlj.js +0 -1
- package/dist/client/assets/HostedConnectionControls-CscV6hm1.js +0 -1
- package/dist/client/assets/HostedHubRoot-gp7-ClBP.js +0 -2
- package/dist/client/assets/HostedNodeRenameDialog-D1DSiTpx.js +0 -1
- package/dist/client/assets/HostedRelayTrustNotice-B9jp4SRh.js +0 -1
- package/dist/client/assets/IntegrationsSettingsPanel-DH7SfWtV.js +0 -2
- package/dist/client/assets/KeybindingsSettings-DkgYYSHS.js +0 -7
- package/dist/client/assets/LazyBrowserPanel-D4e76vc_.js +0 -2
- package/dist/client/assets/McpServersSettings-Dc1kPa-X.js +0 -6
- package/dist/client/assets/MobileSheet-lT--mLEz.js +0 -1
- package/dist/client/assets/NodeSecuritySettings-DcfSx4KT.js +0 -1
- package/dist/client/assets/NullStore-8d2s-Re3.js +0 -1
- package/dist/client/assets/OnboardingDialog-CnLjwM6Z.js +0 -1
- package/dist/client/assets/OpinionatedPluginsSettings-BTJyS3rN.js +0 -1
- package/dist/client/assets/PhoneHome-CIMkuDJF.js +0 -1
- package/dist/client/assets/PhoneSettingsSurface-CfZQxJNI.js +0 -2
- package/dist/client/assets/ProvidersSettingsPanel-DAVSiwE1.js +0 -1
- package/dist/client/assets/RedactedSensitiveText-BHGbQJwB.js +0 -1
- package/dist/client/assets/RootAppShell-T056pByH.js +0 -7
- package/dist/client/assets/SettingsDialog-BERU2Qg7.js +0 -2
- package/dist/client/assets/SettingsPanels-De_XZOQF.js +0 -3
- package/dist/client/assets/SettingsPanels.editor-Dkva9gX_.js +0 -2
- package/dist/client/assets/SourceControlSettings-B4HS17cB.js +0 -1
- package/dist/client/assets/StatisticsPage-Bj2ftFdH.js +0 -1
- package/dist/client/assets/StatisticsPanel-Dw7GBBmd.js +0 -1
- package/dist/client/assets/StatisticsSettingsLink-_XL3ABoI.js +0 -1
- package/dist/client/assets/ThreadTerminalDrawer-CPPzQSXN.js +0 -18
- package/dist/client/assets/ThreadWorkspacePanel-DWKU7Omm.js +0 -2073
- package/dist/client/assets/appChrome-TkWLAGxk.js +0 -1
- package/dist/client/assets/architecture-7GRP2DOG-HS59zfrk.js +0 -1
- package/dist/client/assets/authorization-D8dOcEYq.js +0 -1
- package/dist/client/assets/badge-2AZ3HfVS.js +0 -1
- package/dist/client/assets/capabilities-CsHjxjab.js +0 -1
- package/dist/client/assets/channel-Dn3_cOkm.js +0 -1
- package/dist/client/assets/chevron-right-Dsw16yGn.js +0 -1
- package/dist/client/assets/classDiagram-JCYQIIEL-ZQvrS8No.js +0 -1
- package/dist/client/assets/classDiagram-v2-OCEON4UE-ZQvrS8No.js +0 -1
- package/dist/client/assets/compiler-runtime-C4g8XhC5.js +0 -1
- package/dist/client/assets/desktopWorkspace-_iM6B9Kf.js +0 -1
- package/dist/client/assets/editorPreferences-D8q1ItMW.js +0 -1
- package/dist/client/assets/eventmodeling-NTZA5JFV-Dj71kuPV.js +0 -1
- package/dist/client/assets/flowDiagram-UKHOOZJN-BaAiwuvL.js +0 -1
- package/dist/client/assets/hostedConnectionCoordinator-BuRWCvUG.js +0 -1
- package/dist/client/assets/hubRoutes-jcMPIFy3.js +0 -1
- package/dist/client/assets/kbd-Dxm5Elqj.js +0 -1
- package/dist/client/assets/layers-Dqez1Uq8.js +0 -1
- package/dist/client/assets/liquidGlass-CA2o_Cq0.js +0 -1
- package/dist/client/assets/liquidGlass.worker-icvLJKHf.js +0 -1
- package/dist/client/assets/main-BqSANuAs.css +0 -2
- package/dist/client/assets/main-DAbEANjY.js +0 -9
- package/dist/client/assets/motion-BdscFixQ.js +0 -1
- package/dist/client/assets/palette-92ylWqeC.js +0 -1
- package/dist/client/assets/perfInstrumentation-BT27w4tn.js +0 -1
- package/dist/client/assets/presentationTier-xlIjcFab.js +0 -1
- package/dist/client/assets/primary-DZjgHvyf.js +0 -5
- package/dist/client/assets/providerDriverMeta-T2YbXzuS.js +0 -1
- package/dist/client/assets/providerStatus-DBGvvkyF.js +0 -1
- package/dist/client/assets/radio-group-CRnHYWa8.js +0 -1
- package/dist/client/assets/railroad-abnf-HS5TGJTU-DxU7Mt1k.js +0 -1
- package/dist/client/assets/railroad-ebnf-LZEXJU2U-BYAPVjRd.js +0 -1
- package/dist/client/assets/railroad-peg-WCYAUIDC-BOqgR_X7.js +0 -1
- package/dist/client/assets/runtime-BwHA1GUS.js +0 -18
- package/dist/client/assets/scroll-area-7n2X_RLQ.js +0 -1
- package/dist/client/assets/separator-CL1qjMqJ.js +0 -1
- package/dist/client/assets/settingsLayout-DxsFwhF0.js +0 -1
- package/dist/client/assets/sheet-CGiaw8-i.js +0 -1
- package/dist/client/assets/sidebar-Cc6ANbOP.js +0 -1
- package/dist/client/assets/sidebarProjectFolders-DO2Uv84F.js +0 -4
- package/dist/client/assets/sidebarStatusText-B4AtFXZo.js +0 -1
- package/dist/client/assets/sidebarUndo-gdSrfa4O.js +0 -1
- package/dist/client/assets/square-Cr9X8U6y.js +0 -1
- package/dist/client/assets/src-C3Y_imaX.js +0 -14
- package/dist/client/assets/stateDiagram-v2-UEYNNEHI-CWtHILqh.js +0 -1
- package/dist/client/assets/storeSelectors-CTDWheMy.js +0 -1
- package/dist/client/assets/swimlanesDiagram-ULZ7WXOC-DuaPce9O.js +0 -8
- package/dist/client/assets/switch-DnpJB2xv.js +0 -48
- package/dist/client/assets/toggle-D10FsFoE.js +0 -1
- package/dist/client/assets/toggle-group-BhzbQPEQ.js +0 -1
- package/dist/client/assets/tooltip-BlweKBxc.js +0 -1
- package/dist/client/assets/usage-BBwaxMif.js +0 -1
- package/dist/client/assets/useAppSidebarCollapsed-CFy476E3.js +0 -1
- package/dist/client/assets/useAppearancePreference-Dlh9P8iu.js +0 -1
- package/dist/client/assets/useBaseUiId-DKOjzmu3.js +0 -1
- package/dist/client/assets/useLabelableId-DQbY2GG1.js +0 -1
- package/dist/client/assets/useNavigate-B8oXtF30.js +0 -1
- package/dist/client/assets/usePhoneThreadActions-6DCLiyJ5.js +0 -1
- package/dist/client/assets/usePopupViewport-CNWcP7Od.js +0 -1
- package/dist/client/assets/usePresentationTier-hxB7Yv_Q.js +0 -1
- package/dist/client/assets/useScrollLock-BbKeKZdj.js +0 -1
- package/dist/client/assets/useTriggerFocusGuards-BC4Wb3GI.js +0 -1
- package/dist/client/assets/useValueChanged-BkTbyZdO.js +0 -1
- package/dist/client/assets/workspaceMetadataProjection-aqZEXDrQ.js +0 -1
- package/dist/collectUint8StreamText-BAUF-vzz.mjs +0 -37
- package/dist/collectUint8StreamText-vagpNUMJ.cjs +0 -42
- package/dist/git-9xWsJYIH.mjs +0 -132
- package/dist/git-xIkXFy_l.cjs +0 -218
- package/dist/sourceControl-B0D1Op29.cjs +0 -253
- package/dist/sourceControl-BiEBxN01.mjs +0 -224
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{K as t,q as n}from"./primary-Cf-xJExj.js";import{l as r}from"./wsTransport-C88seBPA.js";import{$i as i,Ei as a,Gi as o,J as s,Mr as c,P as l,Qu as u,Ti as d,Xi as f,Yu as p,Zi as m,Zr as h,Zu as g,ad as _,ai as v,hs as y,id as b,ki as x,oi as S,p as C,rd as w,si as T,ws as E}from"./runtime-DjjjAcTE.js";import{t as D}from"./react-CwJFpaho.js";import{l as O}from"./hostedConnectionCoordinator-BkAE-RhA.js";import{i as k}from"./presentationTier-DPVAxTK4.js";import{t as A}from"./clipboard-copy-DGi8FKNO.js";import{n as j,t as M}from"./play-DpXXQ1qB.js";import{t as N}from"./refresh-cw-CRUTivd6.js";import{t as P}from"./toastHelpers-CSQRKo4F.js";import{f as F,p as ee}from"./authorization-Ob6YwWiI.js";import"./usePresentationTier-B9kCQ4YH.js";import{r as I}from"./editorPreferences-DqKyA-2Z.js";import{a as L,c as R,i as te,o as z,s as B,t as V}from"./select-Cb9FUPHD.js";import{i as ne,r as H,t as U}from"./alert-FV7ZIit_.js";import{a as W,c as re,i as G,l as ie,n as K,o as ae,r as q,s as J,t as oe,u as se}from"./DiagnosticsSettings.logic-Byf-Bu4S.js";import{d as Y,f as ce,l as le,u as ue}from"./settingsLayout-CRFNCk_D.js";var de={name:`clipboard-check`,size:24,node:[[`rect`,{width:`8`,height:`4`,x:`8`,y:`2`,rx:`1`,ry:`1`,key:`tgr4d6`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2`,key:`116196`}],[`path`,{d:`m9 14 2 2 4-4`,key:`df797q`}]]};de.node;var fe=E(de),X=e(D(),1),Z=k();function pe(e){return!e.connected||e.role===`client`?!1:e.primary||e.role===`owner`}function me(e){let t=(0,Z.c)(12),r=b(),i=l(he),a=O(),o;t[0]===r?o=t[1]:(o=e=>r?e.byId[r.environmentId]:void 0,t[0]=r,t[1]=o);let s=S(o),c,u;if(t[2]!==e||t[3]!==i||t[4]!==r||t[5]!==a.machines){let o;t[8]===r?.environmentId?o=t[9]:(o=e=>e.environmentId===r?.environmentId,t[8]=r?.environmentId,t[9]=o);let s=a.machines.find(o);c=n(),u=ee({hosted:c,role:s?s.effectiveRole:r&&!r.primary?null:i.effectiveRole,fresh:i.directoryStatus===`ready`&&(s?s.connectionState===`connected`&&s.canMutate&&s.cacheDisposition===`available`&&s.presence.online:i.transportStatus===`online`),browserCurrent:i.browserStatus===`current`,sessionReady:F(i,e),method:e}),t[2]=e,t[3]=i,t[4]=r,t[5]=a.machines,t[6]=c,t[7]=u}else c=t[6],u=t[7];let d=u;if(!c&&r&&!pe({primary:r.primary,connected:r.connected&&(!s||s.connectionState===`connected`),role:s?.role})){let e;return t[10]===c?e=t[11]:(e={hosted:c,allowed:!1,reason:`Diagnostics require a connected owner session.`},t[10]=c,t[11]=e),e}return d}function he(e){return e}function ge(e){let t=!1,n=!1;return{async refresh(){if(!(t||n)){n=!0,e.onLoading(!0);try{let n=await e.fetch();t||e.onSuccess(n)}catch(n){t||e.onError(n)}finally{n=!1,t||e.onLoading(!1)}}},dispose(){t=!0}}}function _e(e,t){let n=new Map(e.map(e=>[e.identity.pid,e]));return e.filter(e=>{let r=new Set([e.identity.pid]),i=n.get(e.ppid);for(;i&&!r.has(i.identity.pid);){if(t.has(`${i.identity.pid}:${i.identity.startTimeMs}`))return!1;r.add(i.identity.pid),i=n.get(i.ppid)}return!0})}var Q=_(),ve=[{label:`5m`,windowMs:3e5,bucketMs:15e3},{label:`15m`,windowMs:9e5,bucketMs:3e4},{label:`30m`,windowMs:18e5,bucketMs:6e4},{label:`1h`,windowMs:36e5,bucketMs:12e4}];function ye({telemetry:e,paused:t,refresh:n}){let i=b()?.environmentId,[a,o]=(0,X.useState)(0),[s,c]=(0,X.useState)(null),[l,u]=(0,X.useState)(null),[d,f]=(0,X.useState)(!1),[p,g]=(0,X.useState)(!1),[_,v]=(0,X.useState)(!0),[y,x]=(0,X.useState)(new Set),S=(0,X.useRef)(null),C=(0,X.useRef)(t);C.current=t;let w=me(r.serverRetryResourceTelemetry),E=me(r.serverGetResourceTelemetryHistory),D=ve[a]??ve[0],O=(0,X.useRef)(0);(0,X.useEffect)(()=>(O.current+=1,g(!1),()=>{O.current+=1}),[i]),(0,X.useEffect)(()=>{if(c(null),u(null),!E.allowed){f(!1);return}let e=ge({fetch:async()=>{let e=i?h(i)?.server:T().server;if(!e?.getResourceTelemetryHistory)throw Error(`Resource history is unavailable on this server.`);return e.getResourceTelemetryHistory({windowMs:D.windowMs,bucketMs:D.bucketMs})},onSuccess:e=>{c(e),u(null)},onError:e=>u(e instanceof Error?e.message:`Resource history could not be refreshed.`),onLoading:f});S.current=e.refresh;let t=()=>{!C.current&&document.visibilityState===`visible`&&e.refresh()};t();let n=window.setInterval(t,5e3);return document.addEventListener(`visibilitychange`,t),()=>{e.dispose(),S.current=null,window.clearInterval(n),document.removeEventListener(`visibilitychange`,t)}},[i,D,E.allowed,E.reason]);async function k(){if(p||!w.allowed)return;let e=O.current;g(!0);try{let t=i?h(i)?.server:T().server;if(!t?.retryResourceTelemetry)throw Error(`Resource monitor retry is unavailable on this server.`);if(await t.retryResourceTelemetry(),e!==O.current)return;await n(),await S.current?.()}catch(t){e===O.current&&u(t instanceof Error?t.message:`Could not retry resource monitor.`)}finally{e===O.current&&g(!1)}}let A=e?.health,j=_e(e?.processes??[],y).filter(e=>_||e.cpuPercent>0||e.ioReadBytesPerSecond>0||e.ioWriteBytesPerSecond>0||e.category===`server`),M=s?.buckets??[],N=Math.max(1,...M.map(e=>e.maxCpuPercent)),P=Math.max(1,...M.map(e=>Math.max(e.ioReadBytes,e.ioWriteBytes))),F=Math.max(1,...M.map(e=>e.maxRssBytes));return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsxs)(Y,{title:`Resource monitor`,headerAction:(0,Q.jsx)(m,{size:`xs`,variant:`outline`,disabled:p||!w.allowed,onClick:()=>void k(),children:p?`Retrying…`:`Retry monitor`}),children:[(0,Q.jsxs)(`p`,{className:`px-4 sm:px-5 py-3 text-xs text-muted-foreground`,children:[e?`Sampled ${J(e.readAt)} · interval ${q(e.sampleIntervalMs)}`:`Waiting for resource telemetry.`,` `,`CPU may exceed 100% across cores. I/O availability depends on the platform.`]}),(0,Q.jsx)(`dl`,{className:`grid grid-cols-2 gap-px border-t border-border/60 bg-border/60 lg:grid-cols-3`,children:[[`Current CPU`,e?G(e.groups.allRyco.currentCpuPercent):`Loading…`],[`Resident memory`,e?K(e.groups.allRyco.currentRssBytes):`Loading…`],[`Process count`,e?String(e.groups.allRyco.processCount):`Loading…`],[`Read throughput`,e?`${K(e.groups.allRyco.ioReadBytesPerSecond)}/s`:`Loading…`],[`Write throughput`,e?`${K(e.groups.allRyco.ioWriteBytesPerSecond)}/s`:`Loading…`],[`CPU speed limit`,e?.speedLimitPercent==null?`Unknown`:`${e.speedLimitPercent}%`]].map(([e,t])=>(0,Q.jsxs)(`div`,{className:`bg-card px-4 py-4 sm:px-5`,children:[(0,Q.jsx)(`dt`,{className:`text-xs text-muted-foreground`,children:e}),(0,Q.jsx)(`dd`,{className:`mt-1.5 text-xl font-semibold tracking-tight tabular-nums`,children:t})]},e))}),(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[850px] text-left text-xs [&_td]:px-4 [&_td]:py-3`,children:[(0,Q.jsx)(`thead`,{className:`border-y text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:[`Group`,`Processes`,`CPU / time`,`RSS / peak`,`Read / write rate`,`Read / write total`,`Starts / exits`].map(e=>(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e))})}),(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:e?Object.entries(e.groups).map(([e,t])=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsx)(`td`,{children:{allRyco:`All Ryco`,backend:`Backend + agents`,electron:`Desktop`,monitor:`Monitor overhead`}[e]??e}),(0,Q.jsx)(`td`,{children:t.processCount}),(0,Q.jsxs)(`td`,{children:[G(t.currentCpuPercent),(0,Q.jsx)(`div`,{children:q(t.cpuTimeMs)})]}),(0,Q.jsxs)(`td`,{children:[K(t.currentRssBytes),(0,Q.jsx)(`div`,{children:K(t.peakRssBytes)})]}),(0,Q.jsxs)(`td`,{children:[K(t.ioReadBytesPerSecond),`/s`,(0,Q.jsxs)(`div`,{children:[K(t.ioWriteBytesPerSecond),`/s`]})]}),(0,Q.jsxs)(`td`,{children:[K(t.ioReadBytes),(0,Q.jsx)(`div`,{children:K(t.ioWriteBytes)})]}),(0,Q.jsxs)(`td`,{children:[t.processStarts,` / `,t.processExits]})]},e)):null})]})})]}),(0,Q.jsxs)(Y,{title:`Host & collection`,children:[A?(0,Q.jsxs)(`div`,{className:`grid gap-3 border-t px-4 sm:px-5 py-3 text-xs sm:grid-cols-2`,children:[[`native`,`desktop`].map(e=>(0,Q.jsxs)(`div`,{children:[(0,Q.jsxs)(`strong`,{className:`capitalize`,children:[e,`: `,A[e].status]}),(0,Q.jsx)(`p`,{className:`mt-1 text-muted-foreground`,children:A[e].lastSampleAt?`Last sample ${J(A[e].lastSampleAt)}`:`No sample`}),A[e].lastError?(0,Q.jsx)(`p`,{className:`mt-1 text-warning`,children:A[e].lastError}):null]},e)),(0,Q.jsxs)(`p`,{children:[`Monitor `,A.sidecarVersion??`version unavailable`,` · PID`,` `,A.sidecarPid??`unavailable`,` · `,A.restartCount,` restarts`]}),(0,Q.jsxs)(`p`,{children:[(A.collectionDurationMicros/1e3).toFixed(2),` ms collection ·`,` `,A.scannedProcessCount,` scanned · `,A.retainedProcessCount,` retained ·`,` `,A.inaccessibleProcessCount,` inaccessible`]})]}):null,(0,Q.jsxs)(`div`,{className:`border-t px-4 sm:px-5 py-3 text-xs`,children:[(0,Q.jsx)(`h3`,{className:`text-xs font-medium`,children:`Power and background state`}),e?.power?(0,Q.jsx)(`dl`,{className:`mt-3 grid grid-cols-2 gap-3`,children:Object.entries(e.power).map(([e,t])=>(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`dt`,{className:`text-muted-foreground`,children:{idleState:`Idle state`,idleSeconds:`Idle seconds`,onBattery:`On battery`,thermalState:`Thermal state`,speedLimitPercent:`CPU speed limit (%)`,suspended:`Suspended`,lowPowerMode:`Low power mode`,locked:`Screen locked`,updatedAt:`Updated`,stale:`Stale`}[e]??e}),(0,Q.jsx)(`dd`,{children:t===null?`Unknown`:typeof t==`boolean`?t?`Yes`:`No`:String(t)})]},e))}):(0,Q.jsx)(`p`,{className:`mt-2 text-muted-foreground`,children:`Desktop power state is unavailable on this connection.`}),(0,Q.jsxs)(`p`,{className:`mt-2`,children:[`CPU speed limit:`,` `,e?.speedLimitPercent==null?`Unknown`:`${e.speedLimitPercent}%`]})]})]}),(0,Q.jsxs)(Y,{title:`Resource timeline`,headerAction:(0,Q.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,Q.jsx)(`div`,{role:`group`,"aria-label":`Resource history period`,className:`flex gap-1`,children:ve.map((e,t)=>(0,Q.jsx)(m,{size:`xs`,variant:a===t?`secondary`:`outline`,"aria-pressed":a===t,onClick:()=>o(t),children:e.label},e.label))}),(0,Q.jsx)(m,{size:`xs`,variant:`outline`,disabled:d,onClick:()=>void S.current?.(),children:`Refresh`})]}),children:[l?(0,Q.jsx)(`p`,{role:`alert`,className:`px-4 sm:px-5 py-3 text-xs text-destructive`,children:l}):null,(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-3 text-xs text-muted-foreground`,children:s?`${s.totalCpuTimeMs===void 0?`Unavailable`:q(s.totalCpuTimeMs)} total CPU time · ${s.retainedSampleCount} retained samples · ${q(s.sampleIntervalMs)} sampling interval · checked ${J(s.readAt)}`:`Collecting resource history…`}),(0,Q.jsx)(`div`,{className:`grid gap-4 px-4 sm:px-5 pb-4 sm:grid-cols-2`,children:[`cpu`,`memory`,`read`,`write`].map(e=>(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`p`,{className:`mb-2 text-xs font-medium`,children:e===`cpu`?`CPU average / peak`:e===`memory`?`Peak RSS`:e===`read`?`I/O reads`:`I/O writes`}),(0,Q.jsx)(`svg`,{viewBox:`0 0 400 100`,role:`img`,"aria-label":e===`cpu`?`CPU history`:e===`memory`?`Memory history`:e===`read`?`I/O read history`:`I/O write history`,className:`h-24 w-full text-info`,children:M.map((t,n)=>{let r=e===`cpu`?t.maxCpuPercent/N:e===`memory`?t.maxRssBytes/F:(e===`read`?t.ioReadBytes:t.ioWriteBytes)/P,i=t.avgCpuPercent/N;return(0,Q.jsxs)(`g`,{children:[(0,Q.jsxs)(`title`,{children:[new Date(t.startedAt).toLocaleTimeString(),`: average`,` `,G(t.avgCpuPercent),`, peak`,` `,G(t.maxCpuPercent),`, RSS `,K(t.maxRssBytes),`, read `,K(t.ioReadBytes),`, write`,` `,K(t.ioWriteBytes),`, `,t.maxProcessCount,` processes`]}),(0,Q.jsx)(`rect`,{x:n*400/Math.max(1,M.length),y:100-r*100,width:Math.max(1,400/Math.max(1,M.length)-2),height:r*100,fill:`currentColor`,opacity:e===`cpu`?.3:1}),e===`cpu`?(0,Q.jsx)(`rect`,{x:n*400/Math.max(1,M.length),y:100-i*100,width:Math.max(1,400/Math.max(1,M.length)-2),height:i*100,fill:`currentColor`}):null]},t.startedAt)})}),(0,Q.jsxs)(`p`,{className:`text-[11px] text-muted-foreground`,children:[`Scale:`,` `,e===`cpu`?G(N):K(e===`memory`?F:P)]})]},e))}),(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[850px] text-left text-xs [&_td]:px-4 [&_td]:py-3`,children:[(0,Q.jsx)(`thead`,{className:`border-y text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:[`Process`,`CPU avg / peak`,`CPU time`,`RSS / peak`,`I/O read / write`,`Samples / last seen`].map(e=>(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e))})}),(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:s?.topProcesses.map(e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsxs)(`td`,{children:[(0,Q.jsxs)(`details`,{children:[(0,Q.jsxs)(`summary`,{className:`cursor-pointer`,children:[e.name,` (`,e.identity.pid,`)`]}),(0,Q.jsx)(`p`,{className:`max-w-72 break-all font-mono`,children:e.command})]}),(0,Q.jsx)(`div`,{className:`text-muted-foreground`,children:e.category})]}),(0,Q.jsxs)(`td`,{children:[G(e.avgCpuPercent),` / `,G(e.maxCpuPercent)]}),(0,Q.jsx)(`td`,{children:q(e.cpuTimeMs)}),(0,Q.jsxs)(`td`,{children:[K(e.currentRssBytes),` / `,K(e.peakRssBytes)]}),(0,Q.jsx)(`td`,{children:e.ioSemantics===`unavailable`?`Unavailable`:`${K(e.ioReadBytes)} / ${K(e.ioWriteBytes)}`}),(0,Q.jsxs)(`td`,{children:[e.sampleCount,` · `,J(e.lastSeenAt)]})]},`${e.identity.pid}:${e.identity.startTimeMs}`))})]})})]}),(0,Q.jsxs)(Y,{title:`Live process tree`,headerAction:(0,Q.jsx)(m,{size:`xs`,variant:`outline`,"aria-pressed":_,onClick:()=>v(e=>!e),children:_?`Hide idle processes`:`Show idle processes`}),children:[(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[1000px] text-left text-xs [&_td]:px-4 [&_td]:py-3 [&_td]:align-top`,children:[(0,Q.jsx)(`thead`,{className:`border-b text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:[`Process / category`,`PID / parent`,`CPU / time`,`RSS / peak / virtual`,`I/O rate / semantics`,`Wakeups / uptime`].map(e=>(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e))})}),(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:j.map(e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsxs)(`td`,{className:`max-w-80`,children:[(0,Q.jsxs)(`div`,{style:{paddingLeft:Math.min(e.depth,8)*10},children:[e.childPids.length>0?(0,Q.jsx)(m,{size:`xs`,variant:`ghost`,"aria-label":`${y.has(`${e.identity.pid}:${e.identity.startTimeMs}`)?`Expand`:`Collapse`} ${e.name} children`,"aria-expanded":!y.has(`${e.identity.pid}:${e.identity.startTimeMs}`),onClick:()=>x(t=>{let n=new Set(t),r=`${e.identity.pid}:${e.identity.startTimeMs}`;return n.has(r)?n.delete(r):n.add(r),n}),children:y.has(`${e.identity.pid}:${e.identity.startTimeMs}`)?`+`:`−`}):null,(0,Q.jsxs)(`details`,{children:[(0,Q.jsx)(`summary`,{className:`cursor-pointer break-all`,children:e.name}),(0,Q.jsx)(`p`,{className:`mt-2 break-all font-mono`,children:e.command}),(0,Q.jsxs)(`p`,{children:[`First seen `,J(e.firstSeenAt),` · last seen`,` `,J(e.lastSeenAt)]})]})]}),(0,Q.jsxs)(`div`,{className:`mt-1 text-muted-foreground`,children:[e.category,` `,e.electronType,` `,e.electronServiceName,` ·`,` `,e.status]})]}),(0,Q.jsxs)(`td`,{children:[e.identity.pid,` / `,e.ppid]}),(0,Q.jsxs)(`td`,{children:[G(e.cpuPercent),(0,Q.jsx)(`div`,{children:q(e.cpuTimeMs)})]}),(0,Q.jsxs)(`td`,{children:[K(e.residentBytes),(0,Q.jsx)(`div`,{children:K(e.peakResidentBytes)}),(0,Q.jsx)(`div`,{children:K(e.virtualBytes)})]}),(0,Q.jsxs)(`td`,{children:[e.ioSemantics===`unavailable`?`Unavailable`:(0,Q.jsxs)(Q.Fragment,{children:[K(e.ioReadBytesPerSecond),`/s read`,(0,Q.jsxs)(`div`,{children:[K(e.ioWriteBytesPerSecond),`/s write`]}),(0,Q.jsxs)(`div`,{children:[K(e.ioReadBytes),` / `,K(e.ioWriteBytes),` `,`total`]})]}),(0,Q.jsx)(`div`,{className:`text-muted-foreground`,children:e.ioSemantics})]}),(0,Q.jsxs)(`td`,{children:[e.idleWakeupsPerSecond==null?`Unavailable`:`${e.idleWakeupsPerSecond.toFixed(1)}/s`,(0,Q.jsx)(`div`,{children:q(e.runTimeMs)})]})]},`${e.identity.pid}:${e.identity.startTimeMs}`))})]})}),j.length===0?(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-3 text-xs text-muted-foreground`,children:`No active processes in this sample. Show idle processes to include retained idle entries.`}):null]}),(0,Q.jsxs)(Y,{title:`Instrumented application I/O`,children:[(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-3 text-xs text-muted-foreground`,children:`Application read/write counters describe logical work and are separate from operating-system storage bytes.`}),(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[650px] text-left text-xs [&_td]:px-4 [&_td]:py-3`,children:[(0,Q.jsx)(`thead`,{className:`border-y text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:[`Component / operation`,`Read`,`Write`,`Count`,`Duration`].map(e=>(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e))})}),(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:e?.attribution.entries.map(e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsxs)(`td`,{children:[e.component,` / `,e.operation]}),(0,Q.jsx)(`td`,{children:K(e.logicalReadBytes)}),(0,Q.jsx)(`td`,{children:K(e.logicalWriteBytes)}),(0,Q.jsx)(`td`,{children:e.count}),(0,Q.jsx)(`td`,{children:q(e.durationMs)})]},`${e.component}:${e.operation}`))})]})}),e?.attribution.entries.length?null:(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-3 text-xs text-muted-foreground`,children:`No logical I/O attribution captured.`})]})]})}function be({snapshot:e,refresh:t}){let n=b(),i=me(r.serverSignalDiagnosticProcess),[a,o]=(0,X.useState)(null),[s,c]=(0,X.useState)(null),l=(0,X.useRef)({target:n,snapshot:e,allowed:!1}),u=(0,X.useRef)(!1),d=(0,X.useRef)(!0),f=i.allowed;l.current={target:n,snapshot:e,allowed:f},(0,X.useEffect)(()=>(d.current=!0,()=>{d.current=!1}),[]);async function p(e,n){if(u.current||!l.current.allowed)return;let r=l.current.target?.environmentId;u.current=!0,o(e.pid),c(null);try{if(!await T().dialogs.confirm(`${n===`SIGKILL`?`Force kill`:`Interrupt`} process ${e.pid} (${e.command})? ${n===`SIGKILL`?`Unsaved work may be lost.`:`This may stop an active agent or terminal task.`}`)||!d.current||!l.current.allowed||l.current.target?.environmentId!==r)return;if(!l.current.snapshot?.processTree?.processes.find(t=>t.pid===e.pid&&t.startTimeMs===e.startTimeMs)){c(`Process already exited or changed. Refresh diagnostics.`);return}let i=r?h(r)?.server:T().server;if(!i?.signalDiagnosticProcess)throw Error(`Process controls are unavailable on this server.`);let a=await i.signalDiagnosticProcess({pid:e.pid,startTimeMs:e.startTimeMs,signal:n});if(!d.current||l.current.target?.environmentId!==r)return;c(a.signaled?`${n} sent to process ${e.pid}.`:a.message??`Process already exited or is no longer a server child.`),await t()}catch(e){d.current&&l.current.target?.environmentId===r&&c(e instanceof Error?e.message:`Could not signal process.`)}finally{u.current=!1,d.current&&o(null)}}let g=e?.processTree;return(0,Q.jsxs)(Y,{title:`Live descendant processes`,children:[(0,Q.jsxs)(`div`,{className:`grid grid-cols-2 gap-4 px-4 sm:px-5 py-4 text-xs lg:grid-cols-4`,children:[(0,Q.jsxs)(`div`,{children:[`Child processes`,(0,Q.jsx)(`div`,{className:`mt-1 font-mono`,children:g?.processes.length??`Unavailable`})]}),(0,Q.jsxs)(`div`,{children:[`Child CPU`,(0,Q.jsx)(`div`,{className:`mt-1 font-mono`,children:G(g?.totalCpuPercent)})]}),(0,Q.jsxs)(`div`,{children:[`Child RSS`,(0,Q.jsx)(`div`,{className:`mt-1 font-mono`,children:g?K(g.totalRssBytes):`Unavailable`})]}),(0,Q.jsxs)(`div`,{children:[`Server PID`,(0,Q.jsx)(`div`,{className:`mt-1 font-mono`,children:g?.serverPid??e?.liveProcesses.server.pid??`Unavailable`})]})]}),(0,Q.jsxs)(`p`,{className:`px-4 sm:px-5 pb-3 text-xs text-muted-foreground`,children:[`Live children of the selected server. The server and desktop shell are excluded.`,` `,g?`Checked ${J(g.readAt)}.`:`This server has not supplied process diagnostics.`]}),g?.error?(0,Q.jsx)(`p`,{role:`alert`,className:`px-4 sm:px-5 pb-3 text-xs text-destructive`,children:g.error}):null,s?(0,Q.jsx)(`p`,{role:`status`,className:`px-4 sm:px-5 pb-3 text-xs`,children:s}):null,f?null:(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 pb-3 text-xs text-muted-foreground`,children:i.reason??`Process controls require a connected owner session.`}),(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[760px] text-left text-xs [&_td]:px-4 [&_td]:py-3 [&_td]:align-top`,children:[(0,Q.jsx)(`thead`,{className:`border-y text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:[`Process`,`PID / Parent`,`CPU`,`RSS`,`Status / Age`,`Actions`].map(e=>(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e))})}),(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:g?.processes.map(e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsx)(`td`,{className:`max-w-96`,children:(0,Q.jsxs)(`details`,{style:{marginLeft:Math.min(e.depth,8)*10},children:[(0,Q.jsx)(`summary`,{className:`cursor-pointer break-all`,children:e.command.split(/[\\/]/).at(-1)||`Process`}),(0,Q.jsx)(`div`,{className:`mt-2 break-all font-mono`,children:e.command}),(0,Q.jsxs)(`div`,{className:`mt-1 text-muted-foreground`,children:[e.childPids.length,` children · Started`,` `,new Date(e.startTimeMs).toLocaleString()]})]})}),(0,Q.jsxs)(`td`,{className:`font-mono`,children:[e.pid,` / `,e.ppid]}),(0,Q.jsx)(`td`,{children:G(e.cpuPercent)}),(0,Q.jsx)(`td`,{children:K(e.rssBytes)}),(0,Q.jsxs)(`td`,{children:[e.status,(0,Q.jsx)(`div`,{className:`mt-1 text-muted-foreground`,children:e.elapsed})]}),(0,Q.jsx)(`td`,{children:(0,Q.jsxs)(`div`,{className:`flex gap-1`,children:[(0,Q.jsx)(m,{size:`xs`,variant:`outline`,disabled:!f||a!==null,onClick:()=>void p(e,`SIGINT`),children:`Interrupt`}),(0,Q.jsx)(m,{size:`xs`,variant:`outline`,disabled:!f||a!==null,onClick:()=>void p(e,`SIGKILL`),children:`Force kill`})]})})]},`${e.pid}:${e.startTimeMs}`))})]})}),g?.processes.length===0?(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-sm text-muted-foreground`,children:`No live descendant processes.`}):null]})}function xe(e){let t=(0,Z.c)(11),{value:n}=e,{copyToClipboard:r,isCopied:i}=f(),a;t[0]===n?a=t[1]:(a=(0,Q.jsx)(`code`,{className:`break-all text-[11px]`,children:n}),t[0]=n,t[1]=a);let o;t[2]!==r||t[3]!==n?(o=()=>r(n,void 0),t[2]=r,t[3]=n,t[4]=o):o=t[4];let s=i?`Copied`:`Copy`,c;t[5]!==o||t[6]!==s?(c=(0,Q.jsx)(m,{size:`xs`,variant:`ghost`,"aria-label":`Copy trace ID`,onClick:o,children:s}),t[5]=o,t[6]=s,t[7]=c):c=t[7];let l;return t[8]!==a||t[9]!==c?(l=(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[a,c]}),t[8]=a,t[9]=c,t[10]=l):l=t[10],l}function Se(e){let t=(0,Z.c)(2),{children:n}=e,r;return t[0]===n?r=t[1]:(r=n.length>180?(0,Q.jsxs)(`details`,{children:[(0,Q.jsxs)(`summary`,{className:`cursor-pointer break-words`,children:[n.slice(0,180),`…`]}),(0,Q.jsx)(`pre`,{className:`mt-2 max-h-64 overflow-auto whitespace-pre-wrap break-words font-sans`,children:n})]}):(0,Q.jsx)(`span`,{className:`break-words`,children:n}),t[0]=n,t[1]=r),r}function Ce(e){let t=(0,Z.c)(10),{headers:n,children:r,empty:i}=e;if(i){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-sm text-muted-foreground`,children:`No retained records.`}),t[0]=e):e=t[0],e}let a;t[1]===n?a=t[2]:(a=n.map(we),t[1]=n,t[2]=a);let o;t[3]===a?o=t[4]:(o=(0,Q.jsx)(`thead`,{className:`border-b text-muted-foreground`,children:(0,Q.jsx)(`tr`,{children:a})}),t[3]=a,t[4]=o);let s;t[5]===r?s=t[6]:(s=(0,Q.jsx)(`tbody`,{className:`divide-y divide-border/60`,children:r}),t[5]=r,t[6]=s);let c;return t[7]!==o||t[8]!==s?(c=(0,Q.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Q.jsxs)(`table`,{className:`w-full min-w-[680px] text-left text-xs [&_td]:px-4 [&_td]:py-3 [&_td]:align-top`,children:[o,s]})}),t[7]=o,t[8]=s,t[9]=c):c=t[9],c}function we(e){return(0,Q.jsx)(`th`,{className:`px-4 sm:px-5 py-2 font-medium`,children:e},e)}function Te(e){let t=(0,Z.c)(84),{snapshot:n,nowMs:r}=e,i=n?.tracing.summary,a;t[0]===n?.tracing.topSpanNames?a=t[1]:(a=n?.tracing.topSpanNames??[],t[0]=n?.tracing.topSpanNames,t[1]=a);let o=a,s;t[2]===n?.failures.common?s=t[3]:(s=n?.failures.common??[],t[2]=n?.failures.common,t[3]=s);let c=s,l;t[4]===i?.latestWarningAndErrorLogs?l=t[5]:(l=i?.latestWarningAndErrorLogs??[],t[4]=i?.latestWarningAndErrorLogs,t[5]=l);let u=l,d=n?.tracing.retainedSpanCount,f;t[6]===d?f=t[7]:(f=[`Retained spans`,d],t[6]=d,t[7]=f);let p=i?.failureCount,m;t[8]===p?m=t[9]:(m=[`Failures`,p],t[8]=p,t[9]=m);let h=i?.interruptionCount,g;t[10]===h?g=t[11]:(g=[`Interrupted spans`,h],t[10]=h,t[11]=g);let _=i?.slowSpanCount,v;t[12]===_?v=t[13]:(v=[`Slow spans`,_],t[12]=_,t[13]=v);let y=i?.parseErrorCount,b;t[14]===y?b=t[15]:(b=[`Parse errors`,y],t[14]=y,t[15]=b);let x;t[16]===i?x=t[17]:(x=i?q(i.slowSpanThresholdMs):void 0,t[16]=i,t[17]=x);let S;t[18]===x?S=t[19]:(S=[`Slow threshold`,x],t[18]=x,t[19]=S);let C;t[20]!==r||t[21]!==i?(C=i?.firstSpanAt?J(i.firstSpanAt,r):void 0,t[20]=r,t[21]=i,t[22]=C):C=t[22];let w;t[23]===C?w=t[24]:(w=[`First span`,C],t[23]=C,t[24]=w);let T;t[25]!==r||t[26]!==i?(T=i?.lastSpanAt?J(i.lastSpanAt,r):void 0,t[25]=r,t[26]=i,t[27]=T):T=t[27];let E;t[28]===T?E=t[29]:(E=[`Last span`,T],t[28]=T,t[29]=E);let D;t[30]!==v||t[31]!==b||t[32]!==S||t[33]!==w||t[34]!==E||t[35]!==f||t[36]!==m||t[37]!==g?(D=(0,Q.jsx)(`dl`,{className:`grid grid-cols-2 gap-4 px-4 sm:px-5 py-4 text-xs lg:grid-cols-4`,children:[f,m,g,v,b,S,w,E].map(ke)}),t[30]=v,t[31]=b,t[32]=S,t[33]=w,t[34]=E,t[35]=f,t[36]=m,t[37]=g,t[38]=D):D=t[38];let O;t[39]===i?.partialFailure?O=t[40]:(O=i?.partialFailure?(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 pb-3 text-xs text-warning`,children:`Some trace files could not be read. These results are incomplete.`}):null,t[39]=i?.partialFailure,t[40]=O);let k;t[41]===i?k=t[42]:(k=i?(0,Q.jsxs)(`details`,{className:`border-t px-4 sm:px-5 py-3 text-xs`,children:[(0,Q.jsx)(`summary`,{className:`cursor-pointer`,children:`Collection details`}),(0,Q.jsxs)(`div`,{className:`mt-2 space-y-2`,children:[(0,Q.jsxs)(`p`,{children:[`Log levels:`,` `,Object.entries(i.logLevelCounts).map(Oe).join(` · `)||`None`]}),i.scannedFilePaths.map(De)]})]}):null,t[41]=i,t[42]=k);let A;t[43]!==D||t[44]!==O||t[45]!==k?(A=(0,Q.jsxs)(Y,{title:`Trace diagnostics`,children:[D,O,k]}),t[43]=D,t[44]=O,t[45]=k,t[46]=A):A=t[46];let j;t[47]===Symbol.for(`react.memo_cache_sentinel`)?(j=[`Source / category`,`Count`,`Cause`,`Last seen`],t[47]=j):j=t[47];let M=c.length===0,N;if(t[48]!==c||t[49]!==r){let e;t[51]===r?e=t[52]:(e=e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsxs)(`td`,{children:[e.source,(0,Q.jsx)(`div`,{className:`text-muted-foreground`,children:e.category})]}),(0,Q.jsx)(`td`,{className:`font-mono`,children:e.count}),(0,Q.jsx)(`td`,{className:`max-w-96`,children:(0,Q.jsx)(Se,{children:e.sampleMessage})}),(0,Q.jsx)(`td`,{className:`whitespace-nowrap`,children:J(e.latestAt,r)})]},`${e.source}:${e.signature}`),t[51]=r,t[52]=e),N=c.map(e),t[48]=c,t[49]=r,t[50]=N}else N=t[50];let P;t[53]!==M||t[54]!==N?(P=(0,Q.jsx)(Y,{title:`Most common failures`,children:(0,Q.jsx)(Ce,{headers:j,empty:M,children:N})}),t[53]=M,t[54]=N,t[55]=P):P=t[55];let F;t[56]===Symbol.for(`react.memo_cache_sentinel`)?(F=[`Time`,`Level`,`Span`,`Message`,`Trace`],t[56]=F):F=t[56];let ee=u.length===0,I;if(t[57]!==u||t[58]!==r){let e;t[60]===r?e=t[61]:(e=e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsx)(`td`,{className:`whitespace-nowrap`,children:J(e.seenAt,r)}),(0,Q.jsx)(`td`,{children:e.level}),(0,Q.jsx)(`td`,{children:e.spanName}),(0,Q.jsx)(`td`,{className:`max-w-96`,children:(0,Q.jsx)(Se,{children:e.message})}),(0,Q.jsx)(`td`,{children:(0,Q.jsx)(xe,{value:e.traceId})})]},`${e.traceId}:${e.spanId}:${e.seenAt}:${e.level}:${e.message}`),t[60]=r,t[61]=e),I=u.map(e),t[57]=u,t[58]=r,t[59]=I}else I=t[59];let L;t[62]!==ee||t[63]!==I?(L=(0,Q.jsx)(Y,{title:`Span warning and error logs`,children:(0,Q.jsx)(Ce,{headers:F,empty:ee,children:I})}),t[62]=ee,t[63]=I,t[64]=L):L=t[64];let R;t[65]===Symbol.for(`react.memo_cache_sentinel`)?(R=[`Span`,`Count`,`Failures`,`Average`,`Maximum`,`Total`],t[65]=R):R=t[65];let te=o.length===0,z;t[66]===o?z=t[67]:(z=o.map(Ee),t[66]=o,t[67]=z);let B;t[68]!==te||t[69]!==z?(B=(0,Q.jsx)(Y,{title:`Top span names`,children:(0,Q.jsx)(Ce,{headers:R,empty:te,children:z})}),t[68]=te,t[69]=z,t[70]=B):B=t[70];let V;t[71]===Symbol.for(`react.memo_cache_sentinel`)?(V=[`Span`,`Status`,`Duration`,`Ended`,`Trace`],t[71]=V):V=t[71];let ne=!n?.tracing.recentSpans.length,H;t[72]!==r||t[73]!==n?.tracing.recentSpans?(H=n?.tracing.recentSpans.map(e=>(0,Q.jsxs)(`tr`,{children:[(0,Q.jsxs)(`td`,{children:[e.name,e.failureMessage?(0,Q.jsx)(`div`,{className:`mt-1 text-destructive`,children:(0,Q.jsx)(Se,{children:e.failureMessage})}):null]}),(0,Q.jsx)(`td`,{children:e.status}),(0,Q.jsx)(`td`,{children:q(e.durationMs)}),(0,Q.jsx)(`td`,{className:`whitespace-nowrap`,children:J(e.endTime,r)}),(0,Q.jsx)(`td`,{children:(0,Q.jsx)(xe,{value:e.traceId})})]},e.id)),t[72]=r,t[73]=n?.tracing.recentSpans,t[74]=H):H=t[74];let U;t[75]!==ne||t[76]!==H?(U=(0,Q.jsx)(Y,{title:`Recent spans`,children:(0,Q.jsx)(Ce,{headers:V,empty:ne,children:H})}),t[75]=ne,t[76]=H,t[77]=U):U=t[77];let W;return t[78]!==A||t[79]!==P||t[80]!==L||t[81]!==B||t[82]!==U?(W=(0,Q.jsxs)(Q.Fragment,{children:[A,P,L,B,U]}),t[78]=A,t[79]=P,t[80]=L,t[81]=B,t[82]=U,t[83]=W):W=t[83],W}function Ee(e){return(0,Q.jsxs)(`tr`,{children:[(0,Q.jsx)(`td`,{children:e.name}),(0,Q.jsx)(`td`,{children:e.count}),(0,Q.jsx)(`td`,{children:e.failureCount}),(0,Q.jsx)(`td`,{children:q(e.averageDurationMs)}),(0,Q.jsx)(`td`,{children:q(e.maxDurationMs)}),(0,Q.jsx)(`td`,{children:q(e.totalDurationMs)})]},e.name)}function De(e){return(0,Q.jsx)(`p`,{className:`break-all font-mono`,children:e},e)}function Oe(e){let[t,n]=e;return`${t}: ${n}`}function ke(e){let[t,n]=e;return(0,Q.jsxs)(`div`,{children:[(0,Q.jsx)(`dt`,{className:`text-muted-foreground`,children:t}),(0,Q.jsx)(`dd`,{className:`mt-1 font-mono`,children:n??`Unavailable`})]},t)}var Ae=/token|secret|password|passwd|credential|authorization|bearer|api[-_]?key|cookie|session|private[-_]?key|pairing[-_]?code|access[-_]?key|signature|email|proof|ticket/iu;function je(e){return e.replace(/-----BEGIN [^-]*PRIVATE KEY-----[\s\S]*?(?:-----END [^-]*PRIVATE KEY-----|$)/gu,`[redacted]`).replace(/\bBearer\s+[^\s,;"']+/giu,`Bearer [redacted]`).replace(/\b(?:sk-[A-Za-z0-9_-]{8,}|gh[pousr]_[A-Za-z0-9_]{8,}|github_pat_[A-Za-z0-9_]+)\b/gu,`[redacted]`).replace(/\beyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\b/gu,`[redacted]`).replace(/\b((?:access[-_]?token|refresh[-_]?token|token|secret|password|passwd|credential|authorization|api[-_]?key|cookie|pairing[-_]?code|proof|ticket)\s*[=:]\s*)(?:"[^"]*"|'[^']*'|[^\s,;&]+)/giu,`$1[redacted]`).replace(/https?:\/\/[^\s<>"']+/giu,e=>{try{let t=new URL(e);t.username=``,t.password=``,t.hash=``;for(let e of t.searchParams.keys())/token|secret|password|credential|authorization|key|cookie|proof|ticket|signature|code/iu.test(e)&&t.searchParams.set(e,`[redacted]`);return t.toString()}catch{return`[redacted URL]`}})}var Me=`[redacted]`,Ne=Ae;function Pe(e){let t;try{t=new URL(e)}catch{return e}(t.username||t.password)&&(t.username=``,t.password=``);for(let e of t.searchParams.keys())Ne.test(e)&&t.searchParams.set(e,Me);return t.toString()}function Fe(e){return Ie(e,!1)}function Ie(e,t){if(t)return e==null?e:Me;if(typeof e==`string`)return je(Pe(e));if(Array.isArray(e))return e.map(e=>Ie(e,!1));if(typeof e==`object`&&e){let t={};for(let[n,r]of Object.entries(e))t[n]=Ie(r,Ne.test(n));return t}return e}function Le(e){return Fe({generatedAt:e.generatedAt,app:e.app,environments:e.environments.map(e=>({environmentId:e.environmentId,label:e.record?.label??null,connectionState:e.runtime?.connectionState??null,authState:e.runtime?.authState??null,role:e.runtime?.role??null,lastError:e.runtime?.lastError??null,lastErrorAt:e.runtime?.lastErrorAt??null,connectedAt:e.runtime?.connectedAt??null,disconnectedAt:e.runtime?.disconnectedAt??null,pushSequence:e.pushSequence})),providers:e.providers.map(e=>({instanceId:e.instanceId,driver:e.driver,enabled:e.enabled,installed:e.installed,version:e.version,status:e.status,availability:e.availability??`available`,authStatus:e.auth.status,authType:e.auth.type??null,message:e.message??null,unavailableReason:e.unavailableReason??null,checkedAt:e.checkedAt})),observability:e.observability?{logsDirectoryConfigured:e.observability.logsDirectoryPath.length>0,localTracingEnabled:e.observability.localTracingEnabled,otlpTracesEnabled:e.observability.otlpTracesEnabled,otlpMetricsEnabled:e.observability.otlpMetricsEnabled,localMetrics:e.observability.localMetrics?{turnQuiescenceAvgMs:e.observability.localMetrics.turnQuiescenceAvgMs,checkpointDurationP95Ms:e.observability.localMetrics.checkpointDurationP95Ms,wsReconnectCount:e.observability.localMetrics.wsReconnectCount,capturedAt:e.observability.localMetrics.capturedAt}:null}:null,performance:e.performance?{local:{turnQuiescenceAvgMs:e.performance.local.turnQuiescenceAvgMs,checkpointDurationP95Ms:e.performance.local.checkpointDurationP95Ms,latestThreadSnapshotDurationMs:e.performance.local.latestThreadSnapshotDurationMs,threadSnapshotDurationP95Ms:e.performance.local.threadSnapshotDurationP95Ms,wsReconnectCount:e.performance.local.wsReconnectCount,windowSampleCounts:{...e.performance.local.windowSampleCounts},capturedAt:e.performance.local.capturedAt},queues:{...e.performance.queues},traceSink:e.performance.traceSink?{...e.performance.traceSink}:null,snapshotCollectionDurationMs:e.performance.snapshotCollectionDurationMs}:null})}function Re(e){return JSON.stringify(e,null,2)}function ze(e){return(e?.gapCount??0)>0}var Be={connected:`bg-success`,connecting:`bg-warning`,error:`bg-destructive`,disconnected:`bg-muted-foreground/40`},Ve={ready:`bg-success`,warning:`bg-warning`,error:`bg-destructive`,disabled:`bg-muted-foreground/40`};function He(e){let t=(0,Z.c)(4),{className:n}=e,r;t[0]===n?r=t[1]:(r=i(`inline-block size-2 shrink-0 rounded-full`,n),t[0]=n,t[1]=r);let a;return t[2]===r?a=t[3]:(a=(0,Q.jsx)(`span`,{className:r,"aria-hidden":!0}),t[2]=r,t[3]=a),a}function Ue(e){if(!e)return`No push events observed yet.`;let t=[`last #${e.highestSequence??`—`}`,`${e.eventCount} events`,`${e.snapshotCount} snapshots`];return e.gapCount>0?t.push(`${e.gapCount} gap${e.gapCount===1?``:`s`}`):t.push(`no gaps`),t.join(` · `)}function We(e){let t=(0,Z.c)(25),{environmentId:n,record:r,runtime:a,pushSequence:o}=e,s=a?.connectionState??`disconnected`,c=r?.label??n,l=ze(o),u=Be[s]??`bg-muted-foreground/40`,d;t[0]===u?d=t[1]:(d=(0,Q.jsx)(He,{className:u}),t[0]=u,t[1]=d);let f;t[2]!==c||t[3]!==d?(f=(0,Q.jsxs)(`span`,{className:`inline-flex items-center gap-2`,children:[d,c]}),t[2]=c,t[3]=d,t[4]=f):f=t[4];let p=a?.authState?` · auth ${a.authState}`:``,m=a?.role?` · ${a.role}`:``,h;t[5]!==s||t[6]!==p||t[7]!==m?(h=(0,Q.jsxs)(`span`,{className:`block`,children:[`WS `,s,p,m]}),t[5]=s,t[6]=p,t[7]=m,t[8]=h):h=t[8];let g=l?`text-warning`:`text-muted-foreground/70`,_;t[9]===g?_=t[10]:(_=i(`block`,g),t[9]=g,t[10]=_);let v;t[11]===o?v=t[12]:(v=Ue(o),t[11]=o,t[12]=v);let y;t[13]!==_||t[14]!==v?(y=(0,Q.jsx)(`span`,{className:_,children:v}),t[13]=_,t[14]=v,t[15]=y):y=t[15];let b;t[16]===a?b=t[17]:(b=a?.lastError?(0,Q.jsx)(`span`,{className:`block break-all text-destructive`,children:a.lastError}):null,t[16]=a,t[17]=b);let x;t[18]!==y||t[19]!==b||t[20]!==h?(x=(0,Q.jsxs)(`span`,{className:`space-y-0.5`,children:[h,y,b]}),t[18]=y,t[19]=b,t[20]=h,t[21]=x):x=t[21];let S;return t[22]!==x||t[23]!==f?(S=(0,Q.jsx)(ue,{title:f,description:x}),t[22]=x,t[23]=f,t[24]=S):S=t[24],S}function Ge(e){let n=(0,Z.c)(59),{snapshot:r}=e,i=v(Qe),s=S(Ze),l=c(Xe),h=b(),_=u(),y=g(),x=p(),w;n[0]!==_||n[1]!==h?(w=h?h.serverConfig?.providers??[]:_,n[0]=_,n[1]=h,n[2]=w):w=n[2];let E=w,D=r?.observability??(h?h.serverConfig?.observability??null:y),O;n[3]!==x||n[4]!==h?(O=h?h.serverConfig?.availableEditors??[]:x,n[3]=x,n[4]=h,n[5]=O):O=n[5];let k=O,j=r?.performance?.local??null,[M,N]=(0,X.useState)(!1),F;n[6]!==j||n[7]!==D?(F=D?{...D,...j?{localMetrics:j}:{}}:null,n[6]=j,n[7]=D,n[8]=F):F=n[8];let ee=F,L;n[9]!==l||n[10]!==i||n[11]!==s?(L=[...new Set([...Object.keys(i),...Object.keys(s),...Object.keys(l)])].toSorted(),n[9]=l,n[10]=i,n[11]=s,n[12]=L):L=n[12];let R=L,te;n[13]===Symbol.for(`react.memo_cache_sentinel`)?(te={onCopy:Ye,onError:Je},n[13]=te):te=n[13];let{copyToClipboard:z,isCopied:B}=f(te),V;n[14]!==z||n[15]!==R||n[16]!==ee||n[17]!==E||n[18]!==l||n[19]!==i||n[20]!==s||n[21]!==r?.performance?(V=()=>{let e=Le({generatedAt:new Date().toISOString(),app:{version:a,stage:d,isElectron:t,userAgent:typeof navigator>`u`?null:navigator.userAgent},environments:R.map(e=>({environmentId:e,record:i[e]??null,runtime:s[e]??null,pushSequence:l[e]??null})),providers:E,observability:ee,performance:r?.performance??null});z(Re(e),void 0)},n[14]=z,n[15]=R,n[16]=ee,n[17]=E,n[18]=l,n[19]=i,n[20]=s,n[21]=r?.performance,n[22]=V):V=n[22],r?.performance;let ne=V,H=D?.logsDirectoryPath??null,U;n[23]!==k||n[24]!==H||n[25]!==h?(U=()=>{if(!H)return;N(!0);let e=I(k??[]);if(!e){N(!1),o.add(P({type:`error`,title:`Could not open logs folder`,description:`No available editors found.`}));return}(h?C(h.environmentId)?.client.shell.openInEditor({cwd:H,editor:e})??Promise.reject(Error(`Selected environment is disconnected.`)):T().shell.openInEditor(H,e)).catch(qe).finally(()=>{N(!1)})},n[23]=k,n[24]=H,n[25]=h,n[26]=U):U=n[26];let W=U,re;n[27]===B?re=n[28]:(re=B?(0,Q.jsx)(fe,{className:`size-3.5`}):(0,Q.jsx)(A,{className:`size-3.5`}),n[27]=B,n[28]=re);let G=B?`Copied`:`Copy debug bundle`,ie;n[29]!==ne||n[30]!==re||n[31]!==G?(ie=(0,Q.jsxs)(m,{size:`xs`,variant:`outline`,onClick:ne,children:[re,G]}),n[29]=ne,n[30]=re,n[31]=G,n[32]=ie):ie=n[32];let K;n[33]===Symbol.for(`react.memo_cache_sentinel`)?(K=(0,Q.jsx)(ue,{title:`Application`,description:`Version ${a} · ${d}${t?` · Desktop`:` · Browser`}`}),n[33]=K):K=n[33];let ae=H??`Resolving logs directory…`,q=!H||M,J=M?`Opening…`:`Open logs folder`,oe;n[34]!==W||n[35]!==q||n[36]!==J?(oe=(0,Q.jsx)(m,{size:`xs`,variant:`outline`,disabled:q,onClick:W,children:J}),n[34]=W,n[35]=q,n[36]=J,n[37]=oe):oe=n[37];let se;n[38]!==ae||n[39]!==oe?(se=(0,Q.jsx)(ue,{title:`Logs`,description:ae,control:oe}),n[38]=ae,n[39]=oe,n[40]=se):se=n[40];let ce;n[41]!==ie||n[42]!==se?(ce=(0,Q.jsxs)(Y,{title:`Diagnostics`,headerAction:ie,children:[K,se]}),n[41]=ie,n[42]=se,n[43]=ce):ce=n[43];let le;n[44]!==R||n[45]!==l||n[46]!==i||n[47]!==s?(le=R.length===0?(0,Q.jsx)(ue,{title:`No environments`,description:`No environment connections are tracked yet.`}):R.map(e=>(0,Q.jsx)(We,{environmentId:e,record:i[e]??null,runtime:s[e]??null,pushSequence:l[e]??null},e)),n[44]=R,n[45]=l,n[46]=i,n[47]=s,n[48]=le):le=n[48];let de;n[49]===le?de=n[50]:(de=(0,Q.jsx)(Y,{title:`Environments`,children:le}),n[49]=le,n[50]=de);let pe;n[51]===E?pe=n[52]:(pe=E.length===0?(0,Q.jsx)(ue,{title:`No providers`,description:`No provider instances are configured.`}):E.map(Ke),n[51]=E,n[52]=pe);let me;n[53]===pe?me=n[54]:(me=(0,Q.jsx)(Y,{title:`Providers`,children:pe}),n[53]=pe,n[54]=me);let he;return n[55]!==ce||n[56]!==de||n[57]!==me?(he=(0,Q.jsxs)(Q.Fragment,{children:[ce,de,me]}),n[55]=ce,n[56]=de,n[57]=me,n[58]=he):he=n[58],he}function Ke(e){let t=e.unavailableReason??e.message??null;return(0,Q.jsx)(ue,{title:(0,Q.jsxs)(`span`,{className:`inline-flex items-center gap-2`,children:[(0,Q.jsx)(He,{className:Ve[e.status]??`bg-muted-foreground/40`}),e.displayName??e.instanceId]}),description:(0,Q.jsxs)(`span`,{className:`space-y-0.5`,children:[(0,Q.jsxs)(`span`,{className:`block`,children:[e.status,` · auth `,e.auth.status,e.version?` · v${e.version}`:``]}),t?(0,Q.jsx)(`span`,{className:`block break-all text-muted-foreground/70`,children:t}):null]})},e.instanceId)}function qe(e){o.add(P({type:`error`,title:`Could not open logs folder`,description:e instanceof Error?e.message:`Failed to open logs folder.`}))}function Je(e){o.add(P({type:`error`,title:`Could not copy debug bundle`,description:e.message}))}function Ye(){o.add({type:`success`,title:`Debug bundle copied`,description:`Secrets are redacted before export.`})}function Xe(e){return e.byEnvironment}function Ze(e){return e.byId}function Qe(e){return e.byId}var $e=[{method:`thread/snapshot`,requestId:`req_9f2c81d4a6`,startedAt:`12s ago`},{method:`git/status`,requestId:`req_c07b3e51fd`,startedAt:`9s ago`}];function et(e){o.update(e,{type:`loading`,title:`Updating Claude Code`,description:`Running provider update command.`,timeout:0,actionProps:void 0,data:{hideCopyButton:!0}}),window.setTimeout(()=>{o.update(e,{type:`success`,title:`Provider updated`,description:`New sessions will use the updated provider.`,timeout:0,data:{hideCopyButton:!0,dismissAfterVisibleMs:3e3}})},1800)}var tt=[{value:`provider-update`,label:`Provider update available`,fire:()=>{let e=o.add(P({type:`warning`,title:`Update Available: Claude Code v2.1.4`,description:`Install the update now or review provider settings.`,timeout:0,actionProps:{children:`Update`,onClick:()=>et(e)},actionVariant:`default`,data:{hideCopyButton:!0,secondaryActionProps:{children:`Settings`,onClick:()=>s.getState().openSettings(`providers`)},secondaryActionVariant:`outline`}}))}},{value:`pr-checks-passed`,label:`PR checks passed`,fire:()=>{o.add({type:`success`,title:`Checks passed for PR #316`,description:`Redesign the notification toasts · 3273af68e412`,timeout:6e3,actionProps:{children:`Open PR`,onClick:()=>void 0},data:{actionVariant:`outline`}})}},{value:`git-push`,label:`Git push with follow-up action`,fire:()=>{o.add(P({type:`success`,title:`Pushed`,description:`3 commits pushed to origin/feat/notifications-toasts.`,timeout:0,actionProps:{children:`Open PR`,onClick:()=>void 0},actionVariant:`outline`,data:{dismissAfterVisibleMs:1e4}}))}},{value:`git-failed`,label:`Git action failed`,fire:()=>{o.add(P({type:`error`,title:`Action failed`,description:`remote: Permission to sak0a/ryco.git denied to deploy-bot.
|
|
2
|
+
fatal: unable to access 'https://github.com/sak0a/ryco.git/': The requested URL returned error: 403`,timeout:0}))}},{value:`git-pull`,label:`Git pull (loading → result)`,fire:()=>{o.promise(new Promise(e=>{window.setTimeout(e,2400)}),{loading:{title:`Pulling...`},success:{title:`Pulled`,description:`Updated main from origin/main.`},error:{title:`Pull failed`,description:`Could not fast-forward.`}})}},{value:`slow-requests`,label:`Slow requests (expandable)`,fire:()=>{o.add({type:`warning`,title:`Some requests are slow`,description:`2 requests waiting longer than 5s.`,timeout:0,data:{expandableDescriptionTrigger:!0,expandableLabels:{expand:`Show requests`,collapse:`Hide requests`},expandableContent:(0,Q.jsx)(`ul`,{className:`flex flex-col gap-1.5`,children:$e.map(e=>(0,Q.jsxs)(`li`,{className:`flex min-w-0 items-baseline gap-2`,children:[(0,Q.jsx)(`span`,{className:`shrink-0 rounded-sm bg-muted px-1 py-0.5 font-mono text-[10px]`,children:e.method}),(0,Q.jsx)(`span`,{className:`min-w-0 truncate font-mono text-[11px] text-muted-foreground`,children:e.requestId}),(0,Q.jsx)(`span`,{className:`ml-auto shrink-0 text-[11px] text-muted-foreground`,children:e.startedAt})]},e.requestId))})}})}},{value:`reconnected`,label:`Connection restored`,fire:()=>{o.add({type:`success`,title:`Reconnected to Ryco Server`,description:`Connection restored at ${new Date().toLocaleTimeString()}.`,timeout:0,data:{dismissAfterVisibleMs:8e3,hideCopyButton:!0}})}},{value:`long-error`,label:`Error with long details`,fire:()=>{o.add({type:`error`,title:`Provider session crashed`,description:`The provider session exited unexpectedly with code 137 while processing the turn. Last stderr output: FATAL ERROR: Reached heap limit — allocation failed, JavaScript heap out of memory. Restart the session or reduce the attached context, then try again.`,timeout:0})}}],nt=[`pr-checks-passed`,`provider-update`,`git-failed`];function rt(){nt.forEach((e,t)=>{let n=tt.find(t=>t.value===e);n&&window.setTimeout(()=>n.fire(),t*350)})}function it(){let e=(0,Z.c)(17),[t,n]=(0,X.useState)(tt[0]?.value??``),r;e[0]===t?r=e[1]:(r=tt.find(e=>e.value===t)??tt[0],e[0]=t,e[1]=r);let i=r,a;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(a=e=>{typeof e==`string`&&n(e)},e[2]=a):a=e[2];let o=i?.label,s;e[3]===o?s=e[4]:(s=(0,Q.jsx)(z,{className:`w-full sm:w-56`,"aria-label":`Notification sample`,children:(0,Q.jsx)(B,{children:o})}),e[3]=o,e[4]=s);let c;e[5]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,Q.jsx)(L,{align:`end`,alignItemWithTrigger:!1,children:tt.map(at)}),e[5]=c):c=e[5];let l;e[6]!==t||e[7]!==s?(l=(0,Q.jsxs)(V,{value:t,onValueChange:a,children:[s,c]}),e[6]=t,e[7]=s,e[8]=l):l=e[8];let u;e[9]===i?u=e[10]:(u=(0,Q.jsx)(m,{"aria-label":`Show test notification`,size:`xs`,onClick:()=>i?.fire(),children:`Show`}),e[9]=i,e[10]=u);let d;e[11]!==l||e[12]!==u?(d=(0,Q.jsx)(ue,{title:`Test notification`,description:`Preview the notification design with realistic samples. Nothing is sent or changed.`,control:(0,Q.jsxs)(`div`,{className:`flex w-full items-center gap-2 sm:w-auto`,children:[l,u]})}),e[11]=l,e[12]=u,e[13]=d):d=e[13];let f;e[14]===Symbol.for(`react.memo_cache_sentinel`)?(f=(0,Q.jsx)(ue,{title:`Notification stack`,description:`Fire a short burst to preview stacking, peeking, and hover expansion.`,control:(0,Q.jsx)(m,{size:`xs`,variant:`outline`,onClick:rt,children:`Show stack`})}),e[14]=f):f=e[14];let p;return e[15]===d?p=e[16]:(p=(0,Q.jsxs)(Y,{title:`Notifications`,children:[d,f]}),e[15]=d,e[16]=p),p}function at(e){return(0,Q.jsx)(te,{hideIndicator:!0,value:e.value,children:e.label},e.value)}var ot=5e3;function st(e){let t=(0,Z.c)(33),{points:n,formatValue:r}=e,i;bb0:{if(n.length===0){i=``;break bb0}let e;t[0]===n?e=t[1]:(e=Math.max(...n.map(ct),1),t[0]=n,t[1]=e);let r=e,a;if(t[2]!==r||t[3]!==n){let e;t[5]!==r||t[6]!==n.length?(e=(e,t)=>{let i=n.length===1?320:t/(n.length-1)*320,a=96-e.value/r*84-6;return`${t===0?`M`:`L`}${i.toFixed(2)},${a.toFixed(2)}`},t[5]=r,t[6]=n.length,t[7]=e):e=t[7],a=n.map(e).join(` `),t[2]=r,t[3]=n,t[4]=a}else a=t[4];i=a}let a=i,o,s,c,l,u;if(t[8]!==r||t[9]!==n){let e=n.at(-1)?.value??0;u=`min-w-0`,c=`mb-2 flex items-baseline justify-between gap-3`,t[15]===n.length?l=t[16]:(l=(0,Q.jsxs)(`span`,{className:`font-mono text-[11px] text-muted-foreground/70`,children:[n.length,` samples`]}),t[15]=n.length,t[16]=l),o=`font-mono text-xs text-foreground`,s=r(e),t[8]=r,t[9]=n,t[10]=o,t[11]=s,t[12]=c,t[13]=l,t[14]=u}else o=t[10],s=t[11],c=t[12],l=t[13],u=t[14];let d;t[17]!==o||t[18]!==s?(d=(0,Q.jsx)(`span`,{className:o,children:s}),t[17]=o,t[18]=s,t[19]=d):d=t[19];let f;t[20]!==c||t[21]!==l||t[22]!==d?(f=(0,Q.jsxs)(`div`,{className:c,children:[l,d]}),t[20]=c,t[21]=l,t[22]=d,t[23]=f):f=t[23];let p;t[24]===a?p=t[25]:(p=(0,Q.jsx)(`path`,{d:a,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,vectorEffect:`non-scaling-stroke`}),t[24]=a,t[25]=p);let m;t[26]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,Q.jsx)(`line`,{x1:`0`,y1:95,x2:320,y2:95,className:`stroke-border`}),t[26]=m):m=t[26];let h;t[27]===p?h=t[28]:(h=(0,Q.jsxs)(`svg`,{viewBox:`0 0 320 96`,className:`h-24 w-full overflow-visible text-info`,role:`img`,"aria-label":`Diagnostics history chart`,children:[p,m]}),t[27]=p,t[28]=h);let g;return t[29]!==h||t[30]!==u||t[31]!==f?(g=(0,Q.jsxs)(`div`,{className:u,children:[f,h]}),t[29]=h,t[30]=u,t[31]=f,t[32]=g):g=t[32],g}function ct(e){return e.value}function lt(e){let t=(0,Z.c)(12),{points:n,formatValue:r}=e,i=r===void 0?String:r,a;t[0]===n?a=t[1]:(a=Math.max(...n.map(ut),1),t[0]=n,t[1]=a);let o=a;if(n.length===0){let e;return t[2]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-muted-foreground text-sm`,children:`No data yet.`}),t[2]=e):e=t[2],e}let s;if(t[3]!==i||t[4]!==o||t[5]!==n){let e;t[7]!==i||t[8]!==o?(e=e=>(0,Q.jsxs)(`div`,{className:`grid grid-cols-[minmax(0,1fr)_5rem] items-center gap-3 px-4 sm:px-5 py-2.5`,children:[(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[(0,Q.jsx)(`div`,{className:`mb-1 truncate text-[12px] font-medium`,children:e.label}),(0,Q.jsx)(`div`,{className:`h-1.5 overflow-hidden rounded-full bg-muted`,children:(0,Q.jsx)(`div`,{className:`h-full rounded-full bg-info`,style:{width:`${Math.max(4,e.value/o*100)}%`}})})]}),(0,Q.jsx)(`div`,{className:`text-right font-mono text-[11px] text-muted-foreground`,children:i(e.value)})]},e.label),t[7]=i,t[8]=o,t[9]=e):e=t[9],s=n.map(e),t[3]=i,t[4]=o,t[5]=n,t[6]=s}else s=t[6];let c;return t[10]===s?c=t[11]:(c=(0,Q.jsx)(`div`,{className:`divide-y divide-border/60`,children:s}),t[10]=s,t[11]=c),c}function ut(e){return e.value}function $(e){let t=(0,Z.c)(10),{label:n,value:r,detail:i}=e,a;t[0]===n?a=t[1]:(a=(0,Q.jsx)(`div`,{className:`truncate text-xs text-muted-foreground`,children:n}),t[0]=n,t[1]=a);let o;t[2]===r?o=t[3]:(o=(0,Q.jsx)(`div`,{className:`mt-1 truncate text-[15px] font-semibold tracking-tight text-foreground tabular-nums`,children:r}),t[2]=r,t[3]=o);let s;t[4]===i?s=t[5]:(s=i?(0,Q.jsx)(`div`,{className:`mt-0.5 truncate text-[11px] text-muted-foreground`,children:i}):null,t[4]=i,t[5]=s);let c;return t[6]!==a||t[7]!==o||t[8]!==s?(c=(0,Q.jsxs)(`div`,{className:`min-w-0 border-r border-b border-border/60 px-4 py-3 sm:px-5`,children:[a,o,s]}),t[6]=a,t[7]=o,t[8]=s,t[9]=c):c=t[9],c}function dt(e){let t=(0,Z.c)(12),{label:n,value:r,detail:i}=e,a;t[0]===n?a=t[1]:(a=(0,Q.jsx)(`div`,{className:`text-[12px] font-medium text-foreground`,children:n}),t[0]=n,t[1]=a);let o;t[2]===r?o=t[3]:(o=(0,Q.jsx)(`div`,{className:`font-mono text-[12px] text-foreground`,children:r}),t[2]=r,t[3]=o);let s;t[4]===i?s=t[5]:(s=(0,Q.jsx)(`div`,{className:`mt-0.5 text-[11px] text-muted-foreground`,children:i}),t[4]=i,t[5]=s);let c;t[6]!==o||t[7]!==s?(c=(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[o,s]}),t[6]=o,t[7]=s,t[8]=c):c=t[8];let l;return t[9]!==a||t[10]!==c?(l=(0,Q.jsxs)(`div`,{className:`grid gap-1 border-border/60 border-t px-4 py-3 first:border-t-0 sm:grid-cols-[11rem_minmax(0,1fr)] sm:px-5`,children:[a,c]}),t[9]=a,t[10]=c,t[11]=l):l=t[11],l}function ft(e){let t=(0,Z.c)(5),{value:n}=e,r;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,Q.jsx)(`summary`,{className:`cursor-pointer select-none text-[11px] text-muted-foreground hover:text-foreground`,children:`raw`}),t[0]=r):r=t[0];let i;t[1]===n?i=t[2]:(i=JSON.stringify(n,null,2),t[1]=n,t[2]=i);let a;return t[3]===i?a=t[4]:(a=(0,Q.jsxs)(`details`,{className:`group`,children:[r,(0,Q.jsx)(`pre`,{className:`mt-2 max-h-64 overflow-auto rounded-md bg-muted/60 p-3 text-[11px] leading-relaxed`,children:i})]}),t[3]=i,t[4]=a),a}function pt(e){let t=(0,Z.c)(8),{spans:n,showTraceId:r}=e,i=r!==void 0&&r;if(n.length===0){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-muted-foreground text-sm`,children:`No spans retained yet.`}),t[0]=e):e=t[0],e}let a;if(t[1]!==i||t[2]!==n){let e;t[4]===i?e=t[5]:(e=e=>(0,Q.jsxs)(`div`,{className:`grid gap-2 px-4 sm:px-5 py-3 sm:grid-cols-[minmax(0,1fr)_6rem_5rem] sm:items-start`,children:[(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[(0,Q.jsx)(`span`,{className:`truncate text-[13px] font-medium`,children:e.name}),(0,Q.jsx)(R,{size:`sm`,variant:W(e.status)?`error`:`outline`,children:e.status})]}),(0,Q.jsxs)(`div`,{className:`mt-1 truncate font-mono text-[11px] text-muted-foreground`,children:[e.source,` / `,e.kind,` / `,e.spanId]}),i?(0,Q.jsx)(xe,{value:e.traceId}):null,e.failureMessage&&W(e.status)?(0,Q.jsx)(`div`,{className:`mt-1 line-clamp-2 text-[11px] text-destructive`,children:e.failureMessage}):null,(0,Q.jsx)(`div`,{className:`mt-2`,children:(0,Q.jsx)(ft,{value:e})})]}),(0,Q.jsx)(`div`,{className:`font-mono text-[11px] text-muted-foreground sm:text-right`,children:q(e.durationMs)}),(0,Q.jsx)(`div`,{className:`font-mono text-[11px] text-muted-foreground sm:text-right`,children:J(e.endTime)})]},e.id),t[4]=i,t[5]=e),a=n.slice(0,10).map(e),t[1]=i,t[2]=n,t[3]=a}else a=t[3];let o;return t[6]===a?o=t[7]:(o=(0,Q.jsx)(`div`,{className:`divide-y divide-border/60`,children:a}),t[6]=a,t[7]=o),o}function mt(e){let t=(0,Z.c)(9),{memorySeries:n,cpuSeries:r}=e,i;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,Q.jsx)(`div`,{className:`mb-1 text-[12px] font-semibold`,children:`RSS memory`}),t[0]=i):i=t[0];let a;t[1]===n?a=t[2]:(a=(0,Q.jsxs)(`div`,{className:`min-w-0 p-4`,children:[i,(0,Q.jsx)(st,{points:n,formatValue:K})]}),t[1]=n,t[2]=a);let o;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,Q.jsx)(`div`,{className:`mb-1 text-[12px] font-semibold`,children:`CPU utilization`}),t[3]=o):o=t[3];let s;t[4]===r?s=t[5]:(s=(0,Q.jsxs)(`div`,{className:`min-w-0 p-4`,children:[o,(0,Q.jsx)(st,{points:r,formatValue:ht})]}),t[4]=r,t[5]=s);let c;return t[6]!==a||t[7]!==s?(c=(0,Q.jsx)(Y,{title:`Resource history`,children:(0,Q.jsxs)(`div`,{className:`grid gap-0 divide-y divide-border/60 lg:grid-cols-2 lg:divide-x lg:divide-y-0`,children:[a,s]})}),t[6]=a,t[7]=s,t[8]=c):c=t[8],c}function ht(e){return`${e.toFixed(1)}%`}function gt(e){let t=(0,Z.c)(26),{snapshot:n,showTraceId:r}=e,i=r!==void 0&&r,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,Q.jsx)(`div`,{className:`border-border/60 border-b px-4 sm:px-5 py-2 text-[12px] font-semibold`,children:`Top span names`}),t[0]=a):a=t[0];let o;t[1]===n?.tracing.topSpanNames?o=t[2]:(o=n?.tracing.topSpanNames??[],t[1]=n?.tracing.topSpanNames,t[2]=o);let s;t[3]===o?s=t[4]:(s=se(o),t[3]=o,t[4]=s);let c;t[5]===s?c=t[6]:(c=(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[a,(0,Q.jsx)(lt,{points:s})]}),t[5]=s,t[6]=c);let l;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,Q.jsx)(`div`,{className:`border-border/60 border-b px-4 sm:px-5 py-2 text-[12px] font-semibold`,children:`Duration buckets`}),t[7]=l):l=t[7];let u;t[8]===n?.tracing.durationBuckets?u=t[9]:(u=n?.tracing.durationBuckets??[],t[8]=n?.tracing.durationBuckets,t[9]=u);let d;t[10]===u?d=t[11]:(d=oe(u),t[10]=u,t[11]=d);let f;t[12]===d?f=t[13]:(f=(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[l,(0,Q.jsx)(lt,{points:d})]}),t[12]=d,t[13]=f);let p;t[14]!==c||t[15]!==f?(p=(0,Q.jsxs)(`div`,{className:`grid gap-0 divide-y divide-border/60 lg:grid-cols-2 lg:divide-x lg:divide-y-0`,children:[c,f]}),t[14]=c,t[15]=f,t[16]=p):p=t[16];let m;t[17]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,Q.jsx)(`div`,{className:`border-border/60 border-b px-4 sm:px-5 py-2 text-[12px] font-semibold`,children:`Slowest spans`}),t[17]=m):m=t[17];let h;t[18]===n?.tracing.slowestSpans?h=t[19]:(h=n?.tracing.slowestSpans??[],t[18]=n?.tracing.slowestSpans,t[19]=h);let g;t[20]!==i||t[21]!==h?(g=(0,Q.jsxs)(`div`,{className:`border-border/60 border-t`,children:[m,(0,Q.jsx)(pt,{spans:h,showTraceId:i})]}),t[20]=i,t[21]=h,t[22]=g):g=t[22];let _;return t[23]!==p||t[24]!==g?(_=(0,Q.jsxs)(Y,{title:`Tracing diagnostics`,children:[p,g]}),t[23]=p,t[24]=g,t[25]=_):_=t[25],_}function _t(e){let t=(0,Z.c)(10),{snapshot:n,nowMs:r}=e,i;if(t[0]!==r||t[1]!==n?.failures.latest){let e;t[3]===r?e=t[4]:(e=e=>(0,Q.jsxs)(`div`,{className:`grid gap-2 px-4 sm:px-5 py-3 sm:grid-cols-[minmax(0,1fr)_6rem]`,children:[(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[(0,Q.jsx)(R,{size:`sm`,variant:`error`,children:e.category}),(0,Q.jsx)(`span`,{className:`truncate text-[13px] font-medium`,children:e.message})]}),(0,Q.jsxs)(`div`,{className:`mt-1 truncate font-mono text-[11px] text-muted-foreground`,children:[e.source,` / `,e.signature]}),(0,Q.jsx)(`div`,{className:`mt-2`,children:(0,Q.jsx)(ft,{value:e.raw??e})})]}),(0,Q.jsx)(`div`,{className:`font-mono text-[11px] text-muted-foreground sm:text-right`,children:J(e.occurredAt,r)})]},e.id),t[3]=r,t[4]=e),i=(n?.failures.latest??[]).slice(0,8).map(e),t[0]=r,t[1]=n?.failures.latest,t[2]=i}else i=t[2];let a;t[5]===n?a=t[6]:(a=n&&n.failures.latest.length===0?(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-muted-foreground text-sm`,children:`No failures retained.`}):null,t[5]=n,t[6]=a);let o;return t[7]!==i||t[8]!==a?(o=(0,Q.jsx)(Y,{title:`Failures`,children:(0,Q.jsxs)(`div`,{className:`divide-y divide-border/60`,children:[i,a]})}),t[7]=i,t[8]=a,t[9]=o):o=t[9],o}function vt(e){let t=(0,Z.c)(27),{snapshot:n,slowRpcAcks:r,nowMs:i}=e,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,Q.jsx)(`div`,{className:`border-border/60 border-b px-4 sm:px-5 py-2 text-[12px] font-semibold`,children:`Providers`}),t[0]=a):a=t[0];let o;t[1]===n?.liveProcesses.providers?o=t[2]:(o=n?.liveProcesses.providers??[],t[1]=n?.liveProcesses.providers,t[2]=o);let s;t[3]===o?s=t[4]:(s=o.map(bt),t[3]=o,t[4]=s);let c;t[5]===s?c=t[6]:(c=(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[a,(0,Q.jsx)(`div`,{className:`divide-y divide-border/60`,children:s})]}),t[5]=s,t[6]=c);let l;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,Q.jsx)(`div`,{className:`border-border/60 border-b px-4 sm:px-5 py-2 text-[12px] font-semibold`,children:`Terminals and slow RPCs`}),t[7]=l):l=t[7];let u;t[8]===n?.liveProcesses.terminals?u=t[9]:(u=n?.liveProcesses.terminals??[],t[8]=n?.liveProcesses.terminals,t[9]=u);let d;t[10]===u?d=t[11]:(d=u.map(yt),t[10]=u,t[11]=d);let f;if(t[12]!==i||t[13]!==r){let e;t[15]===i?e=t[16]:(e=e=>(0,Q.jsxs)(`div`,{className:`px-4 sm:px-5 py-2.5`,children:[(0,Q.jsx)(`div`,{className:`truncate text-[13px] font-medium`,children:e.tag}),(0,Q.jsxs)(`div`,{className:`mt-1 font-mono text-[11px] text-muted-foreground`,children:[`slow ack / `,J(e.startedAt,i)]})]},e.requestId),t[15]=i,t[16]=e),f=r.map(e),t[12]=i,t[13]=r,t[14]=f}else f=t[14];let p;t[17]!==r.length||t[18]!==n?.liveProcesses.terminals.length?(p=(n?.liveProcesses.terminals.length??0)===0&&r.length===0?(0,Q.jsx)(`p`,{className:`px-4 sm:px-5 py-4 text-muted-foreground text-sm`,children:`No live terminal or slow RPC activity.`}):null,t[17]=r.length,t[18]=n?.liveProcesses.terminals.length,t[19]=p):p=t[19];let m;t[20]!==d||t[21]!==f||t[22]!==p?(m=(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[l,(0,Q.jsxs)(`div`,{className:`divide-y divide-border/60`,children:[d,f,p]})]}),t[20]=d,t[21]=f,t[22]=p,t[23]=m):m=t[23];let h;return t[24]!==m||t[25]!==c?(h=(0,Q.jsx)(Y,{title:`Live activity`,children:(0,Q.jsxs)(`div`,{className:`grid gap-0 divide-y divide-border/60 lg:grid-cols-2 lg:divide-x lg:divide-y-0`,children:[c,m]})}),t[24]=m,t[25]=c,t[26]=h):h=t[26],h}function yt(e){return(0,Q.jsxs)(`div`,{className:`px-4 sm:px-5 py-2.5`,children:[(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center justify-between gap-3`,children:[(0,Q.jsx)(`span`,{className:`truncate text-[13px] font-medium`,children:e.terminalId}),(0,Q.jsx)(R,{size:`sm`,variant:e.status===`error`?`error`:`outline`,children:e.status})]}),(0,Q.jsxs)(`div`,{className:`mt-1 truncate font-mono text-[11px] text-muted-foreground`,children:[`pid `,e.pid??`n/a`,` / subprocess`,` `,e.hasRunningSubprocess?`yes`:`no`]})]},`${e.threadId}:${e.terminalId}`)}function bt(e){return(0,Q.jsxs)(`div`,{className:`flex min-w-0 items-center justify-between gap-3 px-4 sm:px-5 py-2.5`,children:[(0,Q.jsxs)(`div`,{className:`min-w-0`,children:[(0,Q.jsx)(`div`,{className:`truncate text-[13px] font-medium`,children:e.displayName??e.instanceId}),(0,Q.jsx)(`div`,{className:`truncate font-mono text-[11px] text-muted-foreground`,children:e.driver})]}),(0,Q.jsx)(R,{size:`sm`,variant:e.status===`error`?`error`:e.status===`warning`?`warning`:`outline`,children:e.status})]},e.instanceId)}function xt(e){let t=(0,Z.c)(57),{snapshot:n,memorySeries:r,cpuSeries:i,slowRpcAcks:a,latestFailure:o,nowMs:s}=e,c;t[0]===n?c=t[1]:(c=n?q(n.uptimeMs):`n/a`,t[0]=n,t[1]=c);let l;t[2]!==s||t[3]!==n?(l=n?`Started ${J(n.serverStartedAt,s)}`:void 0,t[2]=s,t[3]=n,t[4]=l):l=t[4];let u;t[5]!==c||t[6]!==l?(u=(0,Q.jsx)($,{label:`Uptime`,value:c,detail:l}),t[5]=c,t[6]=l,t[7]=u):u=t[7];let d;t[8]===n?d=t[9]:(d=n?K(n.resources.current.memory.rssBytes):`n/a`,t[8]=n,t[9]=d);let f;t[10]===n?f=t[11]:(f=n?`${K(n.resources.current.memory.heapUsedBytes)} heap used`:void 0,t[10]=n,t[11]=f);let p;t[12]!==d||t[13]!==f?(p=(0,Q.jsx)($,{label:`Memory`,value:d,detail:f}),t[12]=d,t[13]=f,t[14]=p):p=t[14];let m;t[15]===n?m=t[16]:(m=n?G(n.resources.current.cpu.utilizationPercent):`n/a`,t[15]=n,t[16]=m);let h;t[17]===n?h=t[18]:(h=n?.resources.current.eventLoopDelayMs===void 0?void 0:`${q(n.resources.current.eventLoopDelayMs)} event loop delay`,t[17]=n,t[18]=h);let g;t[19]!==m||t[20]!==h?(g=(0,Q.jsx)($,{label:`CPU`,value:m,detail:h}),t[19]=m,t[20]=h,t[21]=g):g=t[21];let _;t[22]===n?.liveProcesses.providers?_=t[23]:(_=n?.liveProcesses.providers.filter(St).length??0,t[22]=n?.liveProcesses.providers,t[23]=_);let v=`${_} providers`,y=`${n?.liveProcesses.terminals.length??0} terminal sessions`,b;t[24]!==v||t[25]!==y?(b=(0,Q.jsx)($,{label:`Activity`,value:v,detail:y}),t[24]=v,t[25]=y,t[26]=b):b=t[26];let x=`${n?.tracing.retainedSpanCount??0} spans`,S=n?`${n.limits.fileTailBytes/1024} KB file tail`:void 0,C;t[27]!==x||t[28]!==S?(C=(0,Q.jsx)($,{label:`Tracing`,value:x,detail:S}),t[27]=x,t[28]=S,t[29]=C):C=t[29];let w;t[30]===o?w=t[31]:(w=(0,Q.jsx)($,{label:`Latest failure`,value:o}),t[30]=o,t[31]=w);let T;t[32]!==b||t[33]!==C||t[34]!==w||t[35]!==u||t[36]!==p||t[37]!==g?(T=(0,Q.jsx)(Y,{title:`Overview`,children:(0,Q.jsxs)(`div`,{className:`-mr-px -mb-px grid sm:grid-cols-2 lg:grid-cols-3`,children:[u,p,g,b,C,w]})}),t[32]=b,t[33]=C,t[34]=w,t[35]=u,t[36]=p,t[37]=g,t[38]=T):T=t[38];let E;t[39]!==i||t[40]!==r?(E=(0,Q.jsx)(mt,{memorySeries:r,cpuSeries:i}),t[39]=i,t[40]=r,t[41]=E):E=t[41];let D;t[42]===n?D=t[43]:(D=(0,Q.jsx)(gt,{snapshot:n}),t[42]=n,t[43]=D);let O;t[44]!==s||t[45]!==n?(O=(0,Q.jsx)(_t,{snapshot:n,nowMs:s}),t[44]=s,t[45]=n,t[46]=O):O=t[46];let k;t[47]!==s||t[48]!==a||t[49]!==n?(k=(0,Q.jsx)(vt,{snapshot:n,slowRpcAcks:a,nowMs:s}),t[47]=s,t[48]=a,t[49]=n,t[50]=k):k=t[50];let A;return t[51]!==T||t[52]!==E||t[53]!==D||t[54]!==O||t[55]!==k?(A=(0,Q.jsxs)(Q.Fragment,{children:[T,E,D,O,k]}),t[51]=T,t[52]=E,t[53]=D,t[54]=O,t[55]=k,t[56]=A):A=t[56],A}function St(e){return e.enabled}function Ct(e){let t=(0,Z.c)(14),{snapshot:n,error:r}=e;if(!r&&(!n||n.warnings.length===0))return null;let i=r?`error`:`warning`,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,Q.jsx)(y,{}),t[0]=a):a=t[0];let o=r?`Diagnostics refresh failed`:`Diagnostics warnings`,s;t[1]===o?s=t[2]:(s=(0,Q.jsx)(ne,{children:o}),t[1]=o,t[2]=s);let c;t[3]===r?c=t[4]:(c=r?(0,Q.jsx)(`span`,{children:r}):null,t[3]=r,t[4]=c);let l;t[5]===n?.warnings?l=t[6]:(l=n?.warnings.slice(0,4).map(wt),t[5]=n?.warnings,t[6]=l);let u;t[7]!==c||t[8]!==l?(u=(0,Q.jsxs)(H,{children:[c,l]}),t[7]=c,t[8]=l,t[9]=u):u=t[9];let d;return t[10]!==i||t[11]!==s||t[12]!==u?(d=(0,Q.jsxs)(U,{variant:i,children:[a,s,u]}),t[10]=i,t[11]=s,t[12]=u,t[13]=d):d=t[13],d}function wt(e){return(0,Q.jsxs)(`span`,{children:[e.message,e.count?` (${e.count})`:``]},`${e.code}:${e.source??``}`)}function Tt(e){let t=(0,Z.c)(4),{presentation:n}=e,r=n===void 0?`performance`:n,i=b();if(w()===`client`){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,Q.jsxs)(le,{children:[(0,Q.jsx)(it,{}),null]}),t[0]=e):e=t[0],e}let a=i?.environmentId??`local`,o;return t[1]!==r||t[2]!==a?(o=(0,Q.jsx)(Et,{presentation:r},a),t[1]=r,t[2]=a,t[3]=o):o=t[3],o}function Et({presentation:e}){let t=b(),n=w(),[a,o]=(0,X.useState)(null),[s,c]=(0,X.useState)(null),[l,u]=(0,X.useState)(!0),[d,f]=(0,X.useState)(!1),p=(0,X.useRef)(null),g=(0,X.useRef)(d);g.current=d;let _=x(),v=S(e=>e.byId),y=Date.now(),C=me(r.serverGetDiagnosticsSnapshot),E=t?.environmentId,D=t?.nodeLabel,O=(0,X.useCallback)(async(e=!1)=>{await p.current?.()},[]);(0,X.useEffect)(()=>{if(o(null),c(null),u(!0),!C.allowed){c(C.reason),u(!1);return}let e=ge({fetch:async()=>{let e=E?h(E)?.server:T().server;if(!e)throw Error(`Diagnostics are unavailable on ${D??`this environment`}.`);return e.getDiagnosticsSnapshot()},onSuccess:e=>{o(e),c(null)},onError:e=>c(e instanceof Error?e.message:`Unable to refresh diagnostics.`),onLoading:u});p.current=e.refresh;let t=()=>{!g.current&&document.visibilityState===`visible`&&e.refresh()};t();let n=window.setInterval(t,ot);return document.addEventListener(`visibilitychange`,t),()=>{e.dispose(),p.current=null,window.clearInterval(n),document.removeEventListener(`visibilitychange`,t)}},[E,D,C.allowed,C.reason]),(0,X.useEffect)(()=>{!d&&document.visibilityState===`visible`&&O()},[d,O]);let k=(0,X.useMemo)(()=>ie(a?.resources.history??[]),[a]),A=(0,X.useMemo)(()=>re(a?.resources.history??[]),[a]),P=a?ae(a):`No snapshot`,F=a?.liveProcesses.providers.filter(e=>e.enabled).length??0,ee=a?.liveProcesses.terminals.filter(e=>e.status===`starting`||e.status===`running`).length??0,I=Object.values(v),L=I.filter(e=>e.connectionState===`connected`).length,R=I.filter(e=>e.connectionState===`connecting`).length,te=I.length===0?`No tracked clients`:`${L} connected${R>0?` · ${R} connecting`:``}`,z=a?.tracing.slowestSpans.find(e=>e.source===`server`)??null,B=_[0]??null,V=a?.performance??null,ne=V?.local.turnQuiescenceAvgMs??null,H=V?.local.checkpointDurationP95Ms??null,U=V?.local.latestThreadSnapshotDurationMs??null,W=V?.local.threadSnapshotDurationP95Ms??null;return(0,Q.jsxs)(le,{children:[(0,Q.jsx)(ce,{actions:(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsxs)(m,{size:`xs`,variant:`ghost`,className:`text-muted-foreground hover:text-foreground`,onClick:()=>f(e=>!e),children:[d?(0,Q.jsx)(M,{className:`size-3.5`}):(0,Q.jsx)(j,{className:`size-3.5`}),d?`Resume`:`Pause`]}),(0,Q.jsxs)(m,{size:`xs`,variant:`ghost`,className:`text-muted-foreground hover:text-foreground`,onClick:()=>void O(!0),disabled:l,children:[(0,Q.jsx)(N,{className:i(`size-3.5`,l&&`animate-spin`)}),`Refresh`]})]}),children:(0,Q.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,Q.jsx)(`span`,{"aria-hidden":!0,className:i(`size-1.5 rounded-full`,d?`bg-muted-foreground/50`:a?`bg-success`:`bg-warning`)}),a?`${d?`Paused · `:`Live · `}updated ${J(a.generatedAt,y)}`:`Waiting for snapshot`]})}),(0,Q.jsx)(Ct,{snapshot:a,error:s}),null,e===`phone-legacy`?(0,Q.jsx)(xt,{snapshot:a,memorySeries:k,cpuSeries:A,slowRpcAcks:_,latestFailure:P,nowMs:y}):(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(ye,{telemetry:a?.telemetry,paused:d,refresh:O},`telemetry:${E??`local`}`),(0,Q.jsx)(be,{snapshot:a,refresh:O},E??`local`),(0,Q.jsx)(Te,{snapshot:a,nowMs:y}),(0,Q.jsx)(gt,{snapshot:a,showTraceId:!0}),(0,Q.jsx)(_t,{snapshot:a,nowMs:y}),(0,Q.jsx)(vt,{snapshot:a,slowRpcAcks:_,nowMs:y}),(0,Q.jsx)(Y,{title:`Performance now`,children:(0,Q.jsxs)(`div`,{className:`-mr-px -mb-px grid sm:grid-cols-2 lg:grid-cols-3`,children:[(0,Q.jsx)($,{label:`Backend CPU`,value:a?G(a.resources.current.cpu.utilizationPercent):`n/a`,detail:a?`Process uptime ${q(a.uptimeMs)}`:void 0}),(0,Q.jsx)($,{label:`RSS / heap`,value:a?K(a.resources.current.memory.rssBytes):`n/a`,detail:a?`${K(a.resources.current.memory.heapUsedBytes)} heap used`:void 0}),(0,Q.jsx)($,{label:`Event-loop delay`,value:a?.resources.current.eventLoopDelayMs===void 0?`n/a`:q(a.resources.current.eventLoopDelayMs),detail:`Measured once for this requested snapshot`}),(0,Q.jsx)($,{label:`Providers / terminals`,value:`${F} enabled providers`,detail:`${ee} active terminals`}),(0,Q.jsx)($,{label:`Turn quiescence`,value:ne===null?`No samples`:q(ne),detail:`Rolling average`}),(0,Q.jsx)($,{label:`Checkpoint duration`,value:H===null?`No samples`:q(H),detail:`Rolling p95`}),(0,Q.jsx)($,{label:`WebSocket state`,value:te,detail:`${V?.local.wsReconnectCount??0} reconnects in this server process`}),(0,Q.jsx)($,{label:`Thread snapshot`,value:U===null?`No samples`:q(U),detail:W===null?`Latest successful subscription snapshot`:`${q(W)} rolling p95`}),(0,Q.jsx)($,{label:`Latest failure`,value:P})]})}),(0,Q.jsxs)(Y,{title:`Why was this slow?`,children:[(0,Q.jsx)(dt,{label:`Thread snapshot`,value:U===null?`No thread snapshot timing yet`:`${q(U)} latest`,detail:W===null?`Replay duration and payload bytes are not collected because the current transport has no zero-copy attribution hook.`:`${q(W)} rolling p95. Replay duration and payload bytes are not collected because the current transport has no zero-copy attribution hook.`}),(0,Q.jsx)(dt,{label:`Queue pressure`,value:V?`${V.queues.runtimeDepthTotal+V.queues.liveBufferDepthTotal} queued now`:`No snapshot`,detail:V?`Largest runtime high-water ${V.queues.runtimeHighWaterMax}; live-buffer high-water ${V.queues.liveBufferHighWaterMax}; ${V.queues.liveBufferOverflowCount} overflows; replay depth ${V.queues.replayDepthMax}; replay lag ${V.queues.replayLagMax}; ${V.queues.providerLogDroppedRecords} provider log records dropped.`:`Runtime and replay queue evidence will appear after the first snapshot.`}),(0,Q.jsx)(dt,{label:`Slowest server stage`,value:z?`${z.name} · ${q(z.durationMs)}`:`No retained spans`,detail:z?`Server span completed ${J(z.endTime,y)}.`:`Tracing has not retained a server stage yet.`}),(0,Q.jsx)(dt,{label:`Current slow client RPC`,value:B?.tag??`No slow RPC acknowledgement in progress`,detail:B?`Exceeded its ${q(B.thresholdMs)} acknowledgement threshold; started ${J(B.startedAt,y)}.`:`Only RPCs that cross the existing client acknowledgement threshold appear here.`}),(0,Q.jsx)(dt,{label:`Reconnect / resume`,value:te,detail:`${V?.local.wsReconnectCount??0} server-side reconnects. Per-environment push gaps and recovery state are in the Environments section.`}),(0,Q.jsx)(dt,{label:`Recent failure`,value:a?.failures.latest[0]?.message??`No retained failures`,detail:a?.failures.latest[0]?`${a.failures.latest[0].source} · ${J(a.failures.latest[0].occurredAt,y)}`:`No failure evidence is available for the current server process.`}),(0,Q.jsx)(dt,{label:`Trace persistence`,value:V?.traceSink?`${K(V.traceSink.bufferedBytes)} buffered`:`Health unavailable`,detail:V?.traceSink?`${K(V.traceSink.maxBufferedBytes)} cap; ${V.traceSink.droppedRecords} dropped records; ${V.traceSink.writeFailures} write failures; retry delay ${q(V.traceSink.retryDelayMs)}.`:`This diagnostics service is not attached to the local trace-file sink.`})]}),(0,Q.jsx)(mt,{memorySeries:k,cpuSeries:A}),(0,Q.jsx)(Ge,{snapshot:a}),n===`all`&&(0,Q.jsx)(it,{}),null]})]})}export{Tt as DiagnosticsSettings};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function e(e){return e===`failure`||e===`error`}function t(e){if(!Number.isFinite(e)||e<=0)return`0 B`;let t=[`B`,`KB`,`MB`,`GB`,`TB`],n=e,r=0;for(;n>=1024&&r<t.length-1;)n/=1024,r+=1;return`${n>=10||r===0?n.toFixed(0):n.toFixed(1)} ${t[r]}`}function n(e){return!Number.isFinite(e)||e<=0?`0 ms`:e<1e3?`${Math.round(e)} ms`:e<6e4?`${(e/1e3).toFixed(+(e<1e4))} s`:`${(e/6e4).toFixed(1)} min`}function r(e){return e===void 0||!Number.isFinite(e)?`n/a`:`${Math.max(0,e).toFixed(1)}%`}function i(e,t=Date.now()){let n=Date.parse(e);if(!Number.isFinite(n))return e;let r=Math.max(0,t-n);return r<1e3?`just now`:r<6e4?`${Math.floor(r/1e3)}s ago`:r<36e5?`${Math.floor(r/6e4)}m ago`:r<864e5?`${Math.floor(r/36e5)}h ago`:`${Math.floor(r/864e5)}d ago`}function a(e){return e.map(e=>({label:e.sampledAt,value:e.memory.rssBytes}))}function o(e){return e.map(e=>({label:e.sampledAt,value:e.cpu.utilizationPercent??0}))}function s(e){return e.map(e=>({label:e.label,value:e.count}))}function c(e){return e.slice(0,8).map(e=>({label:e.name,value:e.count}))}function l(e){let t=e.failures.latest[0];return t?t.message:`No failures`}export{e as a,o as c,r as i,a as l,t as n,l as o,n as r,i as s,s as t,c as u};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{hc as e,wc as t}from"./runtime-DjjjAcTE.js";import{b as n}from"./NullStore-gT_6_xZE.js";import{r}from"./DialogViewport-C2iOUx0O.js";var i=class extends n{constructor(){super(r(),`Dialog`,!1)}open(e){this.openByTrigger(e)}openWithPayload(n){let r=this.attachedStore;r!==null&&(r.set(`payload`,n),r.setOpen(!0,e(t)))}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select(`open`)??!1}};function a(){return new i}export{a as n,i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{Gl as t,ad as n,al as r,tl as i}from"./runtime-DjjjAcTE.js";import{t as a}from"./react-CwJFpaho.js";import{a as o,l as s}from"./NullStore-gT_6_xZE.js";import{p as c,s as l}from"./useScrollLock-CLZ31xsK.js";import{a as u,o as d,s as f}from"./DialogViewport-C2iOUx0O.js";var p=e(a(),1),m=p.forwardRef(function(e,n){let{render:i,className:a,style:o,forceRender:s=!1,...c}=e,l=f(),u=l.useState(`open`),d=l.useState(`nested`),p=l.useState(`mounted`),m={open:u,transitionStatus:l.useState(`transitionStatus`)};return r(`div`,e,{state:m,ref:[l.context.backdropRef,n],stateAttributesMapping:t,props:[{role:`presentation`,hidden:!p,style:{userSelect:`none`,WebkitUserSelect:`none`}},c],enabled:s||!d})}),h=`--nested-dialogs`,g=n(),_=p.forwardRef(function(e,t){let{render:n,className:a,style:p,finalFocus:m,initialFocus:_,...v}=e,y=f(),b=y.useState(`descriptionElementId`),x=y.useState(`disablePointerDismissal`),S=y.useState(`floatingRootContext`),C=y.useState(`popupProps`),w=y.useState(`modal`),T=y.useState(`mounted`),E=y.useState(`nested`),D=y.useState(`nestedOpenDialogCount`),O=y.useState(`open`),k=y.useState(`openMethod`),A=y.useState(`titleElementId`),j=y.useState(`transitionStatus`),M=y.useState(`role`),N=S.useState(`floatingId`);d(),i({open:O,ref:y.context.popupRef,onComplete(){O&&y.context.onOpenChangeComplete?.(!0)}});let P=_===void 0?s(y.context.popupRef):_,F=D>0,I=y.useStateSetter(`popupElement`),L=r(`div`,e,{state:{open:O,nested:E,transitionStatus:j,nestedDialogOpen:F},props:[C,{id:N,"aria-labelledby":A,"aria-describedby":b,role:M,...o,hidden:!T,onKeyDown(e){l.has(e.key)&&e.stopPropagation()},style:{[h]:D}},v],ref:[t,y.context.popupRef,I],stateAttributesMapping:u});return(0,g.jsx)(c,{context:S,openInteractionType:k,disabled:!T,closeOnFocusOut:!x,initialFocus:P,returnFocus:m,modal:w!==!1,restoreFocus:`popup`,children:L})});export{m as n,_ as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Ru as e}from"./runtime-DjjjAcTE.js";import{n as t}from"./DialogViewport-C2iOUx0O.js";var n=e(function(e){return t(`dialog`,e)});export{n as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{Bc as t,al as n,hc as r,yc as i}from"./runtime-DjjjAcTE.js";import{t as a}from"./react-CwJFpaho.js";import{n as o}from"./NullStore-gT_6_xZE.js";import{s}from"./DialogViewport-C2iOUx0O.js";var c=e(a(),1),l=c.forwardRef(function(e,a){let{render:o,className:c,style:l,disabled:u=!1,nativeButton:d=!0,...f}=e,p=s(),m=p.useState(`open`),{getButtonProps:h,buttonRef:g}=t({disabled:u,native:d}),_={disabled:u};function v(e){m&&p.setOpen(!1,r(i,e.nativeEvent))}return n(`button`,e,{state:_,ref:[a,g],props:[{onClick:v},f,h]})}),u=c.forwardRef(function(e,t){let{render:r,className:i,style:a,id:c,...l}=e,u=s(),d=o(c);return u.useSyncedValueWithCleanup(`descriptionElementId`,d),n(`p`,e,{ref:t,props:[{id:d},l]})}),d=c.forwardRef(function(e,t){let{render:r,className:i,style:a,id:c,...l}=e,u=s(),d=o(c);return u.useSyncedValueWithCleanup(`titleElementId`,d),n(`h2`,e,{ref:t,props:[{id:d},l]})});export{u as n,l as r,d as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{Hu as t,Iu as n,Uu as r,Wl as i,ad as a,al as o,eu as s,fc as c,hc as l,il as u,lu as d,tc as f,uu as p,wc as m}from"./runtime-DjjjAcTE.js";import{t as h}from"./react-CwJFpaho.js";import{d as g,f as _,h as v,i as y,m as b,o as x,p as S,r as C,t as w,u as T,x as E}from"./NullStore-gT_6_xZE.js";import{n as D,t as O}from"./useScrollLock-CLZ31xsK.js";var k=e(h(),1),A=k.createContext(void 0);function j(e){let n=k.useContext(A);if(!e&&n===void 0)throw Error(t(27));return n}var M=k.createContext(void 0);function N(){let e=k.useContext(M);if(e===void 0)throw Error(t(26));return e}var P=a(),F=`data-nested-dialog-open`,I={...i,...s,nestedDialogOpen(e){return e?{[F]:``}:null}},L=k.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,i=j(),a=i.useState(`mounted`),o=i.useState(`modal`),s=i.useState(`open`);return a||n?(0,P.jsx)(M.Provider,{value:n,children:(0,P.jsxs)(c,{ref:t,...r,children:[a&&o===!0&&(0,P.jsx)(D,{ref:i.context.internalBackdropRef,inert:u(!s)}),e.children]})}):null});function R({store:e,parentContext:t,isDrawer:n}){let i=e.useState(`open`),a=e.useState(`disablePointerDismissal`),o=e.useState(`modal`),s=e.useState(`popupElement`),c=e.useState(`floatingRootContext`),[l,u]=k.useState(0),[f,m]=k.useState(0),h=l===0,g=E(c,{outsidePressEvent(){return e.context.internalBackdropRef.current||e.context.backdropRef.current?`intentional`:{mouse:o===`trap-focus`?`sloppy`:`intentional`,touch:`sloppy`}},outsidePress(t){if(!e.context.outsidePressEnabledRef.current||`button`in t&&t.button!==0)return!1;if(`touches`in t){if(t.type===`touchend`){if(t.changedTouches.length!==1||t.touches.length!==0)return!1}else if(t.touches.length!==1)return!1}let n=p(t);if(h&&!a){if(o){let t=e.context.internalBackdropRef.current,r=e.context.backdropRef.current;return t||r?t===n||r===n||d(n,s)&&!n?.hasAttribute(`data-base-ui-portal`):!0}return!0}return!1},escapeKey:h});return O(i&&o===!0,s),e.useContextCallback(`onNestedDialogOpen`,(e,t)=>{u(e),m(t)}),r(()=>(t?.onNestedDialogOpen&&(i?t.onNestedDialogOpen(l+1,f+ +!!n):t.onNestedDialogOpen(0,0)),()=>{t?.onNestedDialogOpen&&i&&t.onNestedDialogOpen(0,0)}),[n,i,l,f,t]),S(e,{activeTriggerProps:g.reference,inactiveTriggerProps:g.trigger,popupProps:g.floating,nestedOpenDialogCount:l,nestedOpenDrawerCount:f}),null}var z={...y,modal:e=>e.modal,nested:e=>e.nested,nestedOpenDialogCount:e=>e.nestedOpenDialogCount,nestedOpenDrawerCount:e=>e.nestedOpenDrawerCount,disablePointerDismissal:e=>e.disablePointerDismissal,openMethod:e=>e.openMethod,descriptionElementId:e=>e.descriptionElementId,titleElementId:e=>e.titleElementId,viewportElement:e=>e.viewportElement,role:e=>e.role},B=class extends n{constructor(e,t,n){let r=new f,i=H(e,r,t,n);super(i,U(r),z)}setOpen=(e,t)=>{t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},!e&&t.trigger==null&&this.state.activeTriggerId!=null&&(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),!t.isCanceled&&(this.state.floatingRootContext.dispatchOpenChange(e,t),this.update(T(this.state,e,t.trigger)))}};function V(){let e=new f;return new w(Object.freeze(H(void 0,e)),Object.freeze(U(e)),z)}function H(e,t,n,r=!1){return{...C(t,n,r),modal:!0,disablePointerDismissal:!1,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:`dialog`,...e}}function U(e){return{popupRef:k.createRef(),backdropRef:k.createRef(),internalBackdropRef:k.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:e,onOpenChange:void 0,onOpenChangeComplete:void 0}}function W(e,t){let{children:n,open:r,defaultOpen:i=!1,onOpenChange:a,onOpenChangeComplete:o,disablePointerDismissal:s=!1,modal:c=!0,actionsRef:u,handle:d,triggerId:f,defaultTriggerId:p=null}=t,h=e===`drawer`,y=e===`alert-dialog`,S=y?!0:c,C=y||s,w=y?`alertdialog`:`dialog`,T=j(!0),E={modal:S,disablePointerDismissal:C,nested:T!=null,role:w},D=b((e,t)=>new B({open:i,openProp:r,activeTriggerId:p,triggerIdProp:f,...E},e,t),!0);D.useControlledProp(`openProp`,r),D.useControlledProp(`triggerIdProp`,f),D.useSyncedValues(E),D.useContextCallback(`onOpenChange`,a),D.useContextCallback(`onOpenChangeComplete`,o);let O=D.useState(`open`),M=D.useState(`mounted`),N=D.useState(`payload`);v(D,O),g(D);let{forceUnmount:F}=_(O,D);k.useImperativeHandle(u,()=>({unmount:F,close:()=>D.setOpen(!1,l(m))}),[F,D]);let I=O||M;return(0,P.jsxs)(A.Provider,{value:D,children:[d&&(0,P.jsx)(x,{handle:d,store:D}),I&&(0,P.jsx)(R,{store:D,parentContext:T?.context,isDrawer:h}),typeof n==`function`?n({payload:N}):n]})}var G=k.forwardRef(function(e,t){let{render:n,className:r,style:i,children:a,...s}=e,c=N(),l=j(),u=l.useState(`open`),d=l.useState(`nested`),f=l.useState(`transitionStatus`),p=l.useState(`nestedOpenDialogCount`),m=l.useState(`mounted`),h=l.useStateSetter(`viewportElement`);return o(`div`,e,{enabled:c||m,state:{open:u,nested:d,transitionStatus:f,nestedDialogOpen:p>0},ref:[t,h],stateAttributesMapping:I,props:[{role:`presentation`,hidden:!m,style:{pointerEvents:u?void 0:`none`},children:a},s]})});export{I as a,L as i,W as n,N as o,V as r,j as s,G as t};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{on as t}from"./primary-Cf-xJExj.js";import{$i as n,Nc as r,O as i,Qi as a,jc as o,ro as s}from"./wsTransport-C88seBPA.js";import{$i as c,Bi as l,Di as u,Fr as d,Fu as f,Ii as p,Ir as m,Ji as h,Lr as g,Nr as _,Oi as v,Pr as y,Rr as b,Sd as x,Ss as S,Ts as C,Xn as w,Xr as T,Zi as ee,ad as te,ci as ne,cr as re,ft as ie,gt as E,ms as ae,p as D,qi as oe,wr as se,ws as O,xs as ce,y as le}from"./runtime-DjjjAcTE.js";import{t as ue}from"./react-CwJFpaho.js";import{B as de,D as fe,L as k,N as pe,P as me,R as he,Y as ge,Z as _e,et as ve,k as ye,tt as A}from"./popover-OWEv6cQz.js";import{i as j}from"./presentationTier-DPVAxTK4.js";import{t as be}from"./useNavigate-sQZthdyT.js";import{$ as xe,Q as Se,Y as Ce,et as we,nt as Te,rt as Ee,tt as De}from"./ChatRightPanel-BCINd0vP.js";import{Q as Oe,vt as ke}from"./messageQueueDrain-B7R7Qmq6.js";import{u as Ae}from"./useSidebarThreadActions-n6EkLATf.js";import{On as je}from"./formatCount-B4KLI651.js";import{t as Me}from"./columns-2-CWlMOClK.js";import{i as Ne}from"./ThreadLinkList-BN5z5EpS.js";import{t as Pe}from"./text-wrap-DSRdSfDm.js";import"./storeSelectors-BichCKDC.js";import{n as Fe,t as M}from"./diffRouteSearch-D2MKN_ah.js";import{t as Ie}from"./skeleton-DfUe6VV_.js";import{t as Le}from"./Virtualizer-CwXeUPla.js";import{n as N,r as Re,t as ze}from"./useDiffFileNavigation-DeuzdD5E.js";import{n as Be}from"./editorPreferences-DqKyA-2Z.js";import{t as Ve}from"./useDiffLayout-DhcXwhBL.js";import{t as He}from"./useTheme-Bdy-BDs-.js";import{n as Ue,t as We}from"./toggle-group-C5ICmqkI.js";import{Jt as Ge}from"./main-Ch0bwS-M.js";var Ke={name:`pilcrow`,size:24,node:[[`path`,{d:`M13 4v16`,key:`8vvj80`}],[`path`,{d:`M17 4v16`,key:`7dpous`}],[`path`,{d:`M19 4H9.5a4.5 4.5 0 0 0 0 9H13`,key:`sh4n9v`}]]};Ke.node;var qe=O(Ke),Je={name:`rows-3`,size:24,node:[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M21 9H3`,key:`1338ky`}],[`path`,{d:`M21 15H3`,key:`9uk58r`}]],aliases:[`panels-top-bottom`]};Je.node;var Ye=O(Je),P=j();function Xe(e){let t={data:null,isLoading:!1,isApplying:!1,error:null},n=0,r=null,i=!1,a=new Set,o=e=>{t=e;for(let e of a)e()},s=(e=!0)=>{n++,r=null,o({...t,data:e?null:t.data,isLoading:!1})},c=()=>{if(i)return Promise.resolve();if(r)return r;let a=++n;o({...t,isLoading:!0,error:null});let s=Promise.resolve().then(e.read).then(e=>{a===n&&o({...t,data:e,isLoading:!1})},e=>{a===n&&o({...t,data:null,isLoading:!1,error:e instanceof Error?e.message:`Local changes unavailable. Refresh to retry.`})}).finally(()=>{r===s&&(r=null)});return r=s,s};return{getSnapshot:()=>t,subscribe:e=>(a.add(e),()=>{a.delete(e)}),invalidate:s,refresh:c,apply:async a=>{if(i||t.isLoading||!t.data)return;let s=t.data,l=++n;r=null,i=!0,o({...t,isApplying:!0,error:null});let u=null;try{await e.apply({cwd:e.cwd,expectedRevision:s.revision,...a})}catch(e){u=e instanceof Error?e.message:`Staging failed. Refresh before retrying.`}finally{i=!1,l===n?(o({...t,data:null,isApplying:!1,error:u}),u||await c()):o({...t,isApplying:!1})}}}}function Ze(e,t){return`ryco:comparison:v1:${JSON.stringify([e,t])}`}function Qe(e,t,n,r){return JSON.stringify([e,t.repositoryPath,t.worktreePath,t.revision,n,n===`base`?t.baseOid:t.headOid,r])}var $e={selection:null,data:null,isLoading:!1,error:null,refMoved:!1};function et(e){let t=$e,n=0,a=!1,c=null,l=Promise.resolve(),u=new Set,d=e=>{t=e;for(let e of u)e()},f=()=>{if(a||!t.selection)return Promise.resolve();if(c)return c;let r=++n,i=t.selection,o=t.data?.source.refOid;d({...t,error:null,isLoading:!0,refMoved:!1});let s=Promise.resolve().then(()=>e.read(i)).then(e=>{!a&&r===n&&d({selection:i,data:e,error:null,isLoading:!1,refMoved:o!==void 0&&o!==e.source.refOid})},e=>{!a&&r===n&&d({selection:i,data:null,isLoading:!1,refMoved:!1,error:e instanceof Error?e.message:`Comparison unavailable. Refresh or choose another reference.`})}).finally(()=>{c===s&&(c=null)});return c=s,s},p=(r,u=!0)=>{if(!a){if(r&&o(s(i)(r))){d({...t,error:`Enter a branch, tag, or commit ID (no revision expressions or options).`});return}n++,c=null,d({...$e,selection:r}),u&&(l=l.then(()=>e.storage.setItem(e.storageKey,JSON.stringify(r))).catch(()=>{a||d({...t,error:`Could not save comparison preference.`})})),f()}};return{getSnapshot:()=>t,subscribe:e=>(u.add(e),()=>{u.delete(e)}),setSelection:p,refresh:f,invalidate:(e=!0)=>{n++,c=null,d({...t,data:e?null:t.data,isLoading:!1})},hydrate:async()=>{let t=n;try{let o=await e.storage.getItem(e.storageKey);if(a||t!==n||o===null)return;let c=s(i)(JSON.parse(o));r(c)&&p(c.value,!1)}catch{}},dispose:()=>{a=!0,n++,u.clear()}}}var F=e(ue(),1);function I(e,t,r,i,o){let s=(0,P.c)(7),c,l;s[0]!==e||s[1]!==r||s[2]!==i||s[3]!==t||s[4]!==o?(c=()=>{if(!i||!t||!r)return;o();let s=()=>{v.isForeground()&&v.isOnline()&&e.refresh()},c=E(ie(r),()=>{e.invalidate(!1),s()}),l=v.subscribe(t=>{t===`offline`||t===`background`?e.invalidate():s()}),u=D(t)?.client,d=le(()=>{let n=D(t)?.client;u!==n&&(u=n,e.invalidate(),n&&s())}),f=a(t),p=n.get(f),m=n.subscribe(f,t=>{(t.phase!==p.phase||t.connectedAt!==p.connectedAt)&&(p=t,e.invalidate(),t.phase===`connected`&&s())});return()=>{e.invalidate(),c(),l(),d(),m()}},l=[e,i,t,r,o],s[0]=e,s[1]=r,s[2]=i,s[3]=t,s[4]=o,s[5]=c,s[6]=l):(c=s[5],l=s[6]),(0,F.useEffect)(c,l)}function tt(e,t,n){let r=(0,P.c)(13),i=t??``,a;r[0]!==t||r[1]!==e?(a=()=>!e||!t?Promise.reject(Error(`Repository unavailable.`)):T(e).vcs.readLocalChanges({cwd:t}),r[0]=t,r[1]=e,r[2]=a):a=r[2];let o;r[3]===e?o=r[4]:(o=async t=>{if(!e)throw Error(`Repository unavailable.`);await T(e).vcs.applyIndexPatch(t)},r[3]=e,r[4]=o);let s;r[5]!==i||r[6]!==a||r[7]!==o?(s=Xe({cwd:i,read:a,apply:o}),r[5]=i,r[6]=a,r[7]=o,r[8]=s):s=r[8];let c=s,l=(0,F.useSyncExternalStore)(c.subscribe,c.getSnapshot);I(c,e,t,n,c.refresh);let u;return r[9]!==c.apply||r[10]!==c.refresh||r[11]!==l?(u={...l,refresh:c.refresh,apply:c.apply},r[9]=c.apply,r[10]=c.refresh,r[11]=l,r[12]=u):u=r[12],u}var L=te();function nt(e){let t=(0,P.c)(15),[n,r]=(0,F.useState)(0),i=e.scope===`staged`?`Unstage`:`Stage`,a=`${i} file ${e.name}`,o=e.disabled||!e.file.fileAction,s=e.file.fileAction?void 0:`Symlink and submodule changes require external Git review.`,c;t[0]===e?c=t[1]:(c=()=>e.onApply({scope:e.scope,fileId:e.file.id}),t[0]=e,t[1]=c);let l;t[2]!==a||t[3]!==o||t[4]!==s||t[5]!==c||t[6]!==i?(l=(0,L.jsxs)(`button`,{type:`button`,className:`rounded px-2 py-1 text-xs hover:bg-foreground/10 disabled:opacity-50`,"aria-label":a,disabled:o,title:s,onClick:c,children:[i,` file`]}),t[2]=a,t[3]=o,t[4]=s,t[5]=c,t[6]=i,t[7]=l):l=t[7];let u;t[8]!==n||t[9]!==e||t[10]!==i?(u=e.file.hunkAction&&(0,L.jsxs)(L.Fragment,{children:[(0,L.jsx)(`select`,{"aria-label":`Hunk in ${e.name}`,className:`max-w-28 rounded border bg-background text-xs`,disabled:e.disabled,value:n,onChange:e=>r(Number(e.target.value)),children:Array.from({length:e.file.hunkCount},R)}),(0,L.jsxs)(`button`,{type:`button`,className:`rounded px-2 py-1 text-xs hover:bg-foreground/10 disabled:opacity-50`,"aria-label":`${i} hunk ${n+1} in ${e.name}`,disabled:e.disabled,onClick:()=>e.onApply({scope:e.scope,fileId:e.file.id,hunkIndex:n}),children:[i,` hunk`]})]}),t[8]=n,t[9]=e,t[10]=i,t[11]=u):u=t[11];let d;return t[12]!==l||t[13]!==u?(d=(0,L.jsxs)(`span`,{className:`flex items-center gap-1`,onClick:rt,children:[l,u]}),t[12]=l,t[13]=u,t[14]=d):d=t[14],d}function R(e,t){return(0,L.jsxs)(`option`,{value:t,children:[`Hunk `,t+1]},t)}function rt(e){return e.stopPropagation()}function z(e,t,n){if(!Number.isSafeInteger(n)||n<1)return null;let r=t===`base`?e.prevName??e.name:e.name;if(r===`/dev/null`)return null;for(let i of e.hunks){let e=t===`base`?i.deletionStart:i.additionStart;for(let a of i.hunkContent){let i=a.type===`context`?a.lines:t===`base`?a.deletions:a.additions;if(n>=e&&n<e+i)return t===`head`&&a.type===`change`?null:{side:t,line:n,filePath:r};e+=i}}return null}function B(e){let t=!1,n=0,r=new Map;return{invalidate(){n++,r.clear()},dispose(){t=!0,n++,r.clear()},read(i){if(t)return Promise.reject(Error(`Comparison changed. Reopen line blame.`));let a=`${Qe(e.environmentId,e.source,i.side,i.filePath)}:${i.line}`,o=r.get(a);if(o)return o;let s=n,c=Promise.resolve().then(()=>{if(t||s!==n)throw Error(`Comparison changed. Reopen line blame.`);return e.read({cwd:e.source.worktreePath,oid:i.side===`base`?e.source.baseOid:e.source.headOid,filePath:i.filePath,line:i.line})}).then(e=>{if(t||s!==n)throw Error(`Comparison changed. Reopen line blame.`);return e}).catch(e=>{throw r.get(a)===c&&r.delete(a),e});return r.set(a,c),r.size>32&&r.delete(r.keys().next().value),c}}}function it(e){let t=(0,P.c)(74),[n,r]=(0,F.useState)(e.initialSide),[i,a]=(0,F.useState)(String(e.initialLine)),o;t[0]!==e.initialLine||t[1]!==e.initialSide?(o={side:e.initialSide,line:e.initialLine},t[0]=e.initialLine,t[1]=e.initialSide,t[2]=o):o=t[2];let[s,c]=(0,F.useState)(o),l;t[3]===e.environmentId?l=t[4]:(l=t=>T(e.environmentId).vcs.readLineBlame(t),t[3]=e.environmentId,t[4]=l);let u;t[5]!==e.environmentId||t[6]!==e.source||t[7]!==l?(u=B({environmentId:e.environmentId,source:e.source,read:l}),t[5]=e.environmentId,t[6]=e.source,t[7]=l,t[8]=u):u=t[8];let d=u,[f,p]=(0,F.useState)(null),m;t[9]!==e.file||t[10]!==s.line||t[11]!==s.side?(m=z(e.file,s.side,s.line),t[9]=e.file,t[10]=s.line,t[11]=s.side,t[12]=m):m=t[12];let h=m,g=f?.request===s&&f.reader===d?f:null,_=h?g?.result:null,v=h?g?.error:`Choose a displayed context or deleted line. Added lines have no blame here.`,y=h!==null&&g===null,b,x;t[13]===d?(b=t[14],x=t[15]):(b=()=>()=>d.invalidate(),x=[d],t[13]=d,t[14]=b,t[15]=x),(0,F.useEffect)(b,x);let S,C;t[16]!==d||t[17]!==s||t[18]!==h?(S=()=>{let e=!0;if(h)return d.read(h).then(t=>{e&&p({request:s,reader:d,result:t,error:null})},()=>{e&&p({request:s,reader:d,result:null,error:`Blame unavailable. Retry or refresh the comparison.`})}),()=>{e=!1}},C=[d,h,s],t[16]=d,t[17]=s,t[18]=h,t[19]=S,t[20]=C):(S=t[19],C=t[20]),(0,F.useEffect)(S,C);let w;t[21]===e?w=t[22]:(w=t=>{t||e.onClose()},t[21]=e,t[22]=w);let te;t[23]===Symbol.for(`react.memo_cache_sentinel`)?(te=(0,L.jsx)(me,{children:`Line blame`}),t[23]=te):te=t[23];let ne;t[24]===e.file.name?ne=t[25]:(ne=(0,L.jsx)(ye,{className:`mt-1 break-all`,children:e.file.name}),t[24]=e.file.name,t[25]=ne);let re;t[26]!==i||t[27]!==n?(re=e=>{e.preventDefault(),c({side:n,line:Number(i)})},t[26]=i,t[27]=n,t[28]=re):re=t[28];let ie,E,ae;t[29]===Symbol.for(`react.memo_cache_sentinel`)?(ie=e=>r(e.target.value),E=(0,L.jsx)(`option`,{value:`base`,children:`Base`}),ae=(0,L.jsx)(`option`,{value:`head`,children:`Head`}),t[29]=ie,t[30]=E,t[31]=ae):(ie=t[29],E=t[30],ae=t[31]);let D;t[32]===n?D=t[33]:(D=(0,L.jsxs)(`label`,{className:`flex flex-col gap-1 text-xs`,children:[`Side`,(0,L.jsxs)(`select`,{className:`h-8 rounded border bg-background px-2`,value:n,onChange:ie,children:[E,ae]})]}),t[32]=n,t[33]=D);let oe;t[34]===Symbol.for(`react.memo_cache_sentinel`)?(oe=e=>a(e.target.value),t[34]=oe):oe=t[34];let se;t[35]===i?se=t[36]:(se=(0,L.jsxs)(`label`,{className:`flex min-w-0 flex-1 flex-col gap-1 text-xs`,children:[`Line`,(0,L.jsx)(`input`,{className:`h-8 w-full rounded border bg-background px-2`,type:`number`,min:`1`,step:`1`,required:!0,value:i,onChange:oe})]}),t[35]=i,t[36]=se);let O;t[37]===y?O=t[38]:(O=(0,L.jsx)(ee,{type:`submit`,size:`sm`,disabled:y,children:`Look up`}),t[37]=y,t[38]=O);let ce;t[39]!==re||t[40]!==D||t[41]!==se||t[42]!==O?(ce=(0,L.jsxs)(`form`,{className:`mt-4 flex items-end gap-2`,onSubmit:re,children:[D,se,O]}),t[39]=re,t[40]=D,t[41]=se,t[42]=O,t[43]=ce):ce=t[43];let le=s.side===`base`?`Base`:`Head`,ue=s.line,de=s.side===`base`?e.source.baseOid:e.source.headOid,k;t[44]===de?k=t[45]:(k=de.slice(0,12),t[44]=de,t[45]=k);let he;t[46]===k?he=t[47]:(he=(0,L.jsx)(`span`,{className:`font-mono`,children:k}),t[46]=k,t[47]=he);let ge;t[48]!==s.line||t[49]!==le||t[50]!==he?(ge=(0,L.jsxs)(`p`,{className:`text-xs text-muted-foreground`,children:[le,` line `,ue,` ·`,` `,he]}),t[48]=s.line,t[49]=le,t[50]=he,t[51]=ge):ge=t[51];let _e;t[52]===y?_e=t[53]:(_e=y&&(0,L.jsx)(`p`,{children:`Loading blame…`}),t[52]=y,t[53]=_e);let ve;t[54]===v?ve=t[55]:(ve=v&&(0,L.jsx)(`p`,{role:`status`,children:v}),t[54]=v,t[55]=ve);let A;t[56]===_?A=t[57]:(A=_?.kind===`unavailable`&&(0,L.jsx)(`p`,{children:_.reason}),t[56]=_,t[57]=A);let j;t[58]===_?j=t[59]:(j=_?.kind===`committed`&&(0,L.jsxs)(L.Fragment,{children:[(0,L.jsx)(`p`,{className:`break-words font-medium`,children:_.summary}),(0,L.jsxs)(`p`,{className:`break-words text-muted-foreground`,children:[_.author,_.authorTime?` · ${new Date(_.authorTime).toLocaleDateString()}`:``]}),(0,L.jsx)(`p`,{className:`break-all font-mono text-xs`,title:_.oid,children:_.oid})]}),t[58]=_,t[59]=j);let be;t[60]!==y||t[61]!==ge||t[62]!==_e||t[63]!==ve||t[64]!==A||t[65]!==j?(be=(0,L.jsxs)(`div`,{className:`mt-4 min-h-24 space-y-2 text-sm`,"aria-live":`polite`,"aria-busy":y,children:[ge,_e,ve,A,j]}),t[60]=y,t[61]=ge,t[62]=_e,t[63]=ve,t[64]=A,t[65]=j,t[66]=be):be=t[66];let xe;t[67]!==ne||t[68]!==ce||t[69]!==be?(xe=(0,L.jsxs)(pe,{className:`max-w-md p-5`,children:[te,ne,ce,be]}),t[67]=ne,t[68]=ce,t[69]=be,t[70]=xe):xe=t[70];let Se;return t[71]!==xe||t[72]!==w?(Se=(0,L.jsx)(fe,{open:!0,onOpenChange:w,children:xe}),t[71]=xe,t[72]=w,t[73]=Se):Se=t[73],Se}function at(e){let t=(0,P.c)(46),[n,r]=(0,F.useState)(e.selection?.ref??``),[i,a]=(0,F.useState)(e.selection?.mode??`mergeBase`),o;t[0]!==n||t[1]!==i||t[2]!==e?(o=t=>{t.preventDefault(),e.onSelect({ref:n.trim(),mode:i})},t[0]=n,t[1]=i,t[2]=e,t[3]=o):o=t[3];let s=e.turnSelected??!e.selection,c;t[4]===e?c=t[5]:(c=()=>e.onSelect(null),t[4]=e,t[5]=c);let l;t[6]!==s||t[7]!==c?(l=(0,L.jsx)(`button`,{type:`button`,className:`rounded border px-2 py-1`,"aria-pressed":s,onClick:c,children:`Turn review`}),t[6]=s,t[7]=c,t[8]=l):l=t[8];let u,d,f;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(u=e=>a(e.target.value),d=(0,L.jsx)(`option`,{value:`mergeBase`,children:`Branch changes → HEAD`}),f=(0,L.jsx)(`option`,{value:`direct`,children:`Commit to HEAD`}),t[9]=u,t[10]=d,t[11]=f):(u=t[9],d=t[10],f=t[11]);let p;t[12]===i?p=t[13]:(p=(0,L.jsxs)(`select`,{"aria-label":`Comparison mode`,className:`rounded border bg-background px-2 py-1`,value:i,onChange:u,children:[d,f]}),t[12]=i,t[13]=p);let m;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(m=e=>r(e.target.value),t[14]=m):m=t[14];let h;t[15]===n?h=t[16]:(h=(0,L.jsx)(`input`,{"aria-label":`Branch, tag, or commit`,placeholder:`Branch, tag, or commit`,className:`min-w-[160px] flex-1 rounded border bg-background px-2 py-1`,value:n,maxLength:256,onChange:m}),t[15]=n,t[16]=h);let g;t[17]===n?g=t[18]:(g=n.trim(),t[17]=n,t[18]=g);let _=!g,v;t[19]===_?v=t[20]:(v=(0,L.jsx)(`button`,{type:`submit`,className:`rounded border px-2 py-1`,disabled:_,children:`Compare`}),t[19]=_,t[20]=v);let y;t[21]!==e.isLoading||t[22]!==e.onRefresh||t[23]!==e.selection?(y=e.selection&&(0,L.jsx)(`button`,{type:`button`,className:`rounded border px-2 py-1`,onClick:e.onRefresh,disabled:e.isLoading,children:`Refresh comparison`}),t[21]=e.isLoading,t[22]=e.onRefresh,t[23]=e.selection,t[24]=y):y=t[24];let b;t[25]!==o||t[26]!==v||t[27]!==y||t[28]!==l||t[29]!==p||t[30]!==h?(b=(0,L.jsxs)(`form`,{className:`flex flex-wrap items-center gap-2`,onSubmit:o,children:[l,p,h,v,y]}),t[25]=o,t[26]=v,t[27]=y,t[28]=l,t[29]=p,t[30]=h,t[31]=b):b=t[31];let x;t[32]!==e.data||t[33]!==e.refMoved||t[34]!==e.selection?(x=e.selection&&(0,L.jsxs)(`p`,{className:`mt-2 break-words text-muted-foreground`,children:[e.selection.mode===`mergeBase`?`Merge-base of`:`Commit`,` `,(0,L.jsx)(`strong`,{children:e.selection.ref}),e.selection.mode===`mergeBase`?` and HEAD`:``,` → HEAD. Staged, unstaged, and untracked changes are excluded.`,e.data&&(0,L.jsxs)(L.Fragment,{children:[` `,`Resolved `,e.data.source.baseOid.slice(0,8),` →`,` `,e.data.source.headOid.slice(0,8),`.`]}),e.refMoved&&(0,L.jsx)(L.Fragment,{children:` The selected reference moved; showing its current commits.`})]}),t[32]=e.data,t[33]=e.refMoved,t[34]=e.selection,t[35]=x):x=t[35];let S;t[36]!==e.data||t[37]!==e.isLoading?(S=e.isLoading&&(0,L.jsx)(`p`,{role:`status`,className:`mt-2 text-muted-foreground`,children:e.data?`Refreshing; showing the previous committed snapshot.`:`Loading comparison…`}),t[36]=e.data,t[37]=e.isLoading,t[38]=S):S=t[38];let C;t[39]===e.error?C=t[40]:(C=e.error&&(0,L.jsx)(`p`,{role:`alert`,className:`mt-2 text-destructive`,children:e.error}),t[39]=e.error,t[40]=C);let w;return t[41]!==b||t[42]!==x||t[43]!==S||t[44]!==C?(w=(0,L.jsxs)(`section`,{className:`shrink-0 border-b border-border px-3 py-2 text-xs`,"aria-label":`Repository comparison`,children:[b,x,S,C]}),t[41]=b,t[42]=x,t[43]=S,t[44]=C,t[45]=w):w=t[45],w}var ot=e(f(),1),st=new Set([`avif`,`bmp`,`gif`,`ico`,`jpeg`,`jpg`,`png`,`webp`]);function ct(e){let t=e.split(`/`).at(-1)??e,n=t.lastIndexOf(`.`);return n>0&&st.has(t.slice(n+1).toLowerCase())}function lt(e){return e&&/^[0-9a-f]{4,64}$/.test(e)&&!/^0+$/.test(e)?e:null}function ut(e){let{fileDiff:t}=e,n=t.prevName??t.name;if(!ct(t.name)&&!ct(n)||t.hunks.length>0)return[];let r=t.type===`new`?null:lt(t.prevObjectId),i=t.type===`deleted`?null:lt(t.newObjectId),a=r?{side:`before`,path:n,source:{kind:`blob`,oid:r}}:null,o=i?e.afterIsWorkingTree?{side:`after`,path:t.name,source:{kind:`working-tree`,relativePath:t.name,version:i}}:{side:`after`,path:t.name,source:{kind:`blob`,oid:i}}:null;return a&&o?[{...a,label:`Before`},{...o,label:`After`}]:a?[{...a,label:t.type===`deleted`?`Deleted`:`Before`}]:o?[{...o,label:t.type===`new`?`Added`:`After`}]:[]}function V(e){return JSON.stringify(e.source.kind===`blob`?[e.environmentId,e.cwd,`blob`,e.source.oid]:[e.environmentId,e.cwd,`working-tree`,e.source.relativePath,e.source.version])}var H={status:`loading`},dt=new A(64,50331648),U=new Map;function ft(e,t,n){let r=V({environmentId:e,cwd:t,source:n}),i=dt.get(r);if(i)return Promise.resolve(i);let a=U.get(r);if(a)return a;let o=Promise.resolve().then(()=>{let r=T(e);return n.kind===`blob`?r.vcs.readImageBlob({cwd:t,oid:n.oid}):r.projects.readFileBinary({cwd:t,relativePath:n.relativePath}).then(e=>({kind:`image`,...e}))}).then(e=>{let t=e.kind===`image`?{status:`ready`,src:`data:${e.mimeType};base64,${e.dataBase64}`,sizeBytes:e.sizeBytes}:{status:`unavailable`,reason:e.reason};return dt.set(r,t,t.status===`ready`?t.src.length*2:512),t}).catch(e=>({status:`unavailable`,reason:Ae(e,`Couldn’t load this image.`)})).finally(()=>U.delete(r));return U.set(r,o),o}function W(e,t,n){let r=(0,P.c)(21),i;r[0]!==t||r[1]!==e||r[2]!==n?(i=()=>n.map(n=>dt.get(V({environmentId:e,cwd:t,source:n.source}))??H),r[0]=t,r[1]=e,r[2]=n,r[3]=i):i=r[3];let a=i,o;r[4]!==a||r[5]!==n?(o=()=>({targets:n,images:a()}),r[4]=a,r[5]=n,r[6]=o):o=r[6];let[s,c]=(0,F.useState)(o),l;r[7]!==a||r[8]!==s.images||r[9]!==s.targets||r[10]!==n?(l=s.targets===n?s.images:a(),r[7]=a,r[8]=s.images,r[9]=s.targets,r[10]=n,r[11]=l):l=r[11];let u=l,d;r[12]!==t||r[13]!==e||r[14]!==u||r[15]!==n?(d=()=>{let r=!0;return c(e=>e.targets===n?e:{targets:n,images:u}),n.forEach((i,a)=>{u[a]?.status===`loading`&&ft(e,t,i.source).then(e=>{r&&c(t=>t.targets===n?{targets:n,images:t.images.with(a,e)}:t)})}),()=>{r=!1}},r[12]=t,r[13]=e,r[14]=u,r[15]=n,r[16]=d):d=r[16];let f;return r[17]!==t||r[18]!==e||r[19]!==n?(f=[t,e,n],r[17]=t,r[18]=e,r[19]=n,r[20]=f):f=r[20],(0,F.useEffect)(d,f),u}var G=(0,F.memo)(function(e){let t=(0,P.c)(31),{target:n,image:r,dimensions:i,onDimensions:a,onOpen:o}=e,s,l,u;if(t[0]!==i||t[1]!==r.reason||t[2]!==r.sizeBytes||t[3]!==r.src||t[4]!==r.status||t[5]!==a||t[6]!==o||t[7]!==n.label||t[8]!==n.path||t[9]!==n.side){let e=c(`flex h-48 w-full items-center justify-center overflow-hidden rounded-md border bg-background/60 p-1`,n.side===`before`?`border-destructive/35`:`border-success/35`),d=i?`${i.width} × ${i.height}`:null,f;t[13]!==r.sizeBytes||t[14]!==r.status?(f=r.status===`ready`?Ee(r.sizeBytes):null,t[13]=r.sizeBytes,t[14]=r.status,t[15]=f):f=t[15];let p;t[16]!==d||t[17]!==f?(p=[d,f].filter(K),t[16]=d,t[17]=f,t[18]=p):p=t[18],s=p,l=`m-0 flex min-w-0 flex-col gap-1.5`,u=r.status===`ready`?(0,L.jsx)(`button`,{type:`button`,className:c(e,`cursor-zoom-in transition-colors hover:bg-background focus-visible:outline-2 focus-visible:outline-ring`),"aria-label":`Open ${n.label.toLowerCase()} image of ${n.path}`,onClick:()=>o(n.side),children:(0,L.jsx)(`img`,{src:r.src,alt:`${n.label}: ${n.path}`,className:`max-h-full max-w-full select-none object-contain`,decoding:`async`,draggable:!1,onLoad:e=>a(n.side,{width:e.currentTarget.naturalWidth,height:e.currentTarget.naturalHeight})})}):r.status===`loading`?(0,L.jsx)(Ie,{className:c(e,`border-transparent`)}):(0,L.jsx)(`div`,{role:`status`,className:c(e,`px-3 text-center text-[11px] text-muted-foreground`),children:r.reason}),t[0]=i,t[1]=r.reason,t[2]=r.sizeBytes,t[3]=r.src,t[4]=r.status,t[5]=a,t[6]=o,t[7]=n.label,t[8]=n.path,t[9]=n.side,t[10]=s,t[11]=l,t[12]=u}else s=t[10],l=t[11],u=t[12];let d=n.side===`before`?`text-destructive`:`text-success`,f;t[19]===d?f=t[20]:(f=c(`font-medium`,d),t[19]=d,t[20]=f);let p;t[21]!==f||t[22]!==n.label?(p=(0,L.jsx)(`span`,{className:f,children:n.label}),t[21]=f,t[22]=n.label,t[23]=p):p=t[23];let m=s.length>0?` · ${s.join(` · `)}`:null,h;t[24]!==p||t[25]!==m?(h=(0,L.jsxs)(`figcaption`,{className:`truncate text-[11px] text-muted-foreground/80`,children:[p,m]}),t[24]=p,t[25]=m,t[26]=h):h=t[26];let g;return t[27]!==l||t[28]!==u||t[29]!==h?(g=(0,L.jsxs)(`figure`,{className:l,children:[u,h]}),t[27]=l,t[28]=u,t[29]=h,t[30]=g):g=t[30],g}),pt=(0,F.memo)(function(e){let t=(0,P.c)(26),{environmentId:n,cwd:r,fileDiff:i,afterIsWorkingTree:a}=e,o;t[0]!==a||t[1]!==i?(o=ut({fileDiff:i,afterIsWorkingTree:a}),t[0]=a,t[1]=i,t[2]=o):o=t[2];let s=o,l=W(n,r,s),u;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(u={},t[3]=u):u=t[3];let[d,f]=(0,F.useState)(u),[p,m]=(0,F.useState)(null),h;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(h=(e,t)=>{f(n=>({...n,[e]:t}))},t[4]=h):h=t[4];let g=h,_;t[5]!==d||t[6]!==p||t[7]!==l||t[8]!==s?(_=p===null?null:De(s.map((e,t)=>{let n=l[t],r=d[e.side];return{id:e.side,name:`${e.label} — ${e.path}`,...n?.status===`ready`?{previewUrl:n.src}:{},...r?{width:r.width,height:r.height}:{}}}),p),t[5]=d,t[6]=p,t[7]=l,t[8]=s,t[9]=_):_=t[9];let v=_,y;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(y=()=>m(null),t[10]=y):y=t[10];let b=y;if(s.length===0)return null;let x=s.length>1&&`grid-cols-2`,S;t[11]===x?S=t[12]:(S=c(`grid gap-3 p-3`,x),t[11]=x,t[12]=S);let C;if(t[13]!==d||t[14]!==l||t[15]!==s){let e;t[17]!==d||t[18]!==l?(e=(e,t)=>(0,L.jsx)(G,{target:e,image:l[t]??H,dimensions:d[e.side],onDimensions:g,onOpen:m},e.side),t[17]=d,t[18]=l,t[19]=e):e=t[19],C=s.map(e),t[13]=d,t[14]=l,t[15]=s,t[16]=C}else C=t[16];let w;t[20]===v?w=t[21]:(w=v?(0,ot.createPortal)((0,L.jsx)(Te,{preview:v,onClose:b}),document.body):null,t[20]=v,t[21]=w);let T;return t[22]!==S||t[23]!==C||t[24]!==w?(T=(0,L.jsxs)(`div`,{className:S,"data-diff-image-preview":``,children:[C,w]}),t[22]=S,t[23]=C,t[24]=w,t[25]=T):T=t[25],T});function K(e){return e!==null}function mt(e){let t=(0,P.c)(13),{environmentId:n,repositoryPath:r,cwd:i,ignoreWhitespace:a,enabled:o}=e,s;if(t[0]!==i||t[1]!==n||t[2]!==a||t[3]!==r){let e;t[5]!==i||t[6]!==n||t[7]!==a?(e=e=>!n||!i?Promise.reject(Error(`Repository unavailable.`)):T(n).vcs.readComparison({cwd:i,selection:e,ignoreWhitespace:a}),t[5]=i,t[6]=n,t[7]=a,t[8]=e):e=t[8],s=et({storage:u,storageKey:Ze(n??``,r??``),read:e}),t[0]=i,t[1]=n,t[2]=a,t[3]=r,t[4]=s}else s=t[4];let c=s,l=(0,F.useSyncExternalStore)(c.subscribe,c.getSnapshot);I(c,n,i,o&&!!r,c.hydrate);let d;return t[9]!==c.refresh||t[10]!==c.setSelection||t[11]!==l?(d={...l,setSelection:c.setSelection,refresh:c.refresh},t[9]=c.refresh,t[10]=c.setSelection,t[11]=l,t[12]=d):d=t[12],d}function ht(e){let{environmentId:t,threadId:n,fromTurnCount:r,toTurnCount:i,ignoreWhitespace:a,cacheScope:o}=e,s=e.enabled,c=g(e)?d(e):null;(0,F.useEffect)(()=>{if(c!==null)return b({environmentId:t,threadId:n,fromTurnCount:r,toTurnCount:i,ignoreWhitespace:a,...o===void 0?{}:{cacheScope:o},...s===void 0?{}:{enabled:s}})},[c,t,n,r,i,a,o,s]);let l=x(c===null?_:m(c));return c===null?y:l}var gt=`\0`,q=1/0,_t=1;function vt(e){return`${e.turnId}${gt}${e.filePath}${gt}${e.blobSha}`}var yt=class{#e;#t;constructor(e=50){if(!Number.isInteger(e)||e<=0)throw RangeError(`DiffParseCache maxEntries must be a positive integer, received ${String(e)}`);this.#t=e,this.#e=new A(e,q)}get maxEntries(){return this.#t}get(e){return this.#e.get(vt(e))??void 0}set(e,t){this.#e.set(vt(e),t,_t)}getOrCompute(e,t){let n=this.get(e);if(n!==void 0)return n;let r=t();return this.set(e,r),r}clear(){this.#e.clear()}};function bt(e){return e.name??e.prevName??``}function xt(e,t=!1){let n=e.trim();return t?n:n.toLowerCase()}function J(e,t){t.text!==void 0&&e.push({fileIndex:t.fileIndex,field:t.field,text:t.text,normalizedText:t.text.toLowerCase(),...t.lineIndex===void 0?{}:{lineIndex:t.lineIndex},...t.unifiedLineIndex===void 0?{}:{unifiedLineIndex:t.unifiedLineIndex},...t.splitLineIndex===void 0?{}:{splitLineIndex:t.splitLineIndex}})}function St(e,t,n){t.additionLines.forEach((t,r)=>{J(e,{fileIndex:n,field:`addition`,lineIndex:r,text:t})}),t.deletionLines.forEach((t,r)=>{J(e,{fileIndex:n,field:`deletion`,lineIndex:r,text:t})})}function Ct(e,t,n){if(!t.hunks||t.hunks.length===0)return!1;for(let r of t.hunks){let i=r.unifiedLineStart,a=r.splitLineStart;for(let o of r.hunkContent){if(o.type===`context`){for(let r=0;r<o.lines;r+=1){let s=o.additionLineIndex+r,c=o.deletionLineIndex+r;J(e,{fileIndex:n,field:`context`,lineIndex:s,unifiedLineIndex:i+r,splitLineIndex:a+r,text:t.additionLines[s]??t.deletionLines[c]})}i+=o.lines,a+=o.lines;continue}for(let r=0;r<o.deletions;r+=1){let s=o.deletionLineIndex+r;J(e,{fileIndex:n,field:`deletion`,lineIndex:s,unifiedLineIndex:i+r,splitLineIndex:a+r,text:t.deletionLines[s]})}for(let r=0;r<o.additions;r+=1){let s=o.additionLineIndex+r;J(e,{fileIndex:n,field:`addition`,lineIndex:s,unifiedLineIndex:i+o.deletions+r,splitLineIndex:a+r,text:t.additionLines[s]})}i+=o.deletions+o.additions,a+=Math.max(o.deletions,o.additions)}}return!0}function wt(e){let t=[];return e.forEach((e,n)=>{J(t,{text:bt(e),fileIndex:n,field:`path`}),e.prevName&&J(t,{text:bt({name:e.prevName}),fileIndex:n,field:`previousPath`}),Ct(t,e,n)||St(t,e,n)}),{records:t}}function Tt(e){let t=e.caseSensitive?e.record.text:e.record.normalizedText,n=[],r=0;for(;;){let i=t.indexOf(e.needle,r);if(i===-1)return n;let a=i+e.needle.length;n.push({fileIndex:e.record.fileIndex,field:e.record.field,...e.record.lineIndex===void 0?{}:{lineIndex:e.record.lineIndex},...e.record.unifiedLineIndex===void 0?{}:{unifiedLineIndex:e.record.unifiedLineIndex},...e.record.splitLineIndex===void 0?{}:{splitLineIndex:e.record.splitLineIndex},start:i,end:a}),r=a>i?a:i+1}}function Et(e){return!Array.isArray(e)}function Dt(e,t,n){let r=n?.caseSensitive??!1,i=xt(t,r);if(!i)return[];let a=Et(e)?e:wt(e),o=[];for(let e of a.records)o.push(...Tt({record:e,needle:i,caseSensitive:r}));return o}function Ot(e){return[...new Set(e.map(e=>e.fileIndex))]}function kt(e){let t=new Map;for(let n of e){let e=t.get(n.fileIndex);e?e.push(n):t.set(n.fileIndex,[n])}return t}function At(e,t,n){return t<=0?0:(e+n+t)%t}function jt(e,t){return e.field===`path`||e.field===`previousPath`?null:(t===`split`?e.splitLineIndex:e.unifiedLineIndex)??e.lineIndex??null}function Mt(e){return e===`addition`||e===`deletion`||e===`context`}function Nt(e){if(!e)return null;let[t,n]=e.split(`,`),r=Number.parseInt(t??``,10);if(!Number.isFinite(r))return null;let i=Number.parseInt(n??``,10);return{stacked:r,split:Number.isFinite(i)?i:r}}function Pt(e,t){if(!Mt(e.field)||jt(e,t.renderMode)!==(t.renderMode===`split`?t.lineIndexes.split:t.lineIndexes.stacked))return!1;switch(e.field){case`addition`:return t.lineType===`change-addition`||t.lineType===`addition`;case`deletion`:return t.lineType===`change-deletion`||t.lineType===`deletion`;case`context`:return t.lineType===`context`||t.lineType===`context-expanded`}}function Ft(e){let t=e.cwd?Ce(e.filePath,e.cwd):e.filePath;return typeof e.lineNumber==`number`?`${t}:${e.lineNumber}`:t}var It=`
|
|
2
|
+
[data-title] {
|
|
3
|
+
cursor: pointer;
|
|
4
|
+
transition:
|
|
5
|
+
color 120ms ease,
|
|
6
|
+
text-decoration-color 120ms ease;
|
|
7
|
+
text-decoration: underline;
|
|
8
|
+
text-decoration-color: transparent;
|
|
9
|
+
text-underline-offset: 2px;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
[data-title]:hover {
|
|
13
|
+
color: color-mix(in srgb, var(--foreground) 84%, var(--primary)) !important;
|
|
14
|
+
text-decoration-color: currentColor;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
[data-interactive-line-numbers] [data-line-number-content] {
|
|
18
|
+
cursor: pointer;
|
|
19
|
+
}
|
|
20
|
+
`,Lt=`
|
|
21
|
+
::highlight(ryco-diff-search-match) {
|
|
22
|
+
background-color: color-mix(in srgb, var(--warning) 60%, transparent);
|
|
23
|
+
color: var(--foreground);
|
|
24
|
+
}
|
|
25
|
+
`,Rt=`${k}${It}${Lt}`,zt=`${k}${Lt}`;function Bt(e){return bt(e)}function Vt(e){return!e||e.kind!==`files`?[]:e.files.toSorted((e,t)=>Bt(e).localeCompare(Bt(t),void 0,{numeric:!0,sensitivity:`base`}))}var Ht=new yt;function Ut(e){return e.cacheKey??`${e.prevName??`none`}:${e.name}`}var Wt=`ryco-diff-search-match`,Gt=150,Kt=80,qt=1600;function Jt(){return typeof CSS<`u`&&CSS.highlights!==void 0&&globalThis.Highlight!==void 0}function Yt(e,t,n=qt){let r=e.getBoundingClientRect(),i=t.getBoundingClientRect();return r.bottom>=i.top-n&&r.top<=i.bottom+n&&r.right>=i.left-n&&r.left<=i.right+n}function Xt(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_TEXT,{acceptNode(e){let t=e.parentElement;return t&&t.closest(`[data-line-number-content]`)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT}}),r=n.nextNode(),i=0;for(;r;){let e=r,a=i+e.data.length;t.push({node:e,start:i,end:a}),i=a,r=n.nextNode()}return{offsets:t,textLength:i}}function Zt(e,t,n){for(let r of e)if(!(t<r.start||t>r.end)&&(t!==r.end||n!==`start`))return{node:r.node,offset:t-r.start};return null}function Qt(e,t,n){let{offsets:r,textLength:i}=Xt(e);if(r.length===0||t.start<0||t.end>i||t.start>=t.end)return;let a=Zt(r,t.start,`start`),o=Zt(r,t.end,`end`);if(!a||!o)return;let s=document.createRange();s.setStart(a.node,a.offset),s.setEnd(o.node,o.offset),n.push(s)}function $t(e){let t=Nt(e.lineIndexAttr);return t?e.matches.filter(n=>Pt(n,{renderMode:e.renderMode,lineIndexes:t,lineType:e.lineType})):[]}function en(e){if(jt(e.match,e.renderMode)===null)return null;let t=e.fileElement.querySelectorAll(`diffs-container`);for(let n of t){let t=n.shadowRoot?.querySelectorAll(`[data-line][data-line-index]`);for(let n of t??[]){let t=Nt(n.getAttribute(`data-line-index`));if(t&&Pt(e.match,{renderMode:e.renderMode,lineIndexes:t,lineType:n.getAttribute(`data-line-type`)}))return n}}return null}function tn(e){let t=[],n=e.rootElement.querySelectorAll(`[data-diff-file-index]`);for(let r of n){if(!Yt(r,e.viewportElement))continue;let n=r.dataset.diffFileIndex,i=n?Number.parseInt(n,10):NaN;if(!Number.isFinite(i))continue;let a=e.matchesByFileIndex.get(i);if(!a||a.length===0)continue;let o=r.querySelectorAll(`diffs-container`);for(let n of o){let r=n.shadowRoot?.querySelectorAll(`[data-line][data-line-index]`);for(let n of r??[]){if(!Yt(n,e.viewportElement))continue;let r=$t({matches:a,renderMode:e.renderMode,lineIndexAttr:n.getAttribute(`data-line-index`),lineType:n.getAttribute(`data-line-type`)});for(let e of r)Qt(n,e,t)}}}return t}function nn(e){switch(e.type){case`new`:return`text-[var(--diffs-addition-base)]`;case`deleted`:return`text-[var(--diffs-deletion-base)]`;case`change`:case`rename-pure`:case`rename-changed`:return`text-[var(--diffs-modified-base)]`;default:return`text-muted-foreground/80`}}function rn(e){let n=(0,P.c)(288),{mode:r}=e,i=r===void 0?`inline`:r;Oe(`DiffPanel`);let a=be(),{resolvedTheme:o}=He(),s=l(),u=i===`phone`,[d,f]=Ve(),m=u?`stacked`:d,[h,g]=(0,F.useState)(u?!0:s.diffWordWrap),[_,v]=(0,F.useState)(s.diffIgnoreWhitespace),[y,b]=(0,F.useState)(_n),[x,T]=(0,F.useState)(``),ee;n[0]===Symbol.for(`react.memo_cache_sentinel`)?(ee={wait:Gt},n[0]=ee):ee=n[0];let[te]=je(x,ee),ie;n[1]!==te||n[2]!==x?(ie=x.trim().length===0?``:te,n[1]=te,n[2]=x,n[3]=ie):ie=n[3];let E=ie,[D,O]=(0,F.useState)(0),le=(0,F.useRef)(null),ue=(0,F.useRef)(null),[fe]=(0,F.useState)(gn),k=(0,F.useRef)(null),pe=(0,F.useRef)(null),me=(0,F.useRef)(!1),[ye,A]=(0,F.useState)(!1),[j,Ce]=(0,F.useState)(!1),Te;n[4]===Symbol.for(`react.memo_cache_sentinel`)?(Te={strict:!1,select:hn},n[4]=Te):Te=n[4];let Ee=C(Te),De;n[5]===Symbol.for(`react.memo_cache_sentinel`)?(De={strict:!1,select:mn},n[5]=De):De=n[5];let Ae=Ge(De),Ne=Ae.diff===`1`,M=Ee?.threadId??null,Ie;n[6]===Ee?Ie=n[7]:(Ie=w(Ee),n[6]=Ee,n[7]=Ie);let N=se(Ie),Ke=N?.projectId??null,Je;n[8]!==Ke||n[9]!==N?(Je=e=>N&&Ke?re(e,{environmentId:N.environmentId,projectId:Ke}):void 0,n[8]=Ke,n[9]=N,n[10]=Je):Je=n[10];let Xe=se(Je),Ze=N?.worktreePath??Xe?.cwd,Qe=N?.environmentId??null,$e=Ze??null,et;n[11]!==Qe||n[12]!==$e?(et={environmentId:Qe,cwd:$e},n[11]=Qe,n[12]=$e,n[13]=et):et=n[13];let I=p(et).data?.isRepo??!0,[R,rt]=(0,F.useState)(null),z=R!==null&&!u&&Ae.diffTurnId==null,B=tt(N?.environmentId??null,Ze??null,Ne&&I&&z),ot=N?.environmentId??null,st=Xe?.cwd??null,ct=Ze??null,lt=Ne&&I&&!u&&Ae.diffTurnId==null&&!z,ut;n[14]!==_||n[15]!==ot||n[16]!==st||n[17]!==ct||n[18]!==lt?(ut={environmentId:ot,repositoryPath:st,cwd:ct,ignoreWhitespace:_,enabled:lt},n[14]=_,n[15]=ot,n[16]=st,n[17]=ct,n[18]=lt,n[19]=ut):ut=n[19];let V=mt(ut),H=!z&&!u&&Ae.diffTurnId==null&&V.selection!==null,{turnDiffSummaries:dt,inferredCheckpointTurnCountByTurnId:U}=we(N),ft;if(n[20]!==U||n[21]!==dt){let e;n[23]===U?e=n[24]:(e=(e,t)=>{let n=e.checkpointTurnCount??U[e.turnId]??0,r=t.checkpointTurnCount??U[t.turnId]??0;return n===r?t.completedAt.localeCompare(e.completedAt):r-n},n[23]=U,n[24]=e),ft=[...dt].toSorted(e),n[20]=U,n[21]=dt,n[22]=ft}else ft=n[22];let W=ft,G=Ae.diffTurnId??null,K=G===null?null:Ae.diffFilePath??null,gt;n[25]!==W||n[26]!==G?(gt=G===null?void 0:W.find(e=>e.turnId===G)??W[0],n[25]=W,n[26]=G,n[27]=gt):gt=n[27];let q=gt,_t=q&&(q.checkpointTurnCount??U[q.turnId]),vt;n[28]===_t?vt=n[29]:(vt=typeof _t==`number`?{fromTurnCount:Math.max(0,_t-1),toTurnCount:_t}:null,n[28]=_t,n[29]=vt);let yt=vt,bt;if(n[30]!==U||n[31]!==W){bb0:{let e;n[33]===U?e=n[34]:(e=e=>e.checkpointTurnCount??U[e.turnId],n[33]=U,n[34]=e);let t=W.map(e).filter(pn);if(t.length===0){bt=void 0;break bb0}let r=Math.max(...t);bt=r>0?r:void 0}n[30]=U,n[31]=W,n[32]=bt}else bt=n[32];let J=bt,St;n[35]!==J||n[36]!==q?(St=!q&&typeof J==`number`?{fromTurnCount:0,toTurnCount:J}:null,n[35]=J,n[36]=q,n[37]=St):St=n[37];let Ct=q?yt:St,Tt;bb1:{if(q||W.length===0){Tt=null;break bb1}let e;n[38]===W?e=n[39]:(e=W.map(fn).join(`,`),n[38]=W,n[39]=e),Tt=`conversation:${e}`}let Et=Tt,Mt=N?.environmentId??null,Nt=Ct?.fromTurnCount??null,Pt=Ct?.toTurnCount??null,It=q?`turn:${q.turnId}`:Et,Lt=I&&!H&&!z,qt;n[40]!==M||n[41]!==_||n[42]!==Mt||n[43]!==Nt||n[44]!==Pt||n[45]!==It||n[46]!==Lt?(qt={environmentId:Mt,threadId:M,fromTurnCount:Nt,toTurnCount:Pt,ignoreWhitespace:_,cacheScope:It,enabled:Lt},n[40]=M,n[41]=_,n[42]=Mt,n[43]=Nt,n[44]=Pt,n[45]=It,n[46]=Lt,n[47]=qt):qt=n[47];let Xt=ht(qt),Zt=q?Xt.data?.diff:void 0,Qt=q?void 0:Xt.data?.diff,$t=z?B.isLoading:H?V.isLoading:Xt.isLoading,rn=z?B.error:H?V.error:Xt.error instanceof Error?Xt.error.message:Xt.error?`Failed to load checkpoint diff.`:null,vn=z&&R?B.data?.[R].patch:H?V.data?.patch:q?Zt:Qt,[Y,yn]=(0,F.useState)(null);Y&&(!H||Y.source!==V.data?.source)&&yn(null);let bn;n[48]!==N?.environmentId||n[49]!==V||n[50]!==B||n[51]!==R||n[52]!==z?(bn=z&&B.data?JSON.stringify([N?.environmentId,R,B.data.revision]):V.data?JSON.stringify([N?.environmentId,V.data.source.revision]):null,n[48]=N?.environmentId,n[49]=V,n[50]=B,n[51]=R,n[52]=z,n[53]=bn):bn=n[53];let xn=bn,Sn=z?B.data?.worktreePath:Ze,Cn=typeof vn==`string`,wn;n[54]!==Cn||n[55]!==vn?(wn=Cn&&vn.trim().length===0,n[54]=Cn,n[55]=vn,n[56]=wn):wn=n[56];let Tn=wn,En;if(n[57]!==fe||n[58]!==H||n[59]!==xn||n[60]!==Et||n[61]!==o||n[62]!==z||n[63]!==vn||n[64]!==q){bb2:{let e=`diff-panel:${o}`,t=typeof vn==`string`?vn:``;if(t.length===0){fe.parse(``,e);let t;n[66]===Symbol.for(`react.memo_cache_sentinel`)?(t={patch:null,files:[]},n[66]=t):t=n[66],En=t;break bb2}let r={turnId:H||z?`comparison:${xn??`pending`}`:q?`turn:${q.turnId}`:Et??`conversation`,filePath:e,blobSha:he(t)},i=Ht.get(r);if(i){fe.parse(t,e,i.patch),En=i;break bb2}let a=fe.parse(t,e),s={patch:a,files:Vt(a)};a&&Ht.set(r,s),En=s}n[57]=fe,n[58]=H,n[59]=xn,n[60]=Et,n[61]=o,n[62]=z,n[63]=vn,n[64]=q,n[65]=En}else En=n[65];let Dn=En,X=Dn.patch,Z=Dn.files,On;n[67]===Z?On=n[68]:(On=wt(Z),n[67]=Z,n[68]=On);let kn=On,An;n[69]===E?An=n[70]:(An=xt(E),n[69]=E,n[70]=An);let Q=An,jn;n[71]!==kn||n[72]!==E?(jn=Dt(kn,E),n[71]=kn,n[72]=E,n[73]=jn):jn=n[73];let $=jn,Mn;n[74]===$?Mn=n[75]:(Mn=kt($),n[74]=$,n[75]=Mn);let Nn=Mn,Pn;n[76]===Z?Pn=n[77]:(Pn=Z.map(dn),n[76]=Z,n[77]=Pn);let Fn=Pn,In;bb3:{if(!Q){In=Fn;break bb3}let e;if(n[78]!==$||n[79]!==Z){let t;n[81]===Z?t=n[82]:(t=e=>({fileDiff:Z[e],fileIndex:e}),n[81]=Z,n[82]=t),e=Ot($).map(t),n[78]=$,n[79]=Z,n[80]=e}else e=n[80];In=e}let Ln=In,Rn;n[83]===Ln?Rn=n[84]:(Rn=Ln.map(un),n[83]=Ln,n[84]=Rn);let zn=Rn,Bn=ze(ue,zn,Ne&&!u),Vn;n[85]===Symbol.for(`react.memo_cache_sentinel`)?(Vn=()=>{O(0)},n[85]=Vn):Vn=n[85];let Hn;n[86]!==Q||n[87]!==Z?(Hn=[Q,Z],n[86]=Q,n[87]=Z,n[88]=Hn):Hn=n[88],(0,F.useEffect)(Vn,Hn);let Un,Wn;n[89]===$.length?(Un=n[90],Wn=n[91]):(Un=()=>{O(e=>$.length===0?0:Math.min(e,$.length-1))},Wn=[$.length],n[89]=$.length,n[90]=Un,n[91]=Wn),(0,F.useEffect)(Un,Wn);let Gn;n[92]!==D||n[93]!==m||n[94]!==$?(Gn=e=>{if($.length===0)return;let t=At(D,$.length,e);O(t);let n=$[t],r=ue.current;if(!n||!r)return;let i=r.querySelector(`[data-diff-file-index="${n.fileIndex}"]`);if(!i)return;let a=en({fileElement:i,match:n,renderMode:m});(a??i).scrollIntoView({block:`center`,behavior:`smooth`}),!a&&jt(n,m)!==null&&window.requestAnimationFrame(()=>{en({fileElement:i,match:n,renderMode:m})?.scrollIntoView({block:`center`,behavior:`smooth`})})},n[92]=D,n[93]=m,n[94]=$,n[95]=Gn):Gn=n[95];let Kn=Gn,qn,Jn;n[96]!==m||n[97]!==$.length||n[98]!==Nn||n[99]!==Q?(qn=()=>{if(!Jt())return;let e=CSS.highlights,t=ue.current;if(!t||!Q||$.length===0){e.delete(Wt);return}let n=0,r=0,i=new Map,a=t.querySelector(`.diff-render-surface`)??t.querySelector(`[data-virtualizer]`)??t,o=()=>{n=0,c();let r=tn({rootElement:t,viewportElement:a,matchesByFileIndex:Nn,renderMode:m});if(r.length===0){e.delete(Wt);return}e.set(Wt,new Highlight(...r))},s=()=>{n===0&&r===0&&(r=window.setTimeout(()=>{r=0,n=window.requestAnimationFrame(o)},Kt))},c=()=>{let e=t.querySelectorAll(`[data-diff-file-index]`);for(let t of e){if(!Yt(t,a))continue;let e=t.querySelectorAll(`diffs-container`);for(let t of e){let e=t.shadowRoot;if(!e||i.has(e))continue;let n=new MutationObserver(s);n.observe(e,{childList:!0,subtree:!0}),i.set(e,n)}}},l=new MutationObserver(s);l.observe(t,{childList:!0,subtree:!0}),a.addEventListener(`scroll`,s,{passive:!0});let u=new ResizeObserver(s);return u.observe(a),s(),()=>{l.disconnect(),a.removeEventListener(`scroll`,s),u.disconnect();for(let e of i.values())e.disconnect();i.clear(),r!==0&&window.clearTimeout(r),n!==0&&window.cancelAnimationFrame(n),e.delete(Wt)}},Jn=[m,$.length,Nn,Q],n[96]=m,n[97]=$.length,n[98]=Nn,n[99]=Q,n[100]=qn,n[101]=Jn):(qn=n[100],Jn=n[101]),(0,F.useEffect)(qn,Jn);let Yn,Xn;n[102]===Z?(Yn=n[103],Xn=n[104]):(Yn=()=>{if(Z.length===0){b(ln);return}let e=new Set(Z.map(Ut));b(t=>{let n=new Set([...t].filter(t=>e.has(t)));return n.size===t.size?t:n})},Xn=[Z],n[102]=Z,n[103]=Yn,n[104]=Xn),(0,F.useEffect)(Yn,Xn);let Zn,Qn;n[105]!==Ne||n[106]!==u||n[107]!==s.diffIgnoreWhitespace||n[108]!==s.diffWordWrap?(Zn=()=>{Ne&&!me.current&&(g(u?!0:s.diffWordWrap),v(s.diffIgnoreWhitespace),T(``)),me.current=Ne},Qn=[Ne,u,s.diffIgnoreWhitespace,s.diffWordWrap],n[105]=Ne,n[106]=u,n[107]=s.diffIgnoreWhitespace,n[108]=s.diffWordWrap,n[109]=Zn,n[110]=Qn):(Zn=n[109],Qn=n[110]),(0,F.useEffect)(Zn,Qn);let $n;n[111]===Symbol.for(`react.memo_cache_sentinel`)?($n=()=>{T(``)},n[111]=$n):$n=n[111];let er;n[112]===G?er=n[113]:(er=[G],n[112]=G,n[113]=er),(0,F.useEffect)($n,er);let tr;n[114]!==N?.environmentId||n[115]!==M||n[116]!==u||n[117]!==Z||n[118]!==K||n[119]!==G?(tr=()=>{if(!K||!ue.current){pe.current=null;return}let e=JSON.stringify([N?.environmentId,M,G,K]);if(!u&&pe.current===e||!Z.some(e=>Bt(e)===K))return;let t=Array.from(ue.current.querySelectorAll(`[data-diff-file-path]`)).find(e=>e.dataset.diffFilePath===K);t&&(t.scrollIntoView({block:`nearest`}),pe.current=e)},n[114]=N?.environmentId,n[115]=M,n[116]=u,n[117]=Z,n[118]=K,n[119]=G,n[120]=tr):tr=n[120];let nr=N?.environmentId,rr;n[121]!==M||n[122]!==u||n[123]!==Z||n[124]!==K||n[125]!==G||n[126]!==nr?(rr=[nr,M,u,K,G,Z],n[121]=M,n[122]=u,n[123]=Z,n[124]=K,n[125]=G,n[126]=nr,n[127]=rr):rr=n[127],(0,F.useEffect)(tr,rr);let ir;n[128]===Ze?ir=n[129]:(ir=(e,t)=>{let n=ne();if(!n)return;let r=Ft({cwd:Ze,filePath:e,lineNumber:t});Be(n,r).catch(cn)},n[128]=Ze,n[129]=ir);let ar=ir,or;n[130]===Symbol.for(`react.memo_cache_sentinel`)?(or=e=>{b(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})},n[130]=or):or=n[130];let sr=or,cr;n[131]!==N||n[132]!==a?(cr=e=>{N&&a({to:`/$environmentId/$threadId`,params:oe(t(N.environmentId,N.id)),search:t=>({...Fe(t),diff:`1`,diffTurnId:e})})},n[131]=N,n[132]=a,n[133]=cr):cr=n[133];let lr=cr,ur;n[134]!==N||n[135]!==a?(ur=()=>{N&&a({to:`/$environmentId/$threadId`,params:oe(t(N.environmentId,N.id)),search:sn})},n[134]=N,n[135]=a,n[136]=ur):ur=n[136];let dr=ur,fr;n[137]===Symbol.for(`react.memo_cache_sentinel`)?(fr=()=>{let e=k.current;if(!e){A(!1),Ce(!1);return}let t=Math.max(0,e.scrollWidth-e.clientWidth);A(e.scrollLeft>4),Ce(e.scrollLeft<t-4)},n[137]=fr):fr=n[137];let pr=fr,mr;n[138]===Symbol.for(`react.memo_cache_sentinel`)?(mr=e=>{let t=k.current;t&&t.scrollBy({left:e,behavior:`smooth`})},n[138]=mr):mr=n[138];let hr=mr,gr;n[139]===Symbol.for(`react.memo_cache_sentinel`)?(gr=e=>{let t=k.current;t&&(t.scrollWidth<=t.clientWidth+1||Math.abs(e.deltaY)<=Math.abs(e.deltaX)||(e.preventDefault(),t.scrollBy({left:e.deltaY,behavior:`auto`})))},n[139]=gr):gr=n[139];let _r=gr,vr,yr;n[140]===Symbol.for(`react.memo_cache_sentinel`)?(vr=()=>{let e=k.current;if(!e)return;let t=window.requestAnimationFrame(()=>pr()),n=()=>pr();e.addEventListener(`scroll`,n,{passive:!0});let r=new ResizeObserver(()=>pr());return r.observe(e),()=>{window.cancelAnimationFrame(t),e.removeEventListener(`scroll`,n),r.disconnect()}},yr=[pr],n[140]=vr,n[141]=yr):(vr=n[140],yr=n[141]),(0,F.useEffect)(vr,yr);let br;n[142]===Symbol.for(`react.memo_cache_sentinel`)?(br=()=>{let e=window.requestAnimationFrame(()=>pr());return()=>{window.cancelAnimationFrame(e)}},n[142]=br):br=n[142];let xr;n[143]!==W||n[144]!==G?(xr=[W,G,pr],n[143]=W,n[144]=G,n[145]=xr):xr=n[145],(0,F.useEffect)(br,xr);let Sr;n[146]===Symbol.for(`react.memo_cache_sentinel`)?(Sr=()=>{let e=k.current;e&&e.querySelector(`[data-turn-chip-selected='true']`)?.scrollIntoView({block:`nearest`,inline:`nearest`,behavior:`smooth`})},n[146]=Sr):Sr=n[146];let Cr=q?.turnId,wr;n[147]!==G||n[148]!==Cr?(wr=[Cr,G],n[147]=G,n[148]=Cr,n[149]=wr):wr=n[149],(0,F.useEffect)(Sr,wr);let Tr;n[150]!==ye||n[151]!==j||n[152]!==u?(Tr=u?null:(0,L.jsxs)(L.Fragment,{children:[(0,L.jsx)(`button`,{type:`button`,className:c(`absolute left-0 top-1/2 z-20 inline-flex size-6 -translate-y-1/2 items-center justify-center rounded-md border bg-background/90 text-muted-foreground transition-colors`,ye?`border-border/70 hover:border-border hover:text-foreground`:`cursor-not-allowed border-border/40 text-muted-foreground/40`),onClick:()=>hr(-180),disabled:!ye,"aria-label":`Scroll turn list left`,children:(0,L.jsx)(ke,{className:`size-3.5`})}),(0,L.jsx)(`button`,{type:`button`,className:c(`absolute right-0 top-1/2 z-20 inline-flex size-6 -translate-y-1/2 items-center justify-center rounded-md border bg-background/90 text-muted-foreground transition-colors`,j?`border-border/70 hover:border-border hover:text-foreground`:`cursor-not-allowed border-border/40 text-muted-foreground/40`),onClick:()=>hr(180),disabled:!j,"aria-label":`Scroll turn list right`,children:(0,L.jsx)(ve,{className:`size-3.5`})})]}),n[150]=ye,n[151]=j,n[152]=u,n[153]=Tr):Tr=n[153];let Er=u?`px-1`:`px-8`,Dr;n[154]===Er?Dr=n[155]:(Dr=c(`turn-chip-strip flex gap-1 overflow-x-auto py-0.5`,Er),n[154]=Er,n[155]=Dr);let Or;n[156]!==ye||n[157]!==j||n[158]!==u?(Or=!u&&(ye||j)?{maskImage:`linear-gradient(to right, ${ye?`transparent 24px, black 72px`:`black`}, ${j?`black calc(100% - 72px), transparent calc(100% - 24px)`:`black`})`}:void 0,n[156]=ye,n[157]=j,n[158]=u,n[159]=Or):Or=n[159];let kr=u&&`min-h-[44px]`,Ar;n[160]===kr?Ar=n[161]:(Ar=c(`shrink-0 rounded-md`,kr),n[160]=kr,n[161]=Ar);let jr;n[162]!==V||n[163]!==u||n[164]!==dr?(jr=()=>{u||(V.setSelection(null),rt(null)),dr()},n[162]=V,n[163]=u,n[164]=dr,n[165]=jr):jr=n[165];let Mr=!H&&!z&&G===null,Nr=u&&`flex min-h-[44px] items-center`,Pr=!H&&!z&&G===null?`border-border bg-accent text-accent-foreground`:`border-border/70 bg-background/70 text-muted-foreground/80 hover:border-border hover:text-foreground/80`,Fr;n[166]!==Nr||n[167]!==Pr?(Fr=c(`rounded-md border px-2 py-1 text-left transition-colors`,Nr,Pr),n[166]=Nr,n[167]=Pr,n[168]=Fr):Fr=n[168];let Ir;n[169]===Symbol.for(`react.memo_cache_sentinel`)?(Ir=(0,L.jsx)(`div`,{className:`text-[10px] leading-tight font-medium`,children:`All turns`}),n[169]=Ir):Ir=n[169];let Lr;n[170]===Fr?Lr=n[171]:(Lr=(0,L.jsx)(`div`,{className:Fr,children:Ir}),n[170]=Fr,n[171]=Lr);let Rr;n[172]!==Ar||n[173]!==jr||n[174]!==Mr||n[175]!==Lr?(Rr=(0,L.jsx)(`button`,{type:`button`,className:Ar,onClick:jr,"data-turn-chip-selected":Mr,children:Lr}),n[172]=Ar,n[173]=jr,n[174]=Mr,n[175]=Lr,n[176]=Rr):Rr=n[176];let zr;if(n[177]!==U||n[178]!==u||n[179]!==W||n[180]!==lr||n[181]!==q?.turnId||n[182]!==s.timestampFormat){let e;n[184]!==U||n[185]!==u||n[186]!==lr||n[187]!==q?.turnId||n[188]!==s.timestampFormat?(e=e=>(0,L.jsx)(`button`,{type:`button`,className:c(`shrink-0 rounded-md`,u&&`min-h-[44px]`),onClick:()=>lr(e.turnId),title:e.turnId,"data-turn-chip-selected":e.turnId===q?.turnId,children:(0,L.jsx)(`div`,{className:c(`rounded-md border px-2 py-1 text-left transition-colors`,u&&`flex min-h-[44px] items-center`,e.turnId===q?.turnId?`border-border bg-accent text-accent-foreground`:`border-border/70 bg-background/70 text-muted-foreground/80 hover:border-border hover:text-foreground/80`),children:(0,L.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,L.jsxs)(`span`,{className:`text-[10px] leading-tight font-medium`,children:[`Turn`,` `,e.checkpointTurnCount??U[e.turnId]??`?`]}),(0,L.jsx)(`span`,{className:`text-[9px] leading-tight opacity-70`,children:ge(e.completedAt,s.timestampFormat)})]})})},e.turnId),n[184]=U,n[185]=u,n[186]=lr,n[187]=q?.turnId,n[188]=s.timestampFormat,n[189]=e):e=n[189],zr=W.map(e),n[177]=U,n[178]=u,n[179]=W,n[180]=lr,n[181]=q?.turnId,n[182]=s.timestampFormat,n[183]=zr}else zr=n[183];let Br;n[190]!==Dr||n[191]!==Or||n[192]!==Rr||n[193]!==zr?(Br=(0,L.jsxs)(`div`,{ref:k,className:Dr,style:Or,onWheel:_r,children:[Rr,zr]}),n[190]=Dr,n[191]=Or,n[192]=Rr,n[193]=zr,n[194]=Br):Br=n[194];let Vr;n[195]!==Tr||n[196]!==Br?(Vr=(0,L.jsxs)(`div`,{className:`relative min-w-0 flex-1 [-webkit-app-region:no-drag]`,children:[Tr,Br]}),n[195]=Tr,n[196]=Br,n[197]=Vr):Vr=n[197];let Hr;n[198]!==Bn||n[199]!==u||n[200]!==zn?(Hr=!u&&zn.length>0&&(0,L.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1`,"aria-label":`Changed file navigation`,children:[(0,L.jsx)(`button`,{type:`button`,className:`rounded p-1 disabled:opacity-40`,"aria-label":`Previous changed file`,disabled:!Bn.canPrevious,onClick:()=>Bn.jump(-1),children:(0,L.jsx)(ce,{className:`size-4`})}),(0,L.jsxs)(`span`,{className:`max-w-32 truncate text-[11px]`,title:Bn.path??void 0,"aria-live":`polite`,"data-diff-active-file":Bn.path,children:[Bn.index+1,`/`,zn.length,` `,Bn.path]}),(0,L.jsx)(`button`,{type:`button`,className:`rounded p-1 disabled:opacity-40`,"aria-label":`Next changed file`,disabled:!Bn.canNext,onClick:()=>Bn.jump(1),children:(0,L.jsx)(S,{className:`size-4`})})]}),n[198]=Bn,n[199]=u,n[200]=zn,n[201]=Hr):Hr=n[201];let Ur;n[202]!==m||n[203]!==u||n[204]!==f?(Ur=u?null:(0,L.jsxs)(Ue,{className:`shrink-0`,variant:`outline`,size:`xs`,value:[m],onValueChange:e=>{let t=e[0];(t===`stacked`||t===`split`)&&f(t)},children:[(0,L.jsx)(We,{"aria-label":`Stacked diff view`,value:`stacked`,children:(0,L.jsx)(Ye,{className:`size-3`})}),(0,L.jsx)(We,{"aria-label":`Split diff view`,value:`split`,children:(0,L.jsx)(Me,{className:`size-3`})})]}),n[202]=m,n[203]=u,n[204]=f,n[205]=Ur):Ur=n[205];let Wr=h?`Disable diff line wrapping`:`Enable diff line wrapping`,Gr=h?`Disable line wrapping`:`Enable line wrapping`,Kr=u&&`min-h-[44px] min-w-[44px]`,qr;n[206]===Kr?qr=n[207]:(qr=c(Kr),n[206]=Kr,n[207]=qr);let Jr,Yr;n[208]===Symbol.for(`react.memo_cache_sentinel`)?(Jr=e=>{g(!!e)},Yr=(0,L.jsx)(Pe,{className:`size-3`}),n[208]=Jr,n[209]=Yr):(Jr=n[208],Yr=n[209]);let Xr;n[210]!==h||n[211]!==Wr||n[212]!==Gr||n[213]!==qr?(Xr=(0,L.jsx)(We,{"aria-label":Wr,title:Gr,variant:`outline`,size:`xs`,className:qr,pressed:h,onPressedChange:Jr,children:Yr}),n[210]=h,n[211]=Wr,n[212]=Gr,n[213]=qr,n[214]=Xr):Xr=n[214];let Zr=z?`Whitespace is included for staging`:_?`Show whitespace changes`:`Hide whitespace changes`,Qr=z?`Staging always shows the exact patch, including whitespace.`:_?`Show whitespace changes`:`Hide whitespace changes`,$r=u&&`min-h-[44px] min-w-[44px]`,ei;n[215]===$r?ei=n[216]:(ei=c($r),n[215]=$r,n[216]=ei);let ti=!z&&_,ni,ri;n[217]===Symbol.for(`react.memo_cache_sentinel`)?(ri=e=>{v(!!e)},ni=(0,L.jsx)(qe,{className:`size-3`}),n[217]=ni,n[218]=ri):(ni=n[217],ri=n[218]);let ii;n[219]!==z||n[220]!==Zr||n[221]!==Qr||n[222]!==ei||n[223]!==ti?(ii=(0,L.jsx)(We,{"aria-label":Zr,title:Qr,disabled:z,variant:`outline`,size:`xs`,className:ei,pressed:ti,onPressedChange:ri,children:ni}),n[219]=z,n[220]=Zr,n[221]=Qr,n[222]=ei,n[223]=ti,n[224]=ii):ii=n[224];let ai;n[225]!==ii||n[226]!==Hr||n[227]!==Ur||n[228]!==Xr?(ai=(0,L.jsxs)(`div`,{className:`flex shrink-0 items-center gap-1 [-webkit-app-region:no-drag]`,children:[Hr,Ur,Xr,ii]}),n[225]=ii,n[226]=Hr,n[227]=Ur,n[228]=Xr,n[229]=ai):ai=n[229];let oi;n[230]!==ai||n[231]!==Vr?(oi=(0,L.jsxs)(L.Fragment,{children:[Vr,ai]}),n[230]=ai,n[231]=Vr,n[232]=oi):oi=n[232];let si=oi,ci;n[233]!==N||n[234]!==Y||n[235]!==H||n[236]!==V?(ci=H&&V.data&&N&&Y?.source===V.data.source&&(0,L.jsx)(it,{environmentId:N.environmentId,source:V.data.source,file:Y.file,initialSide:Y.side,initialLine:Y.line,onClose:()=>yn(null)},`${N.environmentId}:${V.data.source.revision}:${Y.file.name}:${Y.side}:${Y.line}`),n[233]=N,n[234]=Y,n[235]=H,n[236]=V,n[237]=ci):ci=n[237];let li;n[238]!==Xe?.cwd||n[239]!==N||n[240]!==H||n[241]!==V||n[242]!==I||n[243]!==u||n[244]!==z||n[245]!==dr?(li=!u&&N&&I&&(0,L.jsx)(at,{selection:H?V.selection:null,data:H?V.data:null,turnSelected:!z&&!H,isLoading:H&&V.isLoading,error:H?V.error:null,refMoved:H&&V.refMoved,onSelect:e=>{rt(null),V.setSelection(e),dr()},onRefresh:()=>{V.refresh()}},`${N.environmentId}:${Xe?.cwd}:${V.selection?.mode}:${V.selection?.ref}`),n[238]=Xe?.cwd,n[239]=N,n[240]=H,n[241]=V,n[242]=I,n[243]=u,n[244]=z,n[245]=dr,n[246]=li):li=n[246];let ui;n[247]!==N||n[248]!==I||n[249]!==u||n[250]!==B||n[251]!==R||n[252]!==a||n[253]!==z?(ui=!u&&I&&N&&(0,L.jsxs)(`section`,{"aria-label":`Local change review`,className:`shrink-0 border-b border-border px-3 py-2 text-xs`,children:[(0,L.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2`,children:[[`unstaged`,`staged`].map(e=>(0,L.jsx)(`button`,{type:`button`,className:c(`rounded border px-2 py-1`,z&&R===e&&`border-foreground/30 bg-foreground/10 font-medium`),"aria-pressed":z&&R===e,onClick:()=>{rt(e),a({to:`.`,search:on})},children:e===`staged`?`Staged changes`:`Unstaged changes`},e)),z&&(0,L.jsx)(`button`,{type:`button`,className:`rounded border px-2 py-1`,disabled:B.isLoading||B.isApplying,onClick:()=>void B.refresh(),children:`Refresh local changes`})]}),z&&(0,L.jsxs)(`p`,{className:`mt-2 text-muted-foreground`,children:[R===`staged`?`HEAD → index. Unstage keeps your working files.`:`Index → working files. Later agent edits appear here; refresh to read external changes.`,` `,`Staging does not commit. Existing commit actions stage their selected files.`,B.isApplying&&(0,L.jsx)(`span`,{role:`status`,children:` Updating index…`}),B.isLoading&&(0,L.jsx)(`span`,{role:`status`,children:` Refreshing local changes…`})]})]}),n[247]=N,n[248]=I,n[249]=u,n[250]=B,n[251]=R,n[252]=a,n[253]=z,n[254]=ui):ui=n[254];let di;n[255]!==N||n[256]!==rn||n[257]!==y||n[258]!==H||n[259]!==V||n[260]!==D||n[261]!==m||n[262]!==$.length||n[263]!==x||n[264]!==h||n[265]!==Ln||n[266]!==Kn||n[267]!==Tn||n[268]!==Sn||n[269]!==I||n[270]!==$t||n[271]!==u||n[272]!==B||n[273]!==R||n[274]!==Q||n[275]!==ar||n[276]!==W.length||n[277]!==X||n[278]!==o||n[279]!==z?(di=N?I?!H&&!z&&W.length===0?(0,L.jsx)(`div`,{className:`flex flex-1 items-center justify-center px-5 text-center text-xs text-muted-foreground/70`,children:`No completed turns yet.`}):(0,L.jsx)(L.Fragment,{children:(0,L.jsxs)(`div`,{ref:ue,className:`diff-panel-viewport flex min-h-0 min-w-0 flex-1 flex-col overflow-hidden`,children:[rn&&!X&&(0,L.jsx)(`div`,{className:`px-3`,children:(0,L.jsx)(`p`,{role:`alert`,className:`mb-2 text-[11px] text-red-500/80`,children:rn})}),X?X.kind===`files`?(0,L.jsxs)(L.Fragment,{children:[(0,L.jsxs)(`div`,{className:`flex shrink-0 items-center gap-2 border-b border-border/50 bg-card/40 px-2.5 py-1.5 [-webkit-app-region:no-drag]`,children:[(0,L.jsx)(_e,{className:`size-3.5 shrink-0 text-muted-foreground/70`}),(0,L.jsx)(`input`,{ref:le,type:`text`,value:x,onChange:e=>T(e.target.value),onKeyDown:e=>{if(e.key===`Escape`){T(``),e.currentTarget.blur();return}e.key===`Enter`&&Q&&(e.preventDefault(),Kn(e.shiftKey?-1:1))},placeholder:`Search files or hunks...`,"aria-label":`Search diff`,className:c(`min-w-0 flex-1 bg-transparent text-xs text-foreground outline-none placeholder:text-muted-foreground/55`,u&&`min-h-[44px]`)}),Q&&(0,L.jsxs)(L.Fragment,{children:[(0,L.jsxs)(`span`,{className:`shrink-0 text-[10px] tabular-nums text-muted-foreground/70`,children:[$.length===0?0:D+1,` of`,` `,$.length]}),(0,L.jsxs)(`div`,{className:`flex shrink-0 items-center`,children:[(0,L.jsx)(`button`,{type:`button`,onClick:()=>Kn(-1),disabled:$.length===0,className:c(`inline-flex size-5 cursor-pointer items-center justify-center rounded-sm text-muted-foreground/70 transition-colors hover:bg-foreground/10 hover:text-foreground disabled:cursor-not-allowed disabled:opacity-40 disabled:hover:bg-transparent disabled:hover:text-muted-foreground/70`,u&&`size-[44px]`),"aria-label":`Previous match`,title:`Previous match (Shift+Enter)`,children:(0,L.jsx)(ce,{className:`size-3.5`})}),(0,L.jsx)(`button`,{type:`button`,onClick:()=>Kn(1),disabled:$.length===0,className:c(`inline-flex size-5 cursor-pointer items-center justify-center rounded-sm text-muted-foreground/70 transition-colors hover:bg-foreground/10 hover:text-foreground disabled:cursor-not-allowed disabled:opacity-40 disabled:hover:bg-transparent disabled:hover:text-muted-foreground/70`,u&&`size-[44px]`),"aria-label":`Next match`,title:`Next match (Enter)`,children:(0,L.jsx)(S,{className:`size-3.5`})})]})]}),x&&(0,L.jsx)(`button`,{type:`button`,onClick:()=>{T(``),le.current?.focus()},className:c(`inline-flex size-4 shrink-0 cursor-pointer items-center justify-center rounded-sm text-muted-foreground/70 transition-colors hover:bg-foreground/10 hover:text-foreground`,u&&`size-[44px]`),"aria-label":`Clear search`,title:`Clear search`,children:(0,L.jsx)(ae,{className:`size-3`})})]}),Ln.length===0?(0,L.jsx)(`div`,{className:`flex flex-1 items-center justify-center px-3 py-2 text-xs text-muted-foreground/70`,children:(0,L.jsxs)(`p`,{children:[`No files match “`,x,`”.`]})}):(0,L.jsx)(Le,{className:c(`diff-render-surface min-h-0 flex-1 overflow-auto px-2 pb-2`,u&&`overflow-x-hidden overflow-y-auto overscroll-x-contain`),config:{overscrollSize:600,intersectionObserverMargin:1200},children:Ln.map(e=>{let{fileDiff:t,fileIndex:n}=e,r=Bt(t),i=z&&R&&X?.kind===`files`&&X.files.length===B.data?.[R].files.length?B.data[R].files[X.files.indexOf(t)]:void 0,a=Ut(t),s=`${a}:${o}`,l=y.has(a);return(0,L.jsxs)(`div`,{"data-diff-file-path":r,"data-diff-file-index":n,className:`diff-render-file group/diff-file mb-2 rounded-md first:mt-2 last:mb-0`,onClickCapture:u?void 0:e=>{(e.nativeEvent.composedPath?.()??[]).some(an)&&ar(r)},children:[(0,L.jsx)(Re,{fileDiff:t,renderHeaderMetadata:()=>z&&R&&i?(0,L.jsx)(nt,{scope:R,file:i,name:r,disabled:B.isLoading||B.isApplying||!!B.error,onApply:e=>{B.apply(e)}},`${B.data?.revision}:${i.id}`):H&&V.data?(0,L.jsx)(`button`,{type:`button`,className:`rounded px-2 py-1 text-xs hover:bg-foreground/10`,"aria-label":`Blame line in ${t.name}`,onClick:e=>{e.stopPropagation(),V.data&&yn({source:V.data.source,file:t,side:`base`,line:t.hunks[0]?.deletionStart||1})},children:`Line blame`}):null,renderHeaderPrefix:()=>(0,L.jsx)(`button`,{type:`button`,className:c(`inline-flex size-5 shrink-0 cursor-pointer items-center justify-center rounded-sm border-0 bg-transparent p-0 transition-colors hover:bg-foreground/10 focus-visible:outline-hidden`,u&&`size-[44px]`,nn(t)),"aria-label":l?`Expand ${r}`:`Collapse ${r}`,"aria-expanded":!l,title:l?`Expand diff`:`Collapse diff`,onClick:e=>{e.stopPropagation(),sr(a)},children:l?(0,L.jsx)(ve,{className:`size-4`}):(0,L.jsx)(S,{className:`size-4`})}),options:{collapsed:l,diffStyle:m===`split`?`split`:`unified`,lineDiffType:`none`,overflow:h?`wrap`:`scroll`,theme:de(o),themeType:o,unsafeCSS:u?zt:Rt,lineHoverHighlight:`number`,...H&&V.data?{onLineClick:e=>{!e.numberColumn&&window.getSelection()?.isCollapsed&&V.data&&yn({source:V.data.source,file:t,side:e.annotationSide===`deletions`?`base`:`head`,line:e.lineNumber})}}:{},...u?{}:{onLineNumberClick:e=>{let{lineNumber:t}=e;ar(r,t)}}}}),!l&&N&&Sn?(0,L.jsx)(pt,{environmentId:N.environmentId,cwd:Sn,fileDiff:t,afterIsWorkingTree:z&&R===`unstaged`}):null]},s)})})]}):(0,L.jsx)(`div`,{className:`flex-1 overflow-auto p-2`,children:(0,L.jsxs)(`div`,{className:`space-y-2`,children:[(0,L.jsx)(`p`,{className:`text-[11px] text-muted-foreground/75`,children:X.reason}),(0,L.jsx)(`pre`,{className:c(`max-h-[72vh] rounded-md border border-border/70 bg-background/70 p-3 font-mono text-[11px] leading-relaxed text-muted-foreground/90`,h?`overflow-auto whitespace-pre-wrap wrap-break-word`:`overflow-auto`),children:X.text})]})}):$t?(0,L.jsx)(Se,{label:z?`Loading local changes...`:H?`Loading comparison...`:`Loading checkpoint diff...`}):(0,L.jsx)(`div`,{className:`flex flex-1 items-center justify-center px-3 py-2 text-xs text-muted-foreground/70`,children:(0,L.jsx)(`p`,{children:Tn?`No net changes in this selection.`:`No patch available for this selection.`})})]})}):(0,L.jsx)(`div`,{className:`flex flex-1 items-center justify-center px-5 text-center text-xs text-muted-foreground/70`,children:`Turn diffs are unavailable because this project is not a git repository.`}):(0,L.jsx)(`div`,{className:`flex flex-1 items-center justify-center px-5 text-center text-xs text-muted-foreground/70`,children:`Select a thread to inspect turn diffs.`}),n[255]=N,n[256]=rn,n[257]=y,n[258]=H,n[259]=V,n[260]=D,n[261]=m,n[262]=$.length,n[263]=x,n[264]=h,n[265]=Ln,n[266]=Kn,n[267]=Tn,n[268]=Sn,n[269]=I,n[270]=$t,n[271]=u,n[272]=B,n[273]=R,n[274]=Q,n[275]=ar,n[276]=W.length,n[277]=X,n[278]=o,n[279]=z,n[280]=di):di=n[280];let fi;return n[281]!==si||n[282]!==i||n[283]!==ci||n[284]!==li||n[285]!==ui||n[286]!==di?(fi=(0,L.jsxs)(xe,{mode:i,header:si,children:[ci,li,ui,di]}),n[281]=si,n[282]=i,n[283]=ci,n[284]=li,n[285]=ui,n[286]=di,n[287]=fi):fi=n[287],fi}function an(e){return e instanceof Element&&e.hasAttribute(`data-title`)}function on(e){return{...e,diffTurnId:void 0,diffFilePath:void 0}}function sn(e){return{...Fe(e),diff:`1`}}function cn(e){console.warn(`Failed to open diff in editor.`,e)}function ln(e){return e.size===0?e:new Set}function un(e){let{fileDiff:t}=e;return Bt(t)}function dn(e,t){return{fileDiff:e,fileIndex:t}}function fn(e){return e.turnId}function pn(e){return typeof e==`number`}function mn(e){return M(e)}function hn(e){return h(e)}function gn(){return new N}function _n(){return new Set}export{Ne as DiffWorkerPoolProvider,rn as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{ad as e}from"./runtime-DjjjAcTE.js";import{i as t}from"./presentationTier-DPVAxTK4.js";import{i as n,r,t as i}from"./disclosureMotion-cbMJn5-z.js";var a=t(),o=e();function s(e){let t=(0,a.c)(14),{open:s,children:c,className:l,contentClassName:u}=e,d;t[0]!==l||t[1]!==s?(d=n(s,l),t[0]=l,t[1]=s,t[2]=d):d=t[2];let f=!s||void 0,p=!s,m;t[3]!==u||t[4]!==s?(m=r(s,u),t[3]=u,t[4]=s,t[5]=m):m=t[5];let h;t[6]!==c||t[7]!==m?(h=(0,o.jsx)(`div`,{className:i,children:(0,o.jsx)(`div`,{className:m,children:c})}),t[6]=c,t[7]=m,t[8]=h):h=t[8];let g;return t[9]!==d||t[10]!==f||t[11]!==p||t[12]!==h?(g=(0,o.jsx)(`div`,{className:d,"aria-hidden":f,inert:p,children:h}),t[9]=d,t[10]=f,t[11]=p,t[12]=h,t[13]=g):g=t[13],g}export{s as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{nn as t}from"./primary-Cf-xJExj.js";import{$i as n,Yn as ee,ad as r,do as i,qi as a,wr as te}from"./runtime-DjjjAcTE.js";import{t as o}from"./react-CwJFpaho.js";import{t as ne}from"./useNavigate-sQZthdyT.js";import{a as re,c as s,d as c,f as l,i as u,l as d,n as f,r as p,s as m,t as h,u as g}from"./ChatRightPanel-BCINd0vP.js";import{K as _,P as v}from"./messageQueueDrain-B7R7Qmq6.js";import{t as y}from"./usePresentationTier-B9kCQ4YH.js";import"./storeSelectors-BichCKDC.js";import{u as b}from"./workspaceRouteSearch-CCavUdbH.js";import{o as x}from"./sidebar-0BBaFNm3.js";import{t as S}from"./useAppSidebarCollapsed-BbMxfio5.js";import{h as ie,m as ae}from"./main-Ch0bwS-M.js";var C=e(o(),1),w=r();function T({rawDraftId:e,search:r}){let o=ne(),T=i.make(e),E=`draft:${T}`,D=(0,C.useCallback)(e=>{o({to:`/draft/$draftId`,params:{draftId:T},replace:!0,search:e})},[T,o]),O=s({threadKey:E,search:r,replaceSearch:D}),k=l(T),A=te((0,C.useMemo)(()=>ee(k?.threadId??null),[k?.threadId])),j=v(A),M=(0,C.useMemo)(()=>k?.promotedTo?j?k.promotedTo:null:A?{environmentId:A.environmentId,threadId:A.id}:null,[k?.promotedTo,A,j]),N=ae(O),P=ie(O),F=O.workspaceTab===`agent`&&O.workspaceAgentKey?O.workspaceAgentKey:null,I=_(m),L=y(),R=M?`${M.environmentId}:${M.threadId}`:null,z=t(e=>R?e.pendingOpenByThreadKey[R]:void 0),B=t(e=>e.consumeOpenRequest),V=S(),{maximized:H,toggleMaximized:U}=c({threadKey:T,open:P,canMaximize:!I&&L!==`phone`});(0,C.useEffect)(()=>{M&&z&&L!==`phone`&&(B(M.environmentId,M.threadId),o({to:`/draft/$draftId`,params:{draftId:T},search:e=>b(e)}))},[M,B,T,o,z,L]);let W=(0,C.useCallback)(e=>{o({to:`/draft/$draftId`,params:{draftId:T},search:e})},[T,o]),{openedPanelModes:G,openedAgentKeys:K,lastOpenedRightPanelMode:q,markRightPanelOpened:J,openRightPanel:oe,closeRightPanel:Y,toggleRightPanel:X,closePanelTab:Z,shouldRenderRightPanelContent:Q,shouldRenderPhoneRightPanelContent:se}=g({scopeKey:T,rightPanelMode:N,rightPanelOpen:P,activeAgentKey:F,defaultLastMode:`files`,navigateSearch:W});if((0,C.useEffect)(()=>{M&&(d(E,`${M.environmentId}:${M.threadId}`),o({to:`/$environmentId/$threadId`,params:a(M),replace:!0}))},[M,o,E]),(0,C.useEffect)(()=>{k||M||o({to:`/`,replace:!0})},[M,k,o]),M)return(0,w.jsx)(x,{className:`h-svh min-h-0 overflow-hidden overscroll-y-none bg-background text-foreground md:h-dvh`,children:(0,w.jsx)(p,{environmentId:M.environmentId,threadId:M.threadId,routeKind:`server`})});if(!k)return null;let $=P?N:q;return L===`phone`?(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(x,{className:`h-svh min-h-0 overflow-hidden overscroll-y-none bg-background text-foreground md:h-dvh`,children:(0,w.jsx)(p,{draftId:T,environmentId:k.environmentId,threadId:k.threadId,onDiffPanelOpen:()=>J(`review`),onPreviewPanelOpen:()=>J(`files`),onTerminalPanelOpen:()=>J(`terminal`),onAgentPanelOpen:()=>J(`agent`),workspacePanelOpen:P,onToggleWorkspacePanel:X,routeKind:`draft`})}),(0,w.jsx)(re,{label:`Workspace`,open:P,onClose:Y,children:se?(0,w.jsx)(h,{mode:`phone`,panelMode:$,openedPanelModes:G,openedAgentKeys:K,onClosePanelTab:Z}):null})]}):I?(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(x,{className:`h-svh min-h-0 overflow-hidden overscroll-y-none bg-background text-foreground md:h-dvh`,children:(0,w.jsx)(p,{draftId:T,environmentId:k.environmentId,threadId:k.threadId,onDiffPanelOpen:()=>J(`review`),onPreviewPanelOpen:()=>J(`files`),onTerminalPanelOpen:()=>J(`terminal`),onAgentPanelOpen:()=>J(`agent`),workspacePanelOpen:P,onToggleWorkspacePanel:X,routeKind:`draft`})}),(0,w.jsx)(u,{open:P,onClose:Y,children:Q?(0,w.jsx)(h,{mode:`sheet`,panelMode:$,openedPanelModes:G,openedAgentKeys:K,onClosePanelTab:Z}):null})]}):(0,w.jsxs)(w.Fragment,{children:[(0,w.jsx)(x,{className:n(`h-svh min-h-0 overflow-hidden overscroll-y-none bg-background text-foreground md:h-dvh`,H&&`w-0 flex-none`),inert:H?!0:void 0,children:(0,w.jsx)(p,{draftId:T,environmentId:k.environmentId,threadId:k.threadId,onDiffPanelOpen:()=>J(`review`),onPreviewPanelOpen:()=>J(`files`),onTerminalPanelOpen:()=>J(`terminal`),onAgentPanelOpen:()=>J(`agent`),workspacePanelOpen:P,onToggleWorkspacePanel:X,routeKind:`draft`})}),(0,w.jsx)(f,{open:P,panelMode:$,openedPanelModes:G,openedAgentKeys:K,onClosePanelTab:Z,onClose:Y,onOpen:oe,renderContent:Q,maximized:H,onToggleMaximized:U,reserveChromeInset:H&&V})]})}export{T as DraftChatThreadRouteView};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{j as e}from"./authorization-Ob6YwWiI.js";function t(e){return e.status===`refused`&&e.errorCode===`step_up_required`}function n(t){return t===e}function r(e,t){return!e.inferredErrorCode||t<3}var i=`The Hub refused this change every time. It answers a missing authenticator code and other refusals identically, so if the codes you entered were current then something else is blocking this — sign in again with a passkey, or try again later.`;function a(e,t,n){return!e||n&&t===`step_up_required`?null:e}function o(e){return e.revokedAt!==null}function s(e){return e.filter(e=>!o(e))}function c(e){return e.toSorted((e,t)=>+!!o(e)-!!o(t))}function l(e){return s(e).filter(e=>e.backupState===!0).length}function u(e,t){if(t!==`ready`)return null;let n=s(e).length;return n===0?{variant:`error`,title:`No usable passkey on this account`,description:`Without one you can only get back in through a fallback credential. Adding a passkey is the only action on this page that makes the account stronger.`,actionLabel:`Add your first passkey`}:n===1?{variant:`warning`,title:`One passkey on this account`,description:`If you lose this device you fall back to a password or a recovery code. Add a second passkey on another device.`,actionLabel:`Add another passkey`}:null}function d(e){return e.label?.trim()||`Unnamed passkey (${e.id.slice(0,12)}…)`}function f(e){return e.backupState===!0?`Synced to your password manager`:e.backupEligible===!0?`Can be synced, not yet backed up`:e.backupEligible===!1?`Tied to this device only`:null}function p(e){let t=e.trim();return t.length===0?null:t}function m(e){return e.replace(/\D/gu,``).slice(0,16)}function h(e){return m(e).length>=6}function g(e,t){return e.length===0?`Enter a password.`:e.length>256?`Use 256 characters or fewer.`:t.length===0?`Re-enter the password to confirm it.`:e===t?null:`The two passwords do not match.`}function _(e){let t=e.trim();return t.length===0?`Enter an email address.`:t.length>254?`Use 254 characters or fewer.`:/^[^\s@]+@[^\s@]+\.[^\s@]+$/u.test(t)?null:`Enter a valid email address.`}function v(e){return e.join(`
|
|
2
2
|
`)}var y={"set-password":`Confirm the password change`,"remove-password":`Confirm removing the password`,"revoke-totp":`Confirm removing two-factor authentication`,"request-email-verification":`Confirm the email change`,"add-passkey":`Confirm adding a passkey`,"regenerate-recovery-codes":`Confirm new recovery codes`,"connect-github":`Confirm connecting GitHub`,"disconnect-github":`Confirm disconnecting GitHub`};function b(e){return y[e]}function x(e,t){return e===0?t?`The Hub refused this change without saying why. The usual reason is that it wants a code from your authenticator app.`:`The Hub asked for a code from your authenticator app before making this change.`:t?`That did not work. The Hub answers a wrong code and other refusals identically, so this may not be about the code at all. You can try the code showing now.`:`That code was not accepted. Codes change every 30 seconds — enter the one showing now.`}function S(e){return e?.providers.find(e=>e.provider===`github`)??null}var C={external_provider_unavailable:`GitHub sign-in is temporarily unavailable. Try again later.`,external_authorization_cancelled:`GitHub authorization was cancelled.`,external_authorization_expired:`GitHub authorization expired. Start again.`,external_authorization_rejected:`GitHub could not authorize this request. Try again.`,external_identity_email_conflict:`An account already uses that verified email. Sign in another way, then connect GitHub from account settings.`,external_identity_verified_email_required:`GitHub needs a verified primary email before it can create a Ryco account.`,signup_disabled:`New account signup is closed. Linked GitHub accounts can still sign in.`,username_unavailable:`That username is unavailable. Choose another one and try again.`};function w(e){return C[e]}async function T(e){let t=await e.start({provider:`github`,intent:e.intent,returnTo:e.returnTo});e.navigate(t.authorizationUrl)}export{l as C,b as S,f as _,u as a,r as b,v as c,n as d,t as f,c as g,m as h,i,a as l,p as m,w as n,s as o,h as p,S as r,_ as s,T as t,o as u,d as v,x,g as y};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{$i as e}from"./runtime-DjjjAcTE.js";import"./appearancePreferences-NnsvXwBe.js";var t={sheet:`app-glass-surface-sheet`,chip:`app-glass-surface-chip`,dock:`app-glass-surface-dock`};function n(n){return e(`app-glass-surface`,t[n])}export{n as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{q as t}from"./primary-Cf-xJExj.js";import{Bi as n,Pi as r}from"./wsTransport-C88seBPA.js";import{$i as i,P as a,Ss as o,X as s,Zi as c,ad as l,ms as u,tt as d,vs as f,wr as p,ws as m,yr as h}from"./runtime-DjjjAcTE.js";import{t as g}from"./react-CwJFpaho.js";import{S as _,_ as v,g as y,h as b,p as x,t as S,v as C,x as w,y as T}from"./hostedConnectionCoordinator-BkAE-RhA.js";import{i as E}from"./presentationTier-DPVAxTK4.js";import{t as D}from"./useNavigate-sQZthdyT.js";import{t as O}from"./download-TvtXS4hE.js";import{t as ee}from"./log-out-CKq9YiLY.js";import{t as te}from"./refresh-cw-CRUTivd6.js";import{t as k}from"./shield-check-_wl7R4Js.js";import{t as A}from"./shield-CBHYqlkR.js";import{t as j}from"./smartphone-OEAQOTdv.js";import{t as ne}from"./user-round-BPDXr8Gq.js";import{o as M}from"./authorization-Ob6YwWiI.js";import{t as N}from"./usePresentationTier-B9kCQ4YH.js";import{a as P,i as F,s as I,t as re}from"./readCache-B7cDPz2O.js";import{a as L,i as ie,n as ae,o as R,s as z,t as B}from"./MobileSheet-DfgXNWbd.js";import{t as V}from"./GlassSurface-DLYYzRdP.js";import{a as oe,c as se,i as H,n as ce,o as U,r as le,s as ue,t as W}from"./HostedRelayTrustNotice-BfTyrBi5.js";var G={name:`badge-check`,size:24,node:[[`path`,{d:`M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z`,key:`3c2336`}],[`path`,{d:`m16 9-5.5 5.5L8 12`,key:`xofnsj`}]],aliases:[`verified`]};G.node;var de=m(G),fe={name:`layout-grid`,size:24,node:[[`rect`,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`1g98yp`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`3`,rx:`1`,key:`6d4xhi`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`14`,rx:`1`,key:`nxv5o0`}],[`rect`,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`1bb6yr`}]]};fe.node;var pe=m(fe),me={name:`shield-off`,size:24,node:[[`path`,{d:`m2 2 20 20`,key:`1ooewy`}],[`path`,{d:`M5 5a1 1 0 0 0-1 1v7c0 5 3.5 7.5 7.67 8.94a1 1 0 0 0 .67.01c2.35-.82 4.48-1.97 5.9-3.71`,key:`1jlk70`}],[`path`,{d:`M9.309 3.652A12.252 12.252 0 0 0 11.24 2.28a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1v7a9.784 9.784 0 0 1-.08 1.264`,key:`18rp1v`}]]};me.node;var he=m(me),ge={name:`wifi-off`,size:24,node:[[`path`,{d:`M12 20h.01`,key:`zekei9`}],[`path`,{d:`M8.5 16.429a5 5 0 0 1 7 0`,key:`1bycff`}],[`path`,{d:`M5 12.859a10 10 0 0 1 5.17-2.69`,key:`1dl1wf`}],[`path`,{d:`M19 12.859a10 10 0 0 0-2.007-1.523`,key:`4k23kn`}],[`path`,{d:`M2 8.82a15 15 0 0 1 4.177-2.643`,key:`1grhjp`}],[`path`,{d:`M22 8.82a15 15 0 0 0-11.288-3.764`,key:`z3jwby`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]};ge.node;var _e=m(ge),ve={name:`wifi`,size:24,node:[[`path`,{d:`M12 20h.01`,key:`zekei9`}],[`path`,{d:`M2 8.82a15 15 0 0 1 20 0`,key:`dnpr2z`}],[`path`,{d:`M5 12.859a10 10 0 0 1 14 0`,key:`1x1e6c`}],[`path`,{d:`M8.5 16.429a5 5 0 0 1 7 0`,key:`1bycff`}]]};ve.node;var ye=m(ve),K=E(),q=e(g(),1),be=Object.freeze({"":`overview`,security:`security`,appearance:`appearance`}),xe=Object.freeze({"sign-in":`/sign-in`,"sign-in-password":`/sign-in/password`,"sign-in-recovery-code":`/sign-in/recovery-code`,"sign-up":`/sign-up`,"sign-up-verify":`/public-signup/verify`,"reset-password":`/password-reset`,invitation:`/invitation`,setup:`/setup`,"email-verification":`/email-verification`,nodes:`/nodes`,"nodes-enroll":`/nodes/enroll`}),Se=Object.freeze([`sign-in`,`sign-up`,`public-signup`,`password-reset`,`invitation`,`setup`,`email-verification`,`nodes`,`account`]);function Ce(e){return e.length>1&&e.endsWith(`/`)?e.slice(0,-1):e===``?`/`:e}function we(e){let t=Ce(e);if(t.startsWith(`/account`))return{kind:`account`,section:be[t.slice(8).replace(/^\//,``)]??`overview`};for(let[e,n]of Object.entries(xe))if(t===n)return{kind:e};return null}function Te(e){return e.kind===`account`?e.section===`overview`?`/account`:`/account/${e.section}`:xe[e.kind]}function Ee(e){switch(e.kind){case`sign-in`:return`Sign in`;case`sign-in-password`:return`Sign in with a password`;case`sign-in-recovery-code`:return`Use a recovery code`;case`sign-up`:return`Create your account`;case`sign-up-verify`:return`Verify your email`;case`reset-password`:return`Reset your password`;case`invitation`:return`Redeem your invitation`;case`setup`:return`Claim this Hub`;case`email-verification`:return`Email verification`;case`nodes`:return`Your nodes`;case`nodes-enroll`:return`Enroll a node`;case`account`:return e.section===`overview`?`Account`:e.section===`security`?`Security`:`Appearance`}}var De=typeof window>`u`?`/`:Ce(window.location.pathname),Oe=new Set;function ke(){for(let e of Array.from(Oe))e()}function Ae(e){let t=Ce(e);t!==De&&(De=t,ke())}var je=!1;function Me(){je||(je=!0,_(()=>{Ae(T().logicalPathname)}))}function Ne(){return C()===null?typeof window>`u`?De:Ce(window.location.pathname):De}var Pe=!1;function Fe(){Pe||typeof window>`u`||(Pe=!0,window.addEventListener(`popstate`,()=>{C()===null&&ke()}))}function Ie(e){return Me(),Fe(),Oe.add(e),()=>{Oe.delete(e)}}function Le(e,t){Re(Te(e),t)}function Re(e,t){let n=Ce(e),r=C();if(r){t?.replace===!0?r.replace(n):r.push(n),Ae(n);return}typeof window<`u`&&(t?.replace===!0?window.history.replaceState(window.history.state,``,n):window.history.pushState(window.history.state,``,n)),De=n,ke()}function ze(){let e=(0,K.c)(2),t=(0,q.useSyncExternalStore)(Ie,Ne),n;return e[0]===t?n=e[1]:(n=we(t),e[0]=t,e[1]=n),n}var J=l(),Be={unavailable:`The node from this link is not in your authorized node directory. Choose a node to continue.`,revoked:`Access to the node from this link was revoked. Choose a node to continue.`,offline:`The node from this link is offline. Choose a node to continue.`,"invalid-link":`This node link is not valid. Choose a node to continue.`},Ve=null,He=new Set;function Y(e){if(Ve!==e){Ve=e;for(let e of Array.from(He))e()}}function Ue(e){return He.add(e),()=>{He.delete(e)}}function We(){return Ve===null?null:Be[Ve]}function Ge(){return(0,q.useSyncExternalStore)(Ue,We)}function Ke(){return(0,q.useSyncExternalStore)(_,T)}var qe=new Set([`node`,`draft`,`pair`,`diagnostics`,...Se]);function Je(e){let t=/^\/([^/]+)\/([^/]+)\/?$/.exec(e);if(!t)return null;let n=t[1]??``;if(qe.has(n))return null;try{return decodeURIComponent(n)}catch{return n}}function Ye(e){let t=/^\/([^/]+)\/([^/]+)\/?$/u.exec(e);if(!t||qe.has(t[1]??``))return null;try{return{environmentId:r.make(decodeURIComponent(t[1]??``)),threadId:n.make(decodeURIComponent(t[2]??``))}}catch{return null}}function Xe(e){return e.startsWith(`/draft/`)}var X=null,Z=null,Q=null,Ze=!1,Qe=null,$e=0,et=!1,tt=null,nt=null;function $(e){let t=e?JSON.stringify([e.environmentId,e.threadId]):null;t!==tt&&(nt?.(),nt=null,tt=t,e&&(nt=x(e.environmentId,e.threadId)))}function rt(e){return e?JSON.stringify([e.environmentId,e.threadId]):null}function it(){et||(et=!0,queueMicrotask(()=>{et=!1,$e!==0&&st()}))}function at(e){Ze=!0;try{e()}finally{Ze=!1}it()}function ot(e,t){X=null,Z=null,Q=null,(e===`none`||e===`online`||e===`offline`)&&Y(t),y()}function st(){if(Ze||!C())return;let e=T(),t=a.getState();if(e.malformed){Y(`invalid-link`),$(null),y();return}if(t.accountStatus!==`authenticated`){$(null),Qe===`authenticated`&&Y(null),Qe=t.accountStatus;return}Qe=t.accountStatus;let n=e.nodeId;if(n===null){if(Q=null,$(null),X=null,Z=null,t.selectedNode&&!S()){let e=t.selectionStatus===`revoked`||t.selectionStatus===`authorization-removed`||t.selectionStatus===`incompatible`;M.returnToDirectory(e?{preserveTerminalSelection:!0}:void 0);return}ct(e.logicalPathname,t);return}let r=Ye(e.logicalPathname);rt(r)!==tt&&$(null);let i=t.nodes.find(e=>e.id===n)??null,o=r!==null&&h(p.getState(),r)&&(i?.environmentId===r.environmentId&&i.revokedAt===null&&!i.capabilities?.nativeClientRequired||t.directoryStatus!==`ready`&&re()&&F().nodes.some(e=>e.nodeId===n&&e.environmentId===r.environmentId));if(i&&(i.capabilities?.nativeClientRequired===!0||r&&i.environmentId!==r.environmentId)){$(null),ot(t.selectionStatus,`unavailable`);return}if(t.selectedNode?.id===n){if($(r),X=null,Q=null,t.sessionEstablished){Z=null,Y(null);return}if(Z===n&&t.transportStatus===`terminal-failure`&&(t.selectionStatus===`revoked`||t.selectionStatus===`authorization-removed`||t.selectionStatus===`incompatible`)){Z=null,at(()=>{y(),M.returnToDirectory({preserveTerminalSelection:!0})});return}if(Z===n&&t.transportStatus===`terminal-failure`&&t.selectionStatus===`offline`&&t.errorMessage===`Ryco state could not be synchronized.`){if(o)return;at(()=>{ot(t.selectionStatus,`offline`),M.returnToDirectory()})}return}if(t.directoryStatus===`stale`){if(o){$(null);return}ot(t.selectionStatus,`unavailable`);return}if(t.directoryStatus!==`ready`||t.browserStatus!==`current`&&t.browserStatus!==`synchronizing`)return;let s=t.nodes.find(e=>e.id===n);if(!s){ot(t.selectionStatus,`unavailable`);return}if(s.revokedAt!==null){ot(t.selectionStatus,`revoked`);return}let c=Q===n;$(r);let l=r!==null&&!s.presence.online&&!c;r&&S()&&!l||X!==n&&(X=n,Z=c?null:n,Q=null,Y(null),M.selectNode(s.id).finally(()=>{X===n&&(X=null)}))}function ct(e,t){if(Xe(e)){y();return}let n=Je(e);if(n===null)return;if(t.directoryStatus===`stale`){Y(`unavailable`),y();return}if(t.directoryStatus!==`ready`)return;let r=t.nodes.find(e=>e.environmentId===n&&e.revokedAt===null);if(!r){Y(`unavailable`),y();return}b(r.id)}function lt(e){return C()?(Q=e,Y(null),v(e)):!1}function ut(){if(!C())return!1;Q=null,Y(null);let e=T();return e.nodeId===null&&e.logicalPathname===`/nodes`||w()}function dt(){$e+=1;let e=_(it),t=a.subscribe(it),n=C()?.subscribe(()=>it());it();let r=!1;return()=>{r||(r=!0,--$e,e(),t(),n?.())}}function ft(){let e=(0,K.c)(1),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=[],e[0]=t):t=e[0],(0,q.useEffect)(pt,t)}function pt(){return dt()}function mt(e){let t=(0,K.c)(11),{label:n,status:r,icon:a,onClick:o,testId:s,className:c}=e,l;t[0]===c?l=t[1]:(l=i(V(`chip`),`flex min-h-11 min-w-11 max-w-[136px] shrink items-center justify-center gap-1.5 rounded-full border border-border px-2.5 text-xs font-medium outline-none focus-visible:ring-2 focus-visible:ring-ring`,c),t[0]=c,t[1]=l);let u;t[2]===r?u=t[3]:(u=(0,J.jsx)(`span`,{"data-slot":`mobile-status-chip-status`,className:`min-w-0 truncate`,children:r}),t[2]=r,t[3]=u);let d;return t[4]!==a||t[5]!==n||t[6]!==o||t[7]!==l||t[8]!==u||t[9]!==s?(d=(0,J.jsxs)(`button`,{type:`button`,"aria-label":n,"data-slot":`mobile-status-chip`,"data-testid":s,className:l,onClick:o,children:[a,u]}),t[4]=a,t[5]=n,t[6]=o,t[7]=l,t[8]=u,t[9]=s,t[10]=d):d=t[10],d}var ht={legacy:{glyph:`legacy`,iconClassName:`text-amber-500`},web:{glyph:`browser-encrypted`,iconClassName:`text-sky-500`},account:{glyph:`account-trusted`,iconClassName:`text-indigo-500`},e2ee:{glyph:`native-verified`,iconClassName:`text-emerald-500`}};function gt(e){return e.guarantee===`none`?e.connected?{glyph:`connected`,iconClassName:`text-emerald-500`}:{glyph:`disconnected`,iconClassName:`text-amber-500`}:ht[e.guarantee]}function _t(){let e=(0,K.c)(19),n=oe(),r=U(),i=a(bt),o=a(yt),c=a(vt);if(n!==`web-unsigned`)return null;let l,u;e[0]!==r||e[1]!==o||e[2]!==i||e[3]!==c?(l=le(d(`security`,{hosted:t(),role:s(i,o,c)})),u=H(r,l),e[0]=r,e[1]=o,e[2]=i,e[3]=c,e[4]=l,e[5]=u):(l=e[4],u=e[5]);let p=u;if(!p){let t;return e[6]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,J.jsxs)(`section`,{"aria-label":`Session code`,"data-testid":`hosted-e2ee-verification`,"data-code":`absent`,className:`space-y-2`,children:[(0,J.jsx)(`p`,{className:`text-xs font-medium`,children:`Session code`}),(0,J.jsx)(`p`,{"data-testid":`hosted-e2ee-verification-unavailable`,className:`text-[11px] leading-relaxed text-muted-foreground`,children:ce})]}),e[6]=t):t=e[6],t}let m;e[7]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,J.jsx)(`p`,{className:`text-xs font-medium`,children:`Session code`}),e[7]=m):m=e[7];let h;e[8]===p.display?h=e[9]:(h=(0,J.jsx)(`p`,{"data-testid":`hosted-e2ee-verification-code`,className:`font-mono text-base leading-none font-semibold tracking-[0.2em] whitespace-nowrap select-all`,children:p.display}),e[8]=p.display,e[9]=h);let g;e[10]===p.display?g=e[11]:(g=()=>void navigator.clipboard.writeText(p.display),e[10]=p.display,e[11]=g);let _;e[12]===Symbol.for(`react.memo_cache_sentinel`)?(_=(0,J.jsx)(f,{"aria-hidden":!0,className:`size-3.5`}),e[12]=_):_=e[12];let v;e[13]===g?v=e[14]:(v=(0,J.jsxs)(`button`,{type:`button`,className:`inline-flex items-center gap-1.5 text-xs text-muted-foreground hover:text-foreground`,onClick:g,children:[_,` Copy`]}),e[13]=g,e[14]=v);let y;return e[15]!==l||e[16]!==h||e[17]!==v?(y=(0,J.jsxs)(`section`,{"aria-label":`Session code`,"data-testid":`hosted-e2ee-verification`,"data-code":`present`,"data-form":l,className:`space-y-2`,children:[m,h,v]}),e[15]=l,e[16]=h,e[17]=v,e[18]=y):y=e[18],y}function vt(e){return e.transportStatus}function yt(e){return e.directoryStatus}function bt(e){return e.effectiveRole}var xt=`ryco:pwa:activate:v1`,St=`Installation is temporarily unavailable.`,Ct={errorMessage:null,installState:`hidden`,platform:`other`,registrationState:`disabled`,updateState:`idle`};function wt(e){return e===``||e===`./`?`./`:e.endsWith(`/`)?e:`${e}/`}function Tt(e){let t=e.navigator.userAgent;return/iPad|iPhone|iPod/.test(t)||/Macintosh/.test(t)&&e.navigator.maxTouchPoints>1}function Et(e){let t=e;return typeof t.prompt==`function`&&t.userChoice instanceof Promise}function Dt(e){let t=Ct,n=!1,r=null,i=null,a=!!e.navigator.serviceWorker?.controller,o=!1,s=!1,c=new Set,l=e.window.matchMedia(`(display-mode: standalone)`),u=e=>{let n={...t,...e};Object.entries(n).every(([e,n])=>t[e]===n)||(t=n,c.forEach(e=>e()))},d=()=>l.matches||e.navigator.standalone===!0,f=()=>d()?`installed`:`manual-available`,p=e=>{Et(e)&&!d()&&(e.preventDefault(),r=e,u({installState:`native-available`}))},m=()=>{r=null,u({installState:`installed`})},h=()=>{d()?(r=null,u({installState:`installed`})):u({installState:r?`native-available`:`manual-available`})},g=()=>{let t=a;a=!!e.navigator.serviceWorker?.controller,!(o||!s&&!t)&&(s=!1,o=!0,e.window.reload())},_=t=>{i=t,t.waiting&&u({updateState:`ready`}),t.addEventListener(`updatefound`,()=>{let n=t.installing;n&&n.addEventListener(`statechange`,()=>{n.state===`installed`&&e.navigator.serviceWorker?.controller&&u({updateState:`ready`})})})},v=async()=>{let t=e.navigator.serviceWorker;if(!t){u({registrationState:`unavailable`,errorMessage:St});return}u({registrationState:`registering`,errorMessage:null});try{let n=wt(e.baseUrl);_(await t.register(`${n}service-worker.js`,{scope:n})),u({registrationState:`ready`,errorMessage:null})}catch{u({registrationState:`unavailable`,errorMessage:St})}};return{activateUpdate(){let e=i?.waiting;e&&t.updateState===`ready`&&(s=!0,u({updateState:`activating`}),e.postMessage({type:xt}))},dismissInstall(){r=null,u({installState:d()?`installed`:`hidden`})},getSnapshot(){return t},async promptInstall(){let e=r;e&&(r=null,u({installState:`hidden`}),await e.prompt(),(await e.userChoice).outcome===`dismissed`&&!d()&&u({installState:`manual-available`}))},async start(t){n||(n=!0,t.enabled&&(a=!!e.navigator.serviceWorker?.controller,o=!1,u({installState:f(),platform:Tt(e)?`ios`:`other`}),e.window.addEventListener(`beforeinstallprompt`,p),e.window.addEventListener(`appinstalled`,m),l.addEventListener(`change`,h),e.navigator.serviceWorker?.addEventListener(`controllerchange`,g),e.document.readyState===`complete`?await v():e.window.addEventListener(`load`,()=>void v(),{once:!0})))},stop(){n&&(n=!1,r=null,i=null,a=!1,o=!1,s=!1,e.window.removeEventListener(`beforeinstallprompt`,p),e.window.removeEventListener(`appinstalled`,m),l.removeEventListener(`change`,h),e.navigator.serviceWorker?.removeEventListener(`controllerchange`,g),t=Ct,c.forEach(e=>e()))},subscribe(e){return c.add(e),()=>c.delete(e)}}}function Ot(){let e=navigator;return{baseUrl:`/`,document,navigator:{maxTouchPoints:e.maxTouchPoints,userAgent:e.userAgent,...e.serviceWorker?{serviceWorker:e.serviceWorker}:{},...typeof e.standalone==`boolean`?{standalone:e.standalone}:{}},window:{addEventListener:window.addEventListener.bind(window),removeEventListener:window.removeEventListener.bind(window),matchMedia:window.matchMedia.bind(window),reload:()=>window.location.reload()}}}var kt=typeof window>`u`?null:Dt(Ot());function At(e){let t=(0,K.c)(3),{compact:n,lifecycle:r}=e,i=n!==void 0&&n,a=r===void 0?kt:r,o;return t[0]!==i||t[1]!==a?(o=a?(0,J.jsx)(jt,{compact:i,lifecycle:a}):null,t[0]=i,t[1]=a,t[2]=o):o=t[2],o}function jt(e){let t=(0,K.c)(27),{compact:n,lifecycle:r}=e,i=(0,q.useSyncExternalStore)(r.subscribe,r.getSnapshot,r.getSnapshot),[a,o]=(0,q.useState)(!1);if(i.installState!==`native-available`&&i.installState!==`manual-available`&&i.updateState===`idle`&&i.registrationState!==`unavailable`)return null;let s=n?`space-y-2`:`mt-4 space-y-3`,l;t[0]!==n||t[1]!==r||t[2]!==i.installState?(l=i.installState===`native-available`?(0,J.jsxs)(c,{className:`min-h-11`,size:n?`sm`:`default`,variant:`outline`,onClick:()=>void r.promptInstall(),children:[(0,J.jsx)(O,{"aria-hidden":!0}),` Install Ryco`]}):null,t[0]=n,t[1]=r,t[2]=i.installState,t[3]=l):l=t[3];let u;t[4]!==n||t[5]!==a||t[6]!==i.installState?(u=i.installState===`manual-available`?(0,J.jsxs)(c,{className:`min-h-11`,size:n?`sm`:`default`,variant:`outline`,"aria-expanded":a,onClick:()=>o(Mt),children:[(0,J.jsx)(j,{"aria-hidden":!0}),` How to install`]}):null,t[4]=n,t[5]=a,t[6]=i.installState,t[7]=u):u=t[7];let d;t[8]!==n||t[9]!==r||t[10]!==i.updateState?(d=i.updateState===`idle`?null:(0,J.jsxs)(c,{className:`min-h-11`,size:n?`sm`:`default`,variant:`outline`,disabled:i.updateState===`activating`,onClick:()=>r.activateUpdate(),children:[(0,J.jsx)(te,{"aria-hidden":!0}),i.updateState===`activating`?`Updating…`:`Update ready`]}),t[8]=n,t[9]=r,t[10]=i.updateState,t[11]=d):d=t[11];let f;t[12]!==l||t[13]!==u||t[14]!==d?(f=(0,J.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[l,u,d]}),t[12]=l,t[13]=u,t[14]=d,t[15]=f):f=t[15];let p;t[16]!==a||t[17]!==i?(p=a?(0,J.jsx)(Nt,{snapshot:i,onClose:()=>o(!1)}):null,t[16]=a,t[17]=i,t[18]=p):p=t[18];let m;t[19]!==i.errorMessage||t[20]!==i.registrationState?(m=i.registrationState===`unavailable`&&i.errorMessage?(0,J.jsx)(`p`,{role:`status`,className:`text-xs text-muted-foreground`,children:i.errorMessage}):null,t[19]=i.errorMessage,t[20]=i.registrationState,t[21]=m):m=t[21];let h;return t[22]!==s||t[23]!==f||t[24]!==p||t[25]!==m?(h=(0,J.jsxs)(`section`,{className:s,"aria-label":`Ryco app installation`,children:[f,p,m]}),t[22]=s,t[23]=f,t[24]=p,t[25]=m,t[26]=h):h=t[26],h}function Mt(e){return!e}function Nt(e){let t=(0,K.c)(13),{snapshot:n,onClose:r}=e,i;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,J.jsx)(`p`,{className:`font-medium`,children:`Install Ryco on this device`}),t[0]=i):i=t[0];let a;t[1]===n.platform?a=t[2]:(a=(0,J.jsxs)(`div`,{children:[i,n.platform===`ios`?(0,J.jsx)(`p`,{className:`mt-1 text-xs leading-relaxed text-muted-foreground`,children:`In Safari, open the Share or browser menu, choose Add to Home Screen, enable Open as Web App when offered, then tap Add.`}):(0,J.jsx)(`p`,{className:`mt-1 text-xs leading-relaxed text-muted-foreground`,children:`Open the browser menu, choose Add to home screen or Install app, then confirm Install.`})]}),t[1]=n.platform,t[2]=a);let o;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(o=(0,J.jsx)(u,{"aria-hidden":!0}),t[3]=o):o=t[3];let s;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,J.jsx)(`span`,{className:`sr-only`,children:`Close install instructions`}),t[4]=s):s=t[4];let l;t[5]===r?l=t[6]:(l=(0,J.jsxs)(c,{className:`size-11 shrink-0`,size:`icon`,variant:`ghost`,onClick:r,children:[o,` `,s]}),t[5]=r,t[6]=l);let d;t[7]!==a||t[8]!==l?(d=(0,J.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[a,l]}),t[7]=a,t[8]=l,t[9]=d):d=t[9];let f;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(f=(0,J.jsx)(`div`,{className:`mt-3 border-t border-border pt-3`,children:(0,J.jsx)(W,{compact:!0})}),t[10]=f):f=t[10];let p;return t[11]===d?p=t[12]:(p=(0,J.jsxs)(`div`,{role:`region`,"aria-label":`Install Ryco instructions`,className:`rounded-lg border border-border bg-background p-3 text-sm`,children:[d,f]}),t[11]=d,t[12]=p),p}var Pt={connected:ye,disconnected:_e,legacy:he,"browser-encrypted":A,"account-trusted":de,"native-verified":k};function Ft(e){let t=(0,K.c)(9),{indicator:n,className:r,testId:i}=e,a;t[0]===n?a=t[1]:(a=gt(n),t[0]=n,t[1]=a);let{glyph:o,iconClassName:s}=a,c=Pt[o],l=String(n.connected),u=`${r} ${s}`,d;return t[2]!==c||t[3]!==o||t[4]!==n.guarantee||t[5]!==l||t[6]!==u||t[7]!==i?(d=(0,J.jsx)(c,{"aria-hidden":!0,"data-testid":i,"data-connected":l,"data-guarantee":n.guarantee,"data-glyph":o,className:u}),t[2]=c,t[3]=o,t[4]=n.guarantee,t[5]=l,t[6]=u,t[7]=i,t[8]=d):d=t[8],d}function It(e){let t=(0,K.c)(3),{node:n}=e;if(n.revokedAt){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,J.jsx)(`span`,{className:`text-xs text-destructive`,children:`Revoked`}),t[0]=e):e=t[0],e}let r;return t[1]===n.presence.online?r=t[2]:(r=n.presence.online?(0,J.jsxs)(`span`,{className:`flex items-center gap-1 text-xs text-emerald-600 dark:text-emerald-400`,children:[(0,J.jsx)(ye,{"aria-hidden":!0,className:`size-3.5`}),` Online`]}):(0,J.jsxs)(`span`,{className:`flex items-center gap-1 text-xs text-muted-foreground`,children:[(0,J.jsx)(_e,{"aria-hidden":!0,className:`size-3.5`}),` Offline`]}),t[1]=n.presence.online,t[2]=r),r}function Lt(){let e=(0,K.c)(7),t=D(),n;e[0]===t?n=e[1]:(n=async e=>{lt(e.id)||(await t({to:`/`,replace:!0}),await M.selectNode(e.id))},e[0]=t,e[1]=n);let r=n,i;e[2]===t?i=e[3]:(i=async()=>{ut()||(await t({to:`/`,replace:!0}),await M.returnToDirectory())},e[2]=t,e[3]=i);let a=i,o;return e[4]!==a||e[5]!==r?(o={switchNode:r,returnToAllNodes:a},e[4]=a,e[5]=r,e[6]=o):o=e[6],o}function Rt(){let e=(0,K.c)(5),t=a(Vt),n=a(Bt);if(t!==`delivery-unknown`)return null;let r;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,J.jsx)(`p`,{children:`A request may or may not have reached the node. Ryco did not resend it automatically.`}),e[0]=r):r=e[0];let i=!n,o=n?void 0:`Wait for session replay to finish before acknowledging this warning.`,s=n?`Acknowledge`:`Synchronizing…`,l;return e[1]!==i||e[2]!==o||e[3]!==s?(l=(0,J.jsxs)(`div`,{role:`alert`,className:`mt-2 rounded-md border border-amber-500/30 bg-amber-500/5 p-2 text-xs`,children:[r,(0,J.jsx)(c,{className:`mt-2`,size:`sm`,variant:`outline`,disabled:i,title:o,onClick:zt,children:s})]}),e[1]=i,e[2]=o,e[3]=s,e[4]=l):l=e[4],l}function zt(){return M.acknowledgeDeliveryUnknown()}function Bt(e){return e.sessionRecoveredAfterUnknown}function Vt(e){return e.sessionStatus}function Ht(){let e=(0,K.c)(64),t=I(),n=a(tn),r=a(en),i=a($t),s=a(Qt),l=a(Zt),u=a(Xt),d=a(Yt),f=a(Jt),p=a(qt),m=oe(),{switchNode:h,returnToAllNodes:g}=Lt(),_=(0,q.useRef)(null);if(!n){if(!t.accountId||!re())return null;let n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,J.jsx)(`summary`,{className:`cursor-pointer rounded-lg px-3 py-2 text-muted-foreground`,children:`Saved view · Reconnecting`}),e[0]=n):n=e[0];let r;return e[1]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,J.jsxs)(`details`,{className:`relative text-xs`,children:[n,(0,J.jsxs)(`div`,{className:`absolute right-0 z-50 mt-2 grid w-64 gap-2 rounded-lg border bg-popover p-3 shadow-md`,children:[(0,J.jsx)(`p`,{children:`Reading saved text. Sending work waits for a fresh connection.`}),(0,J.jsx)(c,{variant:`ghost`,size:`sm`,onClick:Kt,children:`Retry connection`}),(0,J.jsx)(c,{variant:`ghost`,size:`sm`,onClick:Gt,children:`Forget saved conversations`})]})]}),e[1]=r):r=e[1],r}let v,y;if(e[2]!==p||e[3]!==m||e[4]!==l||e[5]!==s||e[6]!==i){let t={browserStatus:p,sessionStatus:s,selectionStatus:l,transportStatus:i,e2eeStatus:m};v=se(t),y=ue(t),e[2]=p,e[3]=m,e[4]=l,e[5]=s,e[6]=i,e[7]=v,e[8]=y}else v=e[7],y=e[8];let b=y,x;e[9]===b?x=e[10]:(x=(0,J.jsx)(Ft,{indicator:b,className:`size-4`}),e[9]=b,e[10]=x);let S;e[11]===n.label?S=e[12]:(S=(0,J.jsx)(`span`,{className:`max-w-32 truncate font-medium`,children:n.label}),e[11]=n.label,e[12]=S);let C;e[13]===v?C=e[14]:(C=(0,J.jsx)(`span`,{className:`max-w-24 truncate text-xs text-muted-foreground`,children:v}),e[13]=v,e[14]=C);let w;e[15]===Symbol.for(`react.memo_cache_sentinel`)?(w=(0,J.jsx)(o,{"aria-hidden":!0,className:`size-3.5 transition-transform group-open:rotate-180`}),e[15]=w):w=e[15];let T;e[16]!==x||e[17]!==S||e[18]!==C?(T=(0,J.jsxs)(`summary`,{className:`flex cursor-pointer list-none items-center gap-2 rounded-lg border border-border bg-card/95 px-3 py-2 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[x,S,C,w]}),e[16]=x,e[17]=S,e[18]=C,e[19]=T):T=e[19];let E;e[20]===n.label?E=e[21]:(E=(0,J.jsx)(`p`,{className:`font-medium`,children:n.label}),e[20]=n.label,e[21]=E);let D=d??`Role unavailable`,O;e[22]!==v||e[23]!==D?(O=(0,J.jsxs)(`p`,{className:`mt-0.5 text-xs capitalize text-muted-foreground`,children:[D,` · `,v]}),e[22]=v,e[23]=D,e[24]=O):O=e[24];let k;e[25]!==n.label||e[26]!==v?(k=(0,J.jsxs)(`p`,{className:`sr-only`,"aria-live":`polite`,children:[`Node `,n.label,`: `,v,`.`]}),e[25]=n.label,e[26]=v,e[27]=k):k=e[27];let A;e[28]===f?A=e[29]:(A=f?(0,J.jsx)(`p`,{role:`status`,className:`mt-2 text-xs text-muted-foreground`,children:f}):null,e[28]=f,e[29]=A);let j;e[30]===Symbol.for(`react.memo_cache_sentinel`)?(j=(0,J.jsx)(Rt,{}),e[30]=j):j=e[30];let M;e[31]===g?M=e[32]:(M=()=>void g(),e[31]=g,e[32]=M);let N;e[33]===Symbol.for(`react.memo_cache_sentinel`)?(N=(0,J.jsx)(pe,{"aria-hidden":!0,className:`size-4`}),e[33]=N):N=e[33];let P;e[34]===M?P=e[35]:(P=(0,J.jsxs)(`button`,{type:`button`,className:`flex w-full items-center gap-2 rounded-md px-2 py-2 text-left text-sm hover:bg-accent focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring`,onClick:M,children:[N,` All nodes`]}),e[34]=M,e[35]=P);let F;if(e[36]!==p||e[37]!==u||e[38]!==n.id||e[39]!==r||e[40]!==h){let t;e[42]===n.id?t=e[43]:(t=e=>e.id!==n.id,e[42]=n.id,e[43]=t);let i;e[44]!==p||e[45]!==u||e[46]!==h?(i=e=>(0,J.jsxs)(`button`,{type:`button`,disabled:u!==`ready`||p!==`current`||e.revokedAt!==null||e.capabilities?.nativeClientRequired===!0,title:e.capabilities?.nativeClientRequired===!0?`Open in Desktop/Mobile`:void 0,className:`flex w-full items-center justify-between rounded-md px-2 py-2 text-left text-sm hover:bg-accent focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50`,onClick:()=>void h(e),children:[(0,J.jsx)(`span`,{className:`truncate`,children:e.label}),(0,J.jsx)(It,{node:e})]},e.id),e[44]=p,e[45]=u,e[46]=h,e[47]=i):i=e[47],F=r.filter(t).map(i),e[36]=p,e[37]=u,e[38]=n.id,e[39]=r,e[40]=h,e[41]=F}else F=e[41];let L;e[48]!==P||e[49]!==F?(L=(0,J.jsxs)(`div`,{className:`mt-3 max-h-48 space-y-1 overflow-auto border-t border-border pt-3`,children:[P,F]}),e[48]=P,e[49]=F,e[50]=L):L=e[50];let ie;e[51]===Symbol.for(`react.memo_cache_sentinel`)?(ie=(0,J.jsxs)(c,{size:`sm`,variant:`outline`,onClick:Wt,children:[(0,J.jsx)(te,{"aria-hidden":!0}),` Refresh`]}),e[51]=ie):ie=e[51];let ae;e[52]===Symbol.for(`react.memo_cache_sentinel`)?(ae=(0,J.jsxs)(c,{size:`sm`,variant:`ghost`,onClick:Ut,children:[(0,J.jsx)(ee,{"aria-hidden":!0}),` Sign out`]}),e[52]=ae):ae=e[52];let R;e[53]===Symbol.for(`react.memo_cache_sentinel`)?(R=(0,J.jsxs)(`div`,{className:`mt-3 flex flex-wrap gap-2 border-t border-border pt-3`,children:[ie,ae,(0,J.jsxs)(c,{size:`sm`,variant:`ghost`,onClick:()=>{_.current&&(_.current.open=!1),Le({kind:`account`,section:`security`})},children:[(0,J.jsx)(ne,{"aria-hidden":!0}),` Security details`]})]}),e[53]=R):R=e[53];let z;e[54]===Symbol.for(`react.memo_cache_sentinel`)?(z=(0,J.jsxs)(`div`,{className:`mt-3 space-y-3 border-t border-border pt-3`,children:[(0,J.jsx)(_t,{}),(0,J.jsx)(At,{compact:!0})]}),e[54]=z):z=e[54];let B;e[55]!==A||e[56]!==L||e[57]!==E||e[58]!==O||e[59]!==k?(B=(0,J.jsxs)(`div`,{className:`absolute right-0 z-50 mt-2 w-72 rounded-xl border border-border bg-popover p-3 shadow-xl`,children:[E,O,k,A,j,L,R,z]}),e[55]=A,e[56]=L,e[57]=E,e[58]=O,e[59]=k,e[60]=B):B=e[60];let V;return e[61]!==B||e[62]!==T?(V=(0,J.jsx)(`div`,{className:`relative max-w-full`,children:(0,J.jsxs)(`details`,{ref:_,className:`group relative`,children:[T,B]})}),e[61]=B,e[62]=T,e[63]=V):V=e[63],V}function Ut(){M.signOut()}function Wt(){M.refreshDirectory()}function Gt(){P(!1)}function Kt(){M.bootstrap()}function qt(e){return e.browserStatus}function Jt(e){return e.errorMessage}function Yt(e){return e.effectiveRole}function Xt(e){return e.directoryStatus}function Zt(e){return e.selectionStatus}function Qt(e){return e.sessionStatus}function $t(e){return e.transportStatus}function en(e){return e.nodes}function tn(e){return e.selectedNode}function nn(e){let t=(0,K.c)(66),{open:n,onOpenChange:r}=e,i=a(mn),o=a(pn),s=a(fn),l=a(dn),u=a(un),d=a(ln),f=a(cn),p=a(sn),m=a(on),h=oe(),{switchNode:g,returnToAllNodes:_}=Lt();if(!i)return null;let v,y;if(t[0]!==m||t[1]!==h||t[2]!==u||t[3]!==l||t[4]!==s){let e={browserStatus:m,sessionStatus:l,selectionStatus:u,transportStatus:s,e2eeStatus:h};v=se(e),y=ue(e),t[0]=m,t[1]=h,t[2]=u,t[3]=l,t[4]=s,t[5]=v,t[6]=y}else v=t[5],y=t[6];let b=y,x=d!==`ready`||m!==`current`,S;t[7]===b?S=t[8]:(S=(0,J.jsx)(Ft,{indicator:b,className:`size-4`}),t[7]=b,t[8]=S);let C;t[9]===i.label?C=t[10]:(C=(0,J.jsx)(`span`,{className:`truncate`,children:i.label}),t[9]=i.label,t[10]=C);let w;t[11]!==S||t[12]!==C?(w=(0,J.jsxs)(R,{className:`flex items-center gap-2`,children:[S,C]}),t[11]=S,t[12]=C,t[13]=w):w=t[13];let T=f??`Role unavailable`,E;t[14]!==v||t[15]!==T?(E=(0,J.jsxs)(ae,{className:`capitalize`,children:[T,` · `,v]}),t[14]=v,t[15]=T,t[16]=E):E=t[16];let D;t[17]!==i.label||t[18]!==v?(D=(0,J.jsxs)(`p`,{className:`sr-only`,"aria-live":`polite`,children:[`Node `,i.label,`: `,v,`.`]}),t[17]=i.label,t[18]=v,t[19]=D):D=t[19];let O;t[20]!==w||t[21]!==E||t[22]!==D?(O=(0,J.jsxs)(ie,{children:[w,E,D]}),t[20]=w,t[21]=E,t[22]=D,t[23]=O):O=t[23];let k;t[24]===p?k=t[25]:(k=p?(0,J.jsx)(`p`,{role:`status`,className:`text-xs text-muted-foreground`,children:p}):null,t[24]=p,t[25]=k);let A;t[26]===Symbol.for(`react.memo_cache_sentinel`)?(A=(0,J.jsx)(Rt,{}),t[26]=A):A=t[26];let j;t[27]===Symbol.for(`react.memo_cache_sentinel`)?(j=(0,J.jsx)(ne,{"aria-hidden":!0,className:`size-4 shrink-0`}),t[27]=j):j=t[27];let M;t[28]===r?M=t[29]:(M=(0,J.jsx)(z,{label:`Security details`,icon:j,onClick:()=>{r(!1),Le({kind:`account`,section:`security`})}}),t[28]=r,t[29]=M);let N;t[30]===Symbol.for(`react.memo_cache_sentinel`)?(N=(0,J.jsx)(pe,{"aria-hidden":!0,className:`size-4 shrink-0`}),t[30]=N):N=t[30];let P;t[31]!==r||t[32]!==_?(P=(0,J.jsx)(z,{label:`All nodes`,icon:N,onClick:()=>{r(!1),_()}}),t[31]=r,t[32]=_,t[33]=P):P=t[33];let F;if(t[34]!==i.id||t[35]!==o||t[36]!==r||t[37]!==g||t[38]!==x){let e;t[40]===i.id?e=t[41]:(e=e=>e.id!==i.id,t[40]=i.id,t[41]=e);let n;t[42]!==r||t[43]!==g||t[44]!==x?(n=e=>(0,J.jsx)(z,{label:e.label,disabled:x||e.revokedAt!==null||e.capabilities?.nativeClientRequired===!0,disabledReason:e.capabilities?.nativeClientRequired===!0?`Open in Desktop/Mobile`:e.revokedAt===null?`Node switching is unavailable until the directory and this browser are current.`:`Access to this node was revoked.`,trailing:(0,J.jsx)(It,{node:e}),onClick:()=>{r(!1),g(e)}},e.id),t[42]=r,t[43]=g,t[44]=x,t[45]=n):n=t[45],F=o.filter(e).map(n),t[34]=i.id,t[35]=o,t[36]=r,t[37]=g,t[38]=x,t[39]=F}else F=t[39];let I;t[46]!==M||t[47]!==P||t[48]!==F?(I=(0,J.jsxs)(`div`,{className:`mt-3 space-y-1 border-t border-border pt-3`,children:[M,P,F]}),t[46]=M,t[47]=P,t[48]=F,t[49]=I):I=t[49];let re=d===`loading`,V;t[50]===Symbol.for(`react.memo_cache_sentinel`)?(V=(0,J.jsx)(te,{"aria-hidden":!0}),t[50]=V):V=t[50];let H;t[51]===re?H=t[52]:(H=(0,J.jsxs)(c,{size:`sm`,variant:`outline`,className:`min-h-11`,disabled:re,onClick:an,children:[V,` Refresh nodes`]}),t[51]=re,t[52]=H);let ce;t[53]===Symbol.for(`react.memo_cache_sentinel`)?(ce=(0,J.jsxs)(c,{size:`sm`,variant:`ghost`,className:`min-h-11`,onClick:rn,children:[(0,J.jsx)(ee,{"aria-hidden":!0}),` Sign out`]}),t[53]=ce):ce=t[53];let U;t[54]===H?U=t[55]:(U=(0,J.jsxs)(`div`,{className:`mt-3 flex flex-wrap gap-2 border-t border-border pt-3`,children:[H,ce]}),t[54]=H,t[55]=U);let le;t[56]===Symbol.for(`react.memo_cache_sentinel`)?(le=(0,J.jsx)(`div`,{className:`mt-3 space-y-3 border-t border-border pt-3`,children:(0,J.jsx)(At,{compact:!0})}),t[56]=le):le=t[56];let W;t[57]!==I||t[58]!==U||t[59]!==k?(W=(0,J.jsxs)(L,{children:[k,A,I,U,le]}),t[57]=I,t[58]=U,t[59]=k,t[60]=W):W=t[60];let G;return t[61]!==r||t[62]!==n||t[63]!==W||t[64]!==O?(G=(0,J.jsxs)(B,{open:n,onOpenChange:r,label:`Connection`,children:[O,W]}),t[61]=r,t[62]=n,t[63]=W,t[64]=O,t[65]=G):G=t[65],G}function rn(){M.signOut()}function an(){M.refreshDirectory()}function on(e){return e.browserStatus}function sn(e){return e.errorMessage}function cn(e){return e.effectiveRole}function ln(e){return e.directoryStatus}function un(e){return e.selectionStatus}function dn(e){return e.sessionStatus}function fn(e){return e.transportStatus}function pn(e){return e.nodes}function mn(e){return e.selectedNode}function hn(){let e=(0,K.c)(25),t=a(bn),n=a(yn),r=a(vn),i=a(_n),o=a(gn),s=oe(),[c,l]=(0,q.useState)(!1);if(!t)return null;let u,d;if(e[0]!==o||e[1]!==s||e[2]!==i||e[3]!==r||e[4]!==n){let t={browserStatus:o,sessionStatus:r,selectionStatus:i,transportStatus:n,e2eeStatus:s};u=se(t),d=ue(t),e[0]=o,e[1]=s,e[2]=i,e[3]=r,e[4]=n,e[5]=u,e[6]=d}else u=e[5],d=e[6];let f=d,p;e[7]!==t.label||e[8]!==c||e[9]!==r||e[10]!==u?(p=c?null:(0,J.jsxs)(J.Fragment,{children:[(0,J.jsxs)(`span`,{role:`status`,"aria-live":`polite`,"data-testid":`hosted-connection-status-announcer`,className:`sr-only`,children:[`Node `,t.label,`: `,u,`.`]}),r===`delivery-unknown`?(0,J.jsx)(`span`,{role:`alert`,className:`sr-only`,children:`Delivery unknown: a request may or may not have reached the node. Open the connection controls to acknowledge.`}):null]}),e[7]=t.label,e[8]=c,e[9]=r,e[10]=u,e[11]=p):p=e[11];let m=`Connection: ${t.label}, ${u}`,h;e[12]===f?h=e[13]:(h=(0,J.jsx)(Ft,{indicator:f,testId:`hosted-connection-icon`,className:`size-3.5 shrink-0`}),e[12]=f,e[13]=h);let g;e[14]===Symbol.for(`react.memo_cache_sentinel`)?(g=()=>l(!0),e[14]=g):g=e[14];let _;e[15]!==f.shortLabel||e[16]!==m||e[17]!==h?(_=(0,J.jsx)(mt,{testId:`hosted-connection-pill`,label:m,status:f.shortLabel,icon:h,onClick:g}),e[15]=f.shortLabel,e[16]=m,e[17]=h,e[18]=_):_=e[18];let v;e[19]===c?v=e[20]:(v=(0,J.jsx)(nn,{open:c,onOpenChange:l}),e[19]=c,e[20]=v);let y;return e[21]!==p||e[22]!==_||e[23]!==v?(y=(0,J.jsxs)(J.Fragment,{children:[p,_,v]}),e[21]=p,e[22]=_,e[23]=v,e[24]=y):y=e[24],y}function gn(e){return e.browserStatus}function _n(e){return e.selectionStatus}function vn(e){return e.sessionStatus}function yn(e){return e.transportStatus}function bn(e){return e.selectedNode}function xn(){let e=(0,K.c)(2),t=N(),n;return e[0]===t?n=e[1]:(n=t===`phone`?(0,J.jsx)(hn,{}):(0,J.jsx)(Ht,{}),e[0]=t,e[1]=n),n}export{Re as _,Lt as a,We as c,Ge as d,ft as f,Le as g,Ee as h,It as i,Ye as l,Te as m,hn as n,At as o,Ke as p,Ht as r,kt as s,xn as t,lt as u,ze as v,_e as y};
|