@openscout/scout 0.2.79 → 0.2.80
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/bin/scoutd +0 -0
- package/dist/build-manifest.json +3 -3
- package/dist/client/assets/ActivityScreen-BXm6nJ6L.js +1 -0
- package/dist/client/assets/{AddProjectForm-BoVtelSP.js → AddProjectForm-CtEiLQnm.js} +1 -1
- package/dist/client/assets/{AgentAvatar-CufDA4A-.js → AgentAvatar-CszU5eaU.js} +1 -1
- package/dist/client/assets/AgentConfigurationScreen-CfBXxrsD.js +1 -0
- package/dist/client/assets/AgentDefinitionsWorkspace-4Z0aN8AR.js +1 -0
- package/dist/client/assets/{AgentDetailCard-DxxVkgT1.js → AgentDetailCard-sZuHl1de.js} +1 -1
- package/dist/client/assets/AgentFloorView-DMivAYHU.js +1 -0
- package/dist/client/assets/AgentInfoScreen-CPkLg1pK.js +1 -0
- package/dist/client/assets/{AgentLaneCard-DTUvE96I.js → AgentLaneCard-nB68f2CI.js} +1 -1
- package/dist/client/assets/{AgentLaneChrome-BfVygkgL.js → AgentLaneChrome-O9Yf0uR-.js} +1 -1
- package/dist/client/assets/AgentLaneDetailSheet-BfhpaEQ3.js +4 -0
- package/dist/client/assets/{AgentLaneSummaryResize-CMgzYvAA.js → AgentLaneSummaryResize-Ct3b0TQR.js} +1 -1
- package/dist/client/assets/AgentLanesEmbedScreen-CjHMvy3v.js +1 -0
- package/dist/client/assets/{AgentLanesPreflight-KWfLcaNB.js → AgentLanesPreflight-DNGvZvjd.js} +1 -1
- package/dist/client/assets/{AgentLanesView-CxfbV8Kd.js → AgentLanesView-DqRK5-d2.js} +1 -1
- package/dist/client/assets/{AgentLiveActions-CZdAInEu.js → AgentLiveActions-DI4ooSHW.js} +1 -1
- package/dist/client/assets/{AgentSessions-Bkr0lyry.js → AgentSessions-BxWIPkWh.js} +1 -1
- package/dist/client/assets/{AgentsConsole-WtFVqaPJ.js → AgentsConsole-D6VHSCfZ.js} +1 -1
- package/dist/client/assets/AgentsScreen-zR6b2bUL.js +1 -0
- package/dist/client/assets/AgentsSubnav-q0xcZi6C.js +1 -0
- package/dist/client/assets/{AtopView-_OKDlZ1h.js → AtopView-VZkk40v0.js} +1 -1
- package/dist/client/assets/{BackToPicker-CkUmHuuo.js → BackToPicker-DZg_4nHL.js} +1 -1
- package/dist/client/assets/{BriefingDetailScreen-i54EtZKW.js → BriefingDetailScreen-BZU4qMwE.js} +1 -1
- package/dist/client/assets/{BriefingsScreen-CBrHojlQ.js → BriefingsScreen-Bfc3tqPp.js} +1 -1
- package/dist/client/assets/{BrokerMetadataPanel-opTLuZU6.js → BrokerMetadataPanel-CaFe6kdh.js} +1 -1
- package/dist/client/assets/BrokerScreen-Chh8sGen.js +5 -0
- package/dist/client/assets/{ChatCollapsedStrip-Dr2vmKXQ.js → ChatCollapsedStrip-Cov54p9V.js} +1 -1
- package/dist/client/assets/{CodeDiffPane-CLOGjwul.js → CodeDiffPane-C1ebFt-Y.js} +1 -1
- package/dist/client/assets/{CodeProjectPicker-DTV8hR6A.js → CodeProjectPicker-tsCly-f3.js} +1 -1
- package/dist/client/assets/CodeScreen-D0hpZNLP.js +1 -0
- package/dist/client/assets/{ContextMenu-BlBQhpax.js → ContextMenu-N-Z6X0Z1.js} +1 -1
- package/dist/client/assets/ConversationComposer-CiEF7dhd.js +1 -0
- package/dist/client/assets/ConversationFeedRows-5it6QNBV.js +1 -0
- package/dist/client/assets/ConversationHeader-BGgbITvr.js +1 -0
- package/dist/client/assets/ConversationPanels-vI9YuQJh.js +2 -0
- package/dist/client/assets/ConversationScreen-C-PrCRz1.js +1 -0
- package/dist/client/assets/ConversationScreen-yIKEsm-8.css +1 -0
- package/dist/client/assets/{ConversationStatus-DSgdVofa.js → ConversationStatus-COEj5loj.js} +1 -1
- package/dist/client/assets/{DataTable-0DwuXyvW.js → DataTable-BoofV-_4.js} +1 -1
- package/dist/client/assets/{DispatchAftermath-BrreQifA.js → DispatchAftermath-OXYlMbT1.js} +1 -1
- package/dist/client/assets/{DocumentFocusViewer-DU_9BHsD.js → DocumentFocusViewer-BCG2kOmd.js} +1 -1
- package/dist/client/assets/{EmbeddableSurfacesLab-DdaswbfI.js → EmbeddableSurfacesLab-C2SZvrHJ.js} +1 -1
- package/dist/client/assets/{EmptyState-CoL-QuUO.js → EmptyState-DypEjx0V.js} +1 -1
- package/dist/client/assets/{FileViewerPane-C9Ly01Ef.js → FileViewerPane-CXCq-oKj.js} +1 -1
- package/dist/client/assets/{FleetSearch-DlWTLl-v.js → FleetSearch-Dj7-CfNi.js} +1 -1
- package/dist/client/assets/FlightObserveScreen-Yq5NtQQJ.js +1 -0
- package/dist/client/assets/FollowScreen-DRgYuAvp.js +1 -0
- package/dist/client/assets/HarnessMark-BE-YSyci.js +1 -0
- package/dist/client/assets/HarnessesScreen-L-emPcXd.js +1 -0
- package/dist/client/assets/HerdrSession-DKFCJMst.js +4 -0
- package/dist/client/assets/{HomeHero-Cfsow7qL.js → HomeHero-CAEg8Yg5.js} +1 -1
- package/dist/client/assets/{KnowledgeSearchInspector-DKashKoH.js → KnowledgeSearchInspector-C2EZsQ5i.js} +1 -1
- package/dist/client/assets/KnowledgeSearchScreen-DvdOFh-b.js +1 -0
- package/dist/client/assets/{LaneToolHoverCard-BzehBmdi.js → LaneToolHoverCard-DrPXYZvQ.js} +1 -1
- package/dist/client/assets/LaneTraceDetailSheet-Dl7foF88.js +1 -0
- package/dist/client/assets/{LaneTraceEventFocus-DYvHfs_3.js → LaneTraceEventFocus-X4-DDFEo.js} +1 -1
- package/dist/client/assets/{MeshCanvas-DIjlrMPU.js → MeshCanvas-rtCBD7s6.js} +1 -1
- package/dist/client/assets/{MeshCanvasMinimap-DEq-PkF0.js → MeshCanvasMinimap-CuvXOkc7.js} +1 -1
- package/dist/client/assets/MeshScreen-D5zzTn0o.js +1 -0
- package/dist/client/assets/{MeshTopologyView-BMHpH5BU.js → MeshTopologyView-CeTShs-U.js} +2 -2
- package/dist/client/assets/{MessageComposerSuggestions-zAUUcLOv.js → MessageComposerSuggestions-Cs9u-F_3.js} +1 -1
- package/dist/client/assets/MessagesScreen-BhOJ7_tj.js +1 -0
- package/dist/client/assets/MissionContextRail-0O-Zu1Tn.js +1 -0
- package/dist/client/assets/MissionControlView-D2JO9u-y.js +1 -0
- package/dist/client/assets/{MissionFocusOverlay-C7cPt6eU.js → MissionFocusOverlay-LnjmqBiW.js} +1 -1
- package/dist/client/assets/{MissionLeftAgentRow-CxlH3dON.js → MissionLeftAgentRow-nc1Jyq3D.js} +1 -1
- package/dist/client/assets/MissionLogPane-lZ9vUftY.js +1 -0
- package/dist/client/assets/{NewAgentModal-DprvD4EK.js → NewAgentModal-K1cvdmZr.js} +1 -1
- package/dist/client/assets/NewChatComposer-C5LT7MF7.css +1 -0
- package/dist/client/assets/NewChatComposer-DXDxV2Mh.js +19 -0
- package/dist/client/assets/{NewChatOrigin--pHWUb4V.js → NewChatOrigin-CnjoswTG.js} +1 -1
- package/dist/client/assets/{ObserveEmbedScreen-CfvrnOiZ.js → ObserveEmbedScreen-CRpzYf0Y.js} +1 -1
- package/dist/client/assets/{ObserveTextFlow-CBitljxi.js → ObserveTextFlow-DJxQc2H6.js} +2 -2
- package/dist/client/assets/{ObservedTopologyPanel-Dv6fbHzW.js → ObservedTopologyPanel-C1AQM0Mq.js} +1 -1
- package/dist/client/assets/OpenScoutAppShell-DrHYD_pd.js +87 -0
- package/dist/client/assets/OpsAgentsView-BnMX0vEY.js +1 -0
- package/dist/client/assets/OpsScreen-BeC0lieE.js +1 -0
- package/dist/client/assets/OpsSubnav-D5Bpowtk.js +1 -0
- package/dist/client/assets/{PlanView-DYtt8H37.js → PlanView-DDXdC19M.js} +1 -1
- package/dist/client/assets/ProjectAgentProfile-zE1cApxw.js +1 -0
- package/dist/client/assets/{ProjectAgentProfileBar-B3IvVbqS.js → ProjectAgentProfileBar-MODhG0P6.js} +1 -1
- package/dist/client/assets/{ProjectAgentProfileHero-D5E8yvDj.js → ProjectAgentProfileHero-C1ImgGDu.js} +1 -1
- package/dist/client/assets/ProjectsInbox-C3Jd6JTk.js +2 -0
- package/dist/client/assets/{ProjectsRail-DEDS-M1c.js → ProjectsRail-B1zrQLZe.js} +1 -1
- package/dist/client/assets/ProjectsScreen-PW_NH5VK.js +1 -0
- package/dist/client/assets/ProjectsThreadAside-DaCEUWN1.js +1 -0
- package/dist/client/assets/Provider-DSsb2gLR.js +1 -0
- package/dist/client/assets/{RailRow-BTlVAnHS.js → RailRow-DerXOXQS.js} +1 -1
- package/dist/client/assets/RawSessionsTable-LWEvXJzj.js +1 -0
- package/dist/client/assets/RealtimeVoiceScreen-XtxbCjOs.js +1 -0
- package/dist/client/assets/{RepoDiffEmbedScreen-CtTdlQ2A.js → RepoDiffEmbedScreen-C9oLCcZX.js} +1 -1
- package/dist/client/assets/{RepoDiffPageScreen-BRvaVYoC.js → RepoDiffPageScreen-CGEMAv2Z.js} +1 -1
- package/dist/client/assets/{RepoDiffViewer-Bo0gREMj.js → RepoDiffViewer-CB8PSVey.js} +1 -1
- package/dist/client/assets/RepoDiffViewerLazy-DIxkiMto.js +2 -0
- package/dist/client/assets/{ReposScreen-BBkJf8xT.js → ReposScreen-BN1lVjOj.js} +1 -1
- package/dist/client/assets/{ScoutDeckSurface-Bi9ov9Bm.js → ScoutDeckSurface-BCpl0QCx.js} +1 -1
- package/dist/client/assets/{ScoutSurface-DEQg_7Io.js → ScoutSurface-BEnDlynn.js} +1 -1
- package/dist/client/assets/{ScoutbotBroadcastChip-DJXuyn73.js → ScoutbotBroadcastChip-z9R_pC_U.js} +1 -1
- package/dist/client/assets/{ScoutbotFxLab-BgsuLDjo.js → ScoutbotFxLab-fAROyIfz.js} +1 -1
- package/dist/client/assets/{ScoutbotRealtimeVoiceCall-Bzyl0BCS.js → ScoutbotRealtimeVoiceCall-CDyFJX8m.js} +1 -1
- package/dist/client/assets/{SecondaryNav-Bks0CO2h.js → SecondaryNav-Hv5AJ3Fv.js} +1 -1
- package/dist/client/assets/{SessionEmbedScreen-b0Zgmfx5.js → SessionEmbedScreen-CDRpQc3g.js} +1 -1
- package/dist/client/assets/{SessionObserve-Dlx5vDaV.js → SessionObserve-BmmJ8dEh.js} +1 -1
- package/dist/client/assets/{SessionObserveEvidence-ChBD1d4c.js → SessionObserveEvidence-CEedIk2a.js} +1 -1
- package/dist/client/assets/SessionRefScreen-Dk-O4OVt.js +1 -0
- package/dist/client/assets/SessionsScreen-BJEjuo2X.js +1 -0
- package/dist/client/assets/{SettingsDrawer-C587L1i1.js → SettingsDrawer-DL-SVLdd.js} +1 -1
- package/dist/client/assets/SettingsScreen-DJ-BhBwR.js +1 -0
- package/dist/client/assets/{ShikiPane-I_OTW5NO.js → ShikiPane-B7O4if20.js} +1 -1
- package/dist/client/assets/{SlidePanel-FCqT1zO3.js → SlidePanel-B3gc5HnM.js} +1 -1
- package/dist/client/assets/{SpriteAvatar-CQs-jC-v.js → SpriteAvatar-BpQDpOkq.js} +1 -1
- package/dist/client/assets/{StatusPill-CbABggnQ.js → StatusPill-B33sQinT.js} +1 -1
- package/dist/client/assets/{TailView-C_MXVSum.js → TailView-DL3YZkzE.js} +2 -2
- package/dist/client/assets/Terminal-Dp1FSGIS.js +1 -0
- package/dist/client/assets/TerminalEmbedScreen-DP9IM4xf.js +1 -0
- package/dist/client/assets/{TextDocumentSurface-C-9EtYqt.js → TextDocumentSurface-DRjctOIt.js} +1 -1
- package/dist/client/assets/{TmuxPeek-Dz1gJ2pU.js → TmuxPeek-DNC4uWky.js} +1 -1
- package/dist/client/assets/{VoicePermissionsPanel-MfICy9kk.js → VoicePermissionsPanel-WLN0V-Xv.js} +1 -1
- package/dist/client/assets/{WorkDetailScreen-Cs7kdllj.js → WorkDetailScreen-D2Yl0mYZ.js} +1 -1
- package/dist/client/assets/{WorkFilesViewer-CF-nhtZ4.js → WorkFilesViewer-BbVfcUN-.js} +1 -1
- package/dist/client/assets/{activity-WhBf3FXP.js → activity-BxwKkT8z.js} +1 -1
- package/dist/client/assets/{addon-fit-q-x_HytU.js → addon-fit-B9O2vJoh.js} +1 -1
- package/dist/client/assets/{addon-webgl-fhhvEA9h.js → addon-webgl-BhRZFDcn.js} +1 -1
- package/dist/client/assets/{agent-essentials-DyJiUGpZ.js → agent-essentials-SrzMYEXV.js} +1 -1
- package/dist/client/assets/agent-identity-BxCsXnDp.js +1 -0
- package/dist/client/assets/{agent-lane-card-model-BCIwPjEh.js → agent-lane-card-model-DSWdGu-v.js} +1 -1
- package/dist/client/assets/agent-lane-detail-BNNm6FNu.js +2 -0
- package/dist/client/assets/{agent-lane-preview-BtnfNyFR.js → agent-lane-preview-C33Dwpn7.js} +1 -1
- package/dist/client/assets/{agent-lanes-model-Bl6xfviL.js → agent-lanes-model-CPgQRenB.js} +2 -2
- package/dist/client/assets/{arc.es-DPJ0xRV6.js → arc.es-NlJw-19N.js} +1 -1
- package/dist/client/assets/{arrow-down-DsD-dYj-.js → arrow-down-D3-IbArq.js} +1 -1
- package/dist/client/assets/{arrow-left-WjQIN9J6.js → arrow-left-_vS7itsV.js} +1 -1
- package/dist/client/assets/{arrow-up-right-CtTDrZJr.js → arrow-up-right-CcrWONpD.js} +1 -1
- package/dist/client/assets/{bot-B_Uzf4_O.js → bot-BRINYlC6.js} +1 -1
- package/dist/client/assets/{check-BbgHJX8u.js → check-COxArFXG.js} +1 -1
- package/dist/client/assets/{chevron-down-BFai6ZfE.js → chevron-down-DRCbnzyY.js} +1 -1
- package/dist/client/assets/{chevron-right-CyUa1zXx.js → chevron-right-CNE6QAVr.js} +1 -1
- package/dist/client/assets/{chunk-HRAB3GC3-CvwpNg-G.js → chunk-HRAB3GC3-CAeEKaf5.js} +1 -1
- package/dist/client/assets/chunk-JTPDIGGW-s6WbxdjC.js +46 -0
- package/dist/client/assets/{chunk-T65CQEWV-DI4NKdNq.js → chunk-T65CQEWV-CiZ_ICHW.js} +1 -1
- package/dist/client/assets/chunk-YOZR3KYS-DLOc92uD.js +2 -0
- package/dist/client/assets/{clock-DviOalxA.js → clock-CyfvRmj6.js} +1 -1
- package/dist/client/assets/{code-xml-05TD3uOC.js → code-xml--LjSM4Mv.js} +1 -1
- package/dist/client/assets/content-7ZeCPAEt.js +1 -0
- package/dist/client/assets/content-BHUcUCH5.js +1 -0
- package/dist/client/assets/content-BUhvLPkv.js +1 -0
- package/dist/client/assets/content-BomQ5YWo.js +1 -0
- package/dist/client/assets/content-C39ELNgC.js +1 -0
- package/dist/client/assets/content-C4RYKHut.js +1 -0
- package/dist/client/assets/content-CCiZfG4H.js +1 -0
- package/dist/client/assets/content-CDpDtVI-.js +1 -0
- package/dist/client/assets/content-CO-9CeFd.js +1 -0
- package/dist/client/assets/content-CuOLxp1x.js +1 -0
- package/dist/client/assets/content-CvtLIjXS.js +1 -0
- package/dist/client/assets/content-CzwTUb9n.js +1 -0
- package/dist/client/assets/content-DQXbo2RO.js +1 -0
- package/dist/client/assets/content-DRTQ9QQb.js +1 -0
- package/dist/client/assets/content-LCELs6zg.js +1 -0
- package/dist/client/assets/content-Uqt8AG-s.css +1 -0
- package/dist/client/assets/content-qsDjA4Au.js +1 -0
- package/dist/client/assets/{conversation-icons-DohQL6GI.js → conversation-icons-c-hXv7hY.js} +1 -1
- package/dist/client/assets/conversation-model-CHwHZNw-.js +1 -0
- package/dist/client/assets/conversation-motion-features-T8vF9zED.js +1 -0
- package/dist/client/assets/{copy-CwCAivnc.js → copy-4LfKIdQJ.js} +1 -1
- package/dist/client/assets/{createLucideIcon-DlxlBfLC.js → createLucideIcon-ClCdc3F9.js} +1 -1
- package/dist/client/assets/discover-7Ks00w-M.js +2 -0
- package/dist/client/assets/embed-entry-n2ThmSSX.js +2 -0
- package/dist/client/assets/{external-link-CnjcXf32.js → external-link-CnaI1QFS.js} +1 -1
- package/dist/client/assets/{eye-So8tNNK6.js → eye-BFlhMzQL.js} +1 -1
- package/dist/client/assets/{file-text-i3xTDUjJ.js → file-text-DG-pufl1.js} +1 -1
- package/dist/client/assets/{gestures-CgvAMd6F.js → gestures-CxG3Dphs.js} +1 -1
- package/dist/client/assets/home-live-action-BkqGLVRY.js +1 -0
- package/dist/client/assets/home-moving-signal-aNJusIzL.js +1 -0
- package/dist/client/assets/home-now-card-BQK4EFHx.js +1 -0
- package/dist/client/assets/{home-now-card-nano-CkLHUQ4J.js → home-now-card-nano-CdtzqSIF.js} +1 -1
- package/dist/client/assets/hooks-Dst1TH7n.js +2 -0
- package/dist/client/assets/index-9as_JTUs.css +1 -0
- package/dist/client/assets/index-CU9dtwJk.js +1 -0
- package/dist/client/assets/{index-sUomXsrf.js → index-CzVeWScw.js} +2 -2
- package/dist/client/assets/index-Dewd56RX.js +1 -0
- package/dist/client/assets/index-_YQXKEhb.js +1 -0
- package/dist/client/assets/{inspector-panel-DhXd-YbT.js → inspector-panel-DgOM8nCo.js} +1 -1
- package/dist/client/assets/keyboard-nav-BJnFoFDP.js +1 -0
- package/dist/client/assets/{lane-observe-DrhKkQ3A.js → lane-observe-BA3g9aVd.js} +1 -1
- package/dist/client/assets/{lane-roster-store-NE15Oe6M.js → lane-roster-store-pR4ZaYQm.js} +1 -1
- package/dist/client/assets/left-BhzPp-_E.js +1 -0
- package/dist/client/assets/left-CN1MABD0.js +2 -0
- package/dist/client/assets/left-DDgbsio7.js +1 -0
- package/dist/client/assets/left-Dpf2R9uD.js +1 -0
- package/dist/client/assets/left-HwwbMVtl.js +2 -0
- package/dist/client/assets/left-YfH0daht.js +1 -0
- package/dist/client/assets/left-agents-CYUwAy2Z.js +1 -0
- package/dist/client/assets/left-default-vEGZALPv.js +1 -0
- package/dist/client/assets/left-lanes-bphF-vlX.js +1 -0
- package/dist/client/assets/left-mission-B54-c3hq.js +1 -0
- package/dist/client/assets/left-np5USKqG.js +1 -0
- package/dist/client/assets/left-plan-BNBuDoPQ.js +2 -0
- package/dist/client/assets/library-DbCVJG_O.js +1 -0
- package/dist/client/assets/{loader-circle-lWOOKezu.js → loader-circle-Byb9kSFx.js} +1 -1
- package/dist/client/assets/{local-agents-C7fDHLVC.js → local-agents-DBaUbP-_.js} +1 -1
- package/dist/client/assets/{mentions-CY_wPZc5.js → mentions-fbQJ2mBI.js} +1 -1
- package/dist/client/assets/{mesh-ops-Kn8pCtyJ.js → mesh-ops-Cnw3vwAu.js} +1 -1
- package/dist/client/assets/{mesh-view-store-D14ihwkF.js → mesh-view-store-Btlyc7rW.js} +1 -1
- package/dist/client/assets/{message-circle-C5UZ6fO7.js → message-circle-aGOfQWm2.js} +1 -1
- package/dist/client/assets/{message-markup-C8Nx04sP.js → message-markup-mGF07emJ.js} +1 -1
- package/dist/client/assets/{message-square-BD-4UUdc.js → message-square-CIXda-Y7.js} +1 -1
- package/dist/client/assets/mission-control-m3BTDQ9l.css +1 -0
- package/dist/client/assets/{mission-control-store-xQHVQdm8.js → mission-control-store-CcoNeQHG.js} +1 -1
- package/dist/client/assets/mission-wall-CocIM1cF.js +1 -0
- package/dist/client/assets/{observe-uJfIlIUV.js → observe-BNFzh-7B.js} +1 -1
- package/dist/client/assets/openAgent-Dbv5wfuL.js +1 -0
- package/dist/client/assets/{page-status-BymFEFai.js → page-status-DDvNdA8s.js} +1 -1
- package/dist/client/assets/{paperclip-DL9BXPp2.js → paperclip-DfpJkR4s.js} +1 -1
- package/dist/client/assets/{plus-C9lTjsgd.js → plus-CmFQp9Uj.js} +1 -1
- package/dist/client/assets/profile-s3KRbip1.js +1 -0
- package/dist/client/assets/{projects-inbox-DfVmGFFk.js → projects-inbox-Diddml6e.js} +1 -1
- package/dist/client/assets/{radio-DedMyP8J.js → radio-PauJIekM.js} +1 -1
- package/dist/client/assets/{refresh-cw-D8PFyhUa.js → refresh-cw-4oeFn1Jn.js} +1 -1
- package/dist/client/assets/resolve-panes-cp6eNewO.js +1 -0
- package/dist/client/assets/resolve-sidebar-context-Dbo-5PWx.js +1 -0
- package/dist/client/assets/right-09W2JJFg.js +1 -0
- package/dist/client/assets/right-B-MKhiJ6.js +1 -0
- package/dist/client/assets/right-B91Zl8lQ.js +1 -0
- package/dist/client/assets/{right-C1sIsSHR.js → right-BcFnuse9.js} +1 -1
- package/dist/client/assets/right-BdtMzn35.js +1 -0
- package/dist/client/assets/right-BqmKXLtf.js +1 -0
- package/dist/client/assets/right-BzeB-Dpt.js +1 -0
- package/dist/client/assets/right-CkGOs-sq.js +1 -0
- package/dist/client/assets/right-CzGiNBzB.js +1 -0
- package/dist/client/assets/right-Dc7uqv7l.js +1 -0
- package/dist/client/assets/{rocket-CriBwkHM.js → rocket-C-AskjZH.js} +1 -1
- package/dist/client/assets/router-B-K15T7B.js +1 -0
- package/dist/client/assets/{runtime-picker-DOZpZOlt.js → runtime-picker-BCQD7d4K.js} +1 -1
- package/dist/client/assets/{scope-views-BF_RvGKU.js → scope-views-BhkbIFPY.js} +1 -1
- package/dist/client/assets/{scout-voice-BZ4KqADJ.js → scout-voice-S5_YZ2v8.js} +1 -1
- package/dist/client/assets/{scroll-text-BIYf6g6N.js → scroll-text-BV-BB7v-.js} +1 -1
- package/dist/client/assets/{search-DCT_EvPr.js → search-C3bSJluv.js} +1 -1
- package/dist/client/assets/{secondaryNavConfig-Drb7wPG4.js → secondaryNavConfig-Bg4Tc0gT.js} +1 -1
- package/dist/client/assets/{selection-bridge-CJOTyYQs.js → selection-bridge-B1dmkX3P.js} +1 -1
- package/dist/client/assets/{send-horizontal-DDwOgEs3.js → send-horizontal-CqogPmbY.js} +1 -1
- package/dist/client/assets/{server-CHZCp3cF.js → server-Brw5Y1Gh.js} +1 -1
- package/dist/client/assets/{session-catalog-XhGxCtP-.js → session-catalog-9FqXmjBw.js} +1 -1
- package/dist/client/assets/session-table-1xdSxSXq.js +1 -0
- package/dist/client/assets/{sliders-horizontal-B9Nj-Y4J.js → sliders-horizontal-CUiOH26y.js} +1 -1
- package/dist/client/assets/{sparkles-up7pVlX-.js → sparkles-BjCA3Evu.js} +1 -1
- package/dist/client/assets/{sse-CVoGDiKW.js → sse-QcU9bikk.js} +1 -1
- package/dist/client/assets/synthetic-agent-routing-aduMYO7P.js +1 -0
- package/dist/client/assets/system-surfaces-redesign-B7GQhfpw.css +1 -0
- package/dist/client/assets/{tail-display-BdyoLvzY.js → tail-display-BRcJltQa.js} +2 -2
- package/dist/client/assets/{tail-events-CTipUIli.js → tail-events-C6K7bCWB.js} +1 -1
- package/dist/client/assets/{terminal-DXQISjZn.js → terminal-DrTkVXIj.js} +1 -1
- package/dist/client/assets/{terminal-relay-B5Sma7fK.js → terminal-relay-BkXjjSkq.js} +1 -1
- package/dist/client/assets/{terminal-screen-19jAI0Cw.css → terminal-screen-BqVnCwl0.css} +1 -1
- package/dist/client/assets/terminal-sessions-C3qU8tnY.js +1 -0
- package/dist/client/assets/{terminal-takeover-X97KCSJk.js → terminal-takeover-KvmTwABa.js} +1 -1
- package/dist/client/assets/{use-conversation-list-B1T6J_qE.js → use-conversation-list-C5sF6WBR.js} +1 -1
- package/dist/client/assets/{use-fleet-active-asks-DLofGhhK.js → use-fleet-active-asks-BOMPW0nl.js} +1 -1
- package/dist/client/assets/{use-mesh-ops-items-ByGZk8rU.js → use-mesh-ops-items-Co05vcTV.js} +1 -1
- package/dist/client/assets/{use-reduced-motion-Cvk-HRKg.js → use-reduced-motion-Dla-G_Jz.js} +1 -1
- package/dist/client/assets/{use-scout-dev-flags-BHvg3G2c.js → use-scout-dev-flags-BOQF3fW2.js} +1 -1
- package/dist/client/assets/{useAgentHoverCard-D5e8Qg1z.js → useAgentHoverCard-FtCmY-b9.js} +1 -1
- package/dist/client/assets/useContentSecondaryNav-BX7Sq7vy.js +1 -0
- package/dist/client/assets/{usePierreRuntime-DIVunfX0.js → usePierreRuntime-Bo4lD7Ui.js} +1 -1
- package/dist/client/assets/{wrench-pEVd8JnN.js → wrench-CeCdjiPF.js} +1 -1
- package/dist/client/assets/{x-0XjXwGqq.js → x-D4X_y1j_.js} +1 -1
- package/dist/client/assets/{xterm-CRLlV1Xp.js → xterm-D2a5wrkJ.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/main.mjs +1404 -356
- package/dist/node/main.mjs +63 -15
- package/dist/openscout-terminal-relay.mjs +16 -4
- package/dist/pairing-runtime-controller.mjs +3028 -2946
- package/dist/runtime/broker-daemon.mjs +356 -134
- package/dist/scout-control-plane-web.mjs +5631 -5183
- package/dist/scout-web-server.mjs +5631 -5183
- package/package.json +1 -1
- package/dist/client/assets/ActivityScreen-DnqqRSlS.js +0 -1
- package/dist/client/assets/AgentConfigurationScreen-CJqoMA0J.js +0 -1
- package/dist/client/assets/AgentDefinitionsWorkspace-FpEkb-tu.js +0 -1
- package/dist/client/assets/AgentFloorView-CycUn0Lv.js +0 -1
- package/dist/client/assets/AgentInfoScreen-CAQAxpAK.js +0 -1
- package/dist/client/assets/AgentLaneDetailSheet-CWs9wKWk.js +0 -5
- package/dist/client/assets/AgentLanesEmbedScreen-BUCW4nUj.js +0 -1
- package/dist/client/assets/AgentsScreen-BMXvuiA2.js +0 -1
- package/dist/client/assets/AgentsSubnav-BTNjPYoA.js +0 -1
- package/dist/client/assets/BrokerScreen-CObCQvoy.js +0 -5
- package/dist/client/assets/CodeScreen-BXqi72NK.js +0 -1
- package/dist/client/assets/ConversationComposer-BBNPa5S9.js +0 -1
- package/dist/client/assets/ConversationFeedRows-BuejHMCY.js +0 -1
- package/dist/client/assets/ConversationHeader-DXMT-YXv.js +0 -1
- package/dist/client/assets/ConversationPanels-DHCtilQF.js +0 -2
- package/dist/client/assets/ConversationScreen-DSxIt9pq.css +0 -1
- package/dist/client/assets/ConversationScreen-Dz2d_Z_F.js +0 -1
- package/dist/client/assets/FlightObserveScreen-C-9S0nA5.js +0 -1
- package/dist/client/assets/FollowScreen--Q04xSSE.js +0 -1
- package/dist/client/assets/HarnessMark-Dm_qm1Ku.js +0 -1
- package/dist/client/assets/HarnessesScreen-Y54viPX8.js +0 -1
- package/dist/client/assets/KnowledgeSearchScreen-DsdDz8wY.js +0 -1
- package/dist/client/assets/LaneTraceDetailSheet-CBf_aNZx.js +0 -1
- package/dist/client/assets/MeshScreen-TgDtz-1l.js +0 -1
- package/dist/client/assets/MessagesScreen-BTQL0UcE.js +0 -1
- package/dist/client/assets/MissionControlView-D59SPnAm.js +0 -1
- package/dist/client/assets/MissionLogPane-Ye3YlF9s.js +0 -1
- package/dist/client/assets/NewChatComposer-B5FnPyzS.js +0 -19
- package/dist/client/assets/NewChatComposer-W-t-L4oV.css +0 -1
- package/dist/client/assets/OpenScoutAppShell-BIp0WitK.js +0 -87
- package/dist/client/assets/OpsAgentsView-CoBfAigH.js +0 -1
- package/dist/client/assets/OpsScreen-Bbo0W64T.js +0 -1
- package/dist/client/assets/OpsSubnav-CoN8utF8.js +0 -1
- package/dist/client/assets/ProjectAgentProfile-FiiIcB5R.js +0 -1
- package/dist/client/assets/ProjectsInbox-BWiXjGi7.js +0 -2
- package/dist/client/assets/ProjectsScreen-Cxk4CuYn.js +0 -1
- package/dist/client/assets/ProjectsThreadAside-BF66ugT5.js +0 -1
- package/dist/client/assets/Provider-tFc3jqZ4.js +0 -1
- package/dist/client/assets/RawSessionsTable-BsGVgZB3.js +0 -1
- package/dist/client/assets/RealtimeVoiceScreen-B0Bem5Rc.js +0 -1
- package/dist/client/assets/RepoDiffViewerLazy-C8UPk4oo.js +0 -2
- package/dist/client/assets/SessionRefScreen-D7TfPYPN.js +0 -1
- package/dist/client/assets/SessionsScreen-BlknOWAd.js +0 -1
- package/dist/client/assets/SettingsScreen-BIlYxv_a.js +0 -1
- package/dist/client/assets/Terminal-DwZyo8kA.js +0 -1
- package/dist/client/assets/TerminalEmbedScreen-Czp3tQyd.js +0 -1
- package/dist/client/assets/agent-chat-Bfjd9y6c.js +0 -1
- package/dist/client/assets/agent-identity-xQHedtLl.js +0 -1
- package/dist/client/assets/agent-lane-detail-Cw4QVAgH.js +0 -1
- package/dist/client/assets/chunk-YOZR3KYS-BW85tiCr.js +0 -47
- package/dist/client/assets/content-2u_eV3fX.js +0 -1
- package/dist/client/assets/content-5irOghrY.js +0 -1
- package/dist/client/assets/content-8Z_0CwtD.js +0 -1
- package/dist/client/assets/content-B38YRDBu.js +0 -1
- package/dist/client/assets/content-BE3uK0LB.js +0 -1
- package/dist/client/assets/content-BtIxSqVY.js +0 -1
- package/dist/client/assets/content-CFsPAihU.js +0 -1
- package/dist/client/assets/content-CHU0wwA3.css +0 -1
- package/dist/client/assets/content-CKj5g5tu.js +0 -1
- package/dist/client/assets/content-CLDWXf9Z.js +0 -1
- package/dist/client/assets/content-CRr73E0r.js +0 -1
- package/dist/client/assets/content-CVR75_Uj.js +0 -1
- package/dist/client/assets/content-Czdp7_JQ.js +0 -1
- package/dist/client/assets/content-D0_EJ6nP.js +0 -1
- package/dist/client/assets/content-DNmxpNhD.js +0 -1
- package/dist/client/assets/content-XpbI9uxd.js +0 -1
- package/dist/client/assets/content-cyxWdgKQ.js +0 -1
- package/dist/client/assets/conversation-model-C4yb6_FA.js +0 -1
- package/dist/client/assets/conversation-motion-features-CifSdJtm.js +0 -1
- package/dist/client/assets/discover-DoiAJo4Z.js +0 -2
- package/dist/client/assets/embed-entry-D1Or9S4d.js +0 -2
- package/dist/client/assets/home-live-action-B22u89j7.js +0 -1
- package/dist/client/assets/home-moving-signal-BdkERL6B.js +0 -1
- package/dist/client/assets/home-now-card-lLkv6nQs.js +0 -1
- package/dist/client/assets/hooks-BPLDD9yu.js +0 -2
- package/dist/client/assets/index-DGoLx89y.js +0 -1
- package/dist/client/assets/index-DITWsjFb.css +0 -1
- package/dist/client/assets/index-m6dFtY5f.js +0 -1
- package/dist/client/assets/index-pY8-Mz7y.js +0 -1
- package/dist/client/assets/keyboard-nav-BhZZ5HEq.js +0 -1
- package/dist/client/assets/left-B6eawimv.js +0 -1
- package/dist/client/assets/left-BL2uBHe0.js +0 -2
- package/dist/client/assets/left-BNJguPDG.js +0 -1
- package/dist/client/assets/left-BvCtvN0f.js +0 -1
- package/dist/client/assets/left-CfBb6bxM.js +0 -1
- package/dist/client/assets/left-DTrlBF0h.js +0 -2
- package/dist/client/assets/left-agents-DsOHgDCY.js +0 -1
- package/dist/client/assets/left-d4hlBBxY.js +0 -1
- package/dist/client/assets/left-default-BRCwoCJr.js +0 -1
- package/dist/client/assets/left-lanes-DNtoRzoV.js +0 -1
- package/dist/client/assets/left-mission-DsTu2X5Y.js +0 -1
- package/dist/client/assets/left-plan-CtySjsXC.js +0 -2
- package/dist/client/assets/library-CLpgWNJO.js +0 -1
- package/dist/client/assets/mission-control-D3ikEPND.css +0 -1
- package/dist/client/assets/openAgent-Bjt57GdM.js +0 -1
- package/dist/client/assets/profile-BqY5tesX.js +0 -1
- package/dist/client/assets/resolve-panes-1xeZMuaw.js +0 -1
- package/dist/client/assets/resolve-sidebar-context-PLr32WHN.js +0 -1
- package/dist/client/assets/right-1x7HzabC.js +0 -1
- package/dist/client/assets/right-CFzPUzlF.js +0 -1
- package/dist/client/assets/right-CRKyeJDk.js +0 -1
- package/dist/client/assets/right-CagzkLWg.js +0 -1
- package/dist/client/assets/right-CsV149pN.js +0 -1
- package/dist/client/assets/right-DITNyG2s.js +0 -1
- package/dist/client/assets/right-E3nNcLE3.js +0 -1
- package/dist/client/assets/right-eUQvSjd7.js +0 -1
- package/dist/client/assets/right-ozp4nM44.js +0 -1
- package/dist/client/assets/router-Dja9_ygK.js +0 -1
- package/dist/client/assets/session-table-sAVe44a4.js +0 -1
- package/dist/client/assets/system-surfaces-redesign-CD26LFc0.css +0 -1
- package/dist/client/assets/terminal-sessions-D5CIR2OL.js +0 -1
- package/dist/client/assets/useContentSecondaryNav-ZfBNi3d4.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{e as r}from"./index-CzVeWScw.js";var o=r();export{o as r};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{u as q,a as ie,s as Pe,S as Oe}from"./scope-views-BhkbIFPY.js";import{b as ll,i as cl,c as dl,d as pl}from"./scope-views-BhkbIFPY.js";import{ab as de,ac as Me,$ as $e,a0 as Fe,a1 as Be,a2 as We,a3 as pe,a4 as ze,a5 as Ge,a6 as He,ad as Ke,a7 as Ue,ae as Ve,P as qe,T as Ye,R as Ze,k as Je,u as Se}from"./router-B-K15T7B.js";import{af as ml,ag as fl,ah as hl,ai as gl,aj as _l,ak as Sl,al as bl,am as vl,an as xl,ao as wl,U as Ll,ap as Nl,aq as yl,ar as jl,Q as kl}from"./router-B-K15T7B.js";import{r as p,j as r,D as le,m as Qe}from"./index-CzVeWScw.js";import{k as El,w as Al,p as Il,E as Tl,t as Rl,G as Dl,A as Pl,q as Ol,z as Ml,l as $l,H as Fl,I as Bl}from"./index-CzVeWScw.js";import{u as be}from"./Provider-DSsb2gLR.js";import{S as Xe}from"./ScoutSurface-BEnDlynn.js";import{resolveContentPane as et}from"./resolve-panes-cp6eNewO.js";import{i as tt}from"./model-IGCUEsMy.js";import{t as st}from"./bash-format-BRV5C6Gv.js";import{t as ve}from"./time-Dhsh_2EG.js";import{i as ot,l as xe,j as nt,k as rt,m as at,e as it,g as lt,n as ct,r as dt,A as K,D as pt,h as ut}from"./agent-lanes-model-CPgQRenB.js";import{S as mt}from"./SlidePanel-B3gc5HnM.js";import{H as ft}from"./HarnessMark-BE-YSyci.js";import{o as ht,f as gt,b as _t}from"./lane-observe-BA3g9aVd.js";import{S as we}from"./SessionObserve-BmmJ8dEh.js";import{LaneTraceEventFocus as St}from"./LaneTraceEventFocus-X4-DDFEo.js";import{b as bt}from"./agent-lane-detail-BNNm6FNu.js";import{r as vt,u as xt}from"./AgentLanesView-DqRK5-d2.js";import{u as wt}from"./observe-BNFzh-7B.js";import{f as Lt}from"./terminal-sessions-C3qU8tnY.js";import{o as Nt,i as yt}from"./surface-activity-B1rgWB1i.js";import{AgentFloorView as jt}from"./AgentFloorView-DMivAYHU.js";import{i as kt,c as Ct,n as ue}from"./keyboard-nav-BJnFoFDP.js";import{a as Et}from"./api-h5zurxmi.js";import{RawSessionsTable as At}from"./RawSessionsTable-LWEvXJzj.js";import{SessionRefScreen as It}from"./SessionRefScreen-Dk-O4OVt.js";import{TailView as Tt}from"./TailView-DL3YZkzE.js";import{c as Rt,b as Dt,u as Pt,r as Ot}from"./hooks-Dst1TH7n.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./colors-BtO5_zlx.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./content-CDpDtVI-.js";import"./ActivityScreen-BXm6nJ6L.js";import"./clipboard-e3fSpeo7.js";import"./mentions-fbQJ2mBI.js";import"./AgentDetailCard-sZuHl1de.js";import"./AgentLiveActions-DI4ooSHW.js";import"./terminal-takeover-KvmTwABa.js";import"./openContent-C6XO6kr5.js";import"./eye-BFlhMzQL.js";import"./terminal-DrTkVXIj.js";import"./EmptyState-DypEjx0V.js";/* empty css */import"./left-BhzPp-_E.js";/* empty css */import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";import"./content-BHUcUCH5.js";import"./AgentInfoScreen-CPkLg1pK.js";/* empty css */import"./BackToPicker-DZg_4nHL.js";import"./ObservedTopologyPanel-C1AQM0Mq.js";import"./AgentsScreen-zR6b2bUL.js";/* empty css */import"./AgentsSubnav-q0xcZi6C.js";import"./SecondaryNav-Hv5AJ3Fv.js";import"./secondaryNavConfig-Bg4Tc0gT.js";import"./message-square-CIXda-Y7.js";import"./scroll-text-BV-BB7v-.js";import"./library-DbCVJG_O.js";/* empty css */import"./AgentSessions-BxWIPkWh.js";import"./agents-project-model-UYiamtrU.js";import"./profile-s3KRbip1.js";import"./context-budget-DX_fwUs3.js";import"./session-catalog-9FqXmjBw.js";import"./terminal-relay-BkXjjSkq.js";import"./ConversationScreen-C-PrCRz1.js";import"./ConversationComposer-CiEF7dhd.js";import"./message-markup-mGF07emJ.js";import"./message-visibility-kJM8XcSG.js";import"./sessionRead-CvFz2RHv.js";import"./types-B0PlfpKc.js";/* empty css */import"./ConversationHeader-BGgbITvr.js";import"./ConversationFeedRows-5it6QNBV.js";import"./ConversationPanels-vI9YuQJh.js";import"./use-reduced-motion-Dla-G_Jz.js";import"./activity-BxwKkT8z.js";import"./message-circle-aGOfQWm2.js";import"./tail-display-BRcJltQa.js";import"./lane-edit-display-C_Aujldz.js";import"./tail-events-C6K7bCWB.js";import"./ConversationStatus-COEj5loj.js";import"./AgentDefinitionsWorkspace-4Z0aN8AR.js";import"./project-overview-helpers-BQTc_Ous.js";import"./FileViewerPane-CXCq-oKj.js";/* empty css */import"./agent-essentials-SrzMYEXV.js";import"./lane-tool-detail-0WhMf4Vj.js";import"./LaneToolHoverCard-DrPXYZvQ.js";import"./lane-ask-display-B6iCAVcd.js";import"./ObserveTextFlow-DJxQc2H6.js";import"./SessionObserveEvidence-CEedIk2a.js";import"./wrench-CeCdjiPF.js";import"./external-link-CnaI1QFS.js";/* empty css *//* empty css */import"./right-B-MKhiJ6.js";import"./openAgent-Dbv5wfuL.js";import"./TmuxPeek-DNC4uWky.js";import"./refresh-cw-4oeFn1Jn.js";import"./ProjectsRail-B1zrQLZe.js";import"./AddProjectForm-CtEiLQnm.js";import"./projects-inbox-Diddml6e.js";import"./ProjectsScreen-PW_NH5VK.js";import"./ProjectsInbox-C3Jd6JTk.js";import"./api-BkjHJfgJ.js";import"./ui-LM8pS8qE.js";import"./cache-Dr0why2k.js";import"./arrow-up-right-CcrWONpD.js";/* empty css */import"./ProjectAgentProfile-zE1cApxw.js";import"./ProjectAgentProfileBar-MODhG0P6.js";import"./ProjectsThreadAside-DaCEUWN1.js";import"./content-CvtLIjXS.js";import"./BriefingDetailScreen-BZU4qMwE.js";/* empty css */import"./BriefingsScreen-Bfc3tqPp.js";import"./content-CuOLxp1x.js";import"./BrokerScreen-Chh8sGen.js";import"./status-tone-BM_zuRy1.js";import"./broker-display-pp33bLsu.js";import"./BrokerMetadataPanel-CaFe6kdh.js";import"./DispatchAftermath-OXYlMbT1.js";import"./follow-route-BvcGtBIL.js";import"./ShikiPane-B7O4if20.js";import"./arrow-down-D3-IbArq.js";import"./sparkles-BjCA3Evu.js";import"./paperclip-DfpJkR4s.js";import"./plus-CmFQp9Uj.js";import"./send-horizontal-CqogPmbY.js";import"./check-COxArFXG.js";import"./copy-4LfKIdQJ.js";import"./radio-PauJIekM.js";import"./bot-BRINYlC6.js";import"./left-CN1MABD0.js";import"./conversation-prefs-DNre-Lcx.js";import"./use-conversation-list-C5sF6WBR.js";import"./use-fleet-active-asks-BOMPW0nl.js";import"./RailRow-DerXOXQS.js";/* empty css */import"./content-CO-9CeFd.js";import"./MessagesScreen-BhOJ7_tj.js";import"./right-Dc7uqv7l.js";import"./CodeScreen-D0hpZNLP.js";import"./CodeDiffPane-C1ebFt-Y.js";import"./usePierreRuntime-Bo4lD7Ui.js";/* empty css */import"./CodeProjectPicker-tsCly-f3.js";/* empty css */import"./content-C39ELNgC.js";import"./FollowScreen-DRgYuAvp.js";import"./content-BUhvLPkv.js";import"./HarnessesScreen-L-emPcXd.js";import"./useContentSecondaryNav-BX7Sq7vy.js";import"./OpsSubnav-D5Bpowtk.js";/* empty css */import"./left-HwwbMVtl.js";import"./operator-attention-BwSPeheT.js";import"./content-qsDjA4Au.js";import"./HomeHero-CAEg8Yg5.js";import"./home-moving-signal-aNJusIzL.js";import"./home-live-action-BkqGLVRY.js";import"./right-BqmKXLtf.js";import"./left-YfH0daht.js";import"./mesh-view-store-Btlyc7rW.js";import"./mesh-buckets-CfAukILK.js";import"./FleetSearch-Dj7-CfNi.js";import"./content-DQXbo2RO.js";import"./MeshScreen-D5zzTn0o.js";import"./MeshCanvas-rtCBD7s6.js";import"./chunk-T65CQEWV-CiZ_ICHW.js";import"./useAgentHoverCard-FtCmY-b9.js";import"./local-agents-DBaUbP-_.js";/* empty css */import"./right-B91Zl8lQ.js";import"./left-DDgbsio7.js";import"./mesh-ops-Cnw3vwAu.js";import"./use-mesh-ops-items-Co05vcTV.js";import"./content-C4RYKHut.js";import"./use-scout-dev-flags-BOQF3fW2.js";import"./right-CkGOs-sq.js";import"./left-np5USKqG.js";import"./left-agents-CYUwAy2Z.js";import"./left-default-vEGZALPv.js";import"./left-lanes-bphF-vlX.js";import"./lane-roster-store-pR4ZaYQm.js";import"./left-mission-B54-c3hq.js";import"./mission-control-store-CcoNeQHG.js";import"./MissionLeftAgentRow-nc1Jyq3D.js";import"./page-status-DDvNdA8s.js";import"./left-plan-BNBuDoPQ.js";import"./content-BomQ5YWo.js";import"./OpsScreen-BeC0lieE.js";/* empty css */import"./MissionControlView-D2JO9u-y.js";/* empty css */import"./MissionContextRail-0O-Zu1Tn.js";import"./agent-lane-preview-C33Dwpn7.js";import"./mission-wall-CocIM1cF.js";import"./mission-control-model-C0fByIjm.js";import"./MissionFocusOverlay-LnjmqBiW.js";import"./MissionLogPane-lZ9vUftY.js";import"./OpsAgentsView-BnMX0vEY.js";/* empty css */import"./DataTable-BoofV-_4.js";/* empty css */import"./sliders-horizontal-CUiOH26y.js";import"./PlanView-DDXdC19M.js";/* empty css */import"./AtopView-VZkk40v0.js";/* empty css *//* empty css */import"./AgentLanesPreflight-DNGvZvjd.js";import"./AgentLaneChrome-O9Yf0uR-.js";import"./AgentLaneCard-nB68f2CI.js";/* empty css */import"./AgentLaneSummaryResize-Ct3b0TQR.js";import"./agent-lane-card-model-DSWdGu-v.js";import"./AgentLaneDetailSheet-BfhpaEQ3.js";import"./LaneTraceDetailSheet-Dl7foF88.js";import"./content-LCELs6zg.js";import"./RepoDiffPageScreen-CGEMAv2Z.js";import"./RepoDiffViewerLazy-DIxkiMto.js";import"./ReposScreen-BN1lVjOj.js";/* empty css */import"./selection-bridge-B1dmkX3P.js";import"./right-BcFnuse9.js";import"./content-7ZeCPAEt.js";import"./KnowledgeSearchScreen-DvdOFh-b.js";/* empty css */import"./clock-CyfvRmj6.js";import"./KnowledgeSearchInspector-C2EZsQ5i.js";import"./content-CzwTUb9n.js";import"./SessionsScreen-BJEjuo2X.js";import"./FlightObserveScreen-Yq5NtQQJ.js";/* empty css */import"./right-BzeB-Dpt.js";import"./content-DRTQ9QQb.js";import"./SettingsScreen-DJ-BhBwR.js";import"./StatusPill-B33sQinT.js";import"./AgentConfigurationScreen-CfBXxrsD.js";import"./server-Brw5Y1Gh.js";import"./SettingsDrawer-DL-SVLdd.js";import"./VoicePermissionsPanel-WLN0V-Xv.js";import"./left-Dpf2R9uD.js";import"./chunk-YOZR3KYS-DLOc92uD.js";import"./session-table-1xdSxSXq.js";import"./Terminal-Dp1FSGIS.js";/* empty css */import"./HerdrSession-DKFCJMst.js";import"./chunk-JTPDIGGW-s6WbxdjC.js";import"./right-09W2JJFg.js";import"./content-CCiZfG4H.js";import"./WorkDetailScreen-D2Yl0mYZ.js";import"./WorkFilesViewer-BbVfcUN-.js";import"./right-BdtMzn35.js";import"./RealtimeVoiceScreen-XtxbCjOs.js";import"./ScoutbotRealtimeVoiceCall-CDyFJX8m.js";function Mt(e){return e?`${e[0]?.toUpperCase()}${e.slice(1)}`:"local"}function $t(e){const t=st(e.trim()),s=t.replace(/\/+$/u,"").split(/[\\/]/u).filter(Boolean);return s.length===0?t:s.slice(-2).join("/")}function Ft(e){const t=e?.trim();return t?t.replace(/\.jsonl$/u,"").slice(0,8):"—"}function F(e,t=Date.now()){const{agent:s,source:o,observe:n,lastActiveAt:l}=e,c=s.harness?.trim()||o,d=ot(n),i=$t(s.cwd||s.project||s.projectRoot||"—"),a=d?`${c} · live`:`${c} · ${ve(l??t)}`;return{source:Mt(c),sessionRef:Ft(s.harnessSessionId),path:i,statusLine:a,live:d}}const Bt={think:"Thought",tool:"Tool",ask:"Request",message:"Message",note:"Note",system:"System",boot:"Boot"};function Wt({lane:e,event:t,nowMs:s=Date.now()}){const{agent:o,observe:n,source:l,lastActiveAt:c}=e,d=p.useMemo(()=>bt(e),[e]),i=F(e,s),a=t??n?.events?.at(-1),f=a?Bt[a.kind]??a.kind:null,g=n?.metadata?.session?.sessionStart,_=a?ht(a,g):null,h=_!=null?gt(_,c):void 0,m=_!=null?_t(_):void 0,u=a?.kind==="tool"||a?.kind==="ask"?a:void 0;return r.jsxs("div",{className:"scope-lane-detail",children:[r.jsxs("header",{className:"scope-lane-detail__head",children:[r.jsxs("div",{className:"scope-lane-detail__copy",children:[r.jsx("span",{className:"scope-lane-detail__kicker",children:"Lane trace"}),r.jsxs("h2",{className:"scope-lane-detail__title",children:[i.source,r.jsxs("span",{className:"scope-lane-detail__ref",children:[" · ",i.sessionRef]})]}),r.jsxs("div",{className:"scope-lane-detail__sub",children:[i.path,f?` · ${f}`:"",c?` · ${ve(c)}`:""]})]}),r.jsx(ft,{harness:o.harness??d.harness,size:18,className:"scope-lane-detail__hmark"})]}),r.jsxs("dl",{className:"scope-lane-detail__meta","aria-label":"Session stats",children:[r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"events"}),r.jsx("dd",{children:d.events})]}),r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"tools"}),r.jsx("dd",{children:d.tools})]}),r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"files"}),r.jsx("dd",{children:d.files})]}),r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"model"}),r.jsx("dd",{children:d.model??"—"})]}),r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"branch"}),r.jsx("dd",{children:d.branch??"—"})]}),r.jsxs("div",{className:"scope-lane-detail__stat",children:[r.jsx("dt",{children:"status"}),r.jsx("dd",{children:i.statusLine})]})]}),r.jsx("div",{className:"scope-lane-detail__trace",children:r.jsx(we,{data:n??void 0,agentId:l==="scout"?o.id:void 0,sessionId:o.harnessSessionId??d.sessionId,showRail:!1,variant:"default",surface:"scope",initialCursorT:a?.t,focusEventId:a?.id,inlineFocusEventId:u?.id,inlineFocusContent:u?r.jsx(St,{event:u,wallLabel:h,wallTitle:m,variant:"inline"}):void 0})})]})}function Le({target:e,onClose:t}){const{lane:s,event:o}=e,n=F(s);return r.jsxs(mt,{open:!0,onClose:t,side:"right",owner:"scope.lane-trace",layer:"elevated",resizable:!0,defaultSize:980,minSize:560,maxSize:1280,scrollLock:!0,ariaLabel:`${n.source} ${n.sessionRef} trace`,className:"scope-lane-trace-sheet","data-scope-presentation":!0,children:[r.jsx("div",{className:"scope-lane-trace-sheet__toolbar",children:r.jsx("button",{type:"button",className:"scope-lane-trace-sheet__close",onClick:t,"aria-label":"Close",children:"×"})}),r.jsx(Wt,{lane:s,event:o})]})}function zt(e,t){const[s,o]=p.useState(()=>de(e));p.useEffect(()=>{o(de(e))},[e]);const n=p.useCallback(u=>{Me(u),o(u)},[]),l=p.useMemo(()=>vt({autoLanes:t,deck:s,defaultWidthTier:e}),[t,s,e]),c=p.useCallback((u,S="pinned_left")=>{n($e(s,{laneId:u.id,title:xe(u.agent,u.source),zone:S,width:s.laneWidths[u.id]}))},[s,n]),d=p.useCallback(u=>{n(Fe(s,u))},[s,n]),i=p.useCallback((u,S)=>{n(Be(s,u,S))},[s,n]),a=p.useCallback(u=>{n(We(s,u))},[s,n]),f=p.useCallback((u,S)=>{n(pe(s,{kind:"harness",title:S??`${u} sessions`,harness:u,zone:"pinned_left",width:s.defaultLaneWidth}))},[s,n]),g=p.useCallback(()=>{n(pe(s,{kind:"attention",title:"Needs attention",zone:"pinned_left",width:"sm"}))},[s,n]),_=p.useCallback(()=>{n(ze(s))},[s,n]),h=p.useCallback(u=>Ge(s,u),[s]),m=p.useCallback(u=>He(s,u),[s]);return{deck:s,layout:l,pinLane:c,unpinLane:d,setLaneWidth:i,setDefaultLaneWidth:a,addHarnessLane:f,addAttentionLane:g,clearPins:_,isPinned:h,pinnedZone:m}}const Ne=le("lanes-horizon");function Gt(){try{const e=sessionStorage.getItem(Ne);if(e&&K.some(t=>t.key===e))return e}catch{}return pt}function ye({scoutAgents:e,defaultWidthTier:t="md",harnessFilter:s,projectFilter:o,horizonOverride:n}){const[l,c]=p.useState(Date.now()),[d,i]=p.useState(Gt),a=n??d,[f,g]=p.useState([]),[_,h]=p.useState(()=>new Set),m=ut(a),u=nt(a),S=rt(a),{discovery:b,events:v,loadState:k}=xt({includeTranscriptReplay:!0,discoveryIntervalMs:5e3,recentLimit:m,pauseWhenHidden:!0});p.useEffect(()=>{const x=setInterval(()=>c(Date.now()),1e4);return()=>clearInterval(x)},[]),p.useEffect(()=>{let x=!1;const N=async()=>{if(yt())try{const ee=await Lt({includeDiscovered:!1});x||g(ee)}catch{x||g([])}};N();const I=setInterval(()=>{N()},1e4),X=Nt(()=>{N()});return()=>{x=!0,clearInterval(I),X()}},[]),p.useEffect(()=>{try{sessionStorage.setItem(Ne,d)}catch{}},[d]);const y=p.useRef(at()),T=p.useMemo(()=>e.filter(x=>it(x,l,a)),[e,l,a]),E=wt(T,{pauseWhenHidden:!0}),R=k.discovery==="loading"||k.recent==="loading";p.useEffect(()=>{if(_.size===0)return;const x=setTimeout(()=>h(new Set),900);return()=>clearTimeout(x)},[_]);const{lanes:L,issues:A,freshLaneIds:D}=p.useMemo(()=>{const x=lt({transcripts:b?.transcripts??[],tailEvents:v,processes:b?.processes??[],scoutAgents:e,terminalSessions:f,observeCache:E,now:l,workingOnly:!0,horizon:a}),N=ct(x.lanes,y.current),I=[...dt(b),...x.issues];return{lanes:N.lanes,issues:I,freshLaneIds:N.newLaneIds}},[b,v,e,f,E,l,a]);p.useEffect(()=>{if(A.length!==0)for(const x of A)console.warn(`[agent-lanes] ${x.message}`,x)},[A]),p.useEffect(()=>{D.length!==0&&h(x=>{const N=new Set(x);for(const I of D)N.add(I);return N})},[D.join("\0")]);const O=p.useMemo(()=>L.filter(x=>Kt(x,{harnessFilter:s,projectFilter:o})),[L,s,o]),{deck:W,layout:Z,setLaneWidth:J,setDefaultLaneWidth:Q}=zt(t,O);return{profileId:Ke,now:l,horizon:a,setHorizon:i,horizonLabel:S,traceWindowMs:u,lanes:O,issues:A,newLaneIds:_,tailLoading:R,deck:W,layout:Z,setLaneWidth:J,setDefaultLaneWidth:Q,activeFilterLabel:Ut({harnessFilter:s,projectFilter:o})}}function me(e){const t=e?.trim().toLowerCase();return t||null}function se(e){return e.trim().toLowerCase().replace(/['"]/gu,"").replace(/[^a-z0-9]+/gu,"-").replace(/^-+|-+$/gu,"")}function Ht(e){return e.trim().replace(/\/+$/u,"").split(/[\\/]/u).filter(Boolean).pop()?.trim()||null}function fe(e,t){if(!t)return!0;const s=se(t);return e.some(o=>{const n=o?.trim();if(!n)return!1;const l=n.toLowerCase(),c=Ht(n);return l===t||se(n)===s||!!(c&&(c.toLowerCase()===t||se(c)===s))})}function Kt(e,t){const s=me(t.harnessFilter),o=me(t.projectFilter),{agent:n,facts:l,source:c}=e;return fe([n.harness,n.definitionId,l?.attribution,c],s)&&fe([n.project,n.projectRoot,n.cwd,l?.cwd],o)}function Ut(e){return[e.harnessFilter?.trim()?`harness ${e.harnessFilter.trim()}`:"",e.projectFilter?.trim()?`project ${e.projectFilter.trim()}`:""].filter(Boolean).join(" · ")}function Vt(e){return e?`${e[0]?.toUpperCase()}${e.slice(1)}`:"local"}function qt(e){const t=new Map;for(const s of e){const o=s.agent.harness?.trim()||s.source,n=t.get(o)??[];n.push(s),t.set(o,n)}return[...t.entries()].map(([s,o])=>{const n=[...o].sort((c,d)=>(d.lastActiveAt??0)-(c.lastActiveAt??0)),l=n.filter(c=>F(c).live).length;return{harness:s,label:Vt(s),lanes:n,liveCount:l}}).sort((s,o)=>o.lanes.length-s.lanes.length)}function Yt({lane:e,nowMs:t,onOpen:s}){const o=F(e,t),n=e.observe?.events?.length??0,l=c=>{(c.key==="Enter"||c.key===" ")&&(c.preventDefault(),s(e))};return r.jsxs("div",{className:`scope-dir__row${o.live?" is-live":""}`,role:"button",tabIndex:0,onClick:()=>s(e),onKeyDown:l,"aria-label":`${o.source} ${o.sessionRef}`,children:[r.jsx("span",{className:`scope-dir__dot${o.live?" is-live":""}`,"aria-hidden":!0}),r.jsx("span",{className:"scope-dir__ref",children:o.sessionRef}),r.jsx("span",{className:"scope-dir__path",title:e.agent.cwd??e.agent.project??void 0,children:o.path}),r.jsxs("span",{className:"scope-dir__events",children:[n,r.jsx("span",{className:"scope-dir__unit",children:"ev"})]}),r.jsx("span",{className:"scope-dir__status",children:o.statusLine})]})}function Zt({navigate:e,agents:t}){const s=q(),{now:o,horizonLabel:n,lanes:l,tailLoading:c}=ye({scoutAgents:t,defaultWidthTier:"md"}),d=p.useMemo(()=>qt(l),[l]),[i,a]=p.useState(null),f=p.useCallback(h=>{const m=h.observe?.events?.at(-1);m&&a({lane:h,event:m})},[]),g=l.length,_=d.reduce((h,m)=>h+m.liveCount,0);return r.jsxs("div",{className:"scope-dir","data-scope-presentation":!0,...s,children:[r.jsx("header",{className:"scope-dir__bar",children:r.jsxs("div",{className:"scope-dir__summary",children:[r.jsxs("span",{className:"scope-dir__count",children:[g," instance",g===1?"":"s"]}),_>0?r.jsxs("span",{className:"scope-dir__live",children:[_," live"]}):null,r.jsxs("span",{className:"scope-dir__window",children:["window ",n]})]})}),d.length===0?r.jsx("div",{className:"scope-dir__empty",children:c?"Discovering sessions…":"No sessions discovered for this workspace."}):r.jsx("div",{className:"scope-dir__body",children:d.map(h=>r.jsxs("section",{className:"scope-dir__group",children:[r.jsxs("header",{className:"scope-dir__group-head",children:[r.jsx("span",{className:"scope-dir__group-name",children:h.label}),r.jsx("span",{className:"scope-dir__group-kind",children:"runtime"}),r.jsxs("span",{className:"scope-dir__group-counts",children:[h.lanes.length," ",h.lanes.length===1?"instance":"instances",h.liveCount?` · ${h.liveCount} live`:""]})]}),r.jsx("div",{className:"scope-dir__list",role:"list",children:h.lanes.map(m=>r.jsx(Yt,{lane:m,nowMs:o,onOpen:f},m.id))})]},h.harness))}),i?r.jsx(Le,{target:i,onClose:()=>a(null)}):null]})}function Jt({laneId:e,grabbed:t,onKeyMove:s,onDragStart:o,onDragEnd:n}){const l=i=>{if(!(!i.altKey||!s)){if(i.key==="ArrowLeft"||i.key==="ArrowUp"){i.preventDefault(),i.stopPropagation(),s("before");return}(i.key==="ArrowRight"||i.key==="ArrowDown")&&(i.preventDefault(),i.stopPropagation(),s("after"))}},c=i=>{i.stopPropagation();const a=i.dataTransfer;if(!a)return;a.setData("text/plain",e),a.effectAllowed="move";const f=i.currentTarget.closest("[data-lane-id]");f instanceof HTMLElement&&(a.setDragImage(f,Math.min(48,f.clientWidth/2),18),f.classList.add("is-dragging")),o?.(e)},d=i=>{i.currentTarget.closest("[data-lane-id]")?.classList.remove("is-dragging"),n?.()};return r.jsx("span",{className:"scope-lane__drag",role:"button",tabIndex:0,draggable:!0,"aria-grabbed":t?"true":"false","aria-keyshortcuts":"Alt+ArrowLeft Alt+ArrowRight Alt+ArrowUp Alt+ArrowDown","aria-label":"Drag to reorder lane. Drop in a gutter for a new column. Alt+arrow keys also move.",title:"Drag to reorder · drop in gutters for a new column",onClick:i=>i.stopPropagation(),onKeyDown:l,onDragStart:c,onDragEnd:d,children:"⠿"})}const Qt=["sm","md","lg"],Xt={sm:"¼",md:"½",lg:"full"},es={sm:"Quarter row",md:"Half row",lg:"Full row"};function je({value:e,defaultValue:t,onChange:s,compact:o=!1,label:n="Lane width",variant:l="tier"}){const c=typeof e=="string"?e:t,d=l==="grid";return r.jsx("div",{className:`scope-lane-width${o?" is-compact":""}${d?" is-grid":""}`,role:"group","aria-label":n,onClick:i=>i.stopPropagation(),onKeyDown:i=>i.stopPropagation(),children:Qt.map(i=>r.jsx("button",{type:"button",className:`scope-lane-width__btn${c===i?" is-on":""}`,"aria-pressed":c===i,title:d?es[i]:`${i.toUpperCase()} column width`,onClick:()=>s(i),children:d?Xt[i]:i},i))})}function ts({lane:e,layoutMode:t,compact:s,laneWidth:o,defaultLaneWidth:n,onLaneWidthChange:l,nowMs:c,traceWindowMs:d,traceWindowLabel:i,onOpenTrace:a,onTraceEventSelect:f,onDragStart:g,onDragEnd:_,onDragKeyMove:h,focusProps:m}){const{agent:u,observe:S,source:b}=e,v=F(e,c),k=!!(S&&S.events.length>0),y=m?.ref,T=m?{"data-cursor":m["data-cursor"],tabIndex:m.tabIndex,onFocus:m.onFocus}:void 0,E=()=>{const L=S?.events?.at(-1);a(e,L)},R=L=>{(L.key==="Enter"||L.key===" ")&&(L.preventDefault(),E())};return r.jsxs("article",{ref:y,"data-lane-id":e.id,className:["scope-lane",v.live?"is-live":"",m?.["data-cursor"]?"is-cursor":"",s?"is-stack-compact":"",t==="grid"?"is-grid":""].filter(Boolean).join(" "),...T,children:[r.jsxs("header",{className:`scope-lane__head${s?" is-compact":""}`,role:"button",tabIndex:0,onClick:L=>{L.target instanceof HTMLElement&&L.target.closest(".scope-lane__drag")||E()},onKeyDown:R,"aria-label":`${v.source} ${v.sessionRef}`,children:[r.jsx(Jt,{laneId:e.id,onKeyMove:h,onDragStart:g,onDragEnd:_}),r.jsx("span",{className:"scope-lane__live","aria-hidden":"true"}),r.jsxs("div",{className:"scope-lane__meta",children:[r.jsxs("span",{className:"scope-lane__source",children:[v.source,r.jsxs("span",{className:"scope-lane__ref",children:[" · ",v.sessionRef]})]}),r.jsx("span",{className:"scope-lane__path",title:u.cwd??u.project??void 0,children:v.path}),s?null:r.jsx("span",{className:"scope-lane__status",children:v.statusLine}),l&&(t==="grid"||!s)?r.jsx(je,{value:o,defaultValue:n,onChange:l,compact:!0,label:`${v.sessionRef} width`,variant:t==="grid"?"grid":"tier"}):null]})]}),r.jsx("section",{className:"scope-lane__trace","aria-label":`${xe(u,b)} trace · ${i}`,children:k?r.jsx(we,{data:S??void 0,agentId:b==="scout"?u.id:void 0,sessionId:u.harnessSessionId,showRail:!1,variant:"lane",surface:"scope",nowMs:c,traceWindowMs:d,traceWindowLabel:i,onLaneEventSelect:L=>f(e,L)}):r.jsx("div",{className:"scope-lane__empty",children:"waiting for events"})})]})}function ss({space:e,layoutMode:t,widthPx:s,gridSpan:o,children:n}){const l=t==="swim"?{"--scope-lane-width":`${s}px`}:t==="grid"&&o?{gridColumn:`span ${o}`}:void 0;return r.jsx("div",{className:`scope-lane-space${t==="grid"?" is-grid":""}`,style:l,"data-split":e.ids.length,"data-orient":e.orient,"data-grid-span":t==="grid"?o:void 0,children:r.jsx("div",{className:"scope-lane-space__lanes",children:n})})}const os=[{key:"swim",label:"swim"},{key:"grid",label:"grid"},{key:"floor",label:"floor"}];function ns({liveCount:e,horizon:t,horizonLabel:s,layoutMode:o,laneWidth:n,onHorizonChange:l,onLayoutChange:c,onLaneWidthChange:d}){const i=o==="floor";return r.jsxs("header",{className:"scope-lanes-bar",children:[r.jsxs("div",{className:"scope-lanes-bar__summary",children:[r.jsxs("span",{className:"scope-lanes-bar__count",children:[e," lane",e===1?"":"s"]}),r.jsx("span",{className:"scope-lanes-bar__window",children:i?"past 30m · lanes 4h":`window ${s}`})]}),r.jsxs("div",{className:"scope-lanes-bar__controls",children:[r.jsx("div",{className:"scope-lanes-bar__layouts",role:"group","aria-label":"Lane layout",children:os.map(a=>r.jsx("button",{type:"button",className:`scope-lanes-bar__layout${o===a.key?" is-on":""}`,"aria-pressed":o===a.key,onClick:()=>c(a.key),children:a.label},a.key))}),i?null:r.jsxs(r.Fragment,{children:[r.jsx(je,{value:n,defaultValue:n,onChange:d,label:"Default column width",variant:o==="grid"?"grid":"tier"}),r.jsx("div",{className:"scope-lanes-bar__horizons",role:"group","aria-label":"Activity window",children:K.map(a=>r.jsx("button",{type:"button",className:`scope-lanes-bar__horizon${t===a.key?" is-on":""}`,"aria-pressed":t===a.key,onClick:()=>l(a.key),children:a.label},a.key))})]})]})]})}const U=.22,ce=.46,$=14,V=12,oe={mode:null,before:!0,slotIndex:-1,stackBand:0,targetAgentId:null};function G(e,t){return[...t.querySelectorAll(".scope-lane-space")].indexOf(e)}function rs(e){return[...e.querySelectorAll("[data-lane-id]")].map(t=>t.getAttribute("data-lane-id")).filter(t=>!!t)}function z(e){return e?.querySelector("[data-lane-id]")??null}function ke(e,t){const s=e.filter(n=>{const l=n.getBoundingClientRect();return t>=l.top-$&&t<=l.bottom+$});if(!s.length)return[];const o=s[0].getBoundingClientRect().top;return e.filter(n=>Math.abs(n.getBoundingClientRect().top-o)<=$)}function C(e){return{before:!1,stackBand:0,targetAgentId:null,label:"",previewColumn:!1,col:null,...e}}function as(e,t,s){const o=[...e.querySelectorAll(".scope-lane-space")];if(!o.length)return null;const n=ke(o,s);if(!n.length)return null;const l=n[0].getBoundingClientRect().top,c=Math.max(...n.map(f=>f.getBoundingClientRect().bottom));if(s<l-$||s>c+$)return null;const d=n[0].getBoundingClientRect(),i=G(n[0],e),a=Math.max(V*3,d.width*U);if(t<=d.left+a)return C({mode:"reorder",before:!0,slotIndex:i,slot:n[0],col:z(n[0]),label:"new column",previewColumn:!0});for(let f=0;f<n.length;f+=1){const g=n[f],_=g.getBoundingClientRect(),h=G(g,e),m=n[f+1],u=Math.max(V*3,_.width*U);if(m){const S=m.getBoundingClientRect(),b=_.right-u*.4,v=S.left+u*.4;if(t>=b&&t<=v){const k=(_.right+S.left)/2;if(t<k)return C({mode:"reorder",before:!1,slotIndex:h,slot:g,col:z(g),label:"new column",previewColumn:!0});const y=G(m,e);return C({mode:"reorder",before:!0,slotIndex:y,slot:m,col:z(m),label:"new column",previewColumn:!0})}continue}if(t>=_.right-u)return C({mode:"reorder",before:!1,slotIndex:h,slot:g,col:z(g),label:"new column",previewColumn:!0})}return null}function is(e,t,s,o,n,l){const c=s.closest(".scope-lane-space");if(!c)return null;const d=s.getBoundingClientRect(),i=c.getBoundingClientRect(),a=G(c,o),f=rs(c),g=(t-d.top)/d.height,_=(e-d.left)/d.width,h=(e-i.left)/i.width;if(g<ce){if(h<U)return C({mode:"reorder",before:!0,slotIndex:a,slot:c,col:s,label:"new column",previewColumn:!0});if(h>1-U)return C({mode:"reorder",before:!1,slotIndex:a,slot:c,col:s,label:"new column",previewColumn:!0});const S=_<.5;return C({mode:"reorder",before:S,slotIndex:a,slot:c,col:s,label:"new column",previewColumn:!0})}const m=c.dataset.orient||"row";if(l<=1){const S=_<.5;return C({mode:"reorder",before:S,slotIndex:a,slot:c,col:s,label:"new column",previewColumn:!0})}if(m==="column"&&f.length>=l&&!f.includes(n)){const S=_<.5;return C({mode:"reorder",before:S,slotIndex:a,slot:c,col:s,label:"new column",previewColumn:!0})}const u=ls(c,t);return C({mode:"stack",stackBand:u.band,targetAgentId:s.getAttribute("data-lane-id"),slotIndex:a,slot:c,col:s,label:u.label,stackPreview:u.preview})}function H(e){const t=e.top+e.height*ce;return{top:t,left:e.left,width:e.width,height:Math.max(24,e.bottom-t)}}function he(e,t){return t<=1?e>=1:e>=t}function ls(e,t){const s=e.getBoundingClientRect(),o=[...e.querySelectorAll("[data-lane-id]")];if(!o.length)return{band:0,label:"stack",preview:H(s)};if(o.length===1){const d=o[0].getBoundingClientRect(),i=d.top+d.height*ce,a=d.top+d.height*.5,f=t<a?0:1,g=f===0?{top:i,left:s.left,width:s.width,height:Math.max(18,a-i)}:H(s);return{band:f,label:f===0?"stack above":"stack below",preview:g}}let n=o.length;for(let d=0;d<o.length;d+=1){const i=o[d].getBoundingClientRect();if(t<i.top+i.height/2){n=d;break}}let l;if(he(n,o.length))l=H(s);else if(n===0){const d=o[0].getBoundingClientRect();l={top:d.top,left:s.left,width:s.width,height:Math.max(18,d.height*.5)}}else{const d=o[n-1].getBoundingClientRect(),i=o[n].getBoundingClientRect();l={top:(d.bottom+i.top)/2-10,left:s.left,width:s.width,height:20}}const c=n===0?"stack top":he(n,o.length)?"stack bottom":"stack between";return{band:n,label:c,preview:l}}function cs(e,t,s,o,n){const l=document.elementFromPoint(e,t);if(l&&s.contains(l)){const c=l.closest("[data-lane-id]"),d=c?.getAttribute("data-lane-id");if(c&&d&&d!==o&&!c.classList.contains("is-dragging"))return is(e,t,c,s,o,n)}return as(s,e,t)}function ds(e){return e.querySelector(".scope-lane-space")?.getBoundingClientRect().width||360}function ps(e){return[e.mode,e.slotIndex,e.before,e.stackBand,e.targetAgentId,e.label,e.previewColumn,e.col?.getAttribute("data-lane-id")].join("|")}function us(e,t,s,o){const n=t.getBoundingClientRect(),l=s.slot.getBoundingClientRect();if(s.mode==="stack"){const g=s.stackPreview??H(l),_=s.label==="stack below"||s.label==="stack bottom";e.hidden=!1,e.className=`scope-lane-drop is-band${_?" is-bottom-stack":""}`,e.dataset.mode="stack",e.dataset.label=s.label||"",e.style.transform=`translate(${g.left-n.left+t.scrollLeft}px, ${g.top-n.top+t.scrollTop}px)`,e.style.width=`${g.width}px`,e.style.height=`${g.height}px`;return}if(s.previewColumn){const g=ds(t),_=[...t.querySelectorAll(".scope-lane-space")],h=ke(_,l.top+l.height/2),m=(h.length?h:[s.slot]).map(v=>v.getBoundingClientRect()),u=Math.max(...m.map(v=>v.height),l.height),S=Math.min(...m.map(v=>v.top)),b=Math.max(0,s.before?l.left-n.left+t.scrollLeft-g-V/2:l.right-n.left+t.scrollLeft+V/2);e.hidden=!1,e.className="scope-lane-drop is-column",e.dataset.mode="column",e.dataset.label=s.label||"",e.style.transform=`translate(${b}px, ${S-n.top+t.scrollTop}px)`,e.style.width=`${g}px`,e.style.height=`${u}px`;return}const c=s.slot.dataset.orient||"row";let d,i,a,f;c==="column"?(d=l.left-n.left+t.scrollLeft,i=(s.before?l.top:l.bottom)-n.top+t.scrollTop-2,a=l.width,f=3):(d=(s.before?l.left:l.right)-n.left+t.scrollLeft-2,i=l.top-n.top+t.scrollTop,a=3,f=l.height),e.hidden=!1,e.className="scope-lane-drop is-line",e.dataset.mode="reorder",e.dataset.label=s.label||"",e.style.transform=`translate(${d}px, ${i}px)`,e.style.width=`${a}px`,e.style.height=`${f}px`}function ne(e,t,s={}){!s.keepIndicator&&t&&(t.hidden=!0,t.className="scope-lane-drop",delete t.dataset.label,delete t.dataset.mode,t.style.transform="",t.style.width="",t.style.height=""),e&&(e.querySelectorAll(".scope-lane-space").forEach(o=>{delete o.dataset.dropZone}),e.querySelectorAll("[data-lane-id].is-drop-target").forEach(o=>{o.classList.remove("is-drop-target"),delete o.dataset.dropZone,delete o.dataset.dropLabel}))}function ms({stackMax:e,onReorder:t,onStack:s,indicatorRef:o}){const n=p.useRef(null),l=p.useRef(null),c=p.useRef(oe),d=p.useRef(""),i=p.useCallback(h=>{n.current?.closest(".scope-lanes")?.classList.toggle("is-dragging",h)},[]),a=p.useCallback(h=>{l.current=h,d.current="",c.current=oe,i(!0)},[i]),f=p.useCallback(()=>{l.current=null,d.current="",c.current=oe,ne(n.current,o.current),i(!1)},[o,i]),g=p.useCallback(h=>{const m=l.current;if(!m)return;h.preventDefault(),h.dataTransfer.dropEffect="move";const u=n.current,S=o.current;if(!u||!S)return;const b=cs(h.clientX,h.clientY,u,m,e);if(!b){d.current&&(d.current="",ne(u,S));return}const v=ps(b);if(v===d.current)return;const k=!!(d.current&&b.mode==="reorder");d.current=v,c.current={mode:b.mode,before:b.before,slotIndex:b.slotIndex,stackBand:b.stackBand??0,targetAgentId:b.targetAgentId??null},ne(u,S,{keepIndicator:k}),b.col&&(b.col.classList.add("is-drop-target"),b.col.dataset.dropZone=b.mode,b.label&&(b.col.dataset.dropLabel=b.label)),b.slot.dataset.dropZone=b.mode,us(S,u,b)},[o,e]),_=p.useCallback(h=>{h.preventDefault();const m=h.dataTransfer.getData("text/plain")||l.current,u=c.current;if(!m||u.slotIndex<0||!u.mode){f();return}u.mode==="stack"?s(m,u.slotIndex,u.stackBand):t(m,u.slotIndex,u.before),f()},[f,t,s]);return p.useEffect(()=>{const h=m=>{m.key!=="Escape"||!l.current||f()};return window.addEventListener("keydown",h),()=>window.removeEventListener("keydown",h)},[f]),{scrollRef:n,onDragStart:a,onDragEnd:f,scrollDragProps:{onDragEnter:h=>{l.current&&h.preventDefault()},onDragOver:g,onDrop:_}}}const re=le("lane-spaces"),fs=2,hs=6,B=4;function gs(e){const t=Number(e);return Number.isFinite(t)?Math.min(hs,Math.max(fs,Math.round(t))):B}function Y(e){if(Array.isArray(e))return{ids:e.filter(s=>typeof s=="string"),orient:"row"};if(e&&typeof e=="object"&&Array.isArray(e.ids)){const t=e;return{ids:t.ids.filter(o=>typeof o=="string"),orient:t.orient==="column"?"column":"row"}}return{ids:[],orient:"row"}}function _s(e,t,s=B){const o=new Set(t),n=new Set,l=[];for(const c of e){const d=Y(c),i=d.ids.filter(g=>o.has(g)&&!n.has(g));if(i.forEach(g=>n.add(g)),!i.length)continue;const a=i.length===1?"row":d.orient,f=a==="column"?s:4;l.push({ids:i.slice(0,f),orient:a})}for(const c of t)n.has(c)||(l.push({ids:[c],orient:"row"}),n.add(c));return l}function ge(e,t,s=B){return t.length?_s(t,e,s):e.map(o=>({ids:[o],orient:"row"}))}function Ce(e,t){return e.map(s=>{const o=Y(s),n=o.ids.filter(l=>l!==t);return n.length?{ids:n,orient:n.length===1?"row":o.orient}:null}).filter(s=>s!==null)}function Ss(e,t,s,o){const n=Ce(e,t),l=Math.min(o?s:s+1,n.length);return n.splice(l,0,{ids:[t],orient:"row"}),n}function bs(e,t,s,o,n=B){const l=Ce(e,t),d=[...Y(l[s]??{ids:[],orient:"row"}).ids],i=Math.min(Math.max(0,o),d.length);d.splice(i,0,t);const a=d.slice(0,n);return l[s]={ids:a,orient:a.length>1?"column":"row"},l}function vs(){try{const e=sessionStorage.getItem(re);if(!e)return[];const t=JSON.parse(e);return Array.isArray(t)?t.map(Y).filter(s=>s.ids.length>0):[]}catch{return[]}}function xs(e){try{if(!e.length){sessionStorage.removeItem(re);return}sessionStorage.setItem(re,JSON.stringify(e))}catch{}}function ws(e,t=B){const s=p.useMemo(()=>e.map(m=>m.lane.id),[e]),o=p.useMemo(()=>new Map(e.map(m=>[m.lane.id,m])),[e]),[n,l]=p.useState(()=>vs()),[c,d]=p.useState(()=>n.length>0),i=p.useMemo(()=>c?ge(s,n,t):ge(s,[],t),[s,c,t,n]);p.useEffect(()=>{c&&xs(i)},[c,i]);const a=p.useCallback(m=>{d(!0),l(m)},[]),f=p.useCallback((m,u,S)=>{a(Ss(i,m,u,S))},[a,i]),g=p.useCallback((m,u,S,b=t)=>{a(bs(i,m,u,S,b))},[a,i,t]),_=p.useMemo(()=>i.map(m=>({space:m,columns:m.ids.map(u=>o.get(u)).filter(u=>u!==void 0)})).filter(m=>m.columns.length>0),[o,i]),h=p.useMemo(()=>_.flatMap(m=>m.columns),[_]);return{spaces:i,resolvedSpaces:_,flatColumns:h,reorderLane:f,stackLane:g,stackMax:gs(t)}}function Ls({lanes:e,onOpenTrace:t,onHorizonChange:s}){const[o,n]=p.useState(-1),l=p.useRef(new Map);p.useEffect(()=>{if(o<0)return;if(o>=e.length){n(e.length-1);return}const i=e[o];if(!i)return;const a=l.current.get(i.id);a?.scrollIntoView({block:"nearest",inline:"nearest"}),a?.focus()},[o,e]);const c=p.useCallback((i,a)=>{a?l.current.set(i,a):l.current.delete(i)},[]);p.useEffect(()=>{const i=a=>{if(!document.querySelector(".scope-lanes")||kt(a.target)||Ct()||e.length===0)return;const f=Number(a.key)-1;if(!a.metaKey&&!a.ctrlKey&&!a.altKey&&f>=0&&f<K.length){a.preventDefault(),s(K[f].key);return}if(a.key==="ArrowRight"||a.key==="ArrowDown"||a.key==="j"){a.preventDefault(),n(g=>ue(g,e.length,1));return}if(a.key==="ArrowLeft"||a.key==="ArrowUp"||a.key==="k"){a.preventDefault(),n(g=>ue(g,e.length,-1));return}if(a.key==="Home"||a.key==="g"&&!a.shiftKey){a.preventDefault(),n(0);return}if(a.key==="End"||a.key==="G"){a.preventDefault(),n(e.length-1);return}if(a.key==="Enter"||a.key===" "){const g=o<0?0:o,_=e[g];if(!_)return;a.preventDefault(),n(g),t(_,_.observe?.events?.at(-1))}};return window.addEventListener("keydown",i),()=>window.removeEventListener("keydown",i)},[o,e,s,t]);const d=p.useCallback((i,a)=>({"data-cursor":o===i?!0:void 0,tabIndex:o===i?0:-1,ref:f=>c(a,f),onFocus:()=>n(i)}),[o,c]);return{focusedIndex:o,getLaneFocusProps:d}}const Ee=4;function Ae(e){switch(e){case"sm":return 1;case"md":return 2;case"lg":return Ee}}function Ns(e,t){if(e==="sm"||e==="md"||e==="lg")return e;if(typeof e=="number"&&Number.isFinite(e)){const{tier:s,px:o}=Ue(e);if(s)return s;let n=t,l=Number.POSITIVE_INFINITY;for(const[c,d]of Object.entries(Ve)){const i=Math.abs(d-o);i<l&&(l=i,n=c)}return n}return t}function ys(e,t){return Ae(Ns(e,t))}function js(e,t){return e.length?Math.max(...e.map(s=>ys(s,t))):Ae(t)}const ae=le("lanes-layout");function Ie(e){return e==="swim"||e==="grid"||e==="floor"}function ks(){try{const e=sessionStorage.getItem(ae);if(Ie(e))return e}catch{}return"swim"}function _e(){if(typeof window>"u")return null;const e=new URLSearchParams(window.location.search).get("layout")?.trim().toLowerCase();return Ie(e)?e:null}function Cs(){const[e,t]=p.useState(()=>_e()??ks()),s=p.useCallback(o=>{t(o);try{sessionStorage.setItem(ae,o)}catch{}typeof window>"u"||qe({searchPatch:{layout:o==="swim"?null:o},replace:!0})},[]);return p.useEffect(()=>{const o=_e();if(o&&o!==e){t(o);try{sessionStorage.setItem(ae,o)}catch{}}},[e]),{layoutMode:e,setLayoutMode:s}}function Es({message:e}){return r.jsx("li",{className:"scope-lanes__issue",children:r.jsx("span",{className:"scope-lanes__issue-msg",children:e})})}function As({navigate:e,agents:t}){const s=q(),{layoutMode:o,setLayoutMode:n}=Cs(),l=o==="floor",{now:c,horizon:d,setHorizon:i,horizonLabel:a,traceWindowMs:f,lanes:g,layout:_,deck:h,setLaneWidth:m,setDefaultLaneWidth:u,activeFilterLabel:S,issues:b,tailLoading:v}=ye({scoutAgents:t,defaultWidthTier:"md",horizonOverride:l?"4h":void 0}),{resolvedSpaces:k,flatColumns:y,reorderLane:T,stackLane:E,stackMax:R}=ws(_.flat),L=o==="grid",[A,D]=p.useState(null),O=p.useRef(null),{scrollRef:W,onDragStart:Z,onDragEnd:J,scrollDragProps:Q}=ms({stackMax:R,onReorder:T,onStack:E,indicatorRef:O}),x=p.useCallback(w=>{W.current=w},[W]),N=p.useCallback((w,M)=>{const P=M??w.observe?.events?.at(-1);P&&D({lane:w,event:P})},[]),I=p.useMemo(()=>{const w=new Map;return y.forEach((M,P)=>w.set(M.lane.id,P)),w},[y]),{getLaneFocusProps:X}=Ls({lanes:y.map(w=>w.lane),onOpenTrace:N,onHorizonChange:i}),ee=p.useMemo(()=>v?"Loading sessions…":S?`No lanes match ${S} in the last ${a}.`:`No sessions with recent work in the last ${a}.`,[S,a,v]);return r.jsxs("div",{className:`scope-lanes${o==="grid"?" is-grid":""}`,"data-scope-presentation":!0,"data-scope-view":"lanes","data-scope-layout":o,"data-grid-cols":L?Ee:void 0,style:{"--scope-lane-stack-max":String(R)},...s,children:[r.jsx(ns,{liveCount:l?g.length:y.length,horizon:d,horizonLabel:a,layoutMode:o,laneWidth:h.defaultLaneWidth,onHorizonChange:i,onLayoutChange:n,onLaneWidthChange:u}),b.length>0?r.jsx("div",{className:"scope-lanes__issues",role:"status","aria-live":"polite",children:r.jsx("ul",{className:"scope-lanes__issues-list",children:b.map(w=>r.jsx(Es,{message:w.message},w.id))})}):null,(l?g.length:y.length)===0?r.jsx("div",{className:"scope-lanes__empty",children:ee}):l?r.jsx(jt,{lanes:g,now:c,onOpenTrace:N}):r.jsx("div",{className:"scope-lanes__canvas",role:"listbox","aria-label":"Session lanes",children:r.jsxs("div",{ref:x,className:`scope-lanes__scroll${o==="grid"?" is-grid":""}`,...Q,children:[k.map((w,M)=>{const P=w.space.orient==="column"&&w.columns.length>1,Te=Math.max(...w.columns.map(j=>j.widthPx)),Re=L?js(w.columns.map(j=>h.laneWidths[j.lane.id]??h.defaultLaneWidth),h.defaultLaneWidth):void 0;return r.jsx(ss,{space:w.space,layoutMode:o,widthPx:Te,gridSpan:Re,children:w.columns.map(j=>{const De=I.get(j.lane.id)??0;return r.jsx(ts,{lane:j.lane,layoutMode:o,compact:P,laneWidth:h.laneWidths[j.lane.id]??h.defaultLaneWidth,defaultLaneWidth:h.defaultLaneWidth,onLaneWidthChange:te=>m(j.lane.id,te),nowMs:c,traceWindowMs:f,traceWindowLabel:a,onOpenTrace:N,onTraceEventSelect:N,onDragStart:Z,onDragEnd:J,onDragKeyMove:te=>{T(j.lane.id,M,te==="before")},focusProps:X(De,j.lane.id)},j.key)})},w.space.ids.join(":"))}),r.jsx("div",{ref:O,className:"scope-lane-drop","aria-hidden":"true",hidden:!0})]})}),A?r.jsx(Le,{target:A,onClose:()=>D(null)}):null]})}const Is=1e4;function Ts({route:e,navigate:t}){const s=q(),[o,n]=p.useState(null),[l,c]=p.useState(null),d=p.useCallback(async()=>{c(null);try{n(await Et("/api/tail/discover"))}catch(f){c(f instanceof Error?f.message:String(f))}},[]);p.useEffect(()=>{d();const f=setInterval(()=>{d()},Is);return()=>clearInterval(f)},[d]);const i=o?.transcripts?.length??0,a=o?.processes?.length??0;return e.sessionId?r.jsx("div",{className:"scope-sessions-route","data-scope-view":"sessions",...s,children:r.jsx(It,{sessionRef:e.sessionId,navigate:t})}):r.jsx("div",{className:"scope-sessions-route","data-scope-view":"sessions",...s,children:r.jsxs("div",{className:"scope-sessions",children:[r.jsx("header",{className:"scope-sessions__bar",children:r.jsxs("div",{className:"scope-sessions__summary",children:[r.jsxs("span",{className:"scope-sessions__count",children:[i," session",i===1?"":"s"]}),a>0?r.jsxs("span",{className:"scope-sessions__live",children:[a," active"]}):null,l?r.jsx("span",{className:"scope-sessions__warn",children:"discovery error"}):null]})}),r.jsx("div",{className:"scope-sessions__body",children:r.jsx("div",{className:"scope-sessions__atop",children:r.jsx(At,{navigate:t})})})]})})}function Rs({navigate:e,tailQuery:t}){const s=q();return r.jsx("div",{className:"scope-tail-route","data-scope-view":"tail",...s,children:r.jsxs("div",{className:"scope-tail",children:[r.jsx("header",{className:"scope-tail__bar",children:r.jsxs("div",{className:"scope-tail__summary",children:[r.jsx("span",{className:"scope-tail__count",children:"tail"}),r.jsx("span",{className:"scope-tail__hint",children:"live event stream"}),t?r.jsxs("span",{className:"scope-tail__query",title:t,children:["q=",t]}):null]})}),r.jsx("div",{className:"scope-tail__body",children:r.jsx("div",{className:"scope-tail__stream",children:r.jsx(Tt,{navigate:e,initialFilter:t,variant:"tail",chrome:"embedded"})})})]})})}function Ds(e,t,s,o){if(!Ye(o))return null;const n=Ze(e);if(!n)return null;switch(n){case"lanes":return r.jsx(As,{navigate:t,agents:s});case"tail":return e.view!=="ops"||e.mode!=="tail"?null:r.jsx(Rs,{navigate:t,tailQuery:e.tailQuery});case"sessions":return e.view!=="sessions"?null:r.jsx(Ts,{route:e,navigate:t});case"agents":return e.view!=="agents-v2"||tt(e)?null:r.jsx(Zt,{navigate:t,agents:s});default:return null}}function Ps(){const{route:e,navigate:t,agents:s}=be(),{pathname:o}=Je(),n=Ds(e,t,s,o);return r.jsx(Xe,{children:n??et(e,t,s)})}function Os(){const{route:e,navigate:t}=be();return Ot({className:"scout-nav-tabs scout-nav-tabs--scope",brandTag:Qe,items:Oe,activeKey:Pe(e),navigate:t})}function Ms(){const e=ie(),t=Rt(),s=Os();return Se("nav.sidebar",!1)?null:e?s:t}function $s(){const e=ie(),t=Dt();return Se("nav.sidebar",!1)?null:e?p.createElement("div",{className:"scout-nav-actions"}):t}function Fs(){const e=ie(),t=Pt();return e?{active:!1,dismissible:!0}:t}function rl(e){e.slots.Content=Ps,e.hooks.useNavCenter=Ms,e.hooks.useNavActions=$s,e.hooks.useTakeover=Fs}export{Qe as SCOPE_BRAND_LABEL,ll as SCOPE_ENABLE_HINTS,El as SCOPE_FLAG_BUNDLE,Al as SCOPE_FLAG_BUNDLE_ALIASES,Il as SCOPE_FLAG_KEY,ml as SCOPE_FLAG_REGISTRY_KEY,fl as SCOPE_LANE_DECK_DEFAULTS,Ke as SCOPE_LANE_DECK_PROFILE,Tl as SCOPE_LEGACY_FLAG_BUNDLE,Rl as SCOPE_LEGACY_FLAG_KEY,Dl as SCOPE_LEGACY_PATH_PREFIX,Pl as SCOPE_LEGACY_PATH_SEGMENT,Ol as SCOPE_PATH_PREFIX,Ml as SCOPE_PATH_SEGMENT,$l as SCOPE_ROUTE_SEGMENTS,Fl as SCOPE_STORAGE_PREFIX,Oe as SCOPE_TOP_NAV_ITEMS,Ps as ScopeAppContent,Zt as ScopeDirView,ts as ScopeLaneColumn,Wt as ScopeLaneDetailView,Le as ScopeLaneTraceSheet,ns as ScopeLanesBar,As as ScopeLanesView,hl as buildScopePath,gl as buildScopeRoutePath,Bl as canonicalizeScopePathname,cl as isScopeOnboardingExempt,Ye as isScopePath,_l as isScopePresentation,Sl as parseScopeRouteFromUrl,bl as preserveLocationSearch,Ds as resolveScopeContentPane,vl as routeBelongsInScopeNamespace,Ze as routeToScopeSegment,xl as scopeInstrumentBundleLayer,wl as scopeLaneDeckProfileId,Ll as scopePresentationAttrs,dl as scopePresentationTitle,Nl as scopeRoutePath,le as scopeStorageKey,yl as scopeSurfaceFlagDefinition,Pe as scopeTopNavKeyForRoute,jl as scopeViewSegment,kl as segmentToRoute,ie as useScopePresentation,q as useScopePresentationAttrs,pl as useScopeShellChrome,rl as wireScopeOntoScout};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as p,j as e}from"./index-
|
|
1
|
+
import{r as p,j as e}from"./index-CzVeWScw.js";import{u as _}from"./Provider-DSsb2gLR.js";import{o as q}from"./openAgent-Dbv5wfuL.js";import{o as C}from"./openContent-C6XO6kr5.js";import{a as H,i as K,b as Q,c as X}from"./colors-BtO5_zlx.js";import{a as v}from"./api-h5zurxmi.js";import{c as G}from"./clipboard-e3fSpeo7.js";import{r as J,a as U}from"./operator-attention-BwSPeheT.js";import{u as D}from"./sse-QcU9bikk.js";import{t as j}from"./time-Dhsh_2EG.js";import{X as V}from"./x-D4X_y1j_.js";import{C as Y}from"./check-COxArFXG.js";import{C as Z}from"./copy-4LfKIdQJ.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./index-BWHgHrtv.js";const ee={blocked:"blocked",completed:"done",in_progress:"active",pending:"todo",unknown:"step"},te={mission:"Control",plan:"Plans",issues:"Alerts",tail:"Tail",atop:"Runtime",agents:"Agents",lanes:"Lanes"},se={blocked:"!",completed:"x",in_progress:">",pending:" ",unknown:"-"};function ne(t,s){return t&&typeof t=="object"&&!Array.isArray(t)?t[s]:void 0}function A(t,s){const a=ne(t,s);return typeof a=="string"&&a.trim()?a.trim():null}function W(t){return A(t.input,"task")??A(t.input,"action")}function T(t){return A(t.output,"summary")??A(t.output,"text")}function z(t){const s=t.replace(/\\/g,"/").replace(/\/+$/g,""),a=s.lastIndexOf("/");return a>=0?s.slice(a+1):s}function ae(t,s=180){const a=t.replace(/\s+/g," ").trim();return a.length<=s?a:`${a.slice(0,Math.max(0,s-1)).trimEnd()}...`}function $(t){return t.toLowerCase().replace(/[^a-z0-9_/-]+/g," ").split(/\s+/).map(s=>s.trim()).filter(s=>s.length>=4).filter(s=>!["plan","plans","todo","work","task","docs","markdown"].includes(s)).slice(0,8)}function I(t,s){const a=s.filter(Boolean).join(" ").toLowerCase();if(!a)return 0;const r=t.path.toLowerCase(),o=z(r).toLowerCase(),x=t.title.toLowerCase();let c=0;r&&a.includes(r)&&(c+=8),o&&a.includes(o)&&(c+=6),x.length>8&&a.includes(x)&&(c+=6);for(const d of t.tags)d.length>=3&&a.includes(d.toLowerCase())&&(c+=2);for(const d of $(t.title))a.includes(d)&&(c+=1);for(const d of t.steps.slice(0,8))for(const u of $(d.text).slice(0,3))a.includes(u)&&(c+=1);return c}function le(t,s){let a=I(t,[s.id,s.title,s.preview,s.agentName,s.harness,s.harnessSessionId,s.harnessLogPath,s.currentBranch,s.workspaceRoot,s.participantIds.join(" ")]);return t.agentId&&s.agentId===t.agentId&&(a+=4),t.agentName&&s.agentName&&t.agentName===s.agentName&&(a+=2),t.workspaceName&&s.workspaceRoot&&z(s.workspaceRoot).toLowerCase()===t.workspaceName.toLowerCase()&&(a+=3),a}function ce(t){const s=new Map;for(const a of t)if(a.status==="fulfilled")for(const r of a.value)s.set(r.id,r);return[...s.values()]}function ie(t,s){if(!t)return{asks:[],runs:[],sessions:[],workItems:[],attention:[]};const a=6,r=[...s.fleet?.activeAsks??[],...s.fleet?.recentCompleted??[]].filter(l=>I(t,[l.task,l.summary,l.agentName,l.collaborationRecordId])>=a).slice(0,8),o=s.runs.filter(l=>I(t,[W(l),T(l),l.agentName,l.workId,l.collaborationRecordId])>=a).slice(0,8),x=s.workItems.filter(l=>I(t,[l.title,l.summary,l.lastMeaningfulSummary,l.parentTitle,l.ownerName,l.nextMoveOwnerName])>=a).slice(0,8),c=(s.fleet?.needsAttention??[]).filter(l=>I(t,[l.title,l.summary,l.agentName])>=a).slice(0,6),d=new Set,u=new Set;for(const l of r)l.conversationId&&d.add(l.conversationId);for(const l of o){l.conversationId&&d.add(l.conversationId);for(const b of l.traceSessionIds??[])u.add(b)}for(const l of x)l.conversationId&&d.add(l.conversationId);for(const l of c)l.conversationId&&d.add(l.conversationId);const f=s.sessions.filter(l=>d.has(l.id)||(l.harnessSessionId?u.has(l.harnessSessionId):!1)||le(t,l)>=a).slice(0,8);return{asks:r,runs:o,sessions:f,workItems:x,attention:c}}function it({mode:t,agents:s,navigate:a,returnRoute:r}){const[o,x]=p.useState(null),[c,d]=p.useState(()=>typeof window>"u"?null:F(window.scoutOpsDetailSnapshot)),u=p.useCallback(async()=>{const i=await v("/api/fleet").catch(()=>null);x(i)},[]);if(p.useEffect(()=>{u()},[u]),p.useEffect(()=>{const i=N=>{d(F(N.detail))};return window.addEventListener("scout:ops-detail",i),()=>window.removeEventListener("scout:ops-detail",i)},[]),D(i=>{(i.kind==="message.posted"||i.kind==="flight.updated"||i.kind==="collaboration.event.appended")&&u()}),t==="plan")return e.jsx(pe,{navigate:a,returnRoute:r});if(t==="tail"||t==="issues")return e.jsx(re,{detail:c?.source==="tail"?c:null,mode:t,navigate:a});const f=(o?.activeAsks??[]).filter(i=>i.status!=="needs_attention"),l=o?.needsAttention??[];if(t==="lanes")return null;const b=s.filter(i=>H(i.state)),S=s.filter(i=>K(i.state)),y=[...s].sort((i,N)=>(N.updatedAt??0)-(i.updatedAt??0)).slice(0,7);return e.jsxs("div",{className:"ctx-panel ctx-panel--ops-inspector",children:[c&&e.jsxs("section",{className:"ctx-panel-section ctx-panel-selected-detail",children:[e.jsx("div",{className:"ctx-panel-section-label",children:c.focus==="flow"?"Message":"Selection"}),e.jsxs("div",{className:"ctx-panel-selected-card",children:[e.jsx("div",{className:"ctx-panel-selected-title",children:c.title}),e.jsx("div",{className:"ctx-panel-selected-meta",children:c.meta}),e.jsx("div",{className:"ctx-panel-selected-body",children:c.body}),c.action&&e.jsx("button",{type:"button",className:"ctx-panel-selected-action",onClick:()=>a(c.action.route),children:c.action.label})]})]}),e.jsxs("section",{className:"ctx-panel-section ctx-panel-ops-summary",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"Ops Context"}),e.jsxs("div",{className:"ctx-panel-ops-mode-card",children:[e.jsx("span",{children:"Current"}),e.jsx("strong",{children:te[t]}),e.jsx("small",{children:o?`${j(o.generatedAt)} refresh`:"loading"})]}),e.jsxs("div",{className:"ctx-panel-stat-grid",children:[e.jsx(k,{label:"Needs",value:l.length,tone:l.length>0?"warn":"ok"}),e.jsx(k,{label:"Active",value:f.length}),e.jsx(k,{label:"Online",value:`${S.length}/${s.length}`}),e.jsx(k,{label:"Working",value:b.length})]})]}),e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:["Queue",l.length>0&&e.jsx("span",{className:"ctx-panel-count",children:l.length})]}),l.length===0?e.jsx("div",{className:"ctx-panel-empty",children:"No operator cues"}):e.jsx("div",{className:"ctx-panel-list",children:l.slice(0,5).map(i=>e.jsx(ue,{item:i,navigate:a},i.recordId))})]}),e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:["Runs",f.length>0&&e.jsx("span",{className:"ctx-panel-count",children:f.length})]}),f.length===0?e.jsx("div",{className:"ctx-panel-empty",children:"No active requests"}):e.jsx("div",{className:"ctx-panel-list",children:f.slice(0,5).map(i=>e.jsx(he,{ask:i,navigate:a},i.invocationId))})]}),e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:["Recent activity",y.length>0&&e.jsx("span",{className:"ctx-panel-count",children:y.length})]}),e.jsx("div",{className:"ctx-panel-pulse-list",children:y.map(i=>e.jsxs("button",{type:"button",className:"ctx-panel-pulse-row",onClick:()=>q(a,i,{returnTo:r}),children:[e.jsx("span",{className:`ctx-panel-pulse-dot ctx-panel-pulse-dot--${Q(i.state)}`}),e.jsx("span",{children:i.name}),e.jsxs("small",{children:[X(i.state)," · ",i.updatedAt?j(i.updatedAt):"unknown"]})]},i.id))})]})]})}function oe(){if(typeof window>"u")return;const t=window;t.scoutOpsDetailSnapshot=null,window.dispatchEvent(new CustomEvent("scout:ops-detail",{detail:null}))}function re({detail:t,mode:s,navigate:a}){const r=s==="issues"?"Alert detail":"Tail detail",o=t?.copy?.find(c=>c.label==="Copy message")?.value??t?.body??"",x=t?.copy?.find(c=>c.label==="Copy metadata")?.value??t?.metadata?.map(c=>`${c.label}: ${c.value}`).join(`
|
|
2
2
|
`)??"";return e.jsx("div",{className:"ctx-panel ctx-panel--ops-inspector ctx-panel--tail-inspector",children:e.jsxs("section",{className:"ctx-panel-section ctx-panel-tail-detail",children:[e.jsxs("div",{className:"ctx-panel-section-label ctx-panel-tail-detail-label",children:[e.jsx("span",{children:r}),t&&e.jsx("button",{type:"button",className:"ctx-panel-tail-icon-button",onClick:oe,"aria-label":"Clear Tail detail",title:"Clear",children:e.jsx(V,{size:13,strokeWidth:2,"aria-hidden":"true"})})]}),t?e.jsxs("div",{className:"ctx-panel-tail-card",children:[e.jsxs("div",{className:"ctx-panel-tail-card-head",children:[e.jsx("div",{className:"ctx-panel-tail-card-title",children:t.title}),e.jsx("div",{className:"ctx-panel-tail-card-meta",children:t.meta})]}),t.metadata&&t.metadata.length>0&&e.jsxs("div",{className:"ctx-panel-tail-copy-scope",children:[e.jsx("dl",{className:"ctx-panel-tail-metadata",children:t.metadata.map(c=>e.jsxs("div",{className:"ctx-panel-tail-metadata-row",children:[e.jsx("dt",{children:c.label}),e.jsx("dd",{title:c.value,children:c.value})]},c.label))}),x&&e.jsx(B,{label:"Copy metadata",value:x})]}),t.action&&e.jsx("div",{className:"ctx-panel-tail-actions",children:e.jsx("button",{type:"button",className:"ctx-panel-tail-action-button",onClick:()=>a(t.action.route),children:t.action.label})}),e.jsxs("div",{className:"ctx-panel-tail-copy-scope ctx-panel-tail-copy-scope--message",children:[e.jsx("div",{className:"ctx-panel-tail-message",children:t.body}),o&&e.jsx(B,{label:"Copy message",value:o})]})]}):e.jsxs("div",{className:"ctx-panel-tail-empty-card",children:[e.jsx("span",{children:"Tail"}),e.jsx("strong",{children:"No log selected"})]})]})})}function B({label:t,value:s}){const[a,r]=p.useState(!1),o=p.useRef(null);p.useEffect(()=>()=>{o.current!=null&&window.clearTimeout(o.current)},[]);const x=p.useCallback(async()=>{await G(s)&&(r(!0),o.current!=null&&window.clearTimeout(o.current),o.current=window.setTimeout(()=>r(!1),1200))},[s]);return e.jsxs("button",{type:"button",className:`ctx-panel-tail-hover-copy${a?" ctx-panel-tail-hover-copy--copied":""}`,onClick:()=>{x()},title:t,children:[a?e.jsx(Y,{size:13,strokeWidth:2,"aria-hidden":"true"}):e.jsx(Z,{size:13,strokeWidth:1.9,"aria-hidden":"true"}),e.jsx("span",{children:a?"Copied":t})]})}function pe({navigate:t,returnRoute:s}){const[a,r]=p.useState(null),[o,x]=p.useState(null),[c,d]=p.useState([]),[u,f]=p.useState([]),[l,b]=p.useState([]),[S,y]=p.useState(!1),i=s.view==="ops"&&s.mode==="plan"?s.planDocumentId:void 0,N=p.useCallback(async()=>{const[n,g,O,P,E,M]=await Promise.allSettled([v("/api/plan-documents"),v("/api/fleet"),v("/api/work?limit=250"),v("/api/work?active=false&limit=250"),v("/api/runs?active=false&limit=500"),v("/api/conversations?limit=250")]);n.status==="fulfilled"&&r(n.value),g.status==="fulfilled"&&x(g.value),(O.status==="fulfilled"||P.status==="fulfilled")&&d(ce([O,P])),E.status==="fulfilled"&&f(E.value),M.status==="fulfilled"&&b(M.value),y(!0)},[]);p.useEffect(()=>{y(!1),N()},[N]),D(n=>{(n.kind==="message.posted"||n.kind==="flight.updated"||n.kind==="collaboration.event.appended")&&N()});const R=a?.documents??[],h=p.useMemo(()=>R.find(n=>n.id===i)??R[0]??null,[R,i]),m=p.useMemo(()=>ie(h,{fleet:o,runs:u,sessions:l,workItems:c}),[o,u,h,l,c]),L=m.attention.length+m.workItems.length+m.asks.length+m.runs.length+m.sessions.length;return h?e.jsxs("div",{className:"ctx-panel ctx-panel--ops-inspector ctx-panel--plan-inspector",children:[e.jsxs("section",{className:"ctx-panel-section ctx-panel-plan-summary",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"Plan Context"}),e.jsxs("div",{className:"ctx-panel-plan-card",children:[e.jsx("span",{children:"Current"}),e.jsx("strong",{children:h.title}),e.jsxs("small",{children:[h.path," · ",j(h.updatedAt)]}),h.summary&&e.jsx("p",{children:h.summary})]})]}),e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:["Steps",e.jsx("span",{className:"ctx-panel-count",children:h.steps.length})]}),h.steps.length===0?e.jsx("div",{className:"ctx-panel-empty",children:"No checklist steps parsed"}):e.jsx("div",{className:"ctx-panel-plan-step-list",children:h.steps.map(n=>e.jsxs("div",{className:`ctx-panel-plan-step ctx-panel-plan-step--${n.status}`,children:[e.jsx("span",{className:"ctx-panel-plan-step-marker",children:se[n.status]}),e.jsx("span",{className:"ctx-panel-plan-step-text",children:n.text}),e.jsx("span",{className:"ctx-panel-plan-step-state",children:ee[n.status]})]},n.id))})]}),e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:["Around This Plan",e.jsx("span",{className:"ctx-panel-count",children:L})]}),L===0?e.jsx("div",{className:"ctx-panel-empty",children:"No nearby activity matched yet"}):null]}),e.jsx(w,{title:"Sessions",count:m.sessions.length,children:m.sessions.map(n=>e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-plan-context-item",onClick:()=>C(t,{view:"conversation",conversationId:n.id},{returnTo:s}),children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:n.title||n.agentName||n.id}),e.jsxs("span",{className:"ctx-panel-sub",children:[n.kind," · ",n.agentName??n.harness??"session"," · ",n.messageCount," msg"]}),e.jsx("span",{className:"ctx-panel-preview",children:n.preview?.trim()||n.workspaceRoot||n.id})]})},n.id))}),e.jsx(w,{title:"Work Items",count:m.workItems.length,children:m.workItems.map(n=>e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-plan-context-item",onClick:()=>C(t,{view:"work",workId:n.id},{returnTo:s}),children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:n.title}),e.jsxs("span",{className:"ctx-panel-sub",children:[n.currentPhase||n.state," · ",j(n.lastMeaningfulAt||n.updatedAt)]}),(n.summary||n.lastMeaningfulSummary)&&e.jsx("span",{className:"ctx-panel-preview",children:n.summary??n.lastMeaningfulSummary})]})},n.id))}),e.jsx(w,{title:"Runs",count:m.runs.length,children:m.runs.map(n=>e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-plan-context-item",onClick:()=>t(me(n)),children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:ae(W(n)??n.agentName??n.id,120)}),e.jsxs("span",{className:"ctx-panel-sub",children:[n.agentName??n.agentId," · ",n.state," · ",j(n.updatedAt)]}),T(n)&&e.jsx("span",{className:"ctx-panel-preview",children:T(n)})]})},n.id))}),e.jsx(w,{title:"Requests",count:m.asks.length,children:m.asks.map(n=>e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-plan-context-item",onClick:()=>t(de(n)),children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:n.task}),e.jsxs("span",{className:"ctx-panel-sub",children:[n.agentName??n.agentId," · ",n.statusLabel," · ",j(n.updatedAt)]}),n.summary&&e.jsx("span",{className:"ctx-panel-preview",children:n.summary})]})},n.invocationId))}),e.jsx(w,{title:"Attention",count:m.attention.length,children:m.attention.map(n=>{const g=xe(n);return e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-item--attention ctx-panel-plan-context-item",onClick:()=>g&&t(g),disabled:!g,children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:n.title}),e.jsxs("span",{className:"ctx-panel-sub",children:[n.kind," · ",j(n.updatedAt)]}),n.summary&&e.jsx("span",{className:"ctx-panel-preview",children:n.summary})]})},n.recordId)})})]}):e.jsx("div",{className:"ctx-panel ctx-panel--ops-inspector ctx-panel--plan-inspector",children:e.jsxs("section",{className:"ctx-panel-section ctx-panel-ops-summary",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"Plan Context"}),e.jsx("div",{className:"ctx-panel-empty",children:S?"No plan document selected":"Indexing plan documents"})]})})}function w({title:t,count:s,children:a}){return e.jsxs("section",{className:"ctx-panel-section",children:[e.jsxs("div",{className:"ctx-panel-section-label",children:[t,e.jsx("span",{className:"ctx-panel-count",children:s})]}),s===0?e.jsx("div",{className:"ctx-panel-empty",children:"None matched"}):e.jsx("div",{className:"ctx-panel-list",children:a})]})}function de(t){return J(t)}function me(t){return t.conversationId?{view:"conversation",conversationId:t.conversationId}:t.workId?{view:"work",workId:t.workId}:{view:"agents-v2",agentId:t.agentId}}function xe(t){return U(t)}function k({label:t,value:s,tone:a}){return e.jsxs("div",{className:`ctx-panel-stat${a?` ctx-panel-stat--${a}`:""}`,children:[e.jsx("span",{children:t}),e.jsx("strong",{children:s})]})}function F(t){if(!t||typeof t!="object")return null;const s=t;if(s.focus!=="flow"&&s.focus!=="item"||typeof s.title!="string"||typeof s.meta!="string"||typeof s.body!="string")return null;const a=Array.isArray(s.metadata)?s.metadata.filter(o=>o!=null&&typeof o=="object"&&typeof o.label=="string"&&typeof o.value=="string"):void 0,r=Array.isArray(s.copy)?s.copy.filter(o=>o!=null&&typeof o=="object"&&typeof o.label=="string"&&typeof o.value=="string"):void 0;return{source:s.source==="tail"?"tail":"generic",focus:s.focus,title:s.title,meta:s.meta,body:s.body,metadata:a,copy:r,action:s.action&&typeof s.action=="object"?s.action:null}}function ue({item:t,navigate:s}){const{route:a}=_();return e.jsx("button",{type:"button",className:"ctx-panel-item ctx-panel-item--attention",onClick:()=>{t.conversationId?C(s,{view:"conversation",conversationId:t.conversationId},{returnTo:a}):s({view:"ops",mode:"mission"})},children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:t.title}),e.jsxs("span",{className:"ctx-panel-sub",children:[t.agentName??t.agentId??"operator"," · ",j(t.updatedAt)]})]})})}function he({ask:t,navigate:s}){const{route:a}=_();return e.jsx("button",{type:"button",className:"ctx-panel-item",onClick:()=>{t.conversationId?C(s,{view:"conversation",conversationId:t.conversationId},{returnTo:a}):s({view:"ops",mode:"mission"})},children:e.jsxs("div",{className:"ctx-panel-body",children:[e.jsx("span",{className:"ctx-panel-name",children:t.task}),e.jsxs("span",{className:"ctx-panel-sub",children:[t.agentName??t.agentId," · ",t.statusLabel]})]})})}export{it as OpsRight};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as l}from"./index-CzVeWScw.js";const d=["input","textarea","select","[contenteditable='']","[contenteditable='true']","[contenteditable='plaintext-only']","[role='combobox']","[role='searchbox']","[role='spinbutton']","[role='textbox']"].join(","),y=[".xterm",".xterm-helper-textarea","[data-scout-terminal-input='true']"].join(",");function m(t){const e=t;if(!e)return!1;const n=typeof e.tagName=="string"?e.tagName.toLowerCase():"";return n==="input"||n==="textarea"||n==="select"||e.isContentEditable===!0||typeof e.closest=="function"&&e.closest(d)?!0:typeof e.parentElement?.closest=="function"&&!!e.parentElement.closest(d)}function x(t){const e=t;return e?typeof e.closest=="function"&&e.closest(y)?!0:typeof e.parentElement?.closest=="function"&&!!e.parentElement.closest(y):!1}function k(t){return(t.metaKey||t.ctrlKey)&&t.shiftKey&&!t.altKey&&t.key.toLowerCase()==="b"}function h(){return!!(document.querySelector(".kb-help-backdrop")||document.querySelector("[data-command-palette-open='true']")||document.querySelector("[role='dialog'][aria-modal='true']"))}function g(t,e,n){return e<=0?-1:t<0?n>0?0:e-1:Math.max(0,Math.min(e-1,t+n))}const f=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])","[tabindex]:not([tabindex='-1'])"].join(", ");function w(t=!0){const e=l.useRef(null),n=l.useRef(null);l.useEffect(()=>{if(!t)return;n.current=document.activeElement;const o=e.current;return o?((o.querySelector(f)??o).focus(),()=>{n.current?.focus?.()}):void 0},[t]);const r=l.useCallback(o=>{if(!t||o.key!=="Tab")return;const s=e.current;if(!s)return;const c=Array.from(s.querySelectorAll(f));if(c.length===0){o.preventDefault(),s.focus();return}const u=c[0],a=c[c.length-1],i=document.activeElement;o.shiftKey?(i===u||!s.contains(i))&&(o.preventDefault(),a.focus()):i===a&&(o.preventDefault(),u.focus())},[t]);return{ref:e,onKeyDown:r}}function p(t){return Array.from(t.querySelectorAll([":scope > button:not([disabled])",":scope > [role='button']:not([aria-disabled='true'])",":scope > * > button[data-list-primary]:not([disabled])"].join(", ")))}function b(t,e){t.forEach((n,r)=>{n.tabIndex=r===e?0:-1}),t[e]?.focus()}function S(){return l.useCallback(t=>{const e=t.key==="ArrowDown"||t.key==="j",n=t.key==="ArrowUp"||t.key==="k",r=t.key==="Home"||t.key==="g"&&!t.shiftKey&&!t.metaKey&&!t.ctrlKey,o=t.key==="End"||t.key==="G";if(!e&&!n&&!r&&!o)return;const s=p(t.currentTarget);if(s.length===0)return;const c=document.activeElement,u=s.findIndex(i=>i===c);let a;e?a=u<0?0:Math.min(s.length-1,u+1):n?a=u<0?s.length-1:Math.max(0,u-1):r?a=0:a=s.length-1,t.preventDefault(),b(s,a)},[])}function T(t,e,n){return t||!e&&n?0:-1}function v(){l.useEffect(()=>{const t=e=>{if(e.key!=="["&&e.key!=="]"||m(e.target))return;const n=e.target,r=["left","center","right"],o=e.key==="]"?1:-1,s=r.findIndex(u=>{const a=document.querySelector(`[data-pane="${u}"]`);return a?a.contains(n):!1}),c=s<0?o>0?-1:r.length:s;for(let u=c+o;u>=0&&u<r.length;u+=o){const a=document.querySelector(`[data-pane="${r[u]}"]`);if(!a)continue;const i=a.querySelector(f);if(i){e.preventDefault(),i.focus();return}}};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[])}function L(t){l.useEffect(()=>{const e=n=>{if(n.key!=="/"||m(n.target))return;const r=t();r&&(n.preventDefault(),r.focus(),r.select())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[t])}function A(t){return e=>{if(e.key!=="ArrowDown")return;const n=t();if(!n)return;const r=p(n);if(r.length===0)return;const o=r.findIndex(c=>c.tabIndex===0),s=o>=0?o:0;e.preventDefault(),b(r,s)}}export{S as a,L as b,h as c,v as d,k as e,x as f,m as i,A as m,g as n,T as r,w as u};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as m,t as T,b as A}from"./time-Dhsh_2EG.js";import{o as p,a as v}from"./tail-display-
|
|
1
|
+
import{n as m,t as T,b as A}from"./time-Dhsh_2EG.js";import{o as p,a as v}from"./tail-display-BRcJltQa.js";const w=2*6e4,_=9e4;function y(e,n=Date.now()){const t=T(e,n);return t==="now"?"now":`${t} ago`}function H(e){return A(e)}function D(e){if(!Number.isFinite(e)||e<=0)return"0s";if(e<6e4)return`${Math.max(1,Math.round(e/1e3))}s`;if(e<36e5)return`${Math.max(1,Math.round(e/6e4))}m`;const n=Math.floor(e/36e5),t=Math.round(e%36e5/6e4);return t>0?`${n}h ${t}m`:`${n}h`}function R(e){if(!Number.isFinite(e)||e<w)return null;const n=Math.floor(e/1e3);if(n<3600)return`${Math.floor(n/60)}m gap`;const t=Math.floor(n/3600),s=Math.floor(n%3600/60);return s>0?`${t}h ${s}m gap`:`${t}h gap`}function C(e,n,t,s,o=0){const a=t-s,r=e.map(f=>u(f,n)).filter(f=>f!==null);if(r.length===0)return{eventCount:0,spanMs:0,oldestAt:null,newestAt:null,truncatedBefore:!1,hiddenBeforeCount:o};const i=Math.min(...r),c=Math.max(...r);return{eventCount:e.length,spanMs:Math.max(0,c-i),oldestAt:i,newestAt:c,truncatedBefore:i>a+_,hiddenBeforeCount:o}}function u(e,n){const t=m(e.at);if(t!==null)return t;if(!Number.isFinite(e.t)||e.t<0)return null;const s=m(n);return s===null?null:s+e.t*1e3}function E(e,n,t,s){const o=t-s;return e.filter(a=>{const r=u(a,n);return r===null?!1:r>=o})}function G(e,n,t,s){const o=t-s;return e.reduce((a,r)=>{const i=u(r,n);return i===null||i>=o?a:a+1},0)}const N=50;function q(e,n,t,s=N){const o=S(e,n,t);return!e||!o?o??null:o.events.length>=s||e.events.length<=o.events.length?o:{...e,events:e.events.slice(-s)}}function S(e,n,t){if(!e)return null;const s=e.metadata?.session?.sessionStart,o=E(e.events,s,n,t);if(o.length===e.events.length)return e;const a=n-t,r=e.files.filter(i=>typeof s!="number"||!Number.isFinite(s)||!Number.isFinite(i.lastT)||i.lastT<0?!0:s+i.lastT*1e3>=a);return{...e,events:o,files:r}}const g=180,b=3;function X(e,n=g,t=b){const s=e.replace(/\r\n/g,`
|
|
2
2
|
`).trim();if(!s)return"";const o=s.split(`
|
|
3
3
|
`),a=o.slice(0,t).join(`
|
|
4
4
|
`);if(a.length<=n&&o.length<=t)return a;const r=a.slice(0,n).trimEnd(),i=Math.max(r.lastIndexOf(" "),r.lastIndexOf(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as c}from"./index-
|
|
1
|
+
import{r as c}from"./index-CzVeWScw.js";let s=null;const o=new Set;function d(e,t){return e===t?!0:!e||!t?!1:e.live===t.live&&e.harness===t.harness&&e.actionGlyph===t.actionGlyph&&e.actionLabel===t.actionLabel&&e.actionMeta===t.actionMeta&&e.countsLabel===t.countsLabel&&e.strip.length===t.strip.length&&e.strip.every((n,r)=>n===t.strip[r])}function L(e,t){return e.id===t.id&&e.label===t.label&&e.statusLabel===t.statusLabel&&e.tone===t.tone&&e.agentId===t.agentId&&e.updatedAt===t.updatedAt&&d(e.floor,t.floor)}function p(e,t){return e===t?!0:e===null||t===null||e.length!==t.length?!1:e.every((n,r)=>L(n,t[r]))}function E(e){if(!p(s,e)){s=e;for(const t of o)t()}}function g(e){return o.add(e),()=>{o.delete(e)}}function i(){return s}function I(){return c.useSyncExternalStore(g,i,i)}let u=null;const l=new Set;function y(e){if(u!==e){u=e;for(const t of l)t()}}function h(e){return l.add(e),()=>{l.delete(e)}}function a(){return u}function F(){return c.useSyncExternalStore(h,a,a)}let f=null;function v(e){f=e}function R(){return f}export{y as a,F as b,R as g,E as p,v as s,I as u};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r,j as t}from"./index-CzVeWScw.js";/* empty css */import"./NewChatComposer-DXDxV2Mh.js";import{u as k,e as w}from"./Provider-DSsb2gLR.js";import{A as S}from"./AgentAvatar-CszU5eaU.js";import{a as g}from"./api-h5zurxmi.js";import{b as y}from"./router-B-K15T7B.js";import{u as M}from"./sse-QcU9bikk.js";import{o as A,i as j}from"./surface-activity-B1rgWB1i.js";import{d as N,c as b,e as I,f as C,g as B,h as P}from"./model-Co0zkMIc.js";import"./runtime-picker-BCQD7d4K.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./createLucideIcon-ClCdc3F9.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./colors-BtO5_zlx.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./keyboard-nav-BJnFoFDP.js";import"./x-D4X_y1j_.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./file-text-DG-pufl1.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./index-BWHgHrtv.js";import"./text-DsBWV_4k.js";function W(){const{agents:n,route:d}=k(),m=y(d),l=r.useMemo(()=>w(n,m),[n,m]),[u,h]=r.useState([]),[v,s]=r.useState(null),[a,p]=r.useState(null),c=r.useCallback(async()=>{const[e,i,o]=await Promise.allSettled([g("/api/conversations"),g("/api/fleet"),g("/api/tail/discover")]);e.status==="fulfilled"&&h(e.value),i.status==="fulfilled"&&s(i.value),o.status==="fulfilled"&&p(o.value)},[]);r.useEffect(()=>{c()},[c]),r.useEffect(()=>{const e=()=>{j()&&c()},i=window.setInterval(e,1e4),o=A(e);return()=>{window.clearInterval(i),o()}},[c]),M(()=>{j()&&c()});const x=r.useMemo(()=>{const e=new Map;for(const i of v?.activeAsks??[]){const o=e.get(i.agentId)??[];o.push(i),e.set(i.agentId,o)}return e},[v?.activeAsks]);return{projects:r.useMemo(()=>{const{sessionByAgentId:e}=N(u),i=l.map(f=>b(f,e.get(f.id)??null,x.get(f.id)??[])),o=I(a,Date.now());return C(i,u,o)},[l,u,x,a])}}function Nt(){const{route:n,navigate:d,openContextCapture:m}=k(),{projects:l}=W(),u=n.view==="agents-v2"?n.projectSlug:void 0,h=n.view==="agents-v2"?n.agentId:void 0,v=u??l[0]?.slice.slug;return t.jsxs("div",{className:"ctx-panel s-agents-rail",children:[t.jsx("div",{className:"s-agents-recent s-rail-projects",children:l.length===0?t.jsx("div",{className:"ctx-panel-empty",children:"No projects yet"}):l.map(s=>{const a=B(s),p=P(s),c=s.slice.slug===v&&!h;return t.jsxs("button",{type:"button",className:"s-rail-proj","data-selected":c||void 0,"data-live":a>0||void 0,"data-needs":p||void 0,title:s.slice.root??void 0,onClick:()=>d({view:"agents-v2",projectSlug:s.slice.slug}),children:[t.jsx(S,{name:s.slice.title,size:22,tile:!0,presence:!1}),t.jsxs("span",{className:"s-rail-proj-name","data-idle":a===0||void 0,children:[t.jsx("span",{"aria-hidden":!0,style:{opacity:.4},children:"/"}),s.slice.title]}),a>0?t.jsx("span",{className:"s-rail-proj-count","data-needs":p||void 0,title:p?"needs you":void 0,children:a}):null]},s.slice.key)})}),t.jsxs("div",{className:"s-agents-foot s-rail-foot-icons",children:[t.jsx("button",{type:"button",className:"s-rail-icon",title:"Search","aria-label":"Search",onClick:()=>d({view:"search"}),children:t.jsx(E,{})}),t.jsx("button",{type:"button",className:"s-rail-icon",title:"New chat (⌘⌥N)","aria-label":"New chat",onClick:()=>m(),children:t.jsx(L,{})}),t.jsx("button",{type:"button",className:"s-rail-icon s-rail-icon--end",title:"Settings","aria-label":"Settings",onClick:()=>d({view:"settings"}),children:t.jsx(D,{})})]})]})}function E(){return t.jsxs("svg",{width:"15",height:"15",viewBox:"0 0 16 16",fill:"none","aria-hidden":!0,children:[t.jsx("circle",{cx:"7",cy:"7",r:"4.25",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M10.5 10.5 14 14",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})]})}function L(){return t.jsx("svg",{width:"15",height:"15",viewBox:"0 0 16 16",fill:"none","aria-hidden":!0,children:t.jsx("path",{d:"M8 3v10M3 8h10",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})}function D(){return t.jsxs("svg",{width:"15",height:"15",viewBox:"0 0 16 16",fill:"none","aria-hidden":!0,children:[t.jsx("circle",{cx:"8",cy:"8",r:"2.25",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M8 1.5v1.6M8 12.9v1.6M14.5 8h-1.6M3.1 8H1.5M12.6 3.4l-1.1 1.1M4.5 11.5l-1.1 1.1M12.6 12.6l-1.1-1.1M4.5 4.5 3.4 3.4",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]})}export{Nt as AgentsLeft};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as h,j as i}from"./index-CzVeWScw.js";/* empty css */import{u as Ot,m as Gt,g as _t,i as Dt}from"./Provider-DSsb2gLR.js";import{a as Vt,b as Ft,m as Kt,r as qt}from"./keyboard-nav-BJnFoFDP.js";import{n as ct,g as wt}from"./colors-BtO5_zlx.js";import{j as Ht,a as N,k as jt,l as lt,i as Mt,n as Qt}from"./conversation-model-CHwHZNw-.js";import{l as Wt,i as $,a as M,p as yt,t as Yt,b as zt}from"./conversation-prefs-DNre-Lcx.js";import{i as Jt,l as Xt,s as Zt}from"./sessionRead-CvFz2RHv.js";import{u as te}from"./ContextMenu-N-Z6X0Z1.js";import{t as at}from"./time-Dhsh_2EG.js";import{u as ee}from"./use-conversation-list-C5sF6WBR.js";import{u as ne}from"./use-fleet-active-asks-BOMPW0nl.js";import{b as oe}from"./router-B-K15T7B.js";import{R as Nt}from"./RailRow-DerXOXQS.js";import"./api-h5zurxmi.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";function Y(t){const n=t.split("/").filter(Boolean);return n[n.length-1]??t}function $t(t){const n=t.replace(/\/+$/,"").split("/");return n[n.length-1]??t}function se(t,n){const o=Y(n).toLowerCase(),r=t.filter(p=>!!p.projectRoot),c=r.filter(p=>$t(p.projectRoot).toLowerCase()===o),d=c.length>0?c:r,s=ie(d);return s?{label:(c.length>0?d.find(p=>p.projectRoot===s):[...d].sort((p,w)=>w.lastActivityAt-p.lastActivityAt)[0])?.project??Y(n),canonicalRoot:s}:{label:Y(n),canonicalRoot:null}}function ie(t){const n=new Map;for(const d of t){const s=n.get(d.projectRoot)??{count:0,latest:0};s.count+=1,s.latest=Math.max(s.latest,d.lastActivityAt),n.set(d.projectRoot,s)}let o=null,r=-1,c=-1;for(const[d,s]of n)(s.count>r||s.count===r&&s.latest>c)&&(o=d,r=s.count,c=s.latest);return o}function Ct(t,n,o,r){const c=new Map;for(const s of t){const f=Ht(s),p=s.agentId?n.get(s.agentId):void 0,w=p?.repoKey??null,u=p?.project??null,C=(s.agentName??N(s)).trim(),m=f?`channel:${s.id}`:w?`repo:${w.toLowerCase()}`:u?`project:${u.toLowerCase()}`:C?`name:${C.toLowerCase()}`:`dm:${s.id}`,y=f?N(s):w?Y(w):u??C??N(s);let j=c.get(m);if(j||(j={key:m,label:y,isChannel:f,conversations:[],bestState:"blocked",latestUpdate:0,unreadCount:0,canonicalRoot:null},c.set(m,j)),j.conversations.push(s),j.latestUpdate=Math.max(j.latestUpdate,s.lastMessageAt??0),Jt(s.lastMessageAt,s.id,o)&&(j.unreadCount+=1),!f&&p){const g=ct(p.state);wt(g)<wt(j.bestState)&&(j.bestState=g)}}for(const s of c.values()){if(s.key.startsWith("repo:")){const f=s.conversations.map(w=>{const u=w.agentId?n.get(w.agentId):void 0;return{project:u?.project??null,projectRoot:u?.projectRoot??null,lastActivityAt:w.lastMessageAt??0}}),p=se(f,s.key.slice(5));s.label=p.label,s.canonicalRoot=p.canonicalRoot}s.conversations.sort((f,p)=>(p.lastMessageAt??0)-(f.lastMessageAt??0))}const d=Array.from(c.values());return d.sort((s,f)=>f.latestUpdate-s.latestUpdate),d}const ae=12;function cn(){const{route:t,navigate:n,agents:o,apiConnection:r}=Ot(),{sessions:c,loading:d,loadError:s,reload:f}=ee(),[p,w]=h.useState(()=>Xt()),[u,C]=h.useState(()=>Wt()),[m,y]=h.useState(""),[j,g]=h.useState(()=>new Set),[b,l]=h.useState(!1),[R,L]=h.useState(!1),[q,J]=h.useState(!1),k=ne(),H=oe(t),O=h.useMemo(()=>Gt(o,H),[o,H]),I=h.useMemo(()=>{const e=new Map,a=O?o.filter(v=>O.has(v.id)):o;for(const v of a)e.set(v.id,v);return e},[o,O]),T=t.view==="messages"||t.view==="conversation"||t.view==="agent-info"||t.view==="agents-v2"?t.conversationId:void 0;h.useEffect(()=>{L(!1)},[m]);const G=h.useMemo(()=>_t(c,O,H),[c,O,H]),X=h.useMemo(()=>m?G.filter(e=>kt(e,m)):G,[G,m]),_=h.useMemo(()=>{const e=a=>(a.agentId?k.get(a.agentId)?.updatedAt:void 0)??0;return G.filter(a=>$(a.id,u)||!jt(a)?!1:(a.agentId?k.get(a.agentId):void 0)?.status==="needs_attention").sort((a,v)=>e(v)-e(a))},[G,u,k]),D=h.useMemo(()=>m?_.filter(e=>kt(e,m)):_,[_,m]),x=h.useMemo(()=>{const e=X.filter(A=>!$(A.id,u)),a=W(X.filter(A=>$(A.id,u))),v=e.filter(A=>M(A.id,u)).sort((A,xt)=>yt(xt.id,u)-yt(A.id,u)||(xt.lastMessageAt??0)-(A.lastMessageAt??0)),K=e.filter(A=>!M(A.id,u)),it=K.filter(lt),bt=K.filter(jt),Et=K.filter(Mt);return{pinned:v,channels:W(it),agents:Ct(W(bt),I,p),observed:Ct(W(Et),I,p),archived:a}},[X,I,p,u]),dt=te(),V=h.useCallback(e=>{C(a=>Yt(e,a))},[]),F=h.useCallback(e=>{C(a=>zt(e,a))},[]),S=h.useCallback(e=>{w(Zt(e.id)),n({view:"messages",conversationId:e.id})},[n]),P=h.useCallback((e,a)=>{const v=M(a.id,u),K=$(a.id,u),it=N(a);dt(e,[{kind:"action",label:"Open",onSelect:()=>S(a)},{kind:"separator"},{kind:"action",label:v?"Unpin":"Pin to top",onSelect:()=>V(a.id)},{kind:"action",label:K?"Unarchive":"Archive",onSelect:()=>F(a.id)},{kind:"separator"},{kind:"action",label:"Copy name",onSelect:()=>{navigator.clipboard?.writeText(it).catch(()=>{})}}])},[u,S,V,F,dt]),ut=e=>{g(a=>{const v=new Set(a);return v.has(e)?v.delete(e):v.add(e),v})},Tt=r.status==="offline"||Dt(s),pt=h.useRef(null),mt=h.useRef(null),Pt=Vt(),Ut=Kt(()=>pt.current);Ft(h.useCallback(()=>mt.current,[]));const Z=x.pinned.length,tt=x.channels.length,et=x.agents.reduce((e,a)=>e+a.conversations.length,0),nt=x.observed.reduce((e,a)=>e+a.conversations.length,0),Q=x.archived.length,ht=Z+tt+et+nt+Q,Bt=b||!!m,ot=h.useMemo(()=>{const e=[];for(const a of D)e.push({rowId:`ny-${a.id}`,id:a.id});for(const a of x.pinned)e.push({rowId:`pin-${a.id}`,id:a.id});for(const a of x.agents)for(const v of a.conversations)e.push({rowId:v.id,id:v.id});for(const a of x.channels)e.push({rowId:a.id,id:a.id});for(const a of x.observed)for(const v of a.conversations)e.push({rowId:v.id,id:v.id});for(const a of x.archived)e.push({rowId:`arch-${a.id}`,id:a.id});return e},[D,x]),U=h.useMemo(()=>({activeId:T,activeRowId:T?ot.find(e=>e.id===T)?.rowId:void 0,firstRowId:ot[0]?.rowId}),[T,ot]),vt=R||m?x.observed:x.observed.slice(0,ae),ft=Math.max(0,x.observed.length-vt.length),gt=e=>!!(m||j.has(e.key)||T&&e.conversations.some(a=>a.id===T)),st=e=>i.jsx(rt,{pinned:M(e.id,u),archived:$(e.id,u),onTogglePin:()=>V(e.id),onToggleArchive:()=>F(e.id)});return i.jsxs("div",{className:"ctx-panel",children:[i.jsxs("div",{className:"ctx-panel-toolbar",children:[i.jsx("input",{ref:mt,type:"text",className:"ctx-panel-search-input",placeholder:"Filter… (/)",value:m,onChange:e=>y(e.target.value),onKeyDown:Ut}),_.length>0&&i.jsx("span",{className:"ctx-panel-rail-stat",title:"Asks waiting on your reply",children:ce(_.length)})]}),i.jsx("div",{ref:pt,className:["ctx-panel-list","ctx-panel-list--scroll",ht===0&&"ctx-panel-list--empty"].filter(Boolean).join(" "),onKeyDown:Pt,children:ht===0?i.jsx(re,{query:m,loading:d,error:s,apiOffline:Tt,onRetry:()=>{f(!0)}}):i.jsxs(i.Fragment,{children:[D.length>0&&i.jsx(B,{label:"Needs you",count:D.length,hint:"Asks waiting on your reply",children:D.map(e=>i.jsx(E,{rowId:`ny-${e.id}`,session:e,nav:U,agentById:I,asksByAgent:k,onSelect:S,onContextMenu:P},`ny-${e.id}`))}),Z>0&&i.jsx(B,{label:"Pinned",count:Z,hint:"Pinned conversations",children:x.pinned.map(e=>i.jsx(E,{rowId:`pin-${e.id}`,session:e,nav:U,agentById:I,asksByAgent:k,pinned:!0,actions:st(e),onSelect:S,onContextMenu:P},`pin-${e.id}`))}),et>0&&i.jsx(B,{label:"Agents",count:et,children:x.agents.map(e=>i.jsx(At,{group:e,isOpen:gt(e),nav:U,agentById:I,asksByAgent:k,prefs:u,onToggle:()=>ut(e.key),onSelect:S,onTogglePin:V,onToggleArchive:F,onContextMenu:P},e.key))}),tt>0&&i.jsx(B,{label:"Channels",count:tt,children:x.channels.map(e=>i.jsx(E,{rowId:e.id,session:e,nav:U,agentById:I,asksByAgent:k,actions:st(e),onSelect:S,onContextMenu:P},e.id))}),nt>0&&i.jsxs(B,{label:"Observed",count:nt,hint:"Agent conversations you’re not in",open:Bt,onToggle:()=>l(e=>!e),children:[vt.map(e=>i.jsx(At,{group:e,isOpen:gt(e),nav:U,agentById:I,asksByAgent:k,prefs:u,observed:!0,onToggle:()=>ut(e.key),onSelect:S,onTogglePin:V,onToggleArchive:F,onContextMenu:P},e.key)),ft>0?i.jsxs("button",{type:"button",className:"ctx-panel-more",onClick:()=>L(!0),children:["+ ",ft," more observed"]}):null]}),Q>0&&i.jsxs(B,{label:"Archived",count:Q,hint:"Hidden from the main rail",children:[i.jsx("button",{type:"button",className:"ctx-panel-more",onClick:()=>J(e=>!e),children:q?"▾ hide archived":`› show ${Q} archived`}),q?x.archived.map(e=>i.jsx(E,{rowId:`arch-${e.id}`,session:e,nav:U,agentById:I,asksByAgent:k,actions:st(e),onSelect:S,onContextMenu:P},`arch-${e.id}`)):null]})]})})]})}function B({label:t,count:n,hint:o,open:r,onToggle:c,children:d}){return c?i.jsxs("section",{className:"ctx-panel-rail-section","aria-label":t,children:[i.jsxs("button",{type:"button",className:"ctx-panel-section-label ctx-panel-section-toggle",title:o,"aria-expanded":!!r,onClick:c,children:[i.jsxs("span",{className:"ctx-panel-section-toggle-label",children:[i.jsx("span",{className:"ctx-panel-section-chevron","aria-hidden":!0,children:r?"▾":"▸"}),t]}),i.jsx("span",{className:"ctx-panel-count",children:n})]}),r?i.jsx("div",{className:"ctx-panel-rail-section-body",children:d}):null]}):i.jsxs("section",{className:"ctx-panel-rail-section","aria-label":t,children:[i.jsxs("div",{className:"ctx-panel-section-label",title:o,children:[i.jsx("span",{children:t}),i.jsx("span",{className:"ctx-panel-count",children:n})]}),i.jsx("div",{className:"ctx-panel-rail-section-body",children:d})]})}function rt({pinned:t,archived:n,onTogglePin:o,onToggleArchive:r}){return i.jsxs(i.Fragment,{children:[i.jsx("button",{type:"button",className:["rr-row-action",t&&"rr-row-action--on"].filter(Boolean).join(" "),title:t?"Unpin":"Pin to top","aria-label":t?"Unpin":"Pin",onClick:c=>{c.stopPropagation(),o()},children:t?"Unpin":"Pin"}),i.jsx("button",{type:"button",className:["rr-row-action",n&&"rr-row-action--on"].filter(Boolean).join(" "),title:n?"Unarchive":"Archive","aria-label":n?"Unarchive":"Archive",onClick:c=>{c.stopPropagation(),r()},children:n?"Restore":"Archive"})]})}function E({session:t,rowId:n,nav:o,agentById:r,asksByAgent:c,pinned:d,depth:s,actions:f,worktreeLabel:p,onSelect:w,onContextMenu:u}){const C=t.id===o.activeId,m=N(t),y=lt(t),j=Mt(t),g=t.agentId?r.get(t.agentId):void 0,b=t.agentId?c.get(t.agentId):void 0,l=!y&&!j&&b?.status==="needs_attention",R=Rt(t,g),L=y?`${t.participantIds.length} members`:R.toLowerCase()===m.toLowerCase()?void 0:R,q=!y&&b?ue(t,g,b):L;return i.jsx(Nt,{depth:s,name:s===1?It(t,g,b):m,sub:s===1?Rt(t,g):q,meta:b?at(b.updatedAt):t.lastMessageAt?at(t.lastMessageAt):void 0,tone:y?"channel":b?de(g,b):g?ct(g.state):"dm",avatarName:s===1?g?.name??It(t,g,b):m,avatarKind:y?"channel":"user",active:C,unread:l,pinned:d,activityLabel:b?Lt(b):void 0,activityTone:b?le(b):void 0,worktreeLabel:p??void 0,title:s===1?pe(t,g,b):void 0,actions:f,tabIndex:qt(n===o.activeRowId,o.activeRowId!==void 0,n===o.firstRowId),onClick:()=>w(t),onContextMenu:u?J=>u(J,t):void 0})}function At({group:t,isOpen:n,nav:o,agentById:r,asksByAgent:c,prefs:d,observed:s,onToggle:f,onSelect:p,onTogglePin:w,onToggleArchive:u,onContextMenu:C}){if(t.conversations.length===1){const l=t.conversations[0];return i.jsx(E,{rowId:l.id,session:l,nav:o,agentById:r,asksByAgent:c,pinned:M(l.id,d),actions:i.jsx(rt,{pinned:M(l.id,d),archived:$(l.id,d),onTogglePin:()=>w(l.id),onToggleArchive:()=>u(l.id)}),onSelect:p,onContextMenu:C})}const m=t.conversations.map(l=>l.agentId?c.get(l.agentId):void 0).filter(l=>!!l),y=m.length,j=m.filter(l=>l.status==="working").length,g=m.filter(l=>l.status==="needs_attention").length,b=t.conversations.some(l=>l.id===o.activeId);return i.jsxs("div",{children:[i.jsx(Nt,{name:t.label,meta:y>0?`${y} active · ${St(t)}`:St(t),tone:j>0?"in_turn":t.bestState,caret:n?"open":"closed",active:b&&!n,unread:!s&&g>0&&!n,activityLabel:y>0?`${y} active`:void 0,activityTone:g>0?"attention":j>0?"working":"pending",onClick:f}),n&&t.conversations.map(l=>{const R=l.agentId?r.get(l.agentId):void 0,L=t.canonicalRoot&&R?.projectRoot&&R.projectRoot!==t.canonicalRoot?$t(R.projectRoot):null;return i.jsx(E,{rowId:l.id,session:l,depth:1,nav:o,agentById:r,asksByAgent:c,pinned:M(l.id,d),worktreeLabel:L,actions:i.jsx(rt,{pinned:M(l.id,d),archived:$(l.id,d),onTogglePin:()=>w(l.id),onToggleArchive:()=>u(l.id)}),onSelect:p,onContextMenu:C},l.id)})]},t.key)}function re({query:t,loading:n,error:o,apiOffline:r,onRetry:c}){const d=t.trim().length>0,s=n?"Loading conversations":r?"Scout server offline":o?"Couldn't load conversations":d?"No matching conversations":"No conversations yet",f=n?"Checking the broker for your conversations, channels, and observed threads.":r?"Start or restart Scout services, then retry.":o||(d?"Try a shorter filter.":"Your conversations, channels, and observed agent threads will show here.");return i.jsxs("div",{className:"ctx-panel-empty-card","data-tone":r||o?"error":"neutral",children:[i.jsx("div",{className:"ctx-panel-empty-card-title",children:s}),i.jsx("div",{className:"ctx-panel-empty-card-detail",children:f}),(r||o)&&i.jsx("button",{type:"button",className:"ctx-panel-empty-card-action",onClick:c,children:"Retry"})]})}function kt(t,n){const o=n.toLowerCase();return N(t).toLowerCase().includes(o)||t.id.toLowerCase().includes(o)||(t.preview??"").toLowerCase().includes(o)||(t.agentName??"").toLowerCase().includes(o)}function ce(t){return t===1?"1 needs a reply":`${t} need a reply`}function Lt(t){return t.status==="queued"?"Starting":t.status==="working"?"Working":t.status==="needs_attention"?"Needs you":t.statusLabel||t.status}function le(t){return t.status==="queued"?"pending":t.status==="needs_attention"?"attention":"working"}function de(t,n){return n.status==="working"?"in_turn":t?ct(t.state):"dm"}function ue(t,n,o){const r=Lt(o),c=z(o.task)??z(o.summary)??z(t.preview)??t.currentBranch??n?.branch??"";return c?`${r} · ${c}`:r}function W(t){return[...t].sort((n,o)=>(o.lastMessageAt??0)-(n.lastMessageAt??0))}function It(t,n,o){const r=o?.task??z(t.preview)??t.currentBranch??n?.branch??"",c=n?.name??t.agentName??N(t);return r?`${c} · ${r}`:c}function pe(t,n,o){const r=[];return o&&r.push(`task: ${o.task}`),t.preview&&r.push(`preview: ${t.preview}`),(t.currentBranch??n?.branch)&&r.push(`branch: ${t.currentBranch??n?.branch}`),n?.harness&&r.push(`harness: ${n.harness}`),r.length>0?r.join(`
|
|
2
|
+
`):void 0}function Rt(t,n){if(lt(t))return Qt(t);const o=n?.handle?.trim().replace(/^@+/,"");return o||(t.agentId?t.agentId.split(".")[0]??t.agentId:N(t))}function z(t){if(!t)return null;const n=t.replace(/\s+/g," ").trim();return n?n.length>60?`${n.slice(0,57)}…`:n:null}function St(t){const n=t.latestUpdate?at(t.latestUpdate):"",o=`${t.conversations.length}`;return n?`${o} · ${n}`:o}export{cn as ChatLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as N,j as e}from"./index-CzVeWScw.js";import{a as I}from"./api-h5zurxmi.js";import{b as L,c as j,s as R}from"./router-B-K15T7B.js";import{u as $,r as y,s as b,i as C}from"./mesh-ops-Cnw3vwAu.js";import{u as E,s as T}from"./mesh-view-store-Btlyc7rW.js";import{u as A}from"./Provider-DSsb2gLR.js";import{R as h}from"./RailRow-DerXOXQS.js";import{u as U}from"./use-mesh-ops-items-Co05vcTV.js";/* empty css */import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./colors-BtO5_zlx.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";function S(s){return s.hostName?.split(".")[0]??s.name??s.id.slice(0,12)}function $t(){const{route:s,navigate:u}=A(),l=L(s),{items:i,unattributedOnly:m,lab:M,refreshToken:g}=$(),{meshSnapshot:r}=E();U(l);const[w]=N.useState(()=>y());N.useEffect(()=>{let t=!1;return I("/api/mesh").then(o=>{t||T(o)}).catch(()=>{}),()=>{t=!0}},[g]);const c=t=>{b(!1),u(t?R(s,t):j(s))},O=()=>{u(j(s)),b(!0)},p=r?.localNode??null,d=r?Object.values(r.nodes).filter(t=>t.id!==p?.id):[],a=t=>M.lastLook?t.filter(o=>C(o,w)).length:0,x=i.filter(t=>t.hostNodeId===null),f=t=>{const o=i.filter(k=>k.hostNodeId===t.id),n=a(o),v=l===t.id;return e.jsx(h,{name:S(t),meta:o.length>0?`${n>0?`${n}·`:""}${o.length}`:"—",tone:n>0?"needs_attention":"neutral",active:v,unread:n>0,onClick:()=>c(v?null:t.id),title:`Scope the list to ${S(t)}`},t.id)};return e.jsxs("div",{className:"ctx-panel mesh-ops-rail",children:[e.jsxs("div",{className:"ctx-panel-section",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"Mesh"}),e.jsx(h,{name:"everywhere",meta:`${a(i)>0?`${a(i)}·`:""}${i.length}`,tone:a(i)>0?"needs_attention":"neutral",active:l===null&&!m,onClick:()=>c(null),title:"Show items across all hosts"})]}),p&&e.jsxs("div",{className:"ctx-panel-section",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"This host"}),f(p)]}),d.length>0&&e.jsxs("div",{className:"ctx-panel-section",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"Peers"}),d.map(t=>f(t))]}),e.jsxs("div",{className:"ctx-panel-section",children:[e.jsx("div",{className:"ctx-panel-section-label",children:"No venue"}),e.jsx(h,{name:"unattributed",meta:x.length>0?String(x.length):"—",tone:"neutral",active:m,onClick:()=>m?c(null):O(),title:"Items with no venue host"})]}),!r&&e.jsx("div",{className:"ctx-panel-empty",children:"Loading mesh…"})]})}export{$t as MeshOpsLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as m,j as t}from"./index-CzVeWScw.js";import{u as re,L as W}from"./chunk-YOZR3KYS-DLOc92uD.js";import{a as le,f as oe,b as ce,c as me,d as de,s as ue}from"./terminal-sessions-C3qU8tnY.js";import{a as ve,b as pe,r as G,m as he}from"./keyboard-nav-BJnFoFDP.js";import{u as be}from"./Provider-DSsb2gLR.js";import{c as fe}from"./colors-BtO5_zlx.js";import{r as P,c as xe}from"./terminal-relay-BkXjjSkq.js";import{t as ye,a as H,s as je,b as y,P as ge}from"./session-table-1xdSxSXq.js";/* empty css */import{R as ke}from"./refresh-cw-4oeFn1Jn.js";import{A as Ne}from"./activity-BxwKkT8z.js";import{C as we}from"./clock-CyfvRmj6.js";import{F as Se}from"./DocumentFocusViewer-BCG2kOmd.js";import{c as Ae}from"./createLucideIcon-ClCdc3F9.js";import{C as Ie}from"./chevron-right-CNE6QAVr.js";import{E as U}from"./eye-BFlhMzQL.js";import{T as Ee}from"./terminal-DrTkVXIj.js";import"./arrow-down-D3-IbArq.js";import"./api-h5zurxmi.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./TextDocumentSurface-DRjctOIt.js";import"./file-text-DG-pufl1.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./x-D4X_y1j_.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";/* empty css */const Te=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],Ce=Ae("layers",Te),Re=[{id:"fleet",label:"Fleet",title:"Group by fleet: herdr, tmux, background"},{id:"places",label:"Places",title:"Group by project"},{id:"time",label:"Time",title:"Group by last activity"},{id:"attention",label:"Attention",title:"Group by attention state: attached, live, detached, exited"}],Me=[{id:"herdr",label:"Herdr"},{id:"tmux-named",label:"Tmux"},{id:"tmux-auto",label:"Tmux · auto"},{id:"external",label:"Background"}],Le=900*1e3,$e=1440*60*1e3,_e=10080*60*1e3,V=[{key:"now",label:"Now",maxAgeMs:Le},{key:"today",label:"Today",maxAgeMs:$e},{key:"week",label:"This week",maxAgeMs:_e},{key:"older",label:"Older",maxAgeMs:null},{key:"unknown",label:"Unknown",maxAgeMs:null}],Oe=[{key:"attached",label:"Attached",rank:3},{key:"live",label:"Live",rank:2},{key:"detached",label:"Detached",rank:1},{key:"exited",label:"Exited",rank:0}];function Fe(a){return Me.map(n=>({key:n.id,label:n.label,items:a.filter(l=>le(l)===n.id)})).filter(n=>n.items.length>0)}function Ke(a){const n=new Map;for(const i of a){const o=n.get(i.project);o?o.push(i):n.set(i.project,[i])}const l=new Set(["backend-only","unscoped"]),r=[...n.entries()].map(([i,o])=>({key:`project:${i}`,label:i,items:o,latestActivity:Math.max(...o.map(d=>H(d)??0)),isCatchAll:l.has(i)}));return r.sort((i,o)=>i.isCatchAll!==o.isCatchAll?i.isCatchAll?1:-1:i.latestActivity!==o.latestActivity?o.latestActivity-i.latestActivity:i.label.localeCompare(o.label,void 0,{numeric:!0,sensitivity:"base"})),r.map(({key:i,label:o,items:d})=>({key:i,label:o,items:d}))}function Be(a,n){const l=r=>{const i=H(r);if(i===null)return"unknown";const o=Math.max(0,n-i);for(const d of V)if(d.maxAgeMs!==null&&o<d.maxAgeMs)return d.key;return"older"};return V.map(r=>({key:r.key,label:r.label,items:a.filter(i=>l(i)===r.key)})).filter(r=>r.items.length>0)}function De(a){return Oe.map(n=>({key:n.key,label:n.label,items:a.filter(l=>ye(l)===n.rank)})).filter(n=>n.items.length>0)}function ze(a,n,l=Date.now()){switch(n){case"fleet":return Fe(a);case"places":return Ke(a);case"time":return Be(a,l);case"attention":return De(a)}}const We=8e3,Ge=[{id:"recent",label:"Recent"},{id:"name",label:"A–Z"}],Pe={fleet:Ce,places:Se,time:we,attention:Ne};function Gt(){const{route:a,navigate:n,agents:l}=be(),[r,i]=m.useState({state:"loading",sessions:[]}),[o,d]=m.useState(""),[f,Q]=m.useState("recent"),[A,Y]=re("terminal-nav-mode","fleet"),[Z,J]=m.useState(!1),[X,M]=m.useState(null),[L,$]=m.useState(null),_=m.useRef(null),O=m.useRef(null),ee=ve(),te=he(()=>O.current);pe(m.useCallback(()=>_.current,[]));const x=m.useCallback((e={})=>{e.silent||i(s=>({state:"loading",sessions:s.sessions})),oe({includeDiscovered:!0}).then(s=>{i({state:"ready",sessions:s})}).catch(s=>{e.silent||i(c=>({state:"failed",sessions:c.sessions,error:s instanceof Error?s.message:String(s)}))})},[]);m.useEffect(()=>{x()},[x]),m.useEffect(()=>{const e=()=>{document.visibilityState==="visible"&&x({silent:!0})},s=window.setInterval(e,We);return window.addEventListener("focus",e),document.addEventListener("visibilitychange",e),()=>{window.clearInterval(s),window.removeEventListener("focus",e),document.removeEventListener("visibilitychange",e)}},[x]);const k=m.useMemo(()=>ce(r.sessions),[r.sessions]),p=m.useMemo(()=>je(me(k),f==="recent"?{column:"activity",direction:"desc"}:{column:"name",direction:"asc"}),[f,k]),j=m.useMemo(()=>Ue(l,f).filter(e=>{const s=P(e);return s?!k.some(c=>c.surface.backend===s.backend&&c.surface.sessionName===s.sessionName&&(s.paneId==null||c.surface.paneId===s.paneId)):!0}),[l,k,f]),u=o.trim().toLowerCase(),g=u?p.filter(e=>e.searchable.includes(u)):p,N=g.filter(e=>y(e)==="current"),ae=ze(N,A),w=g.filter(e=>y(e)==="inactive"),h=g.filter(e=>y(e)==="review"),F=u?w.length+h.length:p.filter(e=>y(e)!=="current").length,K=u?h.length:p.filter(e=>y(e)==="review").length,S=Z||!!u,v=u?j.filter(e=>qe(e).includes(u)):j,ne=a.view==="terminal"?a.terminalSurfaceKey??null:null,B=a.view==="terminal"?a.terminalSessionId??null:null,I=e=>de(e.key,ne)&&(!B||e.session.id===B),E=a.view==="terminal"&&a.agentId?`agent:${a.agentId}`:null,D=!!(N.some(I)||S&&[...w,...h].some(I)||E!=null&&v.some(e=>`agent:${e.id}`===E)),z=N[0]?.id??(S?w[0]?.id??h[0]?.id:void 0)??(v[0]?`agent:${v[0].id}`:void 0),se=r.state==="loading"?"Syncing":u?`${g.length+v.length}/${p.length+j.length}`:`${p.length+j.length} targets`,T=(e,s)=>({view:"terminal",terminalSessionId:e.session.id,terminalSurfaceKey:ue(e.surface),...s?{mode:s}:{}}),C=(e,s="takeover")=>({view:"terminal",agentId:e.id,mode:s}),ie=async e=>{if(e.surface.backend==="tmux"&&window.confirm(`Release inactive terminal ${e.surface.sessionName}? The tmux surface will stop, but any associated Scout agent remains available and can be started again.`)){M(e.id),$(null);try{await xe({backend:"tmux",sessionName:e.surface.sessionName,paneId:e.surface.paneId??null,socketDir:e.surface.socketDir??null},"release"),x({silent:!0})}catch(s){$(s instanceof Error?s.message:String(s))}finally{M(null)}}},R=e=>{const s=I(e),c=y(e),b=X===e.id;return t.jsxs("div",{className:`terminal-nav-row${s?" terminal-nav-row--active":""}${c==="review"?" terminal-nav-row--review":""}`,title:e.surface.sessionName,children:[t.jsxs("button",{type:"button","data-list-primary":!0,className:"terminal-nav-row-select",tabIndex:G(s,D,e.id===z),onClick:()=>n(T(e)),children:[t.jsx(Ee,{className:"terminal-nav-row-icon",size:14,strokeWidth:1.7}),t.jsxs("span",{className:"terminal-nav-row-main",children:[t.jsx("span",{className:"terminal-nav-row-title",children:t.jsx("span",{children:e.title})}),t.jsx("span",{className:"terminal-nav-row-detail",children:e.detail||e.session.sourceSessionId})]}),t.jsxs("span",{className:"terminal-nav-badges",children:[t.jsx("span",{className:"terminal-nav-badge terminal-nav-badge--backend",children:e.surface.backend}),t.jsx("span",{className:`terminal-nav-badge${c==="review"?" terminal-nav-badge--review":""}`,children:c==="current"?e.condition:c})]})]}),t.jsxs("div",{className:"terminal-nav-row-actions",children:[t.jsxs("button",{type:"button",className:`terminal-nav-action${a.view==="terminal"&&s&&a.mode==="takeover"?" terminal-nav-action--selected":""}`,onClick:()=>n(T(e,"takeover")),title:"Enter this terminal","aria-label":"Enter this terminal",children:[t.jsx(W,{size:12,strokeWidth:1.8}),t.jsx("span",{children:"Enter"})]}),t.jsxs("button",{type:"button",className:`terminal-nav-action${a.view==="terminal"&&s&&a.mode==="observe"?" terminal-nav-action--selected":""}`,onClick:()=>n(T(e,"observe")),title:"Observe this terminal read-only","aria-label":"Observe this terminal read-only",children:[t.jsx(U,{size:12,strokeWidth:1.8}),t.jsx("span",{children:"Observe"})]}),c==="review"&&e.surface.backend==="tmux"&&t.jsxs("button",{type:"button",className:"terminal-nav-action terminal-nav-action--release",onClick:()=>{ie(e)},disabled:b,title:"Release this inactive tmux surface; keep the agent","aria-label":"Release this inactive tmux surface; keep the agent",children:[t.jsx(ge,{size:12,strokeWidth:1.8}),t.jsx("span",{children:b?"Releasing":"Release"})]})]})]},e.id)};return t.jsxs("div",{className:"ctx-panel terminal-nav",children:[t.jsxs("div",{className:"terminal-nav-head",children:[t.jsxs("div",{children:[t.jsx("div",{className:"terminal-nav-title",children:"Terminals"}),t.jsx("div",{className:"terminal-nav-summary",children:se})]}),t.jsx("button",{type:"button",className:"terminal-nav-refresh",onClick:()=>x(),disabled:r.state==="loading",title:"Refresh terminals","aria-label":"Refresh terminals",children:t.jsx(ke,{size:14,strokeWidth:1.8})})]}),t.jsx("div",{className:"terminal-nav-modes",role:"group","aria-label":"Group terminals",children:Re.map(e=>{const s=Pe[e.id];return t.jsx("button",{type:"button",title:e.title,"aria-label":e.title,"aria-pressed":A===e.id,className:`terminal-nav-mode${A===e.id?" terminal-nav-mode--active":""}`,onClick:()=>Y(e.id),children:t.jsx(s,{size:13,strokeWidth:1.8})},e.id)})}),t.jsxs("div",{className:"ctx-panel-toolbar terminal-nav-toolbar",children:[t.jsx("input",{ref:_,type:"text",className:"ctx-panel-search-input",placeholder:"Search… (/)",value:o,onChange:e=>d(e.target.value),onKeyDown:te}),t.jsx("div",{className:"ctx-panel-sort",role:"group","aria-label":"Sort terminals",children:Ge.map(e=>t.jsx("button",{type:"button",title:e.id==="recent"?"Sort by most recent":"Sort alphabetically","aria-pressed":f===e.id,className:`ctx-panel-sort-option${f===e.id?" ctx-panel-sort-option--active":""}`,onClick:()=>Q(e.id),children:e.label},e.id))})]}),r.state==="failed"&&t.jsx("div",{className:"terminal-nav-error",children:r.error}),L&&t.jsx("div",{className:"terminal-nav-error",children:L}),t.jsx("div",{ref:O,className:"terminal-nav-list",onKeyDown:ee,children:g.length===0&&v.length===0&&r.state!=="loading"?t.jsx("div",{className:"ctx-panel-empty",children:p.length+j.length===0?"No terminal targets":"No matches"}):t.jsxs(t.Fragment,{children:[ae.map(e=>e.items.length===0?null:t.jsxs("div",{className:"terminal-nav-section",children:[t.jsxs("div",{className:"terminal-nav-section-title",children:[t.jsx("span",{children:e.label}),t.jsx("span",{children:e.items.length})]}),e.items.map(R)]},e.key)),N.length===0&&r.state!=="loading"&&t.jsx("div",{className:"terminal-nav-empty",children:"No sessions"}),F>0&&t.jsxs("div",{className:"terminal-nav-section terminal-nav-section--inactive",children:[t.jsxs("button",{type:"button",className:"terminal-nav-inactive-toggle","aria-expanded":S,onClick:()=>J(e=>!e),children:[t.jsx(Ie,{size:13,strokeWidth:1.8}),t.jsx("span",{children:"Inactive"}),t.jsx("span",{children:F}),K>0&&t.jsxs("span",{className:"terminal-nav-review-count",children:[K," review"]})]}),S&&t.jsxs(t.Fragment,{children:[w.map(R),h.length>0&&t.jsxs("div",{className:"terminal-nav-section-title terminal-nav-section-title--review",children:[t.jsx("span",{children:"Review after 30 days"}),t.jsx("span",{children:h.length})]}),h.map(R)]})]}),t.jsxs("div",{className:"terminal-nav-section",children:[t.jsxs("div",{className:"terminal-nav-section-title",children:[t.jsx("span",{children:"Available agents"}),t.jsx("span",{children:v.length})]}),v.map(e=>{const s=`agent:${e.id}`,c=s===E,b=P(e);return t.jsxs("div",{className:`terminal-nav-row terminal-nav-row--agent${c?" terminal-nav-row--active":""}`,title:e.name,children:[t.jsxs("button",{type:"button","data-list-primary":!0,className:"terminal-nav-row-select",tabIndex:G(c,D,s===z),onClick:()=>n(C(e)),children:[t.jsx("span",{className:`terminal-nav-agent-dot${b?" terminal-nav-agent-dot--bound":""}`,"aria-hidden":!0}),t.jsxs("span",{className:"terminal-nav-row-main",children:[t.jsx("span",{className:"terminal-nav-row-title",children:t.jsx("span",{children:e.name})}),t.jsx("span",{className:"terminal-nav-row-detail",children:Ve(e)})]}),t.jsxs("span",{className:"terminal-nav-badges",children:[t.jsx("span",{className:"terminal-nav-badge terminal-nav-badge--backend",children:b?.backend??e.harness??"agent"}),t.jsx("span",{className:"terminal-nav-badge",children:b?"bound":fe(e.state)})]})]}),t.jsxs("div",{className:"terminal-nav-row-actions",children:[t.jsxs("button",{type:"button",className:`terminal-nav-action${a.view==="terminal"&&c&&a.mode==="takeover"?" terminal-nav-action--selected":""}`,onClick:()=>n(C(e,"takeover")),title:"Enter this agent terminal","aria-label":"Enter this agent terminal",children:[t.jsx(W,{size:12,strokeWidth:1.8}),t.jsx("span",{children:"Enter"})]}),b&&t.jsxs("button",{type:"button",className:`terminal-nav-action${a.view==="terminal"&&c&&a.mode==="observe"?" terminal-nav-action--selected":""}`,onClick:()=>n(C(e,"observe")),title:"Observe this agent terminal read-only","aria-label":"Observe this agent terminal read-only",children:[t.jsx(U,{size:12,strokeWidth:1.8}),t.jsx("span",{children:"Observe"})]})]})]},e.id)}),v.length===0&&t.jsx("div",{className:"terminal-nav-empty",children:"No agents"})]})]})})]})}function Ue(a,n){return[...a].filter(l=>!l.retiredFromFleet&&!l.staleLocalRegistration).sort((l,r)=>{const i=l.name.localeCompare(r.name,void 0,{numeric:!0,sensitivity:"base"});return n==="name"?i||l.id.localeCompare(r.id):(r.updatedAt??0)-(l.updatedAt??0)||i||l.id.localeCompare(r.id)})}function Ve(a){const n=a.project??q(a.cwd)??q(a.projectRoot)??a.definitionId;return[a.handle?`@${a.handle}`:null,a.harness,n,a.branch].filter(Boolean).join(" · ")}function qe(a){return[a.name,a.handle,a.harness,a.state,a.project,a.branch,a.cwd,a.projectRoot,a.definitionId].filter(Boolean).join(" ").toLowerCase()}function q(a){const n=a?.trim().replace(/\/+$/u,"");return n?n.split("/").pop()||n:null}export{Gt as TerminalLeft};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r,j as e}from"./index-CzVeWScw.js";/* empty css */import{n as k}from"./colors-BtO5_zlx.js";import{p as C,a as L}from"./api-h5zurxmi.js";import{u as F,m as $,e as D,h as H}from"./Provider-DSsb2gLR.js";import{b as O}from"./router-B-K15T7B.js";import{d as B,a as G}from"./operator-attention-BwSPeheT.js";import{u as K}from"./sse-QcU9bikk.js";import{t as f}from"./time-Dhsh_2EG.js";import{o as P}from"./openAgent-Dbv5wfuL.js";import{R as v}from"./RailRow-DerXOXQS.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./index-BWHgHrtv.js";import"./openContent-C6XO6kr5.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";const U=new Set(["message.posted","flight.updated","collaboration.event.appended","agent.updated"]),V=4,z=4,Q=3,N="/api/fleet",X=3e4;function Xt({prepend:t}){const{agents:o,agentsLoaded:a,navigate:c,route:n}=F(),[i]=r.useState(()=>C(N,X)),[l,E]=r.useState(i),[A,T]=r.useState(i!==null),[j,b]=r.useState(()=>new Set),p=O(n),I=r.useMemo(()=>$(o,p),[o,p]),m=r.useMemo(()=>D(o,p),[o,p]),u=r.useMemo(()=>H(l,I),[l,I]),d=r.useCallback(async()=>{try{E(await L(N))}catch{}finally{T(!0)}},[]);r.useEffect(()=>{d()},[d]),K(s=>{U.has(s.kind)&&d()});const w=r.useMemo(()=>Z(m).slice(0,V),[m]),R=r.useMemo(()=>(u?.activity??[]).slice(0,z),[u]),_=r.useMemo(()=>(u?.needsAttention??[]).filter(s=>!j.has(s.recordId)).slice(0,Q),[u,j]),M=r.useCallback(async s=>{b(h=>new Set(h).add(s.recordId));try{await B({recordKind:s.kind,recordId:s.recordId,itemUpdatedAt:s.updatedAt})}catch{b(h=>{const S=new Set(h);return S.delete(s.recordId),S});return}d()},[d]);return e.jsxs("div",{className:"ctx-panel base-rail",children:[t?e.jsx("div",{className:"base-rail-prepend",children:t}):null,e.jsx(Y,{agents:w,totalCount:m.length,loading:!a,onSelect:s=>P(c,s,{returnTo:n}),onSeeAll:()=>c({view:"agents-v2"})}),e.jsx(J,{items:R,loading:!A,onSelect:s=>c(tt(s)),onSeeAll:()=>c({view:"activity"})}),e.jsx(W,{items:_,loading:!A,onSelect:s=>c(G(s)),onDismiss:s=>{M(s)}})]})}function Y({agents:t,totalCount:o,loading:a,onSelect:c,onSeeAll:n}){return e.jsxs("section",{className:"ctx-panel-section base-rail-section",children:[e.jsx(g,{title:"Recent agents",onSeeAll:o>0?n:void 0}),a?e.jsx(x,{}):t.length===0?e.jsx("div",{className:"ctx-panel-empty",children:"No agents yet"}):t.map(i=>e.jsx(v,{name:i.name||i.id,meta:i.updatedAt?f(i.updatedAt):void 0,tone:k(i.state),title:q(i),onClick:()=>c(i)},i.id))]})}function q(t){const o=[];return t.project&&o.push(`project: ${t.project}`),t.branch&&o.push(`branch: ${t.branch}`),t.harness&&o.push(`harness: ${t.harness}`),o.join(`
|
|
2
|
+
`)}function J({items:t,loading:o,onSelect:a,onSeeAll:c}){return e.jsxs("section",{className:"ctx-panel-section base-rail-section",children:[e.jsx(g,{title:"Recent activity",meta:(t.length>0,void 0),onSeeAll:t.length>0?c:void 0}),o?e.jsx(x,{}):t.length===0?e.jsx("div",{className:"ctx-panel-empty",children:"Quiet so far"}):t.map(n=>{const i=n.actorName??n.agentName??n.agentId??"system",l=n.title??n.summary??y(n.kind);return e.jsx(v,{name:l,meta:n.ts?f(n.ts):void 0,tone:"neutral",title:`${i} · ${y(n.kind)}`,onClick:()=>a(n)},n.id)})]})}function W({items:t,loading:o,onSelect:a,onDismiss:c}){return!o&&t.length===0?null:e.jsxs("section",{className:"ctx-panel-section base-rail-section",children:[e.jsx(g,{title:"Needs attention",meta:t.length>0?`${t.length}`:void 0}),o?e.jsx(x,{rows:2}):t.map(n=>{const i=n.agentName??n.agentId??"operator";return e.jsx(v,{name:n.title,meta:f(n.updatedAt),tone:"in_turn",unread:!0,title:`${i} · ${n.kind}`,onClick:()=>a(n),actions:e.jsx("button",{type:"button",className:"rr-row-action",title:"Dismiss — stop asking until this changes","aria-label":"Dismiss",onClick:l=>{l.stopPropagation(),c(n)},children:"Dismiss"})},n.recordId)})]})}function x({rows:t=3}){return e.jsx("div",{className:"base-rail-loading",role:"status","aria-label":"Loading",children:Array.from({length:t},(o,a)=>e.jsx("span",{"aria-hidden":"true"},a))})}function g({title:t,meta:o,onSeeAll:a}){return e.jsxs("div",{className:"ctx-panel-section-label base-rail-section-label",children:[e.jsx("span",{children:t}),e.jsxs("span",{className:"base-rail-section-trailing",children:[o?e.jsx("span",{className:"ctx-panel-count",children:o}):null,a?e.jsx("button",{type:"button",className:"base-rail-see-all",onClick:a,children:"all"}):null]})]})}function Z(t){return[...t].sort((o,a)=>(a.updatedAt??0)-(o.updatedAt??0))}function y(t){switch(t){case"message":return"Message";case"invocation":return"Invocation";case"flight":return"Flight update";case"collaboration":return"Collaboration";default:return t.replace(/_/g," ")}}function tt(t){return t.conversationId?{view:"conversation",conversationId:t.conversationId}:t.agentId?{view:"agents-v2",agentId:t.agentId}:{view:"activity"}}export{Xt as HomeLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as e,r as A}from"./index-CzVeWScw.js";import{u as q,g as z,i as P,j as G,k as I,l as H,a as w,r as T}from"./mesh-view-store-Btlyc7rW.js";import{u as Q}from"./Provider-DSsb2gLR.js";import{n as b,a as V}from"./colors-BtO5_zlx.js";import{b as D}from"./mesh-buckets-CfAukILK.js";import{u as J}from"./use-fleet-active-asks-BOMPW0nl.js";import{R as h}from"./RailRow-DerXOXQS.js";import{F as U}from"./FleetSearch-Dj7-CfNi.js";import{o as W}from"./openAgent-Dbv5wfuL.js";/* empty css */import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./api-h5zurxmi.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";import"./openContent-C6XO6kr5.js";const X=["needs_attention","in_turn","in_flight","callable","blocked"],Y={in_turn:"in turn",in_flight:"in flight",needs_attention:"needs attention",callable:"callable",blocked:"blocked"},Z={in_turn:"working",in_flight:"working",needs_attention:"working",callable:"available",blocked:"offline"};function ee({active:a,onToggle:p}){return e.jsx("div",{className:"fleet-pills",role:"group","aria-label":"State filters",children:X.map(o=>{const l=a.has(o);return e.jsx("button",{type:"button",className:`fleet-pill fleet-pill--${Z[o]}${l?" fleet-pill--on":""}`,onClick:()=>p(o),"aria-pressed":l,children:Y[o]},o)})})}const _=10;function te(a){return b(a.state)}function C(a){return a.updatedAt??a.createdAt??0}function Ye(){const{agents:a,navigate:p}=Q(),{meshSnapshot:o,selectedId:l,selectedType:S,query:d,agentStateFilters:u,hiddenMachineIds:g,treeFullMachineIds:F}=q(),L=J(),m=A.useMemo(()=>o?D(a,o):[],[a,o]),y=A.useMemo(()=>{const n=d.trim().toLowerCase();return m.filter(s=>!g.has(s.machineId)).map(s=>{const t=s.agents.filter(r=>u.has(te(r))?n?`${r.name??""} ${r.project??""} ${r.branch??""} ${r.harness??""}`.toLowerCase().includes(n):!0:!1);return{...s,agents:t}})},[m,d,u,g]),f=A.useMemo(()=>{const n=new Map([["this",[]],["peer",[]],["tailnet",[]]]);for(const s of y){const t=s.reachability==="this"?"this":s.reachability==="peer"?"peer":"tailnet";n.get(t)?.push(s)}return n},[y]);if(!o)return e.jsx("div",{className:"ctx-panel ctx-panel--empty",children:e.jsx("div",{className:"ctx-panel-empty-state",children:e.jsx("div",{className:"ctx-panel-empty-hint",children:"Loading mesh…"})})});const $=n=>{const s=m.map(t=>t.machineId);H(n,s),w(n,"node"),T(n)},v=g.size,x=m.length,E=n=>{w(n.id,"agent");const s=n.authorityNodeId??n.homeNodeId;s&&T(s),W(p,n,{returnTo:{view:"mesh"}})},j=(n,s)=>s.length===0?null:e.jsxs("section",{className:"mesh-nav-group",children:[e.jsx("div",{className:"mesh-nav-group-label",children:n}),s.map(t=>{const r=F.has(t.machineId),c=[...t.agents].sort((i,k)=>C(k)-C(i)),M=r?c:c.slice(0,_),N=c.length-M.length,B=l===t.machineId&&S==="node",R=t.agents.filter(i=>V(i.state)).length,K=t.agents.length>0?`${R}/${t.agents.length}`:t.online?"—":"not ready";return e.jsxs("div",{className:"mesh-nav-machine",children:[e.jsx(h,{name:t.machineLabel,meta:K,tone:"neutral",active:B,onClick:()=>$(t.machineId),title:`Focus ${t.machineLabel} on the map`}),M.map(i=>{const k=l===i.id&&S==="agent",O=L.has(i.id);return e.jsx(h,{name:i.name,tone:b(i.state),depth:1,active:k,unread:O,onClick:()=>E(i),title:i.name},i.id)}),!r&&N>0&&e.jsx(h,{name:`see ${N} more`,depth:1,tone:"neutral",onClick:()=>I(t.machineId),title:"Show all agents on this machine"}),r&&c.length>_&&e.jsx(h,{name:"see less",depth:1,tone:"neutral",onClick:()=>I(t.machineId),title:"Show recent agents only"})]},t.machineId)})]},n);return e.jsxs("div",{className:"ctx-panel mesh-nav",children:[e.jsxs("div",{className:"mesh-nav-head",children:[e.jsx(U,{value:d,onChange:z,placeholder:"Find machines or agents…"}),e.jsx(ee,{active:u,onToggle:P}),v>0&&v<x&&e.jsxs("button",{type:"button",className:"mesh-nav-focus-chip",onClick:G,title:"Show all machines",children:[e.jsxs("span",{className:"mesh-nav-focus-chip-label",children:["focused · ",x-v,"/",x]}),e.jsx("span",{className:"mesh-nav-focus-chip-clear","aria-hidden":!0,children:"×"})]})]}),e.jsxs("div",{className:"mesh-nav-tree",children:[j("this host",f.get("this")??[]),j("peers",f.get("peer")??[]),j("tailnet",f.get("tailnet")??[])]})]})}export{Ye as MeshLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r,j as o}from"./index-CzVeWScw.js";/* empty css */import{a as j}from"./api-h5zurxmi.js";import{u as v}from"./sse-QcU9bikk.js";import{u as N}from"./Provider-DSsb2gLR.js";import{u as g}from"./use-fleet-active-asks-BOMPW0nl.js";import{i as w}from"./colors-BtO5_zlx.js";import{R as a}from"./RailRow-DerXOXQS.js";import"./index-BWHgHrtv.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";const $=new Set(["message.posted","conversation.upserted","agent.updated"]);function k(e){const n=x(e.cwd),m=x(e.projectRoot);return e.authorityNodeName??e.homeNodeName??e.authorityNodeId??e.homeNodeId??e.transport??n??m??"local"}function b(e){return e.project??e.role??e.agentClass??"Unassigned"}function x(e){if(!e)return null;const n=e.split("/").filter(Boolean);return n[n.length-1]??null}function ht(){const{agents:e,navigate:n}=N(),[m,f]=r.useState([]),p=g(),c=r.useCallback(async()=>{const t=await j("/api/conversations").catch(()=>[]);f(t)},[]);r.useEffect(()=>{c()},[c]),v(t=>{$.has(t.kind)&&c()});const h=r.useMemo(()=>e.filter(t=>w(t.state)).length,[e]),l=r.useMemo(()=>{let t=0;for(const s of p.values())(s.status==="failed"||s.status==="needs_attention")&&(t+=1);return t},[p]),u=r.useMemo(()=>{const t=new Map;for(const s of e){const i=b(s);t.set(i,(t.get(i)??0)+1)}return[...t.entries()].sort((s,i)=>i[1]-s[1]).slice(0,8)},[e]),d=r.useMemo(()=>{const t=new Map;for(const s of e){const i=k(s);t.set(i,(t.get(i)??0)+1)}return[...t.entries()].sort((s,i)=>i[1]-s[1]).slice(0,8)},[e]);return o.jsxs("div",{className:"ctx-panel",children:[o.jsxs("section",{className:"ctx-panel-section",children:[o.jsx("div",{className:"ctx-panel-section-label",children:"Agents"}),o.jsx(a,{name:"Overview",meta:`${e.length}`,tone:"neutral",onClick:()=>n({view:"inbox"})}),o.jsx(a,{name:"Agents",meta:`${h}`,tone:"callable",active:!0,onClick:()=>n({view:"ops",mode:"agents"})}),o.jsx(a,{name:"Sessions",meta:`${m.length}`,tone:"neutral",onClick:()=>n({view:"sessions"})}),o.jsx(a,{name:"Alerts",meta:`${l}`,tone:l>0?"in_turn":"neutral",unread:l>0,onClick:()=>n({view:"activity"})})]}),o.jsxs("section",{className:"ctx-panel-section",children:[o.jsx("div",{className:"ctx-panel-section-label",children:"Projects"}),u.length===0?o.jsx("div",{className:"ctx-panel-empty",children:"No projects"}):u.map(([t,s])=>o.jsx(a,{name:t,meta:`${s}`,tone:"neutral",title:`${s} agent${s===1?"":"s"} on ${t}`},t))]}),o.jsxs("section",{className:"ctx-panel-section",children:[o.jsx("div",{className:"ctx-panel-section-label",children:"Machines"}),d.length===0?o.jsx("div",{className:"ctx-panel-empty",children:"No machines"}):d.map(([t,s])=>o.jsx(a,{name:t,meta:`${s}`,tone:"neutral",title:`${s} agent${s===1?"":"s"} on ${t}`},t))]})]})}export{ht as OpsAgentsLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r,j as o}from"./index-CzVeWScw.js";/* empty css */import{a as h}from"./api-h5zurxmi.js";import{n as f}from"./colors-BtO5_zlx.js";import{a as g,r as j}from"./operator-attention-BwSPeheT.js";import{u as N}from"./sse-QcU9bikk.js";import{t as c}from"./time-Dhsh_2EG.js";import{u as A}from"./Provider-DSsb2gLR.js";import{o as l}from"./openContent-C6XO6kr5.js";import{R as m}from"./RailRow-DerXOXQS.js";import"./index-BWHgHrtv.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";const w=[{name:"Control",route:{view:"ops",mode:"mission"},active:e=>e.view==="ops"&&(e.mode===void 0||e.mode==="mission")},{name:"Dispatch",route:{view:"broker"},active:e=>e.view==="broker"},{name:"Mesh",route:{view:"mesh"},active:e=>e.view==="mesh"},{name:"Tail",route:{view:"ops",mode:"tail"},active:e=>e.view==="ops"&&e.mode==="tail"},{name:"Runtime",route:{view:"ops",mode:"atop"},active:e=>e.view==="ops"&&e.mode==="atop"}];function xt(){const{navigate:e,route:n}=A(),[p,d]=r.useState(null),s=r.useCallback(async()=>{const t=await h("/api/fleet").catch(()=>null);d(t)},[]);r.useEffect(()=>{s()},[s]),N(t=>{(t.kind==="message.posted"||t.kind==="flight.updated"||t.kind==="collaboration.event.appended")&&s()});const i=p?.needsAttention??[],a=(p?.activeAsks??[]).filter(t=>t.status!=="needs_attention"),u=t=>{l(e,g(t),{returnTo:n})},v=t=>{l(e,j(t),{returnTo:n})};return o.jsxs("div",{className:"ctx-panel ctx-panel--ops",children:[o.jsxs("section",{className:"ctx-panel-section",children:[o.jsx("div",{className:"ctx-panel-section-label",children:"Surfaces"}),w.map(t=>o.jsx(m,{name:t.name,tone:"neutral",active:t.active(n),onClick:()=>e(t.route)},t.name))]}),o.jsxs("section",{className:"ctx-panel-section",children:[o.jsxs("div",{className:"ctx-panel-section-label",children:["Needs you",i.length>0&&o.jsx("span",{className:"ctx-panel-count",children:i.length})]}),i.length===0?o.jsx("div",{className:"ctx-panel-empty",children:"All clear"}):i.slice(0,4).map(t=>{const x=t.agentName??t.agentId??"operator";return o.jsx(m,{name:t.title,meta:c(t.updatedAt),tone:"in_turn",unread:!0,title:`${x} · ${t.kind}`,onClick:()=>u(t)},t.recordId)})]}),o.jsxs("section",{className:"ctx-panel-section",children:[o.jsxs("div",{className:"ctx-panel-section-label",children:["Active",a.length>0&&o.jsx("span",{className:"ctx-panel-count",children:a.length})]}),a.length===0?o.jsx("div",{className:"ctx-panel-empty",children:"No active requests"}):a.slice(0,10).map(t=>o.jsx(m,{name:t.task,meta:c(t.updatedAt),tone:f(t.agentState),title:`${t.agentName??t.agentId} · ${t.statusLabel}`,onClick:()=>v(t)},t.invocationId))]})]})}export{xt as OpsDefaultLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as f,j as t}from"./index-CzVeWScw.js";/* empty css */import{t as x}from"./time-Dhsh_2EG.js";import{u as b}from"./Provider-DSsb2gLR.js";import{R as g}from"./RailRow-DerXOXQS.js";import{S as v}from"./SpriteAvatar-BpQDpOkq.js";import{n as L}from"./colors-BtO5_zlx.js";import{b as h,c as j,l as p,d as N}from"./agent-lanes-model-CPgQRenB.js";import{u as _,b as A,g as n}from"./lane-roster-store-pR4ZaYQm.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./api-h5zurxmi.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./AgentAvatar-CszU5eaU.js";import"./agent-identity-BxCsXnDp.js";import"./context-budget-DX_fwUs3.js";import"./lane-observe-BA3g9aVd.js";import"./tail-display-BRcJltQa.js";import"./lane-edit-display-C_Aujldz.js";function c(s,e,i){const a=`[data-lane-id="${s.replace(/["\\]/g,"\\$&")}"]`,r=typeof document<"u"?document.querySelector(a):null;if(r){r.scrollIntoView({behavior:"smooth",inline:"center",block:"nearest"}),r.focus();return}e&&i({view:"agents-v2",agentId:e,tab:"profile"})}function R(s){return s.filter(e=>!h(e)&&j(e)).sort((e,i)=>{const a=(i.updatedAt??0)-(e.updatedAt??0);return a!==0?a:p(e,"scout").localeCompare(p(i,"scout"))}).map(e=>({id:e.id,label:p(e,"scout"),statusLabel:N(e,"scout"),tone:L(e.state,e),agentId:e.id,updatedAt:e.updatedAt??void 0}))}function _o(){const{agents:s,navigate:e}=b(),i=_(),a=A(),r=f.useMemo(()=>R(s),[s]),l=i??r,d=l.some(o=>o.floor);return t.jsx("div",{className:"ctx-panel ctx-panel--ops",children:t.jsxs("section",{className:"ctx-panel-section",children:[t.jsxs("div",{className:"ctx-panel-section-label",children:[d?"Fleet":"Lanes",l.length>0&&t.jsx("span",{className:"ctx-panel-count",children:l.length})]}),l.length===0?t.jsx("div",{className:"ctx-panel-empty",children:"No active lanes"}):l.map(o=>o.floor?t.jsxs("button",{type:"button",className:`agent-floor__ledger-row is-rail${a===o.id?" is-focus":""}`,onClick:()=>{const m=n();m?m.onSelect(o.id):c(o.id,o.agentId,e)},onPointerEnter:()=>n()?.onHover(o.id),onPointerLeave:()=>n()?.onHover(null),children:[t.jsxs("span",{className:"agent-floor__ledger-id",children:[t.jsx(v,{name:o.label,size:16,tile:!0}),t.jsx("span",{className:"agent-floor__ledger-name",children:o.label}),t.jsx("span",{className:`agent-floor__card-dot${o.floor.live?" is-live":""}`})]}),t.jsx("span",{className:"agent-floor__ledger-strip",children:o.floor.strip.slice(-6).map((m,u)=>t.jsx("span",{className:`agent-floor__ledger-cell is-${m}`},u))})]},o.id):t.jsx(g,{name:o.label,sub:o.statusLabel||void 0,meta:o.updatedAt?x(o.updatedAt):void 0,tone:o.tone,title:o.statusLabel,onClick:()=>c(o.id,o.agentId,e)},o.id))]})})}export{_o as OpsLanesLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as c,j as i}from"./index-CzVeWScw.js";/* empty css */import{n as S}from"./colors-BtO5_zlx.js";import{u as M,s as A,a as h,b as I,M as C,c as k,d as w,e as F,r as R,t as E}from"./mission-control-store-CcoNeQHG.js";import{u as K}from"./Provider-DSsb2gLR.js";import{a as T,b as q,r as B,m as D}from"./keyboard-nav-BJnFoFDP.js";import{MissionLeftAgentRow as L}from"./MissionLeftAgentRow-nc1Jyq3D.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./api-h5zurxmi.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./page-status-DDvNdA8s.js";import"./RailRow-DerXOXQS.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";function Ee(){const{navigate:r}=K(),s=M(),o=s.visibleAgents,m=c.useRef(null),p=c.useRef(null),v=T(),x=D(()=>m.current);q(c.useCallback(()=>p.current,[]));const[d,y]=c.useState(null),u=s.activityFilter==="active",a=s.selectedIds.length,j=e=>{y(t=>t===e?null:e)},N=()=>{if(a===0)return;const t=o.filter(l=>s.selectedIds.includes(l.id)).map(l=>l.handle??l.name).filter(Boolean).join("|");t&&r({view:"ops",mode:"tail",tailQuery:t})};return i.jsxs("div",{className:"ctx-panel ml-panel",children:[i.jsxs("div",{className:"ml-section",children:[i.jsx("div",{className:"ml-section-label",children:"Source"}),i.jsx("div",{className:"ml-chips ml-chips--primary",children:["all","scout","native"].map(e=>i.jsx("button",{type:"button",className:["ml-chip",s.sourceFilter===e&&"ml-chip--active"].filter(Boolean).join(" "),onClick:()=>A(e),children:e==="all"?"All":e==="scout"?"Scout":"Native"},e))})]}),i.jsx("div",{className:"ctx-panel-search",children:i.jsx("input",{ref:p,type:"text",className:"ctx-panel-search-input",placeholder:"Filter agents… (press /)",value:s.query,onChange:e=>h(e.target.value),onKeyDown:e=>{x(e),e.key==="Escape"&&s.query&&h("")}})}),i.jsx("div",{className:"ml-section ml-section--secondary",children:i.jsxs("div",{className:"ml-chips ml-chips--secondary",children:[["active","live","all"].map(e=>i.jsx("button",{type:"button",className:["ml-chip ml-chip--ghost",s.activityFilter===e&&"ml-chip--ghost-active"].filter(Boolean).join(" "),onClick:()=>I(e),children:e==="active"?"Active":e==="live"?"Live":"Any"},e)),u&&i.jsx("span",{className:"ml-divider","aria-hidden":!0}),u&&C.map(e=>i.jsx("button",{type:"button",className:["ml-chip ml-chip--ghost",s.activityWindowMs===e.value&&"ml-chip--ghost-active"].filter(Boolean).join(" "),onClick:()=>k(e.value),children:e.label},e.value))]})}),i.jsxs("div",{className:"ml-section ml-section--grouping",children:[i.jsx("div",{className:"ml-section-label",children:"Order by"}),i.jsx("div",{className:"ml-chips ml-chips--grouping",children:[["activity","Activity"],["workspace","Project"],["harness","Harness"],["state","Status"],["source","Source"]].map(([e,t])=>i.jsx("button",{type:"button",className:["ml-chip","ml-chip--group",s.groupMode===e&&"ml-chip--group-active"].filter(Boolean).join(" "),"aria-pressed":s.groupMode===e,onClick:()=>w(e),children:t},e))})]}),a>0?i.jsxs("div",{className:"ml-selection",children:[i.jsxs("span",{className:"ml-selection-label",children:[a," selected"]}),i.jsxs("div",{className:"ml-selection-actions",children:[i.jsx("button",{type:"button",className:"ml-selection-btn ml-selection-btn--primary",onClick:N,children:"Tail ↗"}),i.jsx("button",{type:"button",className:"ml-selection-btn",onClick:F,children:"Clear"})]})]}):i.jsxs("div",{className:"ml-count",children:[o.length," visible",i.jsx("span",{className:"ml-count-hint",children:"⌘-click · ⌘A all"})]}),i.jsx("div",{ref:m,className:"ctx-panel-list ctx-panel-list--scroll",onKeyDown:v,children:o.length===0?i.jsx("div",{className:"ctx-panel-empty",children:s.query?"No match":"Nothing visible"}):o.map((e,t)=>{const l=e.id===d,b=o.some(n=>n.id===d),g=s.selectedIds.includes(e.id),f=S(e.state);return i.jsx(L,{agent:e,state:f,isExpanded:l,isSelected:g,tabIndex:B(l,b,t===0),onToggle:n=>{n.metaKey||n.ctrlKey||n.shiftKey?E(e.id):j(e.id)},onReveal:()=>R(e.id),onOpen:()=>r({view:"agents-v2",agentId:e.id})},e.id)})})]})}export{Ee as OpsMissionLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as t}from"./index-CzVeWScw.js";import{u as o}from"./Provider-DSsb2gLR.js";import{OpsAgentsLeft as m}from"./left-agents-CYUwAy2Z.js";import{OpsDefaultLeft as p}from"./left-default-vEGZALPv.js";import{OpsLanesLeft as i}from"./left-lanes-bphF-vlX.js";import{OpsMissionLeft as s}from"./left-mission-B54-c3hq.js";import{OpsPlanLeft as e}from"./left-plan-BNBuDoPQ.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./api-h5zurxmi.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./colors-BtO5_zlx.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./time-Dhsh_2EG.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";/* empty css */import"./use-fleet-active-asks-BOMPW0nl.js";import"./RailRow-DerXOXQS.js";import"./AgentAvatar-CszU5eaU.js";import"./SpriteAvatar-BpQDpOkq.js";import"./agent-identity-BxCsXnDp.js";import"./operator-attention-BwSPeheT.js";import"./openContent-C6XO6kr5.js";import"./agent-lanes-model-CPgQRenB.js";import"./context-budget-DX_fwUs3.js";import"./lane-observe-BA3g9aVd.js";import"./tail-display-BRcJltQa.js";import"./lane-edit-display-C_Aujldz.js";import"./lane-roster-store-pR4ZaYQm.js";import"./mission-control-store-CcoNeQHG.js";import"./MissionLeftAgentRow-nc1Jyq3D.js";import"./page-status-DDvNdA8s.js";import"./FleetSearch-Dj7-CfNi.js";function Lt(){const{route:r}=o();if(r.view!=="ops")return null;switch(r.mode){case"mission":return t.jsx(s,{});case"agents":return t.jsx(m,{});case"plan":return t.jsx(e,{});case"lanes":return t.jsx(i,{});default:return t.jsx(p,{})}}export{Lt as OpsLeft};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as a,j as s}from"./index-CzVeWScw.js";/* empty css */import{a as k}from"./api-h5zurxmi.js";import{u as y}from"./sse-QcU9bikk.js";import{t as S}from"./time-Dhsh_2EG.js";import{u as w}from"./Provider-DSsb2gLR.js";import{F as C}from"./FleetSearch-Dj7-CfNi.js";import"./index-BWHgHrtv.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./surface-activity-B1rgWB1i.js";import"./colors-BtO5_zlx.js";import"./scoutbot-BTIErYHo.js";import"./ContextMenu-N-Z6X0Z1.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./HarnessMark-BE-YSyci.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./model-Co0zkMIc.js";import"./text-DsBWV_4k.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";const u={all:"All",claude:"Claude",codex:"Codex",openscout:"OpenScout",workspace:"Workspace",unknown:"Other"},L={active:"Active",archived:"Archived",blocked:"Blocked",completed:"Complete",draft:"Draft",unknown:"Unknown"};function b(e){const o=e.replace(/\\/g,"/").replace(/\/+$/g,""),l=o.lastIndexOf("/");return l>=0?o.slice(l+1):o}function A(e){return e.steps.length===0?"No steps":`${e.steps.filter(l=>l.status==="completed").length}/${e.steps.length} steps`}function E(e){return[e.title,e.summary,e.source,e.documentKind,e.status,e.path,e.workspaceName,e.agentName,e.tags.join(" "),e.steps.map(o=>o.text).join(" ")].filter(Boolean).join(" ").toLowerCase()}function vt(){const{route:e,navigate:o}=w(),[l,f]=a.useState(null),[i,m]=a.useState(""),[r,h]=a.useState("all"),[x,v]=a.useState(!0),p=a.useCallback(async()=>{const t=await k("/api/plan-documents").catch(()=>null);f(t),v(!1)},[]);a.useEffect(()=>{p()},[p]),y(t=>{(t.kind==="message.posted"||t.kind==="flight.updated"||t.kind==="collaboration.event.appended")&&p()});const n=l?.documents??[],j=e.view==="ops"&&e.mode==="plan"?e.planDocumentId:void 0,c=i.trim().toLowerCase(),g=a.useMemo(()=>{const t={all:n.length,claude:0,codex:0,openscout:0,workspace:0,unknown:0};for(const N of n)t[N.source]+=1;return t},[n]),d=a.useMemo(()=>n.filter(t=>r==="all"||t.source===r).filter(t=>!c||E(t).includes(c)),[n,c,r]);return s.jsxs("div",{className:"s-plan-left-nav",children:[s.jsx("div",{className:"s-left-roster-search",children:s.jsx(C,{value:i,onChange:m,placeholder:"Search plan documents...",onKeyDown:t=>{t.key==="Escape"&&(i?m(""):t.target.blur())}})}),s.jsx("div",{className:"s-plan-left-source-grid",children:["all","claude","codex","openscout","workspace"].map(t=>s.jsxs("button",{type:"button",className:`s-plan-left-source${r===t?" s-plan-left-source--active":""}`,onClick:()=>h(t),children:[s.jsx("span",{children:u[t]}),s.jsx("strong",{children:g[t]})]},t))}),s.jsx("div",{className:"s-plan-left-list",children:x&&n.length===0?s.jsx("div",{className:"s-left-roster-empty",children:"Indexing plan documents..."}):d.length===0?s.jsx("div",{className:"s-left-roster-empty",children:n.length===0?"No plan documents found":"No plans match"}):d.map(t=>s.jsxs("button",{type:"button",className:`s-plan-left-document${t.id===j?" s-plan-left-document--active":""}`,onClick:()=>o({view:"ops",mode:"plan",planDocumentId:t.id}),title:`${t.path}
|
|
2
|
+
${t.summary??""}`,children:[s.jsxs("div",{className:"s-plan-left-document-top",children:[s.jsx("span",{className:`s-plan-left-status s-plan-left-status--${t.status}`,children:L[t.status]}),s.jsx("span",{children:u[t.source]}),s.jsx("time",{children:S(t.updatedAt)})]}),s.jsx("div",{className:"s-plan-left-document-title",children:t.title}),t.summary&&s.jsx("div",{className:"s-plan-left-document-summary",children:t.summary}),s.jsxs("div",{className:"s-plan-left-document-foot",children:[s.jsx("span",{children:A(t)}),s.jsx("span",{children:b(t.path)})]})]},t.id))})]})}export{vt as OpsPlanLeft};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as l,j as e}from"./index-CzVeWScw.js";/* empty css */import{t as O}from"./time-Dhsh_2EG.js";import{u as H}from"./Provider-DSsb2gLR.js";import{S as $}from"./SpriteAvatar-BpQDpOkq.js";import{H as R}from"./HarnessMark-BE-YSyci.js";import{AgentSessions as G}from"./AgentSessions-BxWIPkWh.js";import{a as T}from"./api-h5zurxmi.js";import{u as J}from"./ContextMenu-N-Z6X0Z1.js";import{g as q,p as V,b as _}from"./agents-project-model-UYiamtrU.js";import{c as Q,e as X,f as Y,g as Z}from"./model-Co0zkMIc.js";import"./router-B-K15T7B.js";import"./synthetic-agent-routing-aduMYO7P.js";import"./terminal-sessions-C3qU8tnY.js";import"./sse-QcU9bikk.js";import"./index-BWHgHrtv.js";import"./surface-activity-B1rgWB1i.js";import"./colors-BtO5_zlx.js";import"./scoutbot-BTIErYHo.js";import"./DocumentFocusViewer-BCG2kOmd.js";import"./createLucideIcon-ClCdc3F9.js";import"./TextDocumentSurface-DRjctOIt.js";/* empty css */import"./file-text-DG-pufl1.js";import"./x-D4X_y1j_.js";import"./chevron-right-CNE6QAVr.js";import"./code-xml--LjSM4Mv.js";import"./arrow-left-_vS7itsV.js";import"./scout-voice-S5_YZ2v8.js";import"./fx-z37u1o2z.js";import"./keyboard-nav-BJnFoFDP.js";import"./MessageComposerSuggestions-Cs9u-F_3.js";import"./NewChatComposer-DXDxV2Mh.js";import"./runtime-picker-BCQD7d4K.js";import"./voice-levels-Dcr3jglk.js";import"./loader-circle-Byb9kSFx.js";import"./index-Dewd56RX.js";import"./conversation-model-CHwHZNw-.js";import"./NewChatOrigin-CnjoswTG.js";import"./chevron-down-DRCbnzyY.js";import"./search-C3bSJluv.js";import"./chunk-HRAB3GC3-CAeEKaf5.js";import"./agent-identity-BxCsXnDp.js";import"./openContent-C6XO6kr5.js";import"./clipboard-e3fSpeo7.js";import"./text-DsBWV_4k.js";const ee=30*6e4,D=a=>a==="pi"?"grok":a,K=a=>a?a.replace(/^claude-/,"").replace(/-\d{8}$/,""):null;function Xe({agents:a,fleet:d,sessionByAgentId:c,sessions:A,discovery:k,loading:C,navigate:x,selectedAgentId:S}){const{route:N,reload:p,openContextCapture:u}=H(),m=N.view==="agents-v2"?N.projectSlug:void 0,f=l.useMemo(()=>{const n=new Map;for(const b of d?.activeAsks??[]){const i=n.get(b.agentId)??[];i.push(b),n.set(b.agentId,i)}return n},[d?.activeAsks]),v=l.useMemo(()=>a.map(n=>Q(n,c.get(n.id)??null,f.get(n.id)??[])),[f,a,c]),g=l.useMemo(()=>X(k,Date.now()),[k]),h=l.useMemo(()=>Y(v,A,g),[v,A,g]),w=l.useMemo(()=>h.find(n=>n.slice.slug===m)??h[0]??null,[h,m]),r=w?.slice.slug,M={selectAgent:n=>x({view:"agents-v2",agentId:n.agent.id,...r?{projectSlug:r}:{}}),openAgentPage:n=>x({view:"agents-v2",agentId:n.agent.id,tab:"profile"}),startSession:n=>u({intent:"new-task",projectPath:n.agent.projectRoot??n.agent.cwd??void 0}),openSession:n=>x(n),configureAgent:n=>x({view:"agents-v2",agentId:n.agent.id,tab:"config"}),restartAgent:n=>{T(`/api/agents/${encodeURIComponent(n.agent.id)}/config`,{method:"POST",body:JSON.stringify({restart:!0})}).catch(()=>{})},stopAgent:n=>{T(`/api/agents/${encodeURIComponent(n.agent.id)}/interrupt`,{method:"POST",body:JSON.stringify({})}).catch(()=>{})},archiveAgent:n=>{T(`/api/agents/${encodeURIComponent(n.agent.id)}/archive`,{method:"POST",body:JSON.stringify({archived:!0})}).then(()=>p()).catch(()=>{})}};return!w&&C?e.jsx("div",{className:"s-aproj","aria-busy":"true",children:e.jsx("div",{className:"ap-loading",role:"status","aria-label":"Loading agents",children:Array.from({length:7},(n,b)=>e.jsx("span",{"aria-hidden":"true"},b))})}):w?e.jsx("div",{className:"s-aproj",children:e.jsx(te,{project:w,selectedAgentId:S,gestures:M,sessions:A})}):e.jsx("div",{className:"s-aproj",children:e.jsx("div",{className:"ap-empty",children:"No agents discovered yet — they appear here as harnesses register and work."})})}function se(){return e.jsxs("svg",{width:"13",height:"13",viewBox:"0 0 16 16",fill:"none","aria-hidden":!0,children:[e.jsx("circle",{cx:"7",cy:"7",r:"4.2",stroke:"currentColor",strokeWidth:"1.3"}),e.jsx("path",{d:"m10.5 10.5 3 3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]})}function ae({tone:a}){return a==="idle"?null:e.jsx("span",{className:"ap-dot","data-tone":a,"aria-hidden":!0})}function ne({g:a,gestures:d,sessions:c,selected:A,cursor:k,rowRef:C}){const x=J(),S=Date.now()-a.lastActivityAt<ee,N=a.needs?"needs":S?"live":"idle",p=a.nodes[0];if(!p)return null;const u=p.row.agent.handle?.trim()||a.name,m=a.branches.length>0?a.branches:["main"],f=m.length>1,v=f?`${m.length} branches`:m[0],g=[...new Set(a.nodes.map(r=>r.row.agent.model).filter(r=>!!r))],h=g.length>1,w=[{kind:"action",label:"Configure…",onSelect:()=>d.configureAgent(p.row)},{kind:"action",label:"Restart",onSelect:()=>d.restartAgent(p.row)},{kind:"separator"},{kind:"action",label:"Stop",onSelect:()=>d.stopAgent(p.row)},{kind:"action",label:"Archive",onSelect:()=>d.archiveAgent(p.row)}];return e.jsxs("div",{ref:C,tabIndex:-1,className:"ap-row","data-tone":N,"data-selected":A||void 0,"data-cursor":k||void 0,children:[e.jsxs("div",{className:"ap-rowMain",onClick:()=>d.selectAgent(p.row),children:[e.jsxs("div",{className:"ap-rowBody",children:[e.jsxs("div",{className:"ap-rowTop",children:[e.jsx(ae,{tone:N}),e.jsxs("span",{className:"ap-rowName","data-idle":N==="idle"||void 0,children:[e.jsx("span",{className:"ap-sigil","aria-hidden":!0,children:"@"}),u]}),e.jsx("span",{className:"ap-rowMark","aria-hidden":!0,children:e.jsx(R,{harness:D(a.harness),size:11})}),a.needs?e.jsx("span",{className:"ap-needsWord",children:"needs you"}):N==="live"?e.jsx("span",{className:"ap-rowState",children:"working"}):null]}),e.jsxs("div",{className:"ap-rowMeta",children:[e.jsx("span",{className:"ap-rowBranch","data-dim":!0,title:f?m.join(" · "):void 0,children:v}),h?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"ap-rowDivider","aria-hidden":!0}),e.jsxs("span",{className:"ap-rowDim",title:g.join(" · "),children:[g.length," models"]})]}):null,a.sessionCount?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"ap-rowDivider","aria-hidden":!0}),e.jsxs("span",{className:"ap-rowDim",children:[a.sessionCount," session",a.sessionCount===1?"":"s"]})]}):null]})]}),e.jsxs("div",{className:"ap-rowTailWrap",children:[e.jsxs("div",{className:"ap-rowTail",children:[e.jsxs("div",{className:"ap-tailMeta","aria-hidden":N==="needs"||void 0,children:[e.jsx("span",{className:"ap-rowAgo",children:a.lastActivityAt?O(a.lastActivityAt):"—"}),!h&&K(a.model)?e.jsx("span",{className:"ap-rowModel",children:K(a.model)}):null]}),e.jsxs("div",{className:"ap-rowActions",children:[e.jsx("button",{type:"button",className:"ap-act ap-actPrimary",onClick:r=>{r.stopPropagation(),d.openAgentPage(p.row)},children:"Open ↗"}),e.jsx("button",{type:"button",className:"ap-act",onClick:r=>{r.stopPropagation(),d.startSession(p.row)},children:"+ Session"})]})]}),e.jsx("button",{type:"button",className:"ap-rowMore","aria-label":"Agent actions",title:"Configure · restart · stop",onClick:r=>{r.stopPropagation(),x(r,w)},children:"⋯"})]})]}),e.jsx(G,{agentIds:a.nodes.map(r=>r.row.agent.id),sessions:c})]})}function te({project:a,selectedAgentId:d,gestures:c,sessions:A}){const[k,C]=l.useState(""),[x,S]=l.useState(null),[N,p]=l.useState(!1),[u,m]=l.useState(-1),f=l.useRef(null),v=l.useRef(new Map),g=l.useMemo(()=>q(a),[a]),{primary:h,ephemeral:w}=l.useMemo(()=>V(g),[g]),r=l.useMemo(()=>_(a),[a]),M=l.useMemo(()=>[...new Set(h.map(s=>D(s.harness)))],[h]),n=k.trim().toLowerCase(),b=s=>(!x||D(s.harness)===x)&&(!n||s.name.toLowerCase().includes(n)||s.branches.some(t=>t.toLowerCase().includes(n))||s.harness.includes(n)),i=h.filter(b),I=w.filter(b),E=!!(n||x),o=i.find(s=>s.needs)??i[0],U=i.some(s=>s.needs),B=h.length<=1;Z(a);const W=g.reduce((s,t)=>s+t.sessionCount,0),z=s=>!!(d&&s.nodes.some(t=>t.row.agent.id===d));return l.useEffect(()=>{function s(t){const y=document.activeElement,L=!!y&&(y.tagName==="INPUT"||y.tagName==="TEXTAREA"||y.isContentEditable);if(t.key.toLowerCase()==="k"&&(t.metaKey||t.ctrlKey)||t.key==="/"&&!L){t.preventDefault(),f.current?.focus(),f.current?.select();return}if(t.key==="Escape"){L&&y?.blur();return}if(L)return;const F=i.length;if(F){if(t.key==="ArrowDown"||t.key==="j")t.preventDefault(),m(j=>j<0?0:Math.min(F-1,j+1));else if(t.key==="ArrowUp"||t.key==="k")t.preventDefault(),m(j=>j<0?0:Math.max(0,j-1));else if(t.key==="Enter"&&(t.metaKey||t.ctrlKey)){const j=i.find(P=>P.needs)??i[0];j&&(t.preventDefault(),m(i.indexOf(j)),c.selectAgent(j.nodes[0].row))}else if(t.key==="Enter"){const j=u<0?0:u,P=i[j];P&&(t.preventDefault(),m(j),c.selectAgent(P.nodes[0].row))}}}return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[i,u,c]),l.useEffect(()=>{if(!(u<0)){if(u>=i.length){m(i.length-1);return}v.current.get(i[u]?.name??"")?.scrollIntoView({block:"nearest"})}},[u,i]),e.jsx("div",{className:"ap-view",children:e.jsxs("div",{className:"ap-content",children:[e.jsxs("header",{className:"ap-head",children:[e.jsx($,{name:a.slice.title,size:56,tile:!0}),e.jsxs("div",{className:"ap-headIdent",children:[e.jsx("div",{className:"ap-headTop",children:e.jsxs("h1",{className:"ap-headName",children:[e.jsx("span",{className:"ap-sigil","aria-hidden":!0,children:"/"}),a.slice.title]})}),a.slice.root?e.jsx("span",{className:"ap-headRoot",children:a.slice.root}):null]}),e.jsx("div",{className:"ap-headActions",children:e.jsx("button",{type:"button",className:"ap-headCta",disabled:!o,onClick:()=>o&&c.startSession(o.nodes[0].row),children:"+ New agent"})})]}),e.jsxs("div",{className:"ap-digest",children:[e.jsxs("span",{className:"ap-stat",children:[e.jsx("span",{className:"ap-statNum",children:h.length}),e.jsx("span",{className:"ap-statLbl",children:h.length===1?"agent":"agents"})]}),e.jsxs("span",{className:"ap-stat",children:[e.jsx("span",{className:"ap-statNum",children:W}),e.jsx("span",{className:"ap-statLbl",children:W===1?"session":"sessions"})]}),r.length>0?e.jsxs("span",{className:"ap-stat",children:[e.jsx("span",{className:"ap-statNum",children:r.length}),e.jsx("span",{className:"ap-statLbl",children:"in flight"})]}):null,e.jsx("span",{className:"ap-statMarks",children:M.map(s=>e.jsx("span",{title:s,"aria-hidden":!0,children:e.jsx(R,{harness:s,size:12})},s))})]}),o&&!E&&!B?e.jsxs("div",{className:"ap-resume","data-tone":o.needs?"needs":"live","aria-live":"polite",children:[e.jsx("span",{className:"ap-dot","data-tone":o.needs?"needs":"live","aria-hidden":!0}),e.jsx("span",{className:"ap-resumeLbl",children:o.needs?"Waiting on you":"Most recent"}),e.jsxs("span",{className:"ap-resumeWho",children:[e.jsx("span",{className:"ap-sigil","aria-hidden":!0,children:"@"}),o.nodes[0].row.agent.handle?.trim()||o.name]}),e.jsxs("span",{className:"ap-resumeMeta",children:[o.branches[0]??"main"," · ",o.lastActivityAt?O(o.lastActivityAt):"—"]}),e.jsxs("span",{className:"ap-resumeActions",children:[e.jsx("button",{type:"button",className:"ap-linkAccent",onClick:()=>c.selectAgent(o.nodes[0].row),children:o.needs?"Continue":"Resume"}),e.jsx("button",{type:"button",className:"ap-link",onClick:()=>c.openAgentPage(o.nodes[0].row),children:"Open ↗"})]})]}):null,B?null:e.jsxs("div",{className:"ap-find",children:[e.jsx("span",{className:"ap-findIco","aria-hidden":!0,children:e.jsx(se,{})}),e.jsx("input",{ref:f,className:"ap-findInput",placeholder:"Find an agent, branch, or harness… (⌘K)",value:k,onChange:s=>C(s.target.value)}),e.jsx("div",{className:"ap-findFilters",children:M.map(s=>e.jsxs("button",{type:"button",className:"ap-filter","data-on":x===s||void 0,onClick:()=>S(t=>t===s?null:s),children:[e.jsx(R,{harness:s,size:11}),s.charAt(0).toUpperCase()+s.slice(1)]},s))})]}),e.jsxs("div",{className:"ap-main",children:[e.jsxs("div",{className:"ap-sectionHead",children:[e.jsx("span",{className:"ap-sectionTitle",children:"Agents"}),e.jsxs("span",{className:"ap-sectionMeta",children:[i.length," shown",E?" · filtered":""]}),e.jsxs("span",{className:"ap-kbdHint","aria-hidden":!0,children:["↑↓ move · ↵ open",U?" · ⌘↵ needs":""]})]}),e.jsxs("div",{className:"ap-roster",children:[i.map((s,t)=>e.jsx(ne,{g:s,gestures:c,sessions:A,selected:z(s),cursor:u===t,rowRef:y=>{y?v.current.set(s.name,y):v.current.delete(s.name)}},s.name)),i.length===0?e.jsx("div",{className:"ap-empty",children:E?"No agents match.":I.length?"No primary agents — workflow & clone agents are in the fold below.":"No agents in this project yet."}):null]}),I.length?e.jsxs("div",{className:"ap-ephBlock",children:[e.jsxs("button",{type:"button",className:"ap-ephToggle",onClick:()=>p(s=>!s),children:[e.jsx("span",{className:"ap-ephCount",children:I.length})," ephemeral · workflow & clone agents",e.jsx("span",{className:"ap-ephCaret",children:N?"▴":"▾"})]}),N?e.jsx("div",{className:"ap-ephList",children:I.map(s=>e.jsxs("button",{type:"button",className:"ap-ephRow",onClick:()=>c.openAgentPage(s.nodes[0].row),children:[e.jsx("span",{className:"ap-ephMark","aria-hidden":!0,children:e.jsx(R,{harness:D(s.harness),size:10})}),e.jsx("span",{className:"ap-ephName",children:s.name}),e.jsx("span",{className:"ap-ephBranch",children:s.branches[0]??"main"}),e.jsx("span",{className:"ap-ephAgo",children:s.lastActivityAt?O(s.lastActivityAt):"—"})]},s.name))}):null]}):null,e.jsx("button",{type:"button",className:"ap-newAgent",disabled:!o,onClick:()=>o&&c.startSession(o.nodes[0].row),children:"+ New agent on this project"})]})]})})}export{Xe as AgentsLibrary};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c}from"./createLucideIcon-
|
|
1
|
+
import{c}from"./createLucideIcon-ClCdc3F9.js";const e=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],a=c("loader-circle",e);export{a as L};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r}from"./index-
|
|
1
|
+
import{r}from"./index-CzVeWScw.js";import{a as d}from"./api-h5zurxmi.js";import{u as f}from"./Provider-DSsb2gLR.js";function p(e){if(!e)return null;const s=e.split("/").filter(Boolean);return s[s.length-1]??null}function m(e,s){if(!e)return[];const l=new Set;for(const t of s)t.cwd&&l.add(t.cwd),t.projectRoot&&l.add(t.projectRoot);const o=new Map;for(const t of e.transcripts){if(!t.cwd)continue;const n=o.get(t.cwd),a=t.lastEventAt??t.mtimeMs,c=n?.lastEventAt??n?.mtimeMs??0;(!n||a>c)&&o.set(t.cwd,t)}const i=[];for(const t of e.processes){if(t.harness==="scout-managed"||t.cwd&&l.has(t.cwd))continue;const n=t.cwd?o.get(t.cwd):void 0,a=n?.project??p(t.cwd)??null,c=n?.lastEventAt??n?.mtimeMs??e.generatedAt,u=n?.sessionId??null;i.push({id:`harness:${t.source}:${t.pid}`,definitionId:`harness:${t.source}:${t.pid}`,name:t.source,handle:null,agentClass:"organic",harness:t.source,state:"working",projectRoot:t.cwd,cwd:t.cwd,updatedAt:c,createdAt:null,transport:null,selector:null,defaultSelector:null,nodeQualifier:null,workspaceQualifier:null,wakePolicy:null,capabilities:[],project:a,branch:null,role:null,model:null,harnessSessionId:u,terminalSurface:null,harnessLogPath:n?.transcriptPath??null,conversationId:u??`harness:${t.pid}`,homeNodeId:null,homeNodeName:null,ownerId:null,ownerName:null,ownerHandle:null,staleLocalRegistration:!1,retiredFromFleet:!1,replacedByAgentId:null})}return i}function A(){const{agents:e}=f(),[s,l]=r.useState(null);r.useEffect(()=>{let t=!1;const n=async()=>{const c=await d("/api/tail/discover").catch(()=>null);t||l(c)};n();const a=setInterval(()=>{n()},1e4);return()=>{t=!0,clearInterval(a)}},[]);const o=r.useMemo(()=>m(s,e),[s,e]);return{agents:r.useMemo(()=>[...e,...o],[e,o]),scoutAgents:e,organicAgents:o,discovery:s}}export{A as u};
|