@microvac/ui 0.1.0-rc.14 → 0.1.0-rc.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{ActiveAgentsPanel-C9AP9hJu.js → ActiveAgentsPanel-BEx06tMt.js} +1 -1
- package/dist/assets/{AdapterManager-CmxTUKJH.js → AdapterManager-3kEEQWFJ.js} +1 -1
- package/dist/assets/{AdvancedToolsRoute-CXsQnTei.js → AdvancedToolsRoute-CgS6B-oh.js} +1 -1
- package/dist/assets/{AgentActionButtons-DWq2OuVK.js → AgentActionButtons-Cz3jCEd7.js} +1 -1
- package/dist/assets/{AgentAdvancedTab-dhBDxF-H.js → AgentAdvancedTab-BG6ZIAuN.js} +1 -1
- package/dist/assets/{AgentBulkSettingsSheet-DYT4ovDg.js → AgentBulkSettingsSheet-BrrbvspS.js} +1 -1
- package/dist/assets/{AgentChat-r0TPOfPK.js → AgentChat-Dw9iXD6H.js} +1 -1
- package/dist/assets/{AgentDetailPage-Bc_okBuS.js → AgentDetailPage-CuVIHv_q.js} +3 -3
- package/dist/assets/{AgentIdentityChip-CB2NBXkZ.js → AgentIdentityChip-BrVCcuHQ.js} +1 -1
- package/dist/assets/{AgentRosterFilters-b7qMLv8-.js → AgentRosterFilters-GQ2bdXfW.js} +2 -2
- package/dist/assets/{Agents-BsvXy3pZ.js → Agents-clrVQnvc.js} +2 -2
- package/dist/assets/{Agents.production-BeOZmzaF.js → Agents.production-DTopo7XB.js} +2 -2
- package/dist/assets/{AnimatedDialogContent-CWshmxP2.js → AnimatedDialogContent-CDLfw-dJ.js} +1 -1
- package/dist/assets/{AppDetail-DbqENTF_.js → AppDetail-BcWBg5yW.js} +1 -1
- package/dist/assets/{AppNotConnected-BhnCqL0F.js → AppNotConnected-NgfyHZ4L.js} +1 -1
- package/dist/assets/{ApprovalDetail-B2KiYLTj.js → ApprovalDetail-Dm_1V4tC.js} +1 -1
- package/dist/assets/{Approvals-j-wRmqKj.js → Approvals-i5AB3JPj.js} +1 -1
- package/dist/assets/{AppsConnect-CcPVEZ0C.js → AppsConnect-D660Tpuo.js} +1 -1
- package/dist/assets/{AppsReview-B8eWvKkS.js → AppsReview-DdTqOisY.js} +1 -1
- package/dist/assets/{ArtifactEmptyGraphic-5mdkS5jj.js → ArtifactEmptyGraphic-DzxCruYA.js} +1 -1
- package/dist/assets/{Artifacts-Bz7Oo6VX.js → Artifacts-CkXBz6nh.js} +1 -1
- package/dist/assets/{AssigneePickerInner-DdpF7hck.js → AssigneePickerInner-BNjyABBe.js} +1 -1
- package/dist/assets/{AssistantConnection-BpaaJDc_.js → AssistantConnection-CNF6mDmO.js} +1 -1
- package/dist/assets/{AttentionInlineVerbs-DlPQVCO-.js → AttentionInlineVerbs-BiyZ1ekZ.js} +1 -1
- package/dist/assets/{AttentionQueueRow-BC6ezctS.js → AttentionQueueRow-Bh0dKHpF.js} +1 -1
- package/dist/assets/{AuditHub-BVP7LKL9.js → AuditHub-BK848cb4.js} +1 -1
- package/dist/assets/{AuditRuns-DqizHgX1.js → AuditRuns-CUdlbP7S.js} +1 -1
- package/dist/assets/{Auth-DOF0snjp.js → Auth-DDqxm5gD.js} +1 -1
- package/dist/assets/{BoardChat-BYAbDtfd.js → BoardChat-fvKqk0R7.js} +1 -1
- package/dist/assets/{BoardClaim-7y41Pr8e.js → BoardClaim-BEC5BZfz.js} +1 -1
- package/dist/assets/{BootstrapSetupUxLab-BftH1vOv.js → BootstrapSetupUxLab-CXzErrin.js} +1 -1
- package/dist/assets/{Browse-Ck01W1Yl.js → Browse-DoovSMuF.js} +1 -1
- package/dist/assets/{BudgetPolicyCard-CKhrzfgy.js → BudgetPolicyCard-BYMlczCq.js} +1 -1
- package/dist/assets/{CaseDetail-qlXKJ66D.js → CaseDetail-UMAcSH_x.js} +1 -1
- package/dist/assets/{CaseStatus-B3RiZVDH.js → CaseStatus-BI0aMl9l.js} +1 -1
- package/dist/assets/{Cases-CFV3V-5X.js → Cases-CMTkGghU.js} +1 -1
- package/dist/assets/{ChatEndpointDetail-7Hi5TJNt.js → ChatEndpointDetail-CocNEInH.js} +1 -1
- package/dist/assets/{ChatEndpointSetup-CtwgH6sg.js → ChatEndpointSetup-Cyi2tI9K.js} +1 -1
- package/dist/assets/{ChatIdentityConfirm-CXjksBwX.js → ChatIdentityConfirm-Ba3JuTX1.js} +1 -1
- package/dist/assets/{CliAuth-KVjrGMfZ.js → CliAuth-D2jnueGH.js} +1 -1
- package/dist/assets/{Companies-oeJem3De.js → Companies-K75I9dJs.js} +1 -1
- package/dist/assets/{CompanyAccess-vWT6G-n_.js → CompanyAccess-Cw6nLUhE.js} +1 -1
- package/dist/assets/{CompanyActivity-zOzzeN1B.js → CompanyActivity-BsgmVpWS.js} +1 -1
- package/dist/assets/CompanyActivity.production-w-KGxvo6.js +1 -0
- package/dist/assets/{CompanyConnections-llSEaVa2.js → CompanyConnections-yRPYSdm7.js} +1 -1
- package/dist/assets/{CompanyEnvironments-DNyyGC_S.js → CompanyEnvironments-BA7kWdOJ.js} +1 -1
- package/dist/assets/{CompanyExport-CFa-F8Es.js → CompanyExport-DfsK4b9c.js} +1 -1
- package/dist/assets/{CompanyImport-DG6qwQ8F.js → CompanyImport-DJHAsmSF.js} +1 -1
- package/dist/assets/{CompanySettings-Dv5Z3ZQi.js → CompanySettings-DwzHGXec.js} +1 -1
- package/dist/assets/{CompanySettingsPluginPage-CZk1d_0d.js → CompanySettingsPluginPage-Bpa81PF3.js} +1 -1
- package/dist/assets/{CompanySkills-CdzWhJfQ.js → CompanySkills-eTqgbqQN.js} +1 -1
- package/dist/assets/{CompanySkills.production-IoCRW5FQ.js → CompanySkills.production-CQSWfH0r.js} +1 -1
- package/dist/assets/{ConfigureBuiltInAgentModal-BwW7XQ1O.js → ConfigureBuiltInAgentModal-DgeD7t_i.js} +1 -1
- package/dist/assets/{CopyableGatewayUrl-PTn061ft.js → CopyableGatewayUrl-B6K3rOal.js} +1 -1
- package/dist/assets/{CordisPluginSettings-C_BeeGEc.js → CordisPluginSettings-DD3AnD2G.js} +1 -1
- package/dist/assets/{Costs-DhuNxwSj.js → Costs-orBM8T-a.js} +1 -1
- package/dist/assets/{CrossIssueCollaborationUxLab-ZaAXq46r.js → CrossIssueCollaborationUxLab-Bv9y9-NE.js} +1 -1
- package/dist/assets/{Dashboard-BaDnqiKo.js → Dashboard-CrSBNKX1.js} +1 -1
- package/dist/assets/{DashboardLive-D-Ed7osd.js → DashboardLive-Cg8C9RiS.js} +1 -1
- package/dist/assets/{DecisionDateChips-D3pl_mLn.js → DecisionDateChips-BLZKZH71.js} +1 -1
- package/dist/assets/{DecisionHistoryPanel-D5MzyrOh.js → DecisionHistoryPanel-yK-CP7Qg.js} +1 -1
- package/dist/assets/{DecisionQueuePage-D3UZ9oRk.js → DecisionQueuePage-BKXbERai.js} +1 -1
- package/dist/assets/{DesignGuide-COTo7ICj.js → DesignGuide-2FswNsXz.js} +1 -1
- package/dist/assets/{DesignSandboxTaskThread-CMeCSQid.js → DesignSandboxTaskThread-CGU--FXR.js} +1 -1
- package/dist/assets/{EmailConnectionAccess-kCL7obSr.js → EmailConnectionAccess-CZ5QRKyg.js} +1 -1
- package/dist/assets/{EmailEndpointSetup-BGrksR_u.js → EmailEndpointSetup-BI2vsd8Y.js} +1 -1
- package/dist/assets/{EnforcementBanner-_Eb_nK3M.js → EnforcementBanner-B-iX466h.js} +1 -1
- package/dist/assets/{EntityRow-gpsOgEtu.js → EntityRow-BsICt6pd.js} +1 -1
- package/dist/assets/{ExecutionWorkspaceDetail-DwGkH6d3.js → ExecutionWorkspaceDetail-CMqR9puh.js} +1 -1
- package/dist/assets/{ExternalAgentInviteDialog-CGid6pM9.js → ExternalAgentInviteDialog-De30ZrLP.js} +1 -1
- package/dist/assets/{FilterBar-1D-VhrvG.js → FilterBar-rCmsTtG4.js} +1 -1
- package/dist/assets/{FolderControls-CQ6kef3c.js → FolderControls-CmnB7Ap-.js} +1 -1
- package/dist/assets/{GatewayDetail-CCqekM1J.js → GatewayDetail-Duw9pJ10.js} +1 -1
- package/dist/assets/{GatewaysList-nFsRcszh.js → GatewaysList-BBhVGhRq.js} +1 -1
- package/dist/assets/{GitHubConnectionRecovery-B9sFWJup.js → GitHubConnectionRecovery-6VshLoNV.js} +1 -1
- package/dist/assets/{GoalDetail-BQ8y55P-.js → GoalDetail-CahntjlI.js} +1 -1
- package/dist/assets/{GoalTree-laRjXp0P.js → GoalTree-CU4GBFCh.js} +1 -1
- package/dist/assets/{Goals-Cm14EaeP.js → Goals-CzM2NDFR.js} +1 -1
- package/dist/assets/{InstanceAccess-DxQ-Akt_.js → InstanceAccess-CZzkE65W.js} +1 -1
- package/dist/assets/{InstanceExperimentalSettings-BxwqbXNw.js → InstanceExperimentalSettings-DWumKtOK.js} +1 -1
- package/dist/assets/{InviteLanding-Cf0L_u6s.js → InviteLanding-BIy2z50u.js} +1 -1
- package/dist/assets/{IssueChatLongThreadPerf-BfsF6FdF.js → IssueChatLongThreadPerf-D4DJvdOG.js} +1 -1
- package/dist/assets/{JoinRequestQueue-BXCdTFG_.js → JoinRequestQueue-C5rauGYm.js} +1 -1
- package/dist/assets/{Layout.production-CqzU0qMi.js → Layout.production-BSDWnupa.js} +1 -1
- package/dist/assets/{McpConnect-COWnZ9Eb.js → McpConnect-BN8ST0RS.js} +1 -1
- package/dist/assets/{MembershipAction-C9i9Sdmi.js → MembershipAction-DTjhGn-L.js} +1 -1
- package/dist/assets/{MetricCard-Bwnt3_p3.js → MetricCard-CeL9Pdn5.js} +1 -1
- package/dist/assets/{MissingPluginTabPlaceholder-B0Zxv1Kx.js → MissingPluginTabPlaceholder-CbQiSVnZ.js} +1 -1
- package/dist/assets/{NewAgent-BIlJ5Dyt.js → NewAgent-BszrNpQk.js} +1 -1
- package/dist/assets/{NewAgentDialog-CJdMxxYL.js → NewAgentDialog-U9qAcTzc.js} +1 -1
- package/dist/assets/{NewGoalDialog-B8izfKLm.js → NewGoalDialog-DqKbk4-i.js} +1 -1
- package/dist/assets/{NewProjectDialog-DXqjTYFK.js → NewProjectDialog-DrlUAF-N.js} +1 -1
- package/dist/assets/{OnboardingPrimitives-DHYBqn_0.js → OnboardingPrimitives-BkgPF4Mu.js} +1 -1
- package/dist/assets/{OnboardingWizard-DqSfZ13V.js → OnboardingWizard-CMBMcuXv.js} +1 -1
- package/dist/assets/{OrgChart.production-DrSFUf7i.js → OrgChart.production-BLczTjRj.js} +1 -1
- package/dist/assets/{PaperclipCloudOAuthHandoff-jPUvjJ8q.js → PaperclipCloudOAuthHandoff-BTtF8UPD.js} +1 -1
- package/dist/assets/{PluginManager-h3LFPaUq.js → PluginManager-CCcqlfgK.js} +1 -1
- package/dist/assets/{PluginPage-E5Im4454.js → PluginPage-B1empV69.js} +1 -1
- package/dist/assets/{PluginSettings-BBO0jAgo.js → PluginSettings-DtopaRqR.js} +1 -1
- package/dist/assets/{ProfileDetailRoute-CQBD7fms.js → ProfileDetailRoute-BqvVpBZi.js} +1 -1
- package/dist/assets/{ProfileSettings-BwnVEHLp.js → ProfileSettings-5__tVfGi.js} +1 -1
- package/dist/assets/{ProfileWizardRoute-By_SC6Gn.js → ProfileWizardRoute-vt-MRLuD.js} +1 -1
- package/dist/assets/{ProjectDetail-CbiwFBAE.js → ProjectDetail-DJ4zjube.js} +1 -1
- package/dist/assets/{ProjectRepositoryInput-DZF9bX4E.js → ProjectRepositoryInput-BJcnj3At.js} +1 -1
- package/dist/assets/{ProjectWorkspaceDetail-DPsl_4bD.js → ProjectWorkspaceDetail-DEAO3q6v.js} +1 -1
- package/dist/assets/{ProjectWorkspacesContent-COH4dOWK.js → ProjectWorkspacesContent-CZvO7p0i.js} +1 -1
- package/dist/assets/{Projects-Ch9Qu7sn.js → Projects-Dm7-zXUH.js} +1 -1
- package/dist/assets/{QuotaBar-DIFOT9Uh.js → QuotaBar-Drp3CaxX.js} +1 -1
- package/dist/assets/{RepositoryEditor-DHB1bqId.js → RepositoryEditor-BT_VAkJu.js} +1 -1
- package/dist/assets/{Responsibilities-C5O0JXXG.js → Responsibilities-DbUEtGZu.js} +1 -1
- package/dist/assets/{ResponsibilityDetail-D6NpZpkm.js → ResponsibilityDetail--S8_GOkb.js} +1 -1
- package/dist/assets/{ResponsibleUserDenialUxLab-CFrIWYwe.js → ResponsibleUserDenialUxLab-1PB3JNG0.js} +1 -1
- package/dist/assets/{ReviewQueueCard-BPC4Lm67.js → ReviewQueueCard-B8w9aXKU.js} +1 -1
- package/dist/assets/{RoutineAuditActivity-sKyzMajz.js → RoutineAuditActivity-BCo7pYe5.js} +1 -1
- package/dist/assets/{RoutineDetail-CG8HF5fp.js → RoutineDetail-C9Dwn5G9.js} +1 -1
- package/dist/assets/{RoutineRunVariablesDialog-CKh3CmLD.js → RoutineRunVariablesDialog-Baomcbe3.js} +1 -1
- package/dist/assets/{Routines-tF2qfUKo.js → Routines-Dkv4gJno.js} +1 -1
- package/dist/assets/{Routines.production-BTyj1Ljr.js → Routines.production-Cs2Y-lpt.js} +1 -1
- package/dist/assets/{RoutinesToolbar-CvUFVCGN.js → RoutinesToolbar-BNKfCrTo.js} +1 -1
- package/dist/assets/{Search-Z9D0NuS1.js → Search-CVx4cl2o.js} +1 -1
- package/dist/assets/{Secrets-DgmbLOJK.js → Secrets-C2qv2HKZ.js} +1 -1
- package/dist/assets/{SkillBinaryFile-F3_9qcaM.js → SkillBinaryFile-DDkhLlfC.js} +1 -1
- package/dist/assets/{SkillCardIcon-CXHUCMej.js → SkillCardIcon-Cp_hws0N.js} +1 -1
- package/dist/assets/{SkillFolderTree-CB3lrTIE.js → SkillFolderTree-Cv0CmfYx.js} +1 -1
- package/dist/assets/{SkillSourceTree-BbuciCo6.js → SkillSourceTree-DmjlUswf.js} +1 -1
- package/dist/assets/{SkillSources-Dlo6Cew3.js → SkillSources-nmlYypUU.js} +1 -1
- package/dist/assets/{SkillStudio-ZO-Nf7eI.js → SkillStudio-BK3y_3zr.js} +1 -1
- package/dist/assets/{SkillsNavigationTabs-B9Iqnlqt.js → SkillsNavigationTabs-DRwMP1eu.js} +1 -1
- package/dist/assets/{SpekoPhoneCallback-C4VnMiZh.js → SpekoPhoneCallback-Cqi7AIyH.js} +1 -1
- package/dist/assets/{SpekoProviderSetup-I4evPZb3.js → SpekoProviderSetup-CJI4oXk5.js} +1 -1
- package/dist/assets/{StatusCards-D0MVzbsw.js → StatusCards-DKyyY81S.js} +1 -1
- package/dist/assets/{SummarySlotCard-DUXgZPxG.js → SummarySlotCard-f3RomdZS.js} +1 -1
- package/dist/assets/{TailscaleConnector-CMhT73gj.js → TailscaleConnector-yQWLR1Ra.js} +1 -1
- package/dist/assets/{TaskChatLab-D9-KAE-7.js → TaskChatLab-Dsr7eyj4.js} +1 -1
- package/dist/assets/{TaskSummaryList-CUxieFNe.js → TaskSummaryList-eFDfK_QH.js} +1 -1
- package/dist/assets/{Timeline-BNMoRbtK.js → Timeline-BWA9dyk6.js} +1 -1
- package/dist/assets/{ToolsAdminGate-CEr0zy2T.js → ToolsAdminGate-DpBg30hQ.js} +1 -1
- package/dist/assets/{TrustPresetSection-B9YXZtkh.js → TrustPresetSection-DtWjK9Kp.js} +1 -1
- package/dist/assets/{UserProfile-D-tnW96X.js → UserProfile-C66UI5xx.js} +1 -1
- package/dist/assets/{WebhookUrlWarning-Ba_DixKh.js → WebhookUrlWarning-CDygVnDH.js} +1 -1
- package/dist/assets/{WhatNeedsMe-B-Jzj8_M.js → WhatNeedsMe-BQ82RHus.js} +1 -1
- package/dist/assets/{Workspaces-BqhDI_Bl.js → Workspaces-DrjJes30.js} +1 -1
- package/dist/assets/{abnfDiagram-YUKMZFIV-Bn9P-nUW.js → abnfDiagram-YUKMZFIV-Crkksu2D.js} +1 -1
- package/dist/assets/{architecture-WOLXFQ4H-V1ldsZlt.js → architecture-WOLXFQ4H-bHU8FW0c.js} +1 -1
- package/dist/assets/{architectureDiagram-47P4ROYG-BkYxt-Gc.js → architectureDiagram-47P4ROYG-Bj5Styf9.js} +1 -1
- package/dist/assets/{arrow-down-left-o81ENfeW.js → arrow-down-left-Ck9VQyqQ.js} +1 -1
- package/dist/assets/{blockDiagram-E7TT5TSB-BO7pPYbp.js → blockDiagram-E7TT5TSB-OeHpNCQ-.js} +1 -1
- package/dist/assets/{budgets-0Dw6TH1A.js → budgets-CAWPqcn4.js} +1 -1
- package/dist/assets/{building-complex-DciZTnys.js → building-complex-Dxiyk_pH.js} +1 -1
- package/dist/assets/{c4Diagram-CRA5TL53-D4EpmmzV.js → c4Diagram-CRA5TL53-QbK5p76P.js} +1 -1
- package/dist/assets/channel-BSmZkKA8.js +1 -0
- package/dist/assets/{chat-channels-DWyry-9M.js → chat-channels-CzTZV2fr.js} +1 -1
- package/dist/assets/{chunk-2BW5OAIV-DFXIyCJy.js → chunk-2BW5OAIV-Ckr4HfBO.js} +1 -1
- package/dist/assets/{chunk-3YJQHVM4-Dj5wEKIw.js → chunk-3YJQHVM4-C_uoPpLR.js} +1 -1
- package/dist/assets/{chunk-4EA7E6EY-5XiUVgzK.js → chunk-4EA7E6EY-BeMEfIRS.js} +1 -1
- package/dist/assets/{chunk-7TKQ45FW-D0opKcsy.js → chunk-7TKQ45FW-DiwqWHvN.js} +1 -1
- package/dist/assets/{chunk-AW2ZBBNX-DnjsTe04.js → chunk-AW2ZBBNX-Cf57K3PO.js} +1 -1
- package/dist/assets/{chunk-DBDB3WZW-DNqSQPZ0.js → chunk-DBDB3WZW-B2qouVQO.js} +1 -1
- package/dist/assets/{chunk-E2ZNV5FY-cjSf_BTz.js → chunk-E2ZNV5FY-DG8wQ_NS.js} +1 -1
- package/dist/assets/{chunk-EU5HNXII-CZYBiaSw.js → chunk-EU5HNXII-cxRrXRGV.js} +1 -1
- package/dist/assets/{chunk-FVRAUYC3-DSc0-wJA.js → chunk-FVRAUYC3-Dizswk0V.js} +1 -1
- package/dist/assets/{chunk-HJ2JQQFS-MXK0gYSP.js → chunk-HJ2JQQFS-DL4lnpSv.js} +1 -1
- package/dist/assets/{chunk-HTAEGDNF-BjDZm_5k.js → chunk-HTAEGDNF-Zxjdb6kj.js} +1 -1
- package/dist/assets/{chunk-KQW6MTUR-Bfj0tDmO.js → chunk-KQW6MTUR-BsVaJdnu.js} +1 -1
- package/dist/assets/{chunk-NTY3LDVX-Bpz5TkVb.js → chunk-NTY3LDVX-DyT9N5sM.js} +1 -1
- package/dist/assets/{chunk-VPRB5NB3-CfeHjtbb.js → chunk-VPRB5NB3-BNz5CtBn.js} +1 -1
- package/dist/assets/{chunk-XC4XBNZT-FBCWmi6K.js → chunk-XC4XBNZT-CCgIhjYS.js} +1 -1
- package/dist/assets/{circle-slash-DqKFFqfb.js → circle-slash-uNv_ha0X.js} +1 -1
- package/dist/assets/{classDiagram-v2-K4WV4PDN-DbC_J0kK.js → classDiagram-v2-K4WV4PDN-Cdh3CEl4.js} +1 -1
- package/dist/assets/{coins-BztUbqyl.js → coins-BDAh8hDQ.js} +1 -1
- package/dist/assets/{collections-BxrcELwt.js → collections-B58p51lw.js} +1 -1
- package/dist/assets/{connection-owner-D-ikSHyR.js → connection-owner-D8fNrFqC.js} +1 -1
- package/dist/assets/{cynefin-EF2NZ3EQ-COwSJ4qP.js → cynefin-EF2NZ3EQ-BkwhfqJ0.js} +1 -1
- package/dist/assets/{cynefinDiagram-3GCD6N5R-diaEJq9Y.js → cynefinDiagram-3GCD6N5R-DuGb_wq2.js} +1 -1
- package/dist/assets/{dagre-W4DXFKR2-BPAMRuIj.js → dagre-W4DXFKR2-Bxq_Mhia.js} +1 -1
- package/dist/assets/{diagram-2UJZ2QOL-BvRnO1Id.js → diagram-2UJZ2QOL-B-P_hrXV.js} +1 -1
- package/dist/assets/{diagram-OVF4WLC6-CDgBeD0m.js → diagram-OVF4WLC6-Ds0BqQWH.js} +1 -1
- package/dist/assets/{diagram-PFPMY2P6-DAw9lREG.js → diagram-PFPMY2P6-Dpqb2-Cb.js} +1 -1
- package/dist/assets/{diagram-UMYRVEAY-ZQqQn22t.js → diagram-UMYRVEAY-BJSoxjiu.js} +1 -1
- package/dist/assets/{diagram-YEKJPTXX-CoJtGgWs.js → diagram-YEKJPTXX-BxaG_9tT.js} +1 -1
- package/dist/assets/{diagram-ZIFT7M5P-qW_Zn_bO.js → diagram-ZIFT7M5P-6acvVOtc.js} +1 -1
- package/dist/assets/{dist-B2E6oBK1.js → dist-0EWXio4m.js} +1 -1
- package/dist/assets/{dist-IcdxEhjC.js → dist-BGvZP_Cl.js} +1 -1
- package/dist/assets/{dist-DXjkgaZX.js → dist-BZ7AbEhN.js} +1 -1
- package/dist/assets/{dist-_EtfntKJ.js → dist-BlosHr86.js} +1 -1
- package/dist/assets/{dist-DylHAy-6.js → dist-Bmr4uhSk.js} +1 -1
- package/dist/assets/{dist-DML0cJH3.js → dist-C6yMfMNS.js} +1 -1
- package/dist/assets/{dist-Dl94YqeS.js → dist-CMZQedYl.js} +1 -1
- package/dist/assets/{dist-DKyBHaH2.js → dist-C_N_-eaT.js} +1 -1
- package/dist/assets/{dist-CvRpZH53.js → dist-CaUbG4Hl.js} +1 -1
- package/dist/assets/{dist-ptDa9fKh.js → dist-Cn7-nxjU.js} +1 -1
- package/dist/assets/{dist-CG-phytt.js → dist-Cnj95_pX.js} +1 -1
- package/dist/assets/{dist-DbXGl-wj.js → dist-D9DR7k9k.js} +1 -1
- package/dist/assets/{dist-CjRqeLFz.js → dist-DIwsVdS2.js} +1 -1
- package/dist/assets/{dist-BCJybC91.js → dist-DVE0lLId.js} +1 -1
- package/dist/assets/{dist-CPgRB-NQ.js → dist-DkAPL4CQ.js} +1 -1
- package/dist/assets/{dist-CeSzCyeG.js → dist-Dl6N3kpQ.js} +1 -1
- package/dist/assets/{dist-DZruZxAk.js → dist-DmBvXBzK.js} +1 -1
- package/dist/assets/{dist-CdmdXwCZ.js → dist-DpgXK0aZ.js} +1 -1
- package/dist/assets/{dist-CYRzGbSY.js → dist-gMRyU9GJ.js} +1 -1
- package/dist/assets/{dist-CG6fC1Db.js → dist-jQQX2kOU.js} +1 -1
- package/dist/assets/{dist-DZIxMHOT.js → dist-lUaUoFTq.js} +1 -1
- package/dist/assets/{dist-CuwPDbnL.js → dist-qw1ZF2vD.js} +1 -1
- package/dist/assets/{dist-B6Qde8KJ.js → dist-rH4qrNAn.js} +1 -1
- package/dist/assets/{ebnfDiagram-VR2GEFS7-DA4UvKXV.js → ebnfDiagram-VR2GEFS7-Ytj3Z5qC.js} +1 -1
- package/dist/assets/{elk-IJKZMXRS-CM74d3mJ.js → elk-IJKZMXRS-CJurNqqK.js} +1 -1
- package/dist/assets/{erDiagram-O2IAPWRE-d869V0qL.js → erDiagram-O2IAPWRE-hyXckW2d.js} +1 -1
- package/dist/assets/{eventmodeling-K75KTNOO-C-oz_eyI.js → eventmodeling-K75KTNOO-D3xQujrh.js} +1 -1
- package/dist/assets/flowDiagram-OXPTDLAJ-D4ojBTuY.js +1 -0
- package/dist/assets/{folder-plus-CxWXoYCi.js → folder-plus-BJZSMzuj.js} +1 -1
- package/dist/assets/{ganttDiagram-R7TSEDQI-BBul4Kpm.js → ganttDiagram-R7TSEDQI-C8U_ITl4.js} +1 -1
- package/dist/assets/{gitGraph-VSP46ZUC-BriEZgAq.js → gitGraph-VSP46ZUC-CDeq3yKT.js} +1 -1
- package/dist/assets/{gitGraphDiagram-XJZIOB7I-I12rg8s1.js → gitGraphDiagram-XJZIOB7I-CST3EWE9.js} +1 -1
- package/dist/assets/{goals-CvMWzjH4.js → goals-BNJZ4nzg.js} +1 -1
- package/dist/assets/{index-Bt31d8ga.js → index-BJtnP7H1.js} +8 -8
- package/dist/assets/{info-OHQRW6UA-CxrcGiem.js → info-OHQRW6UA-CPvTWk7J.js} +1 -1
- package/dist/assets/{infoDiagram-5W2HQ5XZ-4Sm0LiOu.js → infoDiagram-5W2HQ5XZ-BPUiNdxI.js} +1 -1
- package/dist/assets/{ishikawaDiagram-K3B6WC7H-CKXvKV-s.js → ishikawaDiagram-K3B6WC7H-D5Z3rmaA.js} +1 -1
- package/dist/assets/{issue-detail-4PCbYpdv.js → issue-detail-CZfjXs0M.js} +3 -3
- package/dist/assets/{journeyDiagram-COXZFDF6-BHsrZLvQ.js → journeyDiagram-COXZFDF6-CEkwEYdR.js} +1 -1
- package/dist/assets/{kanban-definition-P3RFRI5V-8HhnIs_l.js → kanban-definition-P3RFRI5V-8h_R6Qjq.js} +1 -1
- package/dist/assets/{line-rrKrpB-b.js → line-Ljt_vfsb.js} +1 -1
- package/dist/assets/{link-BecLzmfo.js → link-DvgFK0mz.js} +1 -1
- package/dist/assets/{list-filter-BC3D4IoX.js → list-filter-BR4_dvwm.js} +1 -1
- package/dist/assets/{log-in-BJCGwGGT.js → log-in-Dvx9-FMC.js} +1 -1
- package/dist/assets/{mcpSkills-DRs3pGKn.js → mcpSkills-76szK_k1.js} +1 -1
- package/dist/assets/{mermaid-parser.core-DmG0b4S0.js → mermaid-parser.core-BjFu937m.js} +3 -3
- package/dist/assets/{mermaid.core-D1vILTuF.js → mermaid.core-B0t95EIS.js} +4 -4
- package/dist/assets/{mindmap-definition-LZFPQGKD-DIMpL0de.js → mindmap-definition-LZFPQGKD-TVnHYUR4.js} +1 -1
- package/dist/assets/{packet-JDAUHWVQ-BnbYht3G.js → packet-JDAUHWVQ-aNGiRWLy.js} +1 -1
- package/dist/assets/{pegDiagram-BGZESJAR-BUjtJVjT.js → pegDiagram-BGZESJAR-DDadxqWQ.js} +1 -1
- package/dist/assets/{pie-XZMESJXO-CM4VXUb-.js → pie-XZMESJXO-CydFP1hd.js} +1 -1
- package/dist/assets/{pieDiagram-CAPJLFHJ-B3v8ryvG.js → pieDiagram-CAPJLFHJ-KhdUDwDS.js} +1 -1
- package/dist/assets/{power-0mw59G-l.js → power-sYV-WuqQ.js} +1 -1
- package/dist/assets/{profile-summary-B5rPf8v-.js → profile-summary-D4LPX-Dv.js} +1 -1
- package/dist/assets/{quadrantDiagram-GDMTTRAM-Cv-dS2Rn.js → quadrantDiagram-GDMTTRAM-B1X8K2Fs.js} +1 -1
- package/dist/assets/{radar-ABXABTNO-v6yZj4Fk.js → radar-ABXABTNO-BqodkLpx.js} +1 -1
- package/dist/assets/{railroad-I3PHUGI6-D-U8Cs0m.js → railroad-I3PHUGI6-HmRKXDJj.js} +1 -1
- package/dist/assets/{railroad-abnf-LNEFI6M7-Dw3fkrVy.js → railroad-abnf-LNEFI6M7-CkBttaHp.js} +1 -1
- package/dist/assets/{railroad-ebnf-DWYD2UWJ-_ln-e3Tx.js → railroad-ebnf-DWYD2UWJ-C6DBawFA.js} +1 -1
- package/dist/assets/{railroad-peg-JR7BVNR7-Bf8u1-RZ.js → railroad-peg-JR7BVNR7-Z9df3u5o.js} +1 -1
- package/dist/assets/{railroadDiagram-SM67HX2B-Drr5UhQI.js → railroadDiagram-SM67HX2B-2vDUUppL.js} +1 -1
- package/dist/assets/{requirementDiagram-X7JNWC4A-D5ef6_ac.js → requirementDiagram-X7JNWC4A-DAuP39Hc.js} +1 -1
- package/dist/assets/{sankeyDiagram-UM26HJRW-DncJWIz_.js → sankeyDiagram-UM26HJRW-ByS54QZK.js} +1 -1
- package/dist/assets/{saved-permissions-CizWg8-P.js → saved-permissions-CPiYtxkZ.js} +1 -1
- package/dist/assets/{scroll-text-Ck6HB7eM.js → scroll-text-CVSt6aO2.js} +1 -1
- package/dist/assets/{sdk-CWyUlmcn.js → sdk-vrG4HtB4.js} +1 -1
- package/dist/assets/{search-DkTqg7ab.js → search-CG-QtPVH.js} +1 -1
- package/dist/assets/{send-CYVi50sh.js → send-CH-0xdLm.js} +1 -1
- package/dist/assets/{sequenceDiagram-ZO4K6R2Y-Cs0nGCCg.js → sequenceDiagram-ZO4K6R2Y-DvWxKTLK.js} +1 -1
- package/dist/assets/{shared-CIwISWMj.js → shared-D37zfckm.js} +1 -1
- package/dist/assets/{smoke-lab-matrix-A7ubFpfk.js → smoke-lab-matrix-C5gR81E3.js} +1 -1
- package/dist/assets/{stateDiagram-v2-TBUQTH76-Dpp3m5Wq.js → stateDiagram-v2-TBUQTH76-DtiiZIXq.js} +1 -1
- package/dist/assets/{swimlanes-N4OXWK64-NXVbx1w8.js → swimlanes-N4OXWK64-BWSEtCbX.js} +1 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-Bl_9DvHU.js +8 -0
- package/dist/assets/{timeline-definition-YOQAKGHF-DqI-Mv2e.js → timeline-definition-YOQAKGHF-U4QcniMh.js} +1 -1
- package/dist/assets/{treeView-D4JQ5SDB-CZBlE7ya.js → treeView-D4JQ5SDB-B2tdrtsj.js} +1 -1
- package/dist/assets/{treemap-SAJKECNS-BlueznID.js → treemap-SAJKECNS-DodN8j4n.js} +1 -1
- package/dist/assets/{useAgentlessOnboardingAutoOpen-CnFwEQ-H.js → useAgentlessOnboardingAutoOpen-DSWW7Juw.js} +1 -1
- package/dist/assets/{useAuthorizationWindow-DnFQsiFj.js → useAuthorizationWindow-tg3aKEU7.js} +1 -1
- package/dist/assets/{useDateRange-9EbqkWXy.js → useDateRange-CnZQr2KO.js} +1 -1
- package/dist/assets/{useFastResponsesEnabled-D8dunm4j.js → useFastResponsesEnabled-B8tHSJ1y.js} +1 -1
- package/dist/assets/{usePageView-BiX5i8ck.js → usePageView-CtFMs34g.js} +1 -1
- package/dist/assets/{useProfilesData-0VYQ4lAT.js → useProfilesData-CWHdMSuL.js} +1 -1
- package/dist/assets/{useReviewCount-WBWxwKI3.js → useReviewCount-W_bCZ2Hz.js} +1 -1
- package/dist/assets/{useRoutineFormOptions-DnX5DBn1.js → useRoutineFormOptions-CCLMmVSF.js} +1 -1
- package/dist/assets/{useSummaryDraftStream-DPQRvaXT.js → useSummaryDraftStream-NVNYNt72.js} +1 -1
- package/dist/assets/{useTailscaleConnections-BDff6dWx.js → useTailscaleConnections-Dy52nCY3.js} +1 -1
- package/dist/assets/{usecaseDiagram-VIAY4XPW-BSDn8OaJ.js → usecaseDiagram-VIAY4XPW-kEHhqgOj.js} +1 -1
- package/dist/assets/{vennDiagram-BLWOH2XV-BBSA9KNN.js → vennDiagram-BLWOH2XV-NPJU0aCU.js} +1 -1
- package/dist/assets/{wardley-7MLQ67FV-CsT-rTZ9.js → wardley-7MLQ67FV-bUGKvIPT.js} +1 -1
- package/dist/assets/{wardleyDiagram-YMQ3BMBF-BLClsIjw.js → wardleyDiagram-YMQ3BMBF-qtUDHfhb.js} +1 -1
- package/dist/assets/{xychartDiagram-TAQBALBS-2x4wB0gq.js → xychartDiagram-TAQBALBS-C-z57aZj.js} +1 -1
- package/dist/index.html +4 -4
- package/dist/sw.js +1 -1
- package/package.json +1 -1
- package/dist/assets/CompanyActivity.production-DbaFBsM0.js +0 -1
- package/dist/assets/channel-BQh2vFIU.js +0 -1
- package/dist/assets/flowDiagram-OXPTDLAJ-Be1xLbJu.js +0 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-Ct3LnXZt.js +0 -8
|
@@ -1 +1 @@
|
|
|
1
|
-
var Be=Object.defineProperty;var s=(e,t)=>Be(e,"name",{value:t,configurable:!0});import{a as Ne,n as Fe}from"./rolldown-runtime-DhZMWcEn.js";import{t as Ue}from"./coins-BztUbqyl.js";import{$A as He,E_ as Ge,GD as Ke,GS as Ze,LS as qe,NE as he,RT as Ve,TC as V,Xb as Ye,YD as Qe,Zb as Je,__ as ye,aw as et,ib as tt,mT as nt,nE as $e,nj as ot,o_ as st,on as re,pb as rt,qC as at,uE as it,xE as ct,zC as lt,zE as dt}from"./index-Bt31d8ga.js";var j=Ne(ot(),1);function ut(e){const t=new URLSearchParams;e.from&&t.set("from",e.from),e.to&&t.set("to",e.to),e.userId&&t.set("userId",e.userId),e.goalId&&t.set("goalId",e.goalId),e.projectId&&t.set("projectId",e.projectId),e.issueId&&t.set("issueId",e.issueId),e.limit&&t.set("limit",String(e.limit)),e.offset&&t.set("offset",String(e.offset));const o=t.toString();return o?`?${o}`:""}s(ut,"query");var ft={get:s((e,t={},o)=>it.get(`/companies/${e}/timeline${ut(t)}`,o),"get")};var mt=new Set(["running","in_progress","queued","pending"]),ht=new Set(["cancelled","canceled","aborted","skipped"]);function xt(e){return mt.has(e)}s(xt,"isRunningStatus");function xe(e){return ht.has(e)}s(xe,"isCancelledStatus");var Z={delegated:"#5b9bf6",automation:"#f4b740",cancelled:"#9aa3ad",now:"#2563eb"};function gt(e){return e.kickoff?"delegated":"automation"}s(gt,"barSourceKind");function Re(e){return Z[gt(e)]}s(Re,"barColor");function pt(e){return e?.type??"system"}s(pt,"actorType");function Mt(e){let t=0;for(let o=0;o<e.length;o++)t=t*31+e.charCodeAt(o)&4294967295;return`hsl(${Math.abs(t)%360} 62% 52%)`}s(Mt,"issueColor");function wt(e){const t=e.trim().split(/\s+/).filter(Boolean);return t.length>=2?(t[0][0]+t[t.length-1][0]).toUpperCase():(e.slice(0,2)||"?").toUpperCase()}s(wt,"shortLabel");function G(e){return new Date(e.start).getTime()}s(G,"spanStartMs$1");function Y(e,t){return e.end?new Date(e.end).getTime():t}s(Y,"spanEndMs$1");function vt(e,t){return Math.abs(G(t)-new Date(e.at).getTime())}s(vt,"kickoffEdgeRunDistanceMs");function je(e,t){return`${e}\0${t}`}s(je,"spanGroupKey");function yt(e,t){let o=null;for(const i of t){const l=vt(e,i);(!o||l<o.distance||l===o.distance&&i.runId.localeCompare(o.span.runId)<0)&&(o={span:i,distance:l})}return o?.span.runId??null}s(yt,"closestRunForKickoffEdge");function jt(e,t){const o=new Map;for(const l of e){const c=je(l.actorId,l.issueId),x=o.get(c);x?x.push(l):o.set(c,[l])}const i=new Map;for(const l of t){const c=yt(l,o.get(je(l.toActorId,l.issueId))??[]);c&&i.set(l,c)}return i}s(jt,"buildClosestRunByKickoffEdge");function kt(e,t,o,i){const l=G(e);let c=null;for(const x of t){if(x.toActorId!==e.actorId||x.issueId!==e.issueId||x.fromActorId===e.actorId)continue;const w=new Date(x.at).getTime(),m=w<=l?l-w:w-l+1e12;(!c||m<c.delta)&&(c={edge:x,delta:m})}return!c||i.get(c.edge)!==e.runId?null:o.get(c.edge.fromActorId)??null}s(kt,"resolveKickoff");function It(e,t){const{pxPerMinute:o,gutter:i,rowH:l,barH:c,laneGap:x,nowMs:w}=t,m=new Date(e.window.from).getTime(),D=new Date(e.window.to).getTime(),k=new Map(e.actors.map(v=>[v.id,v])),b=jt(e.spans,e.edges),N=s(v=>i+(v-m)/6e4*o,"x"),y=new Map,P=s((v,d)=>{const f=y.get(v);(f===void 0||d<f)&&y.set(v,d)},"noteActivity");for(const v of e.spans)P(v.actorId,G(v));const B=e.actors.filter(v=>y.has(v.id)).sort((v,d)=>y.get(v.id)-y.get(d.id)),C=[],R=new Map;for(const v of e.spans){const d=v.issueId;R.has(d)||(C.push(d),R.set(d,v.issueIdentifier??v.issueTitle??"issue"))}const X=C.map(v=>({key:v,label:R.get(v),color:Mt(v)})),g=new Map,_=[];let E=0;for(const v of B){const d=e.spans.filter(T=>T.actorId===v.id).sort((T,$)=>G(T)-G($)),f=[],I=new Map;for(const T of d){const $=G(T),U=Y(T,w);let F=-1;for(let K=0;K<f.length;K++)if(f[K]<=$){F=K;break}F===-1?(F=f.length,f.push(U)):f[F]=U,I.set(T.runId,F)}const r=Math.max(1,f.length),p=Math.max(l,r*(c+x)+8),S=d.map(T=>{const $=I.get(T.runId)??0,U=E+6+$*(c+x),F=N(G(T)),K=N(Y(T,w)),J={span:T,x1:F,x2:Math.max(F+3,K),yTop:U,yc:U+c/2,height:c,running:xt(T.status),kickoff:kt(T,e.edges,k,b)};return g.set(T.runId,J),J}),ne=[],Q=d.reduce((T,$)=>T+Math.max(0,Y($,w)-G($)),0);_.push({actor:v,y:E,h:p,laneCount:r,bars:S,markers:ne,runCount:d.length,activeMs:Q}),E+=p}const O=[];for(const v of _)for(const d of v.bars){const f=d.kickoff;if(!f||f.type==="user")continue;const I=bt(f.id,d,g,w);I&&O.push({x1:I.x2,y1:I.yc,x2:d.x1,y2:d.yc,sourceRunId:I.span.runId,targetRunId:d.span.runId,dashed:!!d.span.retryOfRunId})}return{rows:_,connectors:O,width:i+(D-m)/6e4*o+40,height:E+32,fromMs:m,toMs:D,gutter:i,pxPerMinute:o,issues:X}}s(It,"computeLayout");function bt(e,t,o,i){const l=G(t.span);let c=null,x=null;for(const w of o.values()){if(w.span.actorId!==e||w===t)continue;const m=Y(w.span,i);m>l+1||(w.span.issueId===t.span.issueId&&(!c||Y(c.span,i)<m)&&(c=w),(!x||Y(x.span,i)<m)&&(x=w))}return c??x}s(bt,"nearestSourceBar");function Tt(e){const t=120/e,o=[15,30,60,120,180,360,720,1440,2880,10080];for(const i of o)if(i>=t)return i*6e4;return o[o.length-1]*6e4}s(Tt,"chooseTickStepMs");function Ee(e,t){const o=Math.max(0,Math.round((t-e)/6e4));return o>=1440?`${Math.floor(o/1440)}d ${Math.floor(o%1440/60)}h`:o>=60?`${Math.floor(o/60)}h ${o%60}m`:`${o}m`}s(Ee,"formatDuration");var n=Ne(He(),1),Ce={hour:60,day:1440,week:10080},Dt=.08,St=12,te=960,ie=9e5;function ce(e){return Math.max(240,e-z.gutter-24)}s(ce,"plotViewportWidth");function ke(e,t,o){return Math.max(t,Math.min(o,e))}s(ke,"clampTime");function We(e,t,o){const i=ce(o),l=ke(e.fromMs+t/e.pxPerMinute*6e4,e.fromMs,e.toMs),c=ke(e.fromMs+(t+i)/e.pxPerMinute*6e4,e.fromMs,e.toMs);return{fromMs:l,toMs:Math.max(l,c)}}s(We,"visibleWindowForScroll");function le(e,t=te){return ue(ce(t)/Ce[e])}s(le,"zoomScaleForLevel");function de(e,t=te){return Object.entries(Ce).reduce((o,[i])=>Math.abs(le(i,t)-e)<Math.abs(le(o,t)-e)?i:o,"day")}s(de,"nearestZoomForScale");function ue(e){return Math.min(St,Math.max(Dt,e))}s(ue,"clampZoomScale");function Ie(e,t){const o=(t-e)/36e5;return o<=4?"hour":o<=48?"day":"week"}s(Ie,"defaultZoomForWindow");var z={gutter:176,rowH:34,barH:15,laneGap:4},Ae=11,Nt=9;function ge(e){const t=new Date(e),o=t.getMinutes()!==0;return t.toLocaleTimeString("en-US",{hour:"numeric",minute:o?"2-digit":void 0,hour12:!0})}s(ge,"fmtClock");function $t(e,t){const o=new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric"});return t>=864e5?o:`${o}, ${ge(e)}`}s($t,"fmtTick");function Rt(e){const t=Math.max(1,Math.round(e));if(t>=10080&&t%10080===0){const o=t/10080;return`${o} week${o===1?"":"s"} visible`}if(t>=1440&&t%1440===0){const o=t/1440;return`${o} day${o===1?"":"s"} visible`}if(t>=1440){const o=Math.floor(t/1440),i=Math.round(t%1440/60);return`${o}d${i>0?` ${i}h`:""} visible`}if(t>=60&&t%60===0){const o=t/60;return`${o} hour${o===1?"":"s"} visible`}return t>=60?`${Math.floor(t/60)}h ${t%60}m visible`:`${t} minutes visible`}s(Rt,"formatVisibleDurationMinutes");function ve(e,t=42){return e.length>t?`${e.slice(0,t-1)}…`:e}s(ve,"truncate");function pe(e){return e.replace(/[^a-zA-Z0-9_-]/g,"-")}s(pe,"svgFragmentId");function Me({actor:e,cx:t,cy:o,r:i,clipId:l}){if(e.type==="agent"){const m=i>10?24:16,D=Qe(e.appearance,e.id.replace(/^agent:/,""));return(0,n.jsx)("image",{"data-testid":"timeline-agent-icon",href:Ke(D,m,2),x:t-m/2,y:o-m/2,width:m,height:m,preserveAspectRatio:"xMidYMid meet"})}const c="var(--color-foreground)",x=e.type==="system"?"var(--color-muted)":"var(--color-card)",w=wt(e.name);return e.type==="user"&&e.avatar?(0,n.jsxs)("g",{children:[(0,n.jsx)("defs",{children:(0,n.jsx)("clipPath",{id:l,children:(0,n.jsx)("circle",{cx:t,cy:o,r:i})})}),(0,n.jsx)("image",{"data-testid":"timeline-user-avatar-image",href:e.avatar,x:t-i,y:o-i,width:2*i,height:2*i,preserveAspectRatio:"xMidYMid slice",clipPath:`url(#${l})`}),(0,n.jsx)("circle",{cx:t,cy:o,r:i,fill:"none",stroke:c,strokeWidth:1.2,opacity:.5})]}):(0,n.jsxs)("g",{children:[e.type==="user"?(0,n.jsx)("rect",{x:t-i,y:o-i,width:2*i,height:2*i,rx:3,fill:x,stroke:c,strokeWidth:1.5}):(0,n.jsx)("circle",{cx:t,cy:o,r:i,fill:x,stroke:c,strokeWidth:1.5,strokeDasharray:e.type==="system"?"3 2":void 0}),(0,n.jsx)("text",{x:t,y:o+3.4,fontSize:i>10?9:8,textAnchor:"middle",fill:c,children:w})]})}s(Me,"ActorGlyph");function Et({data:e,zoom:t,zoomScale:o,onZoomScaleChange:i,onVisibleRangeLabelChange:l,onVisibleWindowChange:c,nowMs:x}){const w=$e(),m=(0,j.useRef)(null),D=(0,j.useRef)(null),k=(0,j.useRef)(null),b=(0,j.useRef)(null),N=(0,j.useRef)(null),[y,P]=(0,j.useState)(null),[B,C]=(0,j.useState)(null),[R,X]=(0,j.useState)(0),[g,_]=(0,j.useState)(0),[E,O]=(0,j.useState)(null),v=s(()=>{N.current?.(),N.current=null},"clearDocumentDrag"),d=s((a,u)=>{v();const M=s(h=>{v(),u(h)},"handleUp");document.addEventListener("mousemove",a),document.addEventListener("mouseup",M),N.current=()=>{document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",M)}},"setDocumentDrag");(0,j.useEffect)(()=>()=>v(),[]),b.current==null&&(b.current=Date.now());const f=x??b.current,I=o??le(t,g||te),r=(0,j.useMemo)(()=>It(e,{...z,pxPerMinute:I,nowMs:f}),[e,I,f]),p=(0,j.useMemo)(()=>{if(!B)return null;const a=new Set([B]);let u=!0;for(;u;){u=!1;for(const M of r.connectors)a.has(M.sourceRunId)&&!a.has(M.targetRunId)&&(a.add(M.targetRunId),u=!0),a.has(M.targetRunId)&&!a.has(M.sourceRunId)&&(a.add(M.sourceRunId),u=!0)}return a},[B,r.connectors]),S=(0,j.useMemo)(()=>p?r.connectors.filter(a=>p.has(a.sourceRunId)&&p.has(a.targetRunId)):[],[p,r.connectors]),ne=Je(w.pathname),Q=s((a,u)=>{const M=r.gutter+(a-r.fromMs)/6e4*r.pxPerMinute;return Math.max(0,Math.min(r.width-u,M-u/2))},"timeToScrollLeft"),T=s(a=>{const u=a.scrollLeft+a.clientWidth/2;return r.fromMs+(u-r.gutter)/r.pxPerMinute*6e4},"scrollCenterMs");(0,j.useEffect)(()=>{const a=m.current;if(!a)return;const u=a.clientWidth;u>0&&u!==g&&_(u);const M=`${e.window.from}:${e.window.to}`;if(D.current!==M){D.current=M;const h=Math.max(0,r.width-u);a.scrollLeft=h,X(h),k.current=T(a);return}if(k.current!=null){const h=Q(k.current,u);a.scrollLeft=h,X(h)}},[e.window.from,e.window.to,r.fromMs,r.gutter,r.pxPerMinute,r.toMs,r.width,g]),(0,j.useEffect)(()=>{l&&l(Rt(ce(g||te)/r.pxPerMinute))},[r.pxPerMinute,l,g]),(0,j.useEffect)(()=>{!c||g<=0||c(We(r,R,g))},[r.fromMs,r.toMs,r.pxPerMinute,c,R,g]);const $=Tt(r.pxPerMinute),U=[],F=Math.ceil(r.fromMs/$)*$;for(let a=F;a<=r.toMs;a+=$)U.push(a);const K=s(a=>{const u=Ye(`/issues/${encodeURIComponent(a)}`,ne);window.open(u,"_blank","noopener,noreferrer")},"openIssue"),J=s((a,u)=>{if(!i)return;const M=m.current,h=Math.max(r.fromMs,Math.min(r.toMs,a)),L=Math.max(r.fromMs,Math.min(r.toMs,u)),W=Math.min(h,L),A=Math.max(ie,Math.max(h,L)-W),ee=W+A/2,H=M?.clientWidth||g||te,se=ue(ce(H)/(A/6e4));k.current=ee,i(se,de(se,H))},"updateVisibleRange"),fe=s((a,u)=>{const M=u.getBoundingClientRect();if(M.width<=0)return r.gutter;const h=(a-M.left)/M.width*r.width;return Math.max(r.gutter,Math.min(r.width-40,h))},"svgXFromClientX"),oe=s(a=>r.fromMs+(a-r.gutter)/r.pxPerMinute*6e4,"msFromSvgX"),ze=s(a=>{if(!i||a.button!==0)return;const u=a.currentTarget,M=fe(a.clientX,u);a.preventDefault(),P(null),C(null),O({anchorX:M,currentX:M}),d(s(W=>{O(A=>A&&{...A,currentX:fe(W.clientX,u)})},"move"),s(W=>{const A=fe(W.clientX,u);if(O(null),Math.abs(A-M)<8)return;const ee=Math.min(oe(M),oe(A)),H=Math.max(oe(M),oe(A));J(ee,H)},"up"))},"handlePlotMouseDown"),Xe=s(a=>{const u=r.connectors.filter(M=>M.sourceRunId===a.span.runId||M.targetRunId===a.span.runId);return u.length===0?null:u.some(M=>M.dashed)?"dashed handoff: retry or changes requested":"solid handoff: delegation or assignment"},"connectorHintForBar"),me=s((a,u)=>{C(u.span.runId),P({x:a.clientX,y:a.clientY,bar:u,connectorHint:Xe(u)})},"showTooltip"),Oe=s(a=>{if(!i||!(a.ctrlKey||a.metaKey||a.altKey))return;a.preventDefault();const u=m.current;u&&(k.current=T(u));const M=ue(r.pxPerMinute*Math.exp(-a.deltaY*.001));i(M,de(M,u?.clientWidth??g))},"handleWheel");return(0,n.jsxs)("div",{className:"relative",children:[(0,n.jsx)("div",{ref:m,className:"max-h-(--sz-70vh) overflow-auto","data-testid":"work-timeline-scroll",onScroll:s(a=>{X(a.currentTarget.scrollLeft),k.current=T(a.currentTarget)},"onScroll"),onWheel:Oe,children:(0,n.jsxs)("div",{className:"relative",style:{width:r.width,height:r.height},children:[(0,n.jsx)(Ct,{rows:r.rows,height:r.height}),(0,n.jsxs)("svg",{width:r.width,height:r.height,viewBox:`0 0 ${r.width} ${r.height}`,className:"absolute inset-0 block select-none",onMouseDown:ze,ref:s(a=>{a&&g===0&&m.current&&_(m.current.clientWidth)},"ref"),children:[(0,n.jsx)("defs",{children:(0,n.jsxs)("linearGradient",{id:"tl-fade",x1:"0",y1:"0",x2:"1",y2:"0",children:[(0,n.jsx)("stop",{offset:"0%",stopColor:"var(--color-foreground)",stopOpacity:.28}),(0,n.jsx)("stop",{offset:"100%",stopColor:"var(--color-foreground)",stopOpacity:0})]})}),r.rows.map((a,u)=>(0,n.jsx)("rect",{x:0,y:a.y+32,width:r.width,height:a.h,fill:u%2?"var(--color-muted)":"transparent",opacity:u%2?.35:1},`bg-${a.actor.id}`)),U.map(a=>{const u=r.gutter+(a-r.fromMs)/6e4*r.pxPerMinute;return(0,n.jsx)("g",{children:(0,n.jsx)("line",{x1:u,y1:32,x2:u,y2:r.height,stroke:"var(--color-border)",strokeWidth:1})},`tick-${a}`)}),f>=r.fromMs&&f<=r.toMs&&(0,n.jsx)("line",{x1:r.gutter+(f-r.fromMs)/6e4*r.pxPerMinute,y1:32,x2:r.gutter+(f-r.fromMs)/6e4*r.pxPerMinute,y2:r.height,stroke:Z.now,strokeWidth:1.5,strokeDasharray:"2 3",opacity:.9}),(0,n.jsx)("line",{x1:r.gutter,y1:0,x2:r.gutter,y2:r.height,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:r.width,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5}),S.map((a,u)=>{const M=a.y1+32,h=a.y2+32,L=a.x2>=a.x1?`M${a.x2},${h} l-10,-5 l0,10 z`:`M${a.x2},${h} l10,-5 l0,10 z`;return(0,n.jsxs)("g",{"data-testid":"timeline-connector",opacity:.86,children:[(0,n.jsx)("path",{d:`M${a.x1},${M} V${h} H${a.x2}`,fill:"none",stroke:"var(--color-foreground)",strokeWidth:2.2,strokeDasharray:a.dashed?"5 4":void 0}),(0,n.jsx)("circle",{cx:a.x1,cy:M,r:3.2,fill:"var(--color-foreground)"}),(0,n.jsx)("path",{d:L,fill:"var(--color-foreground)"})]},`edge-${a.sourceRunId}-${a.targetRunId}-${u}`)}),r.rows.map(a=>{const u=a.y+32+a.h/2,M=pe(`plot-${a.actor.id}`);return(0,n.jsxs)("g",{children:[(0,n.jsx)(Me,{actor:a.actor,cx:26,cy:u,r:Ae,clipId:M}),(0,n.jsx)("text",{x:47,y:u+4,fontSize:13,fill:"var(--color-foreground)",children:ve(a.actor.name,18)}),Array.from({length:a.laneCount}).map((h,L)=>{const W=a.y+32+6+L*(z.barH+z.laneGap)+z.barH/2;return(0,n.jsx)("line",{x1:r.gutter,y1:W,x2:r.width-8,y2:W,stroke:"var(--color-border)",strokeWidth:1,strokeDasharray:"2 4",opacity:.6},`lane-${a.actor.id}-${L}`)}),a.bars.map(h=>{const L=h.yTop+32,W=h.x2-h.x1,A=xe(h.span.status),ee=Re(h),H=p==null?"idle":p.has(h.span.runId)?"connected":"faded",se=H==="idle"?.88:H==="connected"?1:.22;return(0,n.jsxs)("g",{opacity:H==="faded"?.42:1,children:[(0,n.jsxs)("g",{className:"cursor-pointer","data-run-id":h.span.runId,"data-connected-state":H,onMouseEnter:s(q=>me(q,h),"onMouseEnter"),onMouseOver:s(q=>me(q,h),"onMouseOver"),onMouseMove:s(q=>me(q,h),"onMouseMove"),onMouseLeave:s(()=>{P(null),C(null)},"onMouseLeave"),onMouseDown:s(q=>q.stopPropagation(),"onMouseDown"),onClick:s(()=>K(h.span.issueId),"onClick"),children:[(0,n.jsx)("rect",{x:h.x1,y:L,width:W,height:h.height,rx:3,fill:A?"transparent":ee,stroke:A?Z.cancelled:"var(--color-foreground)",strokeWidth:1.5,strokeDasharray:A?"4 3":void 0,opacity:se}),h.running&&!A&&W>8&&(0,n.jsx)("rect",{x:h.x2-Math.min(W-2,26),y:L+1.5,width:Math.min(W-2,26),height:h.height-3,fill:"url(#tl-fade)"})]}),h.kickoff&&pt(h.kickoff)==="user"&&(0,n.jsx)("g",{className:"pointer-events-none","data-testid":"timeline-kickoff-chip",children:(0,n.jsx)(Me,{actor:h.kickoff,cx:h.x1,cy:L+h.height/2,r:Nt,clipId:pe(`kickoff-${h.span.runId}-${h.kickoff.id}`)})})]},h.span.runId)})]},`row-${a.actor.id}`)}),E&&(0,n.jsx)("rect",{"data-testid":"timeline-drag-selection",x:Math.min(E.anchorX,E.currentX),y:32,width:Math.abs(E.currentX-E.anchorX),height:r.height-32,fill:"var(--color-primary)",opacity:.16,stroke:"var(--color-primary)",strokeWidth:1.5,pointerEvents:"none"})]})]})}),(0,n.jsx)(Wt,{layout:r,ticks:U,stepMs:$,scrollLeft:R}),(0,n.jsx)(Pt,{layout:r,scrollRef:m,viewportW:g,scrollLeft:R,onVisibleRangeChange:J}),y&&(0,n.jsx)(At,{tooltip:y,now:f})]})}s(Et,"WorkTimelineChart");function Ct({rows:e,height:t}){return(0,n.jsxs)("svg",{"aria-hidden":"true","data-testid":"work-timeline-actor-gutter",width:z.gutter,height:t,viewBox:`0 0 ${z.gutter} ${t}`,className:"sticky left-0 z-20 block bg-card",children:[(0,n.jsx)("rect",{x:0,y:0,width:z.gutter,height:t,fill:"var(--color-card)"}),e.map((o,i)=>{const l=o.y+32+o.h/2,c=pe(`gutter-${o.actor.id}`);return(0,n.jsxs)("g",{children:[(0,n.jsx)("rect",{x:0,y:o.y+32,width:z.gutter,height:o.h,fill:i%2?"var(--color-muted)":"var(--color-card)",opacity:i%2?.35:1}),(0,n.jsx)(Me,{actor:o.actor,cx:26,cy:l,r:Ae,clipId:c}),(0,n.jsx)("text",{x:47,y:l+4,fontSize:13,fill:"var(--color-foreground)",children:ve(o.actor.name,16)})]},`gutter-${o.actor.id}`)}),(0,n.jsx)("line",{x1:z.gutter,y1:0,x2:z.gutter,y2:t,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:z.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]})}s(Ct,"ActorGutter");function Wt({layout:e,ticks:t,stepMs:o,scrollLeft:i}){return(0,n.jsxs)("div",{"aria-hidden":"true","data-testid":"work-timeline-time-axis",className:"pointer-events-none absolute left-0 right-0 top-0 z-30 overflow-hidden bg-card",style:{height:32},children:[(0,n.jsxs)("svg",{width:e.width,height:32,viewBox:`0 0 ${e.width} 32`,className:"block",style:{transform:`translateX(${-i}px)`},children:[(0,n.jsx)("rect",{x:0,y:0,width:e.width,height:32,fill:"var(--color-card)"}),t.map(l=>{const c=e.gutter+(l-e.fromMs)/6e4*e.pxPerMinute;return(0,n.jsxs)("g",{children:[(0,n.jsx)("line",{x1:c,y1:25,x2:c,y2:32,stroke:"var(--color-border)",strokeWidth:1}),(0,n.jsx)("text",{x:c+3,y:19,fontSize:11,fill:"var(--color-muted-foreground)",children:$t(l,o)})]},`axis-tick-${l}`)}),(0,n.jsx)("line",{x1:0,y1:32,x2:e.width,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]}),(0,n.jsxs)("svg",{width:e.gutter,height:32,viewBox:`0 0 ${e.gutter} 32`,className:"absolute left-0 top-0 block bg-card",children:[(0,n.jsx)("rect",{x:0,y:0,width:e.gutter,height:32,fill:"var(--color-card)"}),(0,n.jsx)("line",{x1:e.gutter,y1:0,x2:e.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:e.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]})]})}s(Wt,"TimeAxisOverlay");function At({tooltip:e,now:t}){const{bar:o}=e,i=new Date(o.span.start).getTime(),l=o.span.end?new Date(o.span.end).getTime():t,c=o.span.issueTitle??o.span.issueIdentifier??"run",x=Math.min(e.x+14,(typeof window<"u"?window.innerWidth:1200)-300);return(0,n.jsxs)("div",{className:"pointer-events-none fixed z-50 max-w-(--sz-280px) rounded-md border border-foreground bg-card px-2.5 py-2 text-xs shadow-md",style:{left:x,top:e.y+14},children:[(0,n.jsx)("div",{className:"text-(length:--text-compact) font-medium text-foreground",children:ve(c)}),(0,n.jsxs)("div",{className:"mt-0.5 text-muted-foreground",children:[ge(i),"–",o.span.end?ge(l):"now"," · ",Ee(i,l)," ·"," ",(0,n.jsx)("span",{className:"font-medium text-foreground",children:o.span.status})]}),o.kickoff&&(0,n.jsxs)("div",{className:"text-muted-foreground",children:["kicked off by: ",o.kickoff.name,o.span.retryOfRunId?" · retry":""]}),e.connectorHint&&(0,n.jsx)("div",{className:"text-muted-foreground",children:e.connectorHint})]})}s(At,"Tooltip");function Pt({layout:e,scrollRef:t,viewportW:o,scrollLeft:i,onVisibleRangeChange:l}){const c=(0,j.useRef)(null),x=Math.max(320,o||900),w=54,m=8,D=e.toMs-e.fromMs||1,k=s(d=>m+(d-e.fromMs)/D*(x-16),"mx"),b=new Map(e.rows.map((d,f)=>[d.actor.id,f])),N=38/Math.max(1,e.rows.length),y=We(e,i,o||x),P=y.fromMs,B=y.toMs,C=k(P),R=Math.max(24,k(B)-C),X=14,g=s(()=>{c.current?.(),c.current=null},"clearDocumentDrag"),_=s((d,f)=>{g();const I=s(r=>{g(),f(r)},"handleUp");document.addEventListener("mousemove",d),document.addEventListener("mouseup",I),c.current=()=>{document.removeEventListener("mousemove",d),document.removeEventListener("mouseup",I)}},"setDocumentDrag");(0,j.useEffect)(()=>()=>g(),[]);const E=s((d,f)=>{const I=f.getBoundingClientRect(),r=Math.min(1,Math.max(0,(d-I.left-m)/(x-16)));return e.fromMs+r*D},"msAtClientX"),O=s((d,f)=>{const I=E(d,f);t.current&&(t.current.scrollLeft=e.gutter+(I-e.fromMs)/6e4*e.pxPerMinute-t.current.clientWidth/2)},"seek"),v=s((d,f)=>{f.preventDefault(),f.stopPropagation();const I=f.currentTarget.ownerSVGElement;if(!I)return;const r=P,p=B,S=Math.max(ie,p-r);_(s(Q=>{const T=E(Q.clientX,I);if(d==="left")l(Math.min(T,p-ie),p);else if(d==="right")l(r,Math.max(T,r+ie));else{const $=Math.max(e.fromMs,Math.min(e.toMs-S,T-S/2));l($,$+S)}},"move"),()=>{})},"startRangeDrag");return(0,n.jsx)("div",{className:"mt-2 border-t border-border bg-card px-3.5 py-2",children:(0,n.jsxs)("svg",{width:x,height:w,viewBox:`0 0 ${x} ${w}`,className:"block cursor-grab active:cursor-grabbing",onMouseDown:s(d=>{const f=d.currentTarget;O(d.clientX,f),_(s(r=>O(r.clientX,f),"move"),()=>{})},"onMouseDown"),children:[(0,n.jsx)("rect",{x:0,y:0,width:x,height:w,fill:"var(--color-card)",stroke:"var(--color-foreground)",strokeWidth:1.5}),e.rows.flatMap(d=>d.bars.map(f=>{const I=new Date(f.span.start).getTime(),r=f.span.end?new Date(f.span.end).getTime():e.toMs,p=m+(b.get(d.actor.id)??0)*N;return(0,n.jsx)("rect",{x:k(I),y:p+1,width:Math.max(2,k(r)-k(I)),height:Math.max(2,N-2),fill:xe(f.span.status)?Z.cancelled:Re(f),opacity:xe(f.span.status)?.5:1},`mm-${f.span.runId}`)})),(0,n.jsx)("rect",{x:C,y:1,width:R,height:52,fill:"var(--color-foreground)",opacity:.12,stroke:"var(--color-foreground)",strokeWidth:1.5,onMouseDown:s(d=>v("move",d),"onMouseDown")}),(0,n.jsx)(be,{x:C,y:1,height:52,width:X,testId:"timeline-minimap-left-handle",label:"Drag left edge to resize visible range",onMouseDown:s(d=>v("left",d),"onMouseDown")}),(0,n.jsx)(be,{x:C+R,y:1,height:52,width:X,testId:"timeline-minimap-right-handle",label:"Drag right edge to resize visible range",onMouseDown:s(d=>v("right",d),"onMouseDown")})]})})}s(Pt,"MiniMap");function be({x:e,y:t,width:o,height:i,testId:l,label:c,onMouseDown:x}){const w=e-o/2,m=t+i/2-7;return(0,n.jsxs)("g",{"data-testid":l,className:"cursor-grab active:cursor-grabbing",onMouseDown:x,children:[(0,n.jsx)("title",{children:c}),(0,n.jsx)("rect",{x:w,y:t,width:o,height:i,rx:3,fill:"var(--color-foreground)",opacity:.16}),(0,n.jsx)("line",{x1:e-3,y1:m,x2:e-3,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85}),(0,n.jsx)("line",{x1:e,y1:m,x2:e,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85}),(0,n.jsx)("line",{x1:e+3,y1:m,x2:e+3,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85})]})}s(be,"MiniMapHandle");var Jt=Fe({Timeline:s(()=>Zt,"Timeline"),loadTimelineWindow:s(()=>Pe,"loadTimelineWindow"),timelineSummary:s(()=>Le,"timelineSummary")}),Te=500;function _t(e){return`${e.actorId}\0${e.kind}\0${e.issueId}\0${e.at}`}s(_t,"timelineEventKey");function Lt(e){return`${e.fromActorId}\0${e.toActorId}\0${e.issueId}\0${e.at}\0${e.kind}`}s(Lt,"timelineEdgeKey");async function Pe(e,t,o){const i=new Map,l=new Map,c=new Map,x=new Map;let w=0,m=null,D=0,k=!1;for(;;){const b=await ft.get(e,{...t,limit:Te,offset:w},{signal:o});m??=b,D=Math.max(D,b.pagination.totalIssues),k||=b.window.capped;for(const y of b.actors)i.set(y.id,y);for(const y of b.spans)l.set(y.runId,y);for(const y of b.events)c.set(_t(y),y);for(const y of b.edges)x.set(Lt(y),y);if(!b.pagination.hasMore)break;const N=b.pagination.offset+b.pagination.limit;if(N<=w)throw new Error("Timeline pagination did not advance");w=N}if(!m)throw new Error("Timeline response was empty");return{actors:Array.from(i.values()),spans:Array.from(l.values()),events:Array.from(c.values()),edges:Array.from(x.values()),pagination:{limit:Te,offset:0,totalIssues:D,hasMore:!1},window:{...m.window,capped:k}}}s(Pe,"loadTimelineWindow");function ae(e){return`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`}s(ae,"dateInputValue");function De(e,t=new Date){const o=new Date(t),i=new Date(t);return e==="today"?{fromDate:ae(o),toDate:ae(i)}:(o.setDate(o.getDate()-(e==="7d"?6:29)),{fromDate:ae(o),toDate:ae(i)})}s(De,"presetRange");function _e(e){if(!e.fromDate||!e.toDate)return null;const t=new Date(`${e.fromDate}T00:00:00`),o=new Date(`${e.toDate}T23:59:59.999`);return Number.isNaN(t.getTime())||Number.isNaN(o.getTime())||t>o?null:{from:t.toISOString(),to:o.toISOString()}}s(_e,"rangeWindow");function zt(e){return!e.fromDate||!e.toDate?"Choose a start and end date.":_e(e)?null:"Start date must be before end date."}s(zt,"rangeError");function Se(e){return new Intl.NumberFormat("en-US").format(e)}s(Se,"formatInteger");function Xt(e){return new Intl.NumberFormat("en-US",{notation:"compact",maximumFractionDigits:1}).format(e)}s(Xt,"formatCompactInteger");function Ot(e){return new Date(e.start).getTime()}s(Ot,"spanStartMs");function Bt(e,t){return e.end?new Date(e.end).getTime():t}s(Bt,"spanEndMs");function Ft(e,t,o,i){const l=Ot(e),c=Bt(e,t);return{clippedMs:Math.max(0,Math.min(c,i)-Math.max(l,o)),rawMs:Math.max(0,c-l)}}s(Ft,"spanWindowOverlap");function Ut(e,t,o){const i=e.usage?.totalTokens??0;return i<=0||o<=0?0:t<=0||o>=t?i:Math.round(i*(o/t))}s(Ut,"spanWindowTokens");function we(e){return{fromMs:new Date(e.window.from).getTime(),toMs:new Date(e.window.to).getTime()}}s(we,"dataWindow");function Le(e,t=we(e)){const o=new Map(e.actors.map(k=>[k.id,k])),i=new Set,l=we(e),c=Math.max(l.fromMs,Math.min(l.toMs,t.fromMs)),x=Math.max(c,Math.min(l.toMs,t.toMs));let w=0,m=0,D=0;for(const k of e.spans){const b=Ft(k,l.toMs,c,x);b.clippedMs<=0||(D+=1,o.get(k.actorId)?.type==="agent"&&i.add(k.actorId),w+=b.clippedMs,m+=Ut(k,b.rawMs,b.clippedMs))}return{runs:D,agents:i.size,activeMs:w,totalTokens:m}}s(Le,"timelineSummary");function Ht({value:e,options:t,onChange:o}){return(0,n.jsx)("div",{className:"inline-flex overflow-hidden rounded-md border border-border",children:t.map((i,l)=>(0,n.jsx)("button",{type:"button",onClick:s(()=>o(i.value),"onClick"),"aria-pressed":e===i.value,className:dt("px-3 py-1.5 text-xs transition-colors",l>0&&"border-l border-border",e===i.value?"bg-primary text-primary-foreground":"bg-card text-foreground hover:bg-muted"),children:i.label},i.value))})}s(Ht,"Segmented");function Gt(){return(0,n.jsxs)("div",{className:"flex flex-wrap items-center gap-x-4 gap-y-2 border-b border-border px-3.5 py-2 text-xs text-muted-foreground",children:[(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm",style:{backgroundColor:Z.delegated}}),"Delegated"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm",style:{backgroundColor:Z.automation}}),"Automation"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm border border-dashed bg-transparent",style:{borderColor:Z.cancelled}}),"Cancelled"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-3.5 w-0.5",style:{backgroundColor:Z.now}}),"Now"]})]})}s(Gt,"TimelineLegend");function Kt({summary:e}){const t=[{label:"Runs",value:Se(e.runs),icon:V},{label:"Agents",value:Se(e.agents),icon:Ve},{label:"Run time",value:Ee(0,e.activeMs),icon:nt},{label:"Tokens used",value:e.totalTokens>0?Xt(e.totalTokens):"Not tracked",icon:Ue}];return(0,n.jsx)("dl",{className:"grid flex-1 grid-cols-2 gap-3 border-y border-border py-3 md:grid-cols-4",children:t.map(o=>{const i=o.icon;return(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsxs)("dt",{className:"flex items-center gap-1.5 text-xs text-muted-foreground",children:[(0,n.jsx)(i,{className:"h-3.5 w-3.5 shrink-0"}),(0,n.jsx)("span",{children:o.label})]}),(0,n.jsx)("dd",{className:"mt-1 truncate text-lg font-semibold tabular-nums text-foreground",children:o.value})]},o.label)})})}s(Kt,"TimelineSummaryStats");function Zt({embedded:e=!1}={}){const{selectedCompanyId:t}=qe(),{setBreadcrumbs:o}=tt(),i=$e(),{enabled:l}=st(),c=(0,j.useMemo)(()=>l&&new URLSearchParams(i.search).get("projectId")||void 0,[i.search,l]),[x,w]=(0,j.useState)("day"),[m,D]=(0,j.useState)(void 0),k=(0,j.useRef)(!1),[b,N]=(0,j.useState)("7d"),[y,P]=(0,j.useState)(()=>De("7d")),[B,C]=(0,j.useState)(null);(0,j.useEffect)(()=>{e||o([{label:c?"Project Timeline":"Timeline"}])},[e,c,o]);const R=zt(y),X=(0,j.useMemo)(()=>{const p=_e(y);return p?c?{...p,projectId:c}:p:null},[y,c]),{data:g,isLoading:_,error:E}=ct({queryKey:[...Ze.workTimeline(t??""),y.fromDate,y.toDate,c??null],queryFn:s(({signal:p})=>Pe(t,X,p),"queryFn"),enabled:!!t&&!!X});(0,j.useEffect)(()=>{if(!g||k.current)return;const p=Ie(new Date(g.window.from).getTime(),new Date(g.window.to).getTime());w(p),D(void 0)},[g]),(0,j.useEffect)(()=>{C(null)},[g?.window.from,g?.window.to]);const O=(0,j.useCallback)(p=>{C(S=>S?.fromMs===p.fromMs&&S.toMs===p.toMs?S:p)},[]);if(!t)return(0,n.jsx)(n.Fragment,{children:(0,n.jsx)(re,{icon:V,message:"Select an organization to view its work timeline."})});const v=(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)(V,{className:"h-6 w-6 text-muted-foreground"}),(0,n.jsx)("h1",{className:"text-3xl font-semibold tracking-tight",children:c?"Project Timeline":"Work Timeline"})]}),d=s(p=>{k.current=!0;const S=ue((m??le(x))*p);D(S),w(de(S))},"adjustZoom"),f=s(()=>{k.current=!0,w(g?Ie(new Date(g.window.from).getTime(),new Date(g.window.to).getTime()):"day"),D(void 0)},"resetZoom"),I=g?Le(g,B??we(g)):null,r=(0,n.jsxs)("label",{"data-canonical-toolbar":"timeline-range",className:"flex min-w-0 flex-wrap items-center gap-2 text-xs text-muted-foreground",children:["Range",(0,n.jsx)(Ht,{value:b,onChange:s(p=>{p!=="custom"&&(N(p),P(De(p)))},"onChange"),options:[{value:"today",label:"Today"},{value:"7d",label:"7 days"},{value:"30d",label:"30 days"}]}),(0,n.jsx)(ye,{type:"date",value:y.fromDate,onChange:s(p=>{N("custom"),P(S=>({...S,fromDate:p.target.value}))},"onChange"),className:"h-8 w-(--sz-150px) text-xs","aria-label":"Timeline start date"}),(0,n.jsx)("span",{children:"to"}),(0,n.jsx)(ye,{type:"date",value:y.toDate,onChange:s(p=>{N("custom"),P(S=>({...S,toDate:p.target.value}))},"onChange"),className:"h-8 w-(--sz-150px) text-xs","aria-label":"Timeline end date"})]});return(0,n.jsxs)("div",{className:"space-y-6",children:[v,(0,n.jsxs)("div",{className:"flex flex-wrap items-start gap-3",children:[I&&(0,n.jsx)(Kt,{summary:I}),(0,n.jsxs)("div",{"data-canonical-toolbar":"timeline-zoom",role:"toolbar",className:"ml-auto flex items-center gap-1 pt-3","aria-label":"Timeline zoom controls",children:[(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:s(()=>d(.8),"onClick"),"aria-label":"Zoom out",title:"Zoom out",children:(0,n.jsx)(et,{className:"h-3 w-3"})}),(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:s(()=>d(1.25),"onClick"),"aria-label":"Zoom in",title:"Zoom in",children:(0,n.jsx)(at,{className:"h-3 w-3"})}),(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:f,"aria-label":"Reset zoom",title:"Reset zoom",children:(0,n.jsx)(lt,{className:"h-3 w-3"})})]})]}),_&&(0,n.jsx)(rt,{}),R&&(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsx)(re,{icon:V,message:R}),(0,n.jsx)("div",{className:"flex flex-wrap items-center justify-end gap-3",children:r})]}),E&&(0,n.jsx)(re,{icon:V,message:"Couldn't load the timeline. The aggregation endpoint may be unavailable."}),g&&!_&&!R&&(g.spans.length===0?(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsx)(re,{icon:V,message:c?"No project activity in this window.":"No activity in this window."}),(0,n.jsx)("div",{className:"flex flex-wrap items-center justify-end gap-3",children:r})]}):(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsxs)(Ge,{className:"block py-0",children:[(0,n.jsx)(Gt,{}),(0,n.jsx)(Et,{data:g,zoom:x,zoomScale:m,onVisibleWindowChange:O,onZoomScaleChange:s((p,S=de(p))=>{k.current=!0,D(p),w(S)},"onZoomScaleChange")})]}),(0,n.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[(0,n.jsxs)("p",{className:"text-xs text-muted-foreground",children:[g.spans.length," run",g.spans.length===1?"":"s"," ·"," ",new Date(g.window.from).toLocaleString()," to ",new Date(g.window.to).toLocaleString(),g.window.capped?" · window capped":""]}),r]})]}))]})}s(Zt,"Timeline");export{Jt as n,Zt as t};
|
|
1
|
+
var Be=Object.defineProperty;var s=(e,t)=>Be(e,"name",{value:t,configurable:!0});import{a as Ne,n as Fe}from"./rolldown-runtime-DhZMWcEn.js";import{t as Ue}from"./coins-BDAh8hDQ.js";import{$A as He,E_ as Ge,GD as Ke,GS as Ze,LS as qe,NE as he,RT as Ve,TC as V,Xb as Ye,YD as Qe,Zb as Je,__ as ye,aw as et,ib as tt,mT as nt,nE as $e,nj as ot,o_ as st,on as re,pb as rt,qC as at,uE as it,xE as ct,zC as lt,zE as dt}from"./index-BJtnP7H1.js";var j=Ne(ot(),1);function ut(e){const t=new URLSearchParams;e.from&&t.set("from",e.from),e.to&&t.set("to",e.to),e.userId&&t.set("userId",e.userId),e.goalId&&t.set("goalId",e.goalId),e.projectId&&t.set("projectId",e.projectId),e.issueId&&t.set("issueId",e.issueId),e.limit&&t.set("limit",String(e.limit)),e.offset&&t.set("offset",String(e.offset));const o=t.toString();return o?`?${o}`:""}s(ut,"query");var ft={get:s((e,t={},o)=>it.get(`/companies/${e}/timeline${ut(t)}`,o),"get")};var mt=new Set(["running","in_progress","queued","pending"]),ht=new Set(["cancelled","canceled","aborted","skipped"]);function xt(e){return mt.has(e)}s(xt,"isRunningStatus");function xe(e){return ht.has(e)}s(xe,"isCancelledStatus");var Z={delegated:"#5b9bf6",automation:"#f4b740",cancelled:"#9aa3ad",now:"#2563eb"};function gt(e){return e.kickoff?"delegated":"automation"}s(gt,"barSourceKind");function Re(e){return Z[gt(e)]}s(Re,"barColor");function pt(e){return e?.type??"system"}s(pt,"actorType");function Mt(e){let t=0;for(let o=0;o<e.length;o++)t=t*31+e.charCodeAt(o)&4294967295;return`hsl(${Math.abs(t)%360} 62% 52%)`}s(Mt,"issueColor");function wt(e){const t=e.trim().split(/\s+/).filter(Boolean);return t.length>=2?(t[0][0]+t[t.length-1][0]).toUpperCase():(e.slice(0,2)||"?").toUpperCase()}s(wt,"shortLabel");function G(e){return new Date(e.start).getTime()}s(G,"spanStartMs$1");function Y(e,t){return e.end?new Date(e.end).getTime():t}s(Y,"spanEndMs$1");function vt(e,t){return Math.abs(G(t)-new Date(e.at).getTime())}s(vt,"kickoffEdgeRunDistanceMs");function je(e,t){return`${e}\0${t}`}s(je,"spanGroupKey");function yt(e,t){let o=null;for(const i of t){const l=vt(e,i);(!o||l<o.distance||l===o.distance&&i.runId.localeCompare(o.span.runId)<0)&&(o={span:i,distance:l})}return o?.span.runId??null}s(yt,"closestRunForKickoffEdge");function jt(e,t){const o=new Map;for(const l of e){const c=je(l.actorId,l.issueId),x=o.get(c);x?x.push(l):o.set(c,[l])}const i=new Map;for(const l of t){const c=yt(l,o.get(je(l.toActorId,l.issueId))??[]);c&&i.set(l,c)}return i}s(jt,"buildClosestRunByKickoffEdge");function kt(e,t,o,i){const l=G(e);let c=null;for(const x of t){if(x.toActorId!==e.actorId||x.issueId!==e.issueId||x.fromActorId===e.actorId)continue;const w=new Date(x.at).getTime(),m=w<=l?l-w:w-l+1e12;(!c||m<c.delta)&&(c={edge:x,delta:m})}return!c||i.get(c.edge)!==e.runId?null:o.get(c.edge.fromActorId)??null}s(kt,"resolveKickoff");function It(e,t){const{pxPerMinute:o,gutter:i,rowH:l,barH:c,laneGap:x,nowMs:w}=t,m=new Date(e.window.from).getTime(),D=new Date(e.window.to).getTime(),k=new Map(e.actors.map(v=>[v.id,v])),b=jt(e.spans,e.edges),N=s(v=>i+(v-m)/6e4*o,"x"),y=new Map,P=s((v,d)=>{const f=y.get(v);(f===void 0||d<f)&&y.set(v,d)},"noteActivity");for(const v of e.spans)P(v.actorId,G(v));const B=e.actors.filter(v=>y.has(v.id)).sort((v,d)=>y.get(v.id)-y.get(d.id)),C=[],R=new Map;for(const v of e.spans){const d=v.issueId;R.has(d)||(C.push(d),R.set(d,v.issueIdentifier??v.issueTitle??"issue"))}const X=C.map(v=>({key:v,label:R.get(v),color:Mt(v)})),g=new Map,_=[];let E=0;for(const v of B){const d=e.spans.filter(T=>T.actorId===v.id).sort((T,$)=>G(T)-G($)),f=[],I=new Map;for(const T of d){const $=G(T),U=Y(T,w);let F=-1;for(let K=0;K<f.length;K++)if(f[K]<=$){F=K;break}F===-1?(F=f.length,f.push(U)):f[F]=U,I.set(T.runId,F)}const r=Math.max(1,f.length),p=Math.max(l,r*(c+x)+8),S=d.map(T=>{const $=I.get(T.runId)??0,U=E+6+$*(c+x),F=N(G(T)),K=N(Y(T,w)),J={span:T,x1:F,x2:Math.max(F+3,K),yTop:U,yc:U+c/2,height:c,running:xt(T.status),kickoff:kt(T,e.edges,k,b)};return g.set(T.runId,J),J}),ne=[],Q=d.reduce((T,$)=>T+Math.max(0,Y($,w)-G($)),0);_.push({actor:v,y:E,h:p,laneCount:r,bars:S,markers:ne,runCount:d.length,activeMs:Q}),E+=p}const O=[];for(const v of _)for(const d of v.bars){const f=d.kickoff;if(!f||f.type==="user")continue;const I=bt(f.id,d,g,w);I&&O.push({x1:I.x2,y1:I.yc,x2:d.x1,y2:d.yc,sourceRunId:I.span.runId,targetRunId:d.span.runId,dashed:!!d.span.retryOfRunId})}return{rows:_,connectors:O,width:i+(D-m)/6e4*o+40,height:E+32,fromMs:m,toMs:D,gutter:i,pxPerMinute:o,issues:X}}s(It,"computeLayout");function bt(e,t,o,i){const l=G(t.span);let c=null,x=null;for(const w of o.values()){if(w.span.actorId!==e||w===t)continue;const m=Y(w.span,i);m>l+1||(w.span.issueId===t.span.issueId&&(!c||Y(c.span,i)<m)&&(c=w),(!x||Y(x.span,i)<m)&&(x=w))}return c??x}s(bt,"nearestSourceBar");function Tt(e){const t=120/e,o=[15,30,60,120,180,360,720,1440,2880,10080];for(const i of o)if(i>=t)return i*6e4;return o[o.length-1]*6e4}s(Tt,"chooseTickStepMs");function Ee(e,t){const o=Math.max(0,Math.round((t-e)/6e4));return o>=1440?`${Math.floor(o/1440)}d ${Math.floor(o%1440/60)}h`:o>=60?`${Math.floor(o/60)}h ${o%60}m`:`${o}m`}s(Ee,"formatDuration");var n=Ne(He(),1),Ce={hour:60,day:1440,week:10080},Dt=.08,St=12,te=960,ie=9e5;function ce(e){return Math.max(240,e-z.gutter-24)}s(ce,"plotViewportWidth");function ke(e,t,o){return Math.max(t,Math.min(o,e))}s(ke,"clampTime");function We(e,t,o){const i=ce(o),l=ke(e.fromMs+t/e.pxPerMinute*6e4,e.fromMs,e.toMs),c=ke(e.fromMs+(t+i)/e.pxPerMinute*6e4,e.fromMs,e.toMs);return{fromMs:l,toMs:Math.max(l,c)}}s(We,"visibleWindowForScroll");function le(e,t=te){return ue(ce(t)/Ce[e])}s(le,"zoomScaleForLevel");function de(e,t=te){return Object.entries(Ce).reduce((o,[i])=>Math.abs(le(i,t)-e)<Math.abs(le(o,t)-e)?i:o,"day")}s(de,"nearestZoomForScale");function ue(e){return Math.min(St,Math.max(Dt,e))}s(ue,"clampZoomScale");function Ie(e,t){const o=(t-e)/36e5;return o<=4?"hour":o<=48?"day":"week"}s(Ie,"defaultZoomForWindow");var z={gutter:176,rowH:34,barH:15,laneGap:4},Ae=11,Nt=9;function ge(e){const t=new Date(e),o=t.getMinutes()!==0;return t.toLocaleTimeString("en-US",{hour:"numeric",minute:o?"2-digit":void 0,hour12:!0})}s(ge,"fmtClock");function $t(e,t){const o=new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric"});return t>=864e5?o:`${o}, ${ge(e)}`}s($t,"fmtTick");function Rt(e){const t=Math.max(1,Math.round(e));if(t>=10080&&t%10080===0){const o=t/10080;return`${o} week${o===1?"":"s"} visible`}if(t>=1440&&t%1440===0){const o=t/1440;return`${o} day${o===1?"":"s"} visible`}if(t>=1440){const o=Math.floor(t/1440),i=Math.round(t%1440/60);return`${o}d${i>0?` ${i}h`:""} visible`}if(t>=60&&t%60===0){const o=t/60;return`${o} hour${o===1?"":"s"} visible`}return t>=60?`${Math.floor(t/60)}h ${t%60}m visible`:`${t} minutes visible`}s(Rt,"formatVisibleDurationMinutes");function ve(e,t=42){return e.length>t?`${e.slice(0,t-1)}…`:e}s(ve,"truncate");function pe(e){return e.replace(/[^a-zA-Z0-9_-]/g,"-")}s(pe,"svgFragmentId");function Me({actor:e,cx:t,cy:o,r:i,clipId:l}){if(e.type==="agent"){const m=i>10?24:16,D=Qe(e.appearance,e.id.replace(/^agent:/,""));return(0,n.jsx)("image",{"data-testid":"timeline-agent-icon",href:Ke(D,m,2),x:t-m/2,y:o-m/2,width:m,height:m,preserveAspectRatio:"xMidYMid meet"})}const c="var(--color-foreground)",x=e.type==="system"?"var(--color-muted)":"var(--color-card)",w=wt(e.name);return e.type==="user"&&e.avatar?(0,n.jsxs)("g",{children:[(0,n.jsx)("defs",{children:(0,n.jsx)("clipPath",{id:l,children:(0,n.jsx)("circle",{cx:t,cy:o,r:i})})}),(0,n.jsx)("image",{"data-testid":"timeline-user-avatar-image",href:e.avatar,x:t-i,y:o-i,width:2*i,height:2*i,preserveAspectRatio:"xMidYMid slice",clipPath:`url(#${l})`}),(0,n.jsx)("circle",{cx:t,cy:o,r:i,fill:"none",stroke:c,strokeWidth:1.2,opacity:.5})]}):(0,n.jsxs)("g",{children:[e.type==="user"?(0,n.jsx)("rect",{x:t-i,y:o-i,width:2*i,height:2*i,rx:3,fill:x,stroke:c,strokeWidth:1.5}):(0,n.jsx)("circle",{cx:t,cy:o,r:i,fill:x,stroke:c,strokeWidth:1.5,strokeDasharray:e.type==="system"?"3 2":void 0}),(0,n.jsx)("text",{x:t,y:o+3.4,fontSize:i>10?9:8,textAnchor:"middle",fill:c,children:w})]})}s(Me,"ActorGlyph");function Et({data:e,zoom:t,zoomScale:o,onZoomScaleChange:i,onVisibleRangeLabelChange:l,onVisibleWindowChange:c,nowMs:x}){const w=$e(),m=(0,j.useRef)(null),D=(0,j.useRef)(null),k=(0,j.useRef)(null),b=(0,j.useRef)(null),N=(0,j.useRef)(null),[y,P]=(0,j.useState)(null),[B,C]=(0,j.useState)(null),[R,X]=(0,j.useState)(0),[g,_]=(0,j.useState)(0),[E,O]=(0,j.useState)(null),v=s(()=>{N.current?.(),N.current=null},"clearDocumentDrag"),d=s((a,u)=>{v();const M=s(h=>{v(),u(h)},"handleUp");document.addEventListener("mousemove",a),document.addEventListener("mouseup",M),N.current=()=>{document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",M)}},"setDocumentDrag");(0,j.useEffect)(()=>()=>v(),[]),b.current==null&&(b.current=Date.now());const f=x??b.current,I=o??le(t,g||te),r=(0,j.useMemo)(()=>It(e,{...z,pxPerMinute:I,nowMs:f}),[e,I,f]),p=(0,j.useMemo)(()=>{if(!B)return null;const a=new Set([B]);let u=!0;for(;u;){u=!1;for(const M of r.connectors)a.has(M.sourceRunId)&&!a.has(M.targetRunId)&&(a.add(M.targetRunId),u=!0),a.has(M.targetRunId)&&!a.has(M.sourceRunId)&&(a.add(M.sourceRunId),u=!0)}return a},[B,r.connectors]),S=(0,j.useMemo)(()=>p?r.connectors.filter(a=>p.has(a.sourceRunId)&&p.has(a.targetRunId)):[],[p,r.connectors]),ne=Je(w.pathname),Q=s((a,u)=>{const M=r.gutter+(a-r.fromMs)/6e4*r.pxPerMinute;return Math.max(0,Math.min(r.width-u,M-u/2))},"timeToScrollLeft"),T=s(a=>{const u=a.scrollLeft+a.clientWidth/2;return r.fromMs+(u-r.gutter)/r.pxPerMinute*6e4},"scrollCenterMs");(0,j.useEffect)(()=>{const a=m.current;if(!a)return;const u=a.clientWidth;u>0&&u!==g&&_(u);const M=`${e.window.from}:${e.window.to}`;if(D.current!==M){D.current=M;const h=Math.max(0,r.width-u);a.scrollLeft=h,X(h),k.current=T(a);return}if(k.current!=null){const h=Q(k.current,u);a.scrollLeft=h,X(h)}},[e.window.from,e.window.to,r.fromMs,r.gutter,r.pxPerMinute,r.toMs,r.width,g]),(0,j.useEffect)(()=>{l&&l(Rt(ce(g||te)/r.pxPerMinute))},[r.pxPerMinute,l,g]),(0,j.useEffect)(()=>{!c||g<=0||c(We(r,R,g))},[r.fromMs,r.toMs,r.pxPerMinute,c,R,g]);const $=Tt(r.pxPerMinute),U=[],F=Math.ceil(r.fromMs/$)*$;for(let a=F;a<=r.toMs;a+=$)U.push(a);const K=s(a=>{const u=Ye(`/issues/${encodeURIComponent(a)}`,ne);window.open(u,"_blank","noopener,noreferrer")},"openIssue"),J=s((a,u)=>{if(!i)return;const M=m.current,h=Math.max(r.fromMs,Math.min(r.toMs,a)),L=Math.max(r.fromMs,Math.min(r.toMs,u)),W=Math.min(h,L),A=Math.max(ie,Math.max(h,L)-W),ee=W+A/2,H=M?.clientWidth||g||te,se=ue(ce(H)/(A/6e4));k.current=ee,i(se,de(se,H))},"updateVisibleRange"),fe=s((a,u)=>{const M=u.getBoundingClientRect();if(M.width<=0)return r.gutter;const h=(a-M.left)/M.width*r.width;return Math.max(r.gutter,Math.min(r.width-40,h))},"svgXFromClientX"),oe=s(a=>r.fromMs+(a-r.gutter)/r.pxPerMinute*6e4,"msFromSvgX"),ze=s(a=>{if(!i||a.button!==0)return;const u=a.currentTarget,M=fe(a.clientX,u);a.preventDefault(),P(null),C(null),O({anchorX:M,currentX:M}),d(s(W=>{O(A=>A&&{...A,currentX:fe(W.clientX,u)})},"move"),s(W=>{const A=fe(W.clientX,u);if(O(null),Math.abs(A-M)<8)return;const ee=Math.min(oe(M),oe(A)),H=Math.max(oe(M),oe(A));J(ee,H)},"up"))},"handlePlotMouseDown"),Xe=s(a=>{const u=r.connectors.filter(M=>M.sourceRunId===a.span.runId||M.targetRunId===a.span.runId);return u.length===0?null:u.some(M=>M.dashed)?"dashed handoff: retry or changes requested":"solid handoff: delegation or assignment"},"connectorHintForBar"),me=s((a,u)=>{C(u.span.runId),P({x:a.clientX,y:a.clientY,bar:u,connectorHint:Xe(u)})},"showTooltip"),Oe=s(a=>{if(!i||!(a.ctrlKey||a.metaKey||a.altKey))return;a.preventDefault();const u=m.current;u&&(k.current=T(u));const M=ue(r.pxPerMinute*Math.exp(-a.deltaY*.001));i(M,de(M,u?.clientWidth??g))},"handleWheel");return(0,n.jsxs)("div",{className:"relative",children:[(0,n.jsx)("div",{ref:m,className:"max-h-(--sz-70vh) overflow-auto","data-testid":"work-timeline-scroll",onScroll:s(a=>{X(a.currentTarget.scrollLeft),k.current=T(a.currentTarget)},"onScroll"),onWheel:Oe,children:(0,n.jsxs)("div",{className:"relative",style:{width:r.width,height:r.height},children:[(0,n.jsx)(Ct,{rows:r.rows,height:r.height}),(0,n.jsxs)("svg",{width:r.width,height:r.height,viewBox:`0 0 ${r.width} ${r.height}`,className:"absolute inset-0 block select-none",onMouseDown:ze,ref:s(a=>{a&&g===0&&m.current&&_(m.current.clientWidth)},"ref"),children:[(0,n.jsx)("defs",{children:(0,n.jsxs)("linearGradient",{id:"tl-fade",x1:"0",y1:"0",x2:"1",y2:"0",children:[(0,n.jsx)("stop",{offset:"0%",stopColor:"var(--color-foreground)",stopOpacity:.28}),(0,n.jsx)("stop",{offset:"100%",stopColor:"var(--color-foreground)",stopOpacity:0})]})}),r.rows.map((a,u)=>(0,n.jsx)("rect",{x:0,y:a.y+32,width:r.width,height:a.h,fill:u%2?"var(--color-muted)":"transparent",opacity:u%2?.35:1},`bg-${a.actor.id}`)),U.map(a=>{const u=r.gutter+(a-r.fromMs)/6e4*r.pxPerMinute;return(0,n.jsx)("g",{children:(0,n.jsx)("line",{x1:u,y1:32,x2:u,y2:r.height,stroke:"var(--color-border)",strokeWidth:1})},`tick-${a}`)}),f>=r.fromMs&&f<=r.toMs&&(0,n.jsx)("line",{x1:r.gutter+(f-r.fromMs)/6e4*r.pxPerMinute,y1:32,x2:r.gutter+(f-r.fromMs)/6e4*r.pxPerMinute,y2:r.height,stroke:Z.now,strokeWidth:1.5,strokeDasharray:"2 3",opacity:.9}),(0,n.jsx)("line",{x1:r.gutter,y1:0,x2:r.gutter,y2:r.height,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:r.width,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5}),S.map((a,u)=>{const M=a.y1+32,h=a.y2+32,L=a.x2>=a.x1?`M${a.x2},${h} l-10,-5 l0,10 z`:`M${a.x2},${h} l10,-5 l0,10 z`;return(0,n.jsxs)("g",{"data-testid":"timeline-connector",opacity:.86,children:[(0,n.jsx)("path",{d:`M${a.x1},${M} V${h} H${a.x2}`,fill:"none",stroke:"var(--color-foreground)",strokeWidth:2.2,strokeDasharray:a.dashed?"5 4":void 0}),(0,n.jsx)("circle",{cx:a.x1,cy:M,r:3.2,fill:"var(--color-foreground)"}),(0,n.jsx)("path",{d:L,fill:"var(--color-foreground)"})]},`edge-${a.sourceRunId}-${a.targetRunId}-${u}`)}),r.rows.map(a=>{const u=a.y+32+a.h/2,M=pe(`plot-${a.actor.id}`);return(0,n.jsxs)("g",{children:[(0,n.jsx)(Me,{actor:a.actor,cx:26,cy:u,r:Ae,clipId:M}),(0,n.jsx)("text",{x:47,y:u+4,fontSize:13,fill:"var(--color-foreground)",children:ve(a.actor.name,18)}),Array.from({length:a.laneCount}).map((h,L)=>{const W=a.y+32+6+L*(z.barH+z.laneGap)+z.barH/2;return(0,n.jsx)("line",{x1:r.gutter,y1:W,x2:r.width-8,y2:W,stroke:"var(--color-border)",strokeWidth:1,strokeDasharray:"2 4",opacity:.6},`lane-${a.actor.id}-${L}`)}),a.bars.map(h=>{const L=h.yTop+32,W=h.x2-h.x1,A=xe(h.span.status),ee=Re(h),H=p==null?"idle":p.has(h.span.runId)?"connected":"faded",se=H==="idle"?.88:H==="connected"?1:.22;return(0,n.jsxs)("g",{opacity:H==="faded"?.42:1,children:[(0,n.jsxs)("g",{className:"cursor-pointer","data-run-id":h.span.runId,"data-connected-state":H,onMouseEnter:s(q=>me(q,h),"onMouseEnter"),onMouseOver:s(q=>me(q,h),"onMouseOver"),onMouseMove:s(q=>me(q,h),"onMouseMove"),onMouseLeave:s(()=>{P(null),C(null)},"onMouseLeave"),onMouseDown:s(q=>q.stopPropagation(),"onMouseDown"),onClick:s(()=>K(h.span.issueId),"onClick"),children:[(0,n.jsx)("rect",{x:h.x1,y:L,width:W,height:h.height,rx:3,fill:A?"transparent":ee,stroke:A?Z.cancelled:"var(--color-foreground)",strokeWidth:1.5,strokeDasharray:A?"4 3":void 0,opacity:se}),h.running&&!A&&W>8&&(0,n.jsx)("rect",{x:h.x2-Math.min(W-2,26),y:L+1.5,width:Math.min(W-2,26),height:h.height-3,fill:"url(#tl-fade)"})]}),h.kickoff&&pt(h.kickoff)==="user"&&(0,n.jsx)("g",{className:"pointer-events-none","data-testid":"timeline-kickoff-chip",children:(0,n.jsx)(Me,{actor:h.kickoff,cx:h.x1,cy:L+h.height/2,r:Nt,clipId:pe(`kickoff-${h.span.runId}-${h.kickoff.id}`)})})]},h.span.runId)})]},`row-${a.actor.id}`)}),E&&(0,n.jsx)("rect",{"data-testid":"timeline-drag-selection",x:Math.min(E.anchorX,E.currentX),y:32,width:Math.abs(E.currentX-E.anchorX),height:r.height-32,fill:"var(--color-primary)",opacity:.16,stroke:"var(--color-primary)",strokeWidth:1.5,pointerEvents:"none"})]})]})}),(0,n.jsx)(Wt,{layout:r,ticks:U,stepMs:$,scrollLeft:R}),(0,n.jsx)(Pt,{layout:r,scrollRef:m,viewportW:g,scrollLeft:R,onVisibleRangeChange:J}),y&&(0,n.jsx)(At,{tooltip:y,now:f})]})}s(Et,"WorkTimelineChart");function Ct({rows:e,height:t}){return(0,n.jsxs)("svg",{"aria-hidden":"true","data-testid":"work-timeline-actor-gutter",width:z.gutter,height:t,viewBox:`0 0 ${z.gutter} ${t}`,className:"sticky left-0 z-20 block bg-card",children:[(0,n.jsx)("rect",{x:0,y:0,width:z.gutter,height:t,fill:"var(--color-card)"}),e.map((o,i)=>{const l=o.y+32+o.h/2,c=pe(`gutter-${o.actor.id}`);return(0,n.jsxs)("g",{children:[(0,n.jsx)("rect",{x:0,y:o.y+32,width:z.gutter,height:o.h,fill:i%2?"var(--color-muted)":"var(--color-card)",opacity:i%2?.35:1}),(0,n.jsx)(Me,{actor:o.actor,cx:26,cy:l,r:Ae,clipId:c}),(0,n.jsx)("text",{x:47,y:l+4,fontSize:13,fill:"var(--color-foreground)",children:ve(o.actor.name,16)})]},`gutter-${o.actor.id}`)}),(0,n.jsx)("line",{x1:z.gutter,y1:0,x2:z.gutter,y2:t,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:z.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]})}s(Ct,"ActorGutter");function Wt({layout:e,ticks:t,stepMs:o,scrollLeft:i}){return(0,n.jsxs)("div",{"aria-hidden":"true","data-testid":"work-timeline-time-axis",className:"pointer-events-none absolute left-0 right-0 top-0 z-30 overflow-hidden bg-card",style:{height:32},children:[(0,n.jsxs)("svg",{width:e.width,height:32,viewBox:`0 0 ${e.width} 32`,className:"block",style:{transform:`translateX(${-i}px)`},children:[(0,n.jsx)("rect",{x:0,y:0,width:e.width,height:32,fill:"var(--color-card)"}),t.map(l=>{const c=e.gutter+(l-e.fromMs)/6e4*e.pxPerMinute;return(0,n.jsxs)("g",{children:[(0,n.jsx)("line",{x1:c,y1:25,x2:c,y2:32,stroke:"var(--color-border)",strokeWidth:1}),(0,n.jsx)("text",{x:c+3,y:19,fontSize:11,fill:"var(--color-muted-foreground)",children:$t(l,o)})]},`axis-tick-${l}`)}),(0,n.jsx)("line",{x1:0,y1:32,x2:e.width,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]}),(0,n.jsxs)("svg",{width:e.gutter,height:32,viewBox:`0 0 ${e.gutter} 32`,className:"absolute left-0 top-0 block bg-card",children:[(0,n.jsx)("rect",{x:0,y:0,width:e.gutter,height:32,fill:"var(--color-card)"}),(0,n.jsx)("line",{x1:e.gutter,y1:0,x2:e.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5}),(0,n.jsx)("line",{x1:0,y1:32,x2:e.gutter,y2:32,stroke:"var(--color-foreground)",strokeWidth:1.5})]})]})}s(Wt,"TimeAxisOverlay");function At({tooltip:e,now:t}){const{bar:o}=e,i=new Date(o.span.start).getTime(),l=o.span.end?new Date(o.span.end).getTime():t,c=o.span.issueTitle??o.span.issueIdentifier??"run",x=Math.min(e.x+14,(typeof window<"u"?window.innerWidth:1200)-300);return(0,n.jsxs)("div",{className:"pointer-events-none fixed z-50 max-w-(--sz-280px) rounded-md border border-foreground bg-card px-2.5 py-2 text-xs shadow-md",style:{left:x,top:e.y+14},children:[(0,n.jsx)("div",{className:"text-(length:--text-compact) font-medium text-foreground",children:ve(c)}),(0,n.jsxs)("div",{className:"mt-0.5 text-muted-foreground",children:[ge(i),"–",o.span.end?ge(l):"now"," · ",Ee(i,l)," ·"," ",(0,n.jsx)("span",{className:"font-medium text-foreground",children:o.span.status})]}),o.kickoff&&(0,n.jsxs)("div",{className:"text-muted-foreground",children:["kicked off by: ",o.kickoff.name,o.span.retryOfRunId?" · retry":""]}),e.connectorHint&&(0,n.jsx)("div",{className:"text-muted-foreground",children:e.connectorHint})]})}s(At,"Tooltip");function Pt({layout:e,scrollRef:t,viewportW:o,scrollLeft:i,onVisibleRangeChange:l}){const c=(0,j.useRef)(null),x=Math.max(320,o||900),w=54,m=8,D=e.toMs-e.fromMs||1,k=s(d=>m+(d-e.fromMs)/D*(x-16),"mx"),b=new Map(e.rows.map((d,f)=>[d.actor.id,f])),N=38/Math.max(1,e.rows.length),y=We(e,i,o||x),P=y.fromMs,B=y.toMs,C=k(P),R=Math.max(24,k(B)-C),X=14,g=s(()=>{c.current?.(),c.current=null},"clearDocumentDrag"),_=s((d,f)=>{g();const I=s(r=>{g(),f(r)},"handleUp");document.addEventListener("mousemove",d),document.addEventListener("mouseup",I),c.current=()=>{document.removeEventListener("mousemove",d),document.removeEventListener("mouseup",I)}},"setDocumentDrag");(0,j.useEffect)(()=>()=>g(),[]);const E=s((d,f)=>{const I=f.getBoundingClientRect(),r=Math.min(1,Math.max(0,(d-I.left-m)/(x-16)));return e.fromMs+r*D},"msAtClientX"),O=s((d,f)=>{const I=E(d,f);t.current&&(t.current.scrollLeft=e.gutter+(I-e.fromMs)/6e4*e.pxPerMinute-t.current.clientWidth/2)},"seek"),v=s((d,f)=>{f.preventDefault(),f.stopPropagation();const I=f.currentTarget.ownerSVGElement;if(!I)return;const r=P,p=B,S=Math.max(ie,p-r);_(s(Q=>{const T=E(Q.clientX,I);if(d==="left")l(Math.min(T,p-ie),p);else if(d==="right")l(r,Math.max(T,r+ie));else{const $=Math.max(e.fromMs,Math.min(e.toMs-S,T-S/2));l($,$+S)}},"move"),()=>{})},"startRangeDrag");return(0,n.jsx)("div",{className:"mt-2 border-t border-border bg-card px-3.5 py-2",children:(0,n.jsxs)("svg",{width:x,height:w,viewBox:`0 0 ${x} ${w}`,className:"block cursor-grab active:cursor-grabbing",onMouseDown:s(d=>{const f=d.currentTarget;O(d.clientX,f),_(s(r=>O(r.clientX,f),"move"),()=>{})},"onMouseDown"),children:[(0,n.jsx)("rect",{x:0,y:0,width:x,height:w,fill:"var(--color-card)",stroke:"var(--color-foreground)",strokeWidth:1.5}),e.rows.flatMap(d=>d.bars.map(f=>{const I=new Date(f.span.start).getTime(),r=f.span.end?new Date(f.span.end).getTime():e.toMs,p=m+(b.get(d.actor.id)??0)*N;return(0,n.jsx)("rect",{x:k(I),y:p+1,width:Math.max(2,k(r)-k(I)),height:Math.max(2,N-2),fill:xe(f.span.status)?Z.cancelled:Re(f),opacity:xe(f.span.status)?.5:1},`mm-${f.span.runId}`)})),(0,n.jsx)("rect",{x:C,y:1,width:R,height:52,fill:"var(--color-foreground)",opacity:.12,stroke:"var(--color-foreground)",strokeWidth:1.5,onMouseDown:s(d=>v("move",d),"onMouseDown")}),(0,n.jsx)(be,{x:C,y:1,height:52,width:X,testId:"timeline-minimap-left-handle",label:"Drag left edge to resize visible range",onMouseDown:s(d=>v("left",d),"onMouseDown")}),(0,n.jsx)(be,{x:C+R,y:1,height:52,width:X,testId:"timeline-minimap-right-handle",label:"Drag right edge to resize visible range",onMouseDown:s(d=>v("right",d),"onMouseDown")})]})})}s(Pt,"MiniMap");function be({x:e,y:t,width:o,height:i,testId:l,label:c,onMouseDown:x}){const w=e-o/2,m=t+i/2-7;return(0,n.jsxs)("g",{"data-testid":l,className:"cursor-grab active:cursor-grabbing",onMouseDown:x,children:[(0,n.jsx)("title",{children:c}),(0,n.jsx)("rect",{x:w,y:t,width:o,height:i,rx:3,fill:"var(--color-foreground)",opacity:.16}),(0,n.jsx)("line",{x1:e-3,y1:m,x2:e-3,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85}),(0,n.jsx)("line",{x1:e,y1:m,x2:e,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85}),(0,n.jsx)("line",{x1:e+3,y1:m,x2:e+3,y2:m+14,stroke:"var(--color-foreground)",strokeWidth:1.5,opacity:.85})]})}s(be,"MiniMapHandle");var Jt=Fe({Timeline:s(()=>Zt,"Timeline"),loadTimelineWindow:s(()=>Pe,"loadTimelineWindow"),timelineSummary:s(()=>Le,"timelineSummary")}),Te=500;function _t(e){return`${e.actorId}\0${e.kind}\0${e.issueId}\0${e.at}`}s(_t,"timelineEventKey");function Lt(e){return`${e.fromActorId}\0${e.toActorId}\0${e.issueId}\0${e.at}\0${e.kind}`}s(Lt,"timelineEdgeKey");async function Pe(e,t,o){const i=new Map,l=new Map,c=new Map,x=new Map;let w=0,m=null,D=0,k=!1;for(;;){const b=await ft.get(e,{...t,limit:Te,offset:w},{signal:o});m??=b,D=Math.max(D,b.pagination.totalIssues),k||=b.window.capped;for(const y of b.actors)i.set(y.id,y);for(const y of b.spans)l.set(y.runId,y);for(const y of b.events)c.set(_t(y),y);for(const y of b.edges)x.set(Lt(y),y);if(!b.pagination.hasMore)break;const N=b.pagination.offset+b.pagination.limit;if(N<=w)throw new Error("Timeline pagination did not advance");w=N}if(!m)throw new Error("Timeline response was empty");return{actors:Array.from(i.values()),spans:Array.from(l.values()),events:Array.from(c.values()),edges:Array.from(x.values()),pagination:{limit:Te,offset:0,totalIssues:D,hasMore:!1},window:{...m.window,capped:k}}}s(Pe,"loadTimelineWindow");function ae(e){return`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`}s(ae,"dateInputValue");function De(e,t=new Date){const o=new Date(t),i=new Date(t);return e==="today"?{fromDate:ae(o),toDate:ae(i)}:(o.setDate(o.getDate()-(e==="7d"?6:29)),{fromDate:ae(o),toDate:ae(i)})}s(De,"presetRange");function _e(e){if(!e.fromDate||!e.toDate)return null;const t=new Date(`${e.fromDate}T00:00:00`),o=new Date(`${e.toDate}T23:59:59.999`);return Number.isNaN(t.getTime())||Number.isNaN(o.getTime())||t>o?null:{from:t.toISOString(),to:o.toISOString()}}s(_e,"rangeWindow");function zt(e){return!e.fromDate||!e.toDate?"Choose a start and end date.":_e(e)?null:"Start date must be before end date."}s(zt,"rangeError");function Se(e){return new Intl.NumberFormat("en-US").format(e)}s(Se,"formatInteger");function Xt(e){return new Intl.NumberFormat("en-US",{notation:"compact",maximumFractionDigits:1}).format(e)}s(Xt,"formatCompactInteger");function Ot(e){return new Date(e.start).getTime()}s(Ot,"spanStartMs");function Bt(e,t){return e.end?new Date(e.end).getTime():t}s(Bt,"spanEndMs");function Ft(e,t,o,i){const l=Ot(e),c=Bt(e,t);return{clippedMs:Math.max(0,Math.min(c,i)-Math.max(l,o)),rawMs:Math.max(0,c-l)}}s(Ft,"spanWindowOverlap");function Ut(e,t,o){const i=e.usage?.totalTokens??0;return i<=0||o<=0?0:t<=0||o>=t?i:Math.round(i*(o/t))}s(Ut,"spanWindowTokens");function we(e){return{fromMs:new Date(e.window.from).getTime(),toMs:new Date(e.window.to).getTime()}}s(we,"dataWindow");function Le(e,t=we(e)){const o=new Map(e.actors.map(k=>[k.id,k])),i=new Set,l=we(e),c=Math.max(l.fromMs,Math.min(l.toMs,t.fromMs)),x=Math.max(c,Math.min(l.toMs,t.toMs));let w=0,m=0,D=0;for(const k of e.spans){const b=Ft(k,l.toMs,c,x);b.clippedMs<=0||(D+=1,o.get(k.actorId)?.type==="agent"&&i.add(k.actorId),w+=b.clippedMs,m+=Ut(k,b.rawMs,b.clippedMs))}return{runs:D,agents:i.size,activeMs:w,totalTokens:m}}s(Le,"timelineSummary");function Ht({value:e,options:t,onChange:o}){return(0,n.jsx)("div",{className:"inline-flex overflow-hidden rounded-md border border-border",children:t.map((i,l)=>(0,n.jsx)("button",{type:"button",onClick:s(()=>o(i.value),"onClick"),"aria-pressed":e===i.value,className:dt("px-3 py-1.5 text-xs transition-colors",l>0&&"border-l border-border",e===i.value?"bg-primary text-primary-foreground":"bg-card text-foreground hover:bg-muted"),children:i.label},i.value))})}s(Ht,"Segmented");function Gt(){return(0,n.jsxs)("div",{className:"flex flex-wrap items-center gap-x-4 gap-y-2 border-b border-border px-3.5 py-2 text-xs text-muted-foreground",children:[(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm",style:{backgroundColor:Z.delegated}}),"Delegated"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm",style:{backgroundColor:Z.automation}}),"Automation"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-2.5 w-4 rounded-sm border border-dashed bg-transparent",style:{borderColor:Z.cancelled}}),"Cancelled"]}),(0,n.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,n.jsx)("span",{className:"h-3.5 w-0.5",style:{backgroundColor:Z.now}}),"Now"]})]})}s(Gt,"TimelineLegend");function Kt({summary:e}){const t=[{label:"Runs",value:Se(e.runs),icon:V},{label:"Agents",value:Se(e.agents),icon:Ve},{label:"Run time",value:Ee(0,e.activeMs),icon:nt},{label:"Tokens used",value:e.totalTokens>0?Xt(e.totalTokens):"Not tracked",icon:Ue}];return(0,n.jsx)("dl",{className:"grid flex-1 grid-cols-2 gap-3 border-y border-border py-3 md:grid-cols-4",children:t.map(o=>{const i=o.icon;return(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsxs)("dt",{className:"flex items-center gap-1.5 text-xs text-muted-foreground",children:[(0,n.jsx)(i,{className:"h-3.5 w-3.5 shrink-0"}),(0,n.jsx)("span",{children:o.label})]}),(0,n.jsx)("dd",{className:"mt-1 truncate text-lg font-semibold tabular-nums text-foreground",children:o.value})]},o.label)})})}s(Kt,"TimelineSummaryStats");function Zt({embedded:e=!1}={}){const{selectedCompanyId:t}=qe(),{setBreadcrumbs:o}=tt(),i=$e(),{enabled:l}=st(),c=(0,j.useMemo)(()=>l&&new URLSearchParams(i.search).get("projectId")||void 0,[i.search,l]),[x,w]=(0,j.useState)("day"),[m,D]=(0,j.useState)(void 0),k=(0,j.useRef)(!1),[b,N]=(0,j.useState)("7d"),[y,P]=(0,j.useState)(()=>De("7d")),[B,C]=(0,j.useState)(null);(0,j.useEffect)(()=>{e||o([{label:c?"Project Timeline":"Timeline"}])},[e,c,o]);const R=zt(y),X=(0,j.useMemo)(()=>{const p=_e(y);return p?c?{...p,projectId:c}:p:null},[y,c]),{data:g,isLoading:_,error:E}=ct({queryKey:[...Ze.workTimeline(t??""),y.fromDate,y.toDate,c??null],queryFn:s(({signal:p})=>Pe(t,X,p),"queryFn"),enabled:!!t&&!!X});(0,j.useEffect)(()=>{if(!g||k.current)return;const p=Ie(new Date(g.window.from).getTime(),new Date(g.window.to).getTime());w(p),D(void 0)},[g]),(0,j.useEffect)(()=>{C(null)},[g?.window.from,g?.window.to]);const O=(0,j.useCallback)(p=>{C(S=>S?.fromMs===p.fromMs&&S.toMs===p.toMs?S:p)},[]);if(!t)return(0,n.jsx)(n.Fragment,{children:(0,n.jsx)(re,{icon:V,message:"Select an organization to view its work timeline."})});const v=(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)(V,{className:"h-6 w-6 text-muted-foreground"}),(0,n.jsx)("h1",{className:"text-3xl font-semibold tracking-tight",children:c?"Project Timeline":"Work Timeline"})]}),d=s(p=>{k.current=!0;const S=ue((m??le(x))*p);D(S),w(de(S))},"adjustZoom"),f=s(()=>{k.current=!0,w(g?Ie(new Date(g.window.from).getTime(),new Date(g.window.to).getTime()):"day"),D(void 0)},"resetZoom"),I=g?Le(g,B??we(g)):null,r=(0,n.jsxs)("label",{"data-canonical-toolbar":"timeline-range",className:"flex min-w-0 flex-wrap items-center gap-2 text-xs text-muted-foreground",children:["Range",(0,n.jsx)(Ht,{value:b,onChange:s(p=>{p!=="custom"&&(N(p),P(De(p)))},"onChange"),options:[{value:"today",label:"Today"},{value:"7d",label:"7 days"},{value:"30d",label:"30 days"}]}),(0,n.jsx)(ye,{type:"date",value:y.fromDate,onChange:s(p=>{N("custom"),P(S=>({...S,fromDate:p.target.value}))},"onChange"),className:"h-8 w-(--sz-150px) text-xs","aria-label":"Timeline start date"}),(0,n.jsx)("span",{children:"to"}),(0,n.jsx)(ye,{type:"date",value:y.toDate,onChange:s(p=>{N("custom"),P(S=>({...S,toDate:p.target.value}))},"onChange"),className:"h-8 w-(--sz-150px) text-xs","aria-label":"Timeline end date"})]});return(0,n.jsxs)("div",{className:"space-y-6",children:[v,(0,n.jsxs)("div",{className:"flex flex-wrap items-start gap-3",children:[I&&(0,n.jsx)(Kt,{summary:I}),(0,n.jsxs)("div",{"data-canonical-toolbar":"timeline-zoom",role:"toolbar",className:"ml-auto flex items-center gap-1 pt-3","aria-label":"Timeline zoom controls",children:[(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:s(()=>d(.8),"onClick"),"aria-label":"Zoom out",title:"Zoom out",children:(0,n.jsx)(et,{className:"h-3 w-3"})}),(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:s(()=>d(1.25),"onClick"),"aria-label":"Zoom in",title:"Zoom in",children:(0,n.jsx)(at,{className:"h-3 w-3"})}),(0,n.jsx)(he,{type:"button",variant:"outline",size:"icon-xs",onClick:f,"aria-label":"Reset zoom",title:"Reset zoom",children:(0,n.jsx)(lt,{className:"h-3 w-3"})})]})]}),_&&(0,n.jsx)(rt,{}),R&&(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsx)(re,{icon:V,message:R}),(0,n.jsx)("div",{className:"flex flex-wrap items-center justify-end gap-3",children:r})]}),E&&(0,n.jsx)(re,{icon:V,message:"Couldn't load the timeline. The aggregation endpoint may be unavailable."}),g&&!_&&!R&&(g.spans.length===0?(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsx)(re,{icon:V,message:c?"No project activity in this window.":"No activity in this window."}),(0,n.jsx)("div",{className:"flex flex-wrap items-center justify-end gap-3",children:r})]}):(0,n.jsxs)("div",{className:"space-y-3",children:[(0,n.jsxs)(Ge,{className:"block py-0",children:[(0,n.jsx)(Gt,{}),(0,n.jsx)(Et,{data:g,zoom:x,zoomScale:m,onVisibleWindowChange:O,onZoomScaleChange:s((p,S=de(p))=>{k.current=!0,D(p),w(S)},"onZoomScaleChange")})]}),(0,n.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[(0,n.jsxs)("p",{className:"text-xs text-muted-foreground",children:[g.spans.length," run",g.spans.length===1?"":"s"," ·"," ",new Date(g.window.from).toLocaleString()," to ",new Date(g.window.to).toLocaleString(),g.window.capped?" · window capped":""]}),r]})]}))]})}s(Zt,"Timeline");export{Jt as n,Zt as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var d=Object.defineProperty;var n=(o,t)=>d(o,"name",{value:t,configurable:!0});import{a as m}from"./rolldown-runtime-DhZMWcEn.js";import{$A as l,GS as u,Gb as x,LS as p,ab as h,ay as y,jC as f,ub as b,xE as g}from"./index-
|
|
1
|
+
var d=Object.defineProperty;var n=(o,t)=>d(o,"name",{value:t,configurable:!0});import{a as m}from"./rolldown-runtime-DhZMWcEn.js";import{$A as l,GS as u,Gb as x,LS as p,ab as h,ay as y,jC as f,ub as b,xE as g}from"./index-BJtnP7H1.js";var e=m(l(),1);function N({children:o}){const{selectedCompanyId:t}=p(),s=g({queryKey:u.access.currentBoardAccess,queryFn:n(()=>y.getCurrentBoardAccess(),"queryFn")}),r=b(s);if(s.isLoading||r.kind==="reconnecting")return(0,e.jsx)("div",{className:"mx-auto max-w-xl py-10 text-sm text-muted-foreground",children:"Loading…"});if(r.kind==="error"&&r.errorKind!=="forbidden")return(0,e.jsx)("div",{className:"mx-auto max-w-xl py-10",children:(0,e.jsx)(h,{error:s.error,action:"check your access",onRetry:r.retry,retrying:r.isFetching})});const i=s.data,a=i?.memberships?.find(c=>c.companyId===t&&c.status==="active");return i?.source==="local_implicit"||i?.isInstanceAdmin||a?.membershipRole==="owner"||a?.membershipRole==="admin"||a?.membershipRole==="operator"||a?.membershipRole==="member"?(0,e.jsx)(e.Fragment,{children:o}):(0,e.jsx)("div",{className:"mx-auto max-w-xl py-10",children:(0,e.jsxs)("div",{className:"flex flex-col gap-3 rounded-lg border border-border bg-card p-6",children:[(0,e.jsxs)("div",{className:"flex items-center gap-2 text-foreground",children:[(0,e.jsx)(f,{className:"h-5 w-5 text-muted-foreground"}),(0,e.jsx)("h1",{className:"text-lg font-semibold",children:"Access profiles require editing access"})]}),(0,e.jsxs)("p",{className:"text-sm text-muted-foreground",children:["Access profiles decide which tools your agents can use. Ask a company editor to set these up, or head back to"," ",(0,e.jsx)(x,{to:"/apps",className:"font-medium text-primary hover:underline",children:"your apps"}),"."]})]})})}n(N,"ToolsAdminGate");export{N as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var F=Object.defineProperty;var a=(s,n)=>F(s,"name",{value:n,configurable:!0});import{a as B}from"./rolldown-runtime-DhZMWcEn.js";import{$A as G,Bd as v,MT as V,NE as H,Rd as Q,am as W,cm as Y,fm as J,hw as K,im as X,jC as Z,lm as ee,nj as te,nm as f,om as se,rm as C,sm as re,tm as S,um as ae,zE as y}from"./index-
|
|
1
|
+
var F=Object.defineProperty;var a=(s,n)=>F(s,"name",{value:n,configurable:!0});import{a as B}from"./rolldown-runtime-DhZMWcEn.js";import{$A as G,Bd as v,MT as V,NE as H,Rd as Q,am as W,cm as Y,fm as J,hw as K,im as X,jC as Z,lm as ee,nj as te,nm as f,om as se,rm as C,sm as re,tm as S,um as ae,zE as y}from"./index-BJtnP7H1.js";var h=B(te(),1),e=B(G(),1),w="w-full rounded-md border border-border px-2.5 py-1.5 bg-transparent outline-none text-sm font-mono placeholder:text-muted-foreground/40";function p(s,n,l){const i=s?.length??0;return i===0?"-":`${i} ${i===1?n:l}`}a(p,"formatCount");function o({label:s,value:n}){return(0,e.jsxs)("div",{className:"flex items-start justify-between gap-3 py-1.5 text-sm",children:[(0,e.jsx)("span",{className:"shrink-0 text-xs text-muted-foreground",children:s}),(0,e.jsx)("span",{className:y("min-w-0 text-right",n==="-"&&"text-muted-foreground"),children:n})]})}a(o,"PolicyRow");var ne={project:"Project",root_issue:"Root issue",issue:"Issue"};function de({permissions:s,onChange:n,disabled:l,companyId:i,projectCandidates:k=[],issueCandidates:R=[],candidatesLoading:N,allowSingleIssue:L=!0,projectAccessEditor:x,layout:I="select",aside:A}){const[z,M]=(0,h.useState)(!1),u=re(s),r=W(s),d=se(r),[c,T]=(0,h.useState)(d?.type??"project"),b=u==="low_trust_review",m=ee(r),O=Y(r),$=s?.authorizationPolicy??null,_=(0,h.useMemo)(()=>C(s,u),[s,u]);(0,h.useEffect)(()=>{d&&T(d.type)},[d?.type]);function P(t){n(C(s,t==="low_trust_review"?"low_trust_review":"standard"))}a(P,"handlePresetChange");function q(t){!i||!t||n(ae(s,i,{type:c,id:t}))}a(q,"handleBoundaryTargetChange");function U(){n(X(s))}a(U,"handleClearBoundary");const j=c==="project"?k:R,D=d?.type===c?d.id:"",E=b?(0,e.jsxs)("div",{role:m?"status":"alert","aria-live":"polite",className:y("rounded-md border px-3 py-2.5 text-sm flex gap-2",m?"border-amber-500/30 bg-amber-500/10 text-amber-700 dark:text-amber-100":"border-destructive/30 bg-destructive/10 text-destructive"),children:[m?(0,e.jsx)(Z,{className:"mt-0.5 h-4 w-4 shrink-0"}):(0,e.jsx)(K,{className:"mt-0.5 h-4 w-4 shrink-0"}),(0,e.jsxs)("div",{className:"min-w-0 flex-1 space-y-2",children:[(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"font-medium",children:m?"Containment active":"Containment not configured"}),(0,e.jsx)("p",{className:"mt-1 text-xs leading-5",children:m?"This agent can only read and mutate work inside its assigned review boundary. Raw output is quarantined from higher-trust agents until a trusted reviewer promotes it.":"This agent is set to low-trust review, but no project, root issue, or issue scope is set in the core policy. Add a scope before this agent can run without denial."})]}),x&&(r?.projectIds?.length??0)>1?null:O?(0,e.jsxs)("div",{className:"rounded-md border border-border/70 bg-background/70 p-3 text-foreground space-y-3",children:[(0,e.jsxs)("div",{className:"grid gap-3 sm:grid-cols-(--gtc-12)",children:[(0,e.jsx)(v,{label:"Boundary type",children:(0,e.jsxs)("select",{className:w,value:c,onChange:a(t=>T(t.target.value),"onChange"),disabled:l,children:[(0,e.jsx)("option",{value:"project",children:"Project"}),(0,e.jsx)("option",{value:"root_issue",children:"Root issue"}),L&&(0,e.jsx)("option",{value:"issue",children:"Issue"})]})}),(0,e.jsx)(v,{label:ne[c],children:(0,e.jsxs)("select",{className:w,value:D,onChange:a(t=>q(t.target.value),"onChange"),disabled:l||!i||N||j.length===0,children:[(0,e.jsx)("option",{value:"",children:N?"Loading…":j.length===0?`No ${c==="project"?"projects":"issues"} available`:"Select boundary"}),j.map(t=>(0,e.jsx)("option",{value:t.id,children:t.label},t.id))]})})]}),(0,e.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,e.jsx)("p",{className:"text-xs text-muted-foreground",children:"CE saves one containment boundary at a time. Saved policies include this organization id."}),d?(0,e.jsx)(H,{type:"button",size:"sm",variant:"outline",className:"h-7 px-2.5 text-xs",onClick:U,disabled:l,children:"Clear boundary"}):null]})]}):(0,e.jsxs)("div",{className:"rounded-md border border-border/70 bg-background/70 p-3 text-foreground",children:[(0,e.jsx)("p",{className:"text-sm font-medium",children:"Managed by EE/API"}),(0,e.jsxs)("p",{className:"mt-1 text-xs leading-5 text-muted-foreground",children:["This policy has ",J(r).toLowerCase()," and cannot be edited by the CE single-boundary editor."]})]}),!x&&(0,e.jsxs)("p",{className:"text-xs text-muted-foreground",children:["Want to set more than one containment boundary?"," ",(0,e.jsx)("a",{className:"underline underline-offset-2 hover:text-foreground",href:"https://paperclip.ing/ee",target:"_blank",rel:"noreferrer",children:"Get Microvac EE."})]}),(0,e.jsx)(Q,{title:"View policy",open:z,onToggle:a(()=>M(t=>!t),"onToggle"),children:(0,e.jsxs)("div",{className:"divide-y divide-border/60 text-foreground",children:[(0,e.jsx)(o,{label:"Preset",value:"Low-trust review v1"}),(0,e.jsx)(o,{label:"Raw output",value:"Quarantined from higher-trust agents"}),(0,e.jsx)(o,{label:"Projects",value:p(r?.projectIds,"project","projects")}),(0,e.jsx)(o,{label:"Root issue",value:r?.rootIssueId?r.rootIssueId.slice(0,8):"-"}),(0,e.jsx)(o,{label:"Explicit issues",value:p(r?.issueIds,"issue","issues")}),(0,e.jsx)(o,{label:"Allowed agents",value:p(r?.allowedAgentIds,"agent","agents")}),(0,e.jsx)(o,{label:"Allowed tools",value:r?.allowedToolClasses?.join(" · ")||"-"}),(0,e.jsx)(o,{label:"Allowed secrets",value:p(r?.allowedSecretBindingIds,"binding","bindings")}),(0,e.jsx)(o,{label:"Promotion target",value:r?.outputPromotionTarget?.issueId?.slice(0,8)??"-"}),(0,e.jsx)(o,{label:"EE fields",value:Object.keys($??{}).some(t=>!["trustPreset","reviewPreset","trustBoundary"].includes(t))?"Custom advanced policy fields preserved":"-"})]})})]})]}):null;return I==="cards"?(0,e.jsxs)("div",{className:"flex flex-col gap-(--agent-detail-module-gap)",children:[(0,e.jsxs)("div",{className:"agent-trust-cards grid gap-(--agent-detail-module-gap) sm:grid-cols-3",children:[(0,e.jsx)("div",{role:"radiogroup","aria-label":"Trust preset",className:"contents",children:["low_trust_review","standard"].map(t=>{const g=u===t;return(0,e.jsxs)("button",{type:"button",role:"radio","aria-checked":g,"data-agent-tile":"",disabled:l,onClick:a(()=>g?void 0:P(t),"onClick"),className:y("flex min-h-(--agent-detail-tile-min-h) flex-col gap-2 rounded-lg border bg-(--agent-detail-tile) p-(--agent-detail-module-inset) text-left transition-colors outline-none hover:bg-(--agent-detail-tile-hover) focus-visible:ring-2 focus-visible:ring-ring disabled:opacity-60",g?"border-foreground":"border-transparent"),children:[(0,e.jsxs)("span",{className:"flex items-center justify-between gap-2",children:[(0,e.jsx)("span",{className:"text-sm font-semibold text-foreground",children:f[t]}),g?(0,e.jsx)(V,{className:"size-4 text-foreground","aria-hidden":!0}):null]}),(0,e.jsx)("span",{className:"text-sm leading-5 text-muted-foreground",children:S[t]})]},t)})}),A]}),E,b?x:null,_.authorizationPolicy?.reviewPreset?null:(0,e.jsx)("p",{className:"text-xs text-muted-foreground",children:"Advanced permissions remain editable through the EE permissions extension when installed."})]}):(0,e.jsxs)("div",{children:[(0,e.jsx)("h3",{className:"mb-3 text-sm font-medium",children:"Trust"}),(0,e.jsxs)("div",{className:"rounded-lg border border-border p-4 space-y-3",children:[(0,e.jsx)(v,{label:"Trust preset",hint:"Choose how broadly this agent can read and act on Microvac work objects.",children:(0,e.jsxs)("select",{className:w,value:u,onChange:a(t=>P(t.target.value),"onChange"),disabled:l,children:[(0,e.jsx)("option",{value:"standard",children:f.standard}),(0,e.jsx)("option",{value:"low_trust_review",children:f.low_trust_review})]})}),(0,e.jsx)("p",{className:"text-xs text-muted-foreground",children:S[u]}),E,b&&x,_.authorizationPolicy?.reviewPreset?null:(0,e.jsx)("p",{className:"text-xs text-muted-foreground",children:"Advanced permissions remain editable through the EE permissions extension when installed."})]})]})}a(de,"TrustPresetSection");export{de as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var w=Object.defineProperty;var i=(s,n)=>w(s,"name",{value:n,configurable:!0});import{a as $}from"./rolldown-runtime-DhZMWcEn.js";import{y as B}from"./collections-BxrcELwt.js";import{$A as O,ET as z,Fb as D,GS as y,Gb as k,HE as N,LS as L,NE as F,PD as H,Pb as G,QE as K,Rb as Y,UE as Q,Up as W,XE as u,YE as I,YS as X,aE as J,dC as V,iD as T,ib as Z,nD as C,nj as ee,on as A,pb as se,qE as c,ry as te,uC as ae,uE as ne,xE as P}from"./index-Bt31d8ga.js";var b=$(ee(),1),re={get:i((s,n)=>ne.get(`/companies/${s}/users/${encodeURIComponent(n)}/profile`),"get")},e=$(O(),1),le="__none__",ie="/company/settings/instance/profile";function de(s){const n=s?.trim()||"User",l=n.split(/\s+/).filter(Boolean);return l.length>1?`${l[0]?.[0]??""}${l[l.length-1]?.[0]??""}`.toUpperCase():n.slice(0,2).toUpperCase()}i(de,"initials");function x(s){return s.inputTokens+s.cachedInputTokens+s.outputTokens}i(x,"totalTokens");function E(s){return s.touchedIssues===0?"0%":`${Math.round(s.completedIssues/s.touchedIssues*100)}%`}i(E,"completionRate");function g({label:s,value:n,hint:l}){return(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"text-2xl font-semibold tabular-nums sm:text-3xl",children:n}),(0,e.jsx)("div",{className:"mt-1 text-(length:--text-micro) font-medium uppercase tracking-wide text-muted-foreground",children:s}),l?(0,e.jsx)("div",{className:"mt-0.5 text-xs text-muted-foreground/70",children:l}):null]})}i(g,"HeroStat");function ce({stats:s}){const n=x(s);return(0,e.jsxs)("div",{className:"flex min-w-0 flex-col gap-4 border-l border-border pl-5 first:border-l-0 first:pl-0",children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3",children:[(0,e.jsx)("h2",{className:"text-(length:--text-micro) font-medium uppercase tracking-wide text-muted-foreground",children:s.label}),(0,e.jsxs)("span",{className:"text-(length:--text-micro) text-muted-foreground tabular-nums",children:[E(s)," done"]})]}),(0,e.jsxs)("div",{className:"grid grid-cols-2 gap-x-5 gap-y-3",children:[(0,e.jsx)(h,{value:c(s.touchedIssues),label:"Touched"}),(0,e.jsx)(h,{value:c(s.completedIssues),label:"Completed"}),(0,e.jsx)(h,{value:c(s.commentCount),label:"Comments"}),(0,e.jsx)(h,{value:c(s.activityCount),label:"Actions"})]}),(0,e.jsxs)("div",{className:"grid grid-cols-2 gap-x-5 gap-y-1.5 pt-3 text-xs tabular-nums text-muted-foreground",children:[(0,e.jsx)("span",{children:"Tokens"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:u(n)}),(0,e.jsx)("span",{children:"Spend"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:N(s.costCents)}),(0,e.jsx)("span",{children:"Created"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:c(s.createdIssues)}),(0,e.jsx)("span",{children:"Open"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:c(s.assignedOpenIssues)})]})]})}i(ce,"WindowColumn");function h({value:s,label:n}){return(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-xl font-semibold tabular-nums",children:s}),(0,e.jsx)("div",{className:"mt-0.5 text-(length:--text-micro) text-muted-foreground",children:n})]})}i(h,"Metric");function oe({points:s}){const n=s.map(r=>x(r)),l=Math.max(1,...n),o=Math.max(1,...s.map(r=>r.completedIssues)),a=n.reduce((r,d)=>r+d,0);return(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Last 14 days"}),(0,e.jsxs)("div",{className:"flex items-baseline gap-4 text-xs text-muted-foreground",children:[(0,e.jsx)("span",{className:"tabular-nums text-foreground",children:u(a)}),(0,e.jsx)("span",{children:"tokens total"})]})]}),(0,e.jsx)("div",{className:"mt-6 grid grid-cols-(--gtc-57) items-end gap-1.5 sm:gap-2",children:s.map(r=>{const d=x(r),f=d===0?0:Math.max(2,Math.round(d/l*100)),p=r.completedIssues===0?0:Math.max(8,Math.round(r.completedIssues/o*36));return(0,e.jsxs)("div",{className:"group flex h-36 flex-col justify-end",children:[(0,e.jsx)("div",{className:"w-full bg-foreground/80 transition-opacity group-hover:bg-foreground",style:{height:`${f}%`,minHeight:d===0?1:void 0},title:`${I(r.date)}: ${u(d)} tokens, ${r.completedIssues} completed`}),p>0?(0,e.jsx)("div",{className:"mt-1 w-full rounded-full bg-emerald-500/80",style:{height:2,opacity:Math.min(1,.35+p/100)}}):null]},r.date)})}),(0,e.jsx)("div",{className:"mt-2 grid grid-cols-(--gtc-57) gap-1.5 text-(length:--text-nano) tabular-nums text-muted-foreground sm:gap-2",children:s.map((r,d)=>(0,e.jsx)("div",{className:"text-center",children:d===0||d===6||d===13?I(r.date):null},r.date))}),(0,e.jsxs)("div",{className:"mt-4 flex flex-wrap items-center gap-4 text-(length:--text-nano) uppercase tracking-wide text-muted-foreground",children:[(0,e.jsxs)("span",{className:"inline-flex items-center gap-1.5",children:[(0,e.jsx)("span",{className:"h-2 w-2 bg-foreground/80"})," tokens / day"]}),(0,e.jsxs)("span",{className:"inline-flex items-center gap-1.5",children:[(0,e.jsx)("span",{className:"h-(--sz-3px) w-4 rounded-full bg-emerald-500/80"})," completions"]})]})]})}i(oe,"UsageChart");function S({title:s,empty:n,rows:l}){return(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:s}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:l.length})]}),l.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:n}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:l.map(o=>(0,e.jsxs)("li",{className:"grid gap-2 py-2.5 sm:grid-cols-(--gtc-17) sm:items-center",children:[(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-sm font-medium",children:o.label}),(0,e.jsx)("div",{className:"truncate text-xs text-muted-foreground",children:o.sublabel})]}),(0,e.jsxs)("div",{className:"flex items-baseline gap-4 text-xs tabular-nums sm:justify-end",children:[(0,e.jsx)("span",{className:"text-muted-foreground",children:u(x(o))}),(0,e.jsx)("span",{className:"font-medium",children:N(o.costCents)})]})]},o.key))})]})}i(S,"UsageList");function ge(){const{userSlug:s=""}=J(),{selectedCompanyId:n}=L(),{setBreadcrumbs:l}=Z(),o=n??le,{data:a,isLoading:r,error:d}=P({queryKey:y.userProfile(o,s),queryFn:i(()=>re.get(o,s),"queryFn"),enabled:!!n&&!!s}),{data:f}=P({queryKey:y.auth.session,queryFn:i(()=>X.getSession(),"queryFn")}),{hidden:p}=te(),U=!!a?.user.id&&a?.user.id===f?.user.id&&!H(p,"instance.profile");(0,b.useEffect)(()=>{l([{label:"Users"},{label:a?.user.name??s}])},[a?.user.name,l,s]);const m=a?.stats.find(t=>t.key==="all"),v=a?.stats.find(t=>t.key==="last7"),j=a?.user.name?.trim()||a?.user.email?.split("@")[0]||"User",_=(0,b.useMemo)(()=>(a?.topAgents??[]).map(t=>({key:t.agentId??"unknown",label:t.agentName??(t.agentId?t.agentId.slice(0,8):"Microvac services"),sublabel:"Task-linked usage",costCents:t.costCents,inputTokens:t.inputTokens,cachedInputTokens:t.cachedInputTokens,outputTokens:t.outputTokens})),[a?.topAgents]),M=(0,b.useMemo)(()=>(a?.topProviders??[]).map(t=>({key:`${t.provider}:${t.biller}:${t.model}`,label:`${C(t.provider)} / ${t.model}`,sublabel:`Billed through ${C(t.biller)}`,costCents:t.costCents,inputTokens:t.inputTokens,cachedInputTokens:t.cachedInputTokens,outputTokens:t.outputTokens})),[a?.topProviders]);if(!n)return(0,e.jsx)(A,{icon:ae,message:"Select an organization to view user profiles."});if(r)return(0,e.jsx)(se,{variant:"dashboard"});if(d||!a)return(0,e.jsx)(A,{icon:z,message:"User profile not found for this organization."});const R=m?x(m):0,q=[a.user.membershipRole??"member",a.user.membershipStatus,`joined ${Q(a.user.joinedAt)}`];return(0,e.jsxs)("div",{className:"space-y-10 pb-10",children:[(0,e.jsxs)("section",{className:"flex flex-col gap-7 border-b border-border pb-8",children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-center gap-5",children:[(0,e.jsxs)(G,{className:"size-16 border border-border",size:"lg",children:[a.user.image?(0,e.jsx)(Y,{src:a.user.image,alt:j}):null,(0,e.jsx)(D,{className:"text-lg font-semibold",children:de(j)})]}),(0,e.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-baseline gap-x-3 gap-y-1",children:[(0,e.jsx)("h1",{className:"truncate text-2xl font-semibold",children:j}),(0,e.jsxs)("span",{className:"text-sm text-muted-foreground",children:["@",a.user.slug]})]}),(0,e.jsxs)("div",{className:"mt-1.5 flex flex-wrap items-center gap-x-3 gap-y-0.5 text-xs text-muted-foreground",children:[a.user.email?(0,e.jsx)("span",{className:"truncate",children:a.user.email}):null,a.user.email?(0,e.jsx)("span",{"aria-hidden":!0,children:"·"}):null,(0,e.jsx)("span",{children:q.join(" · ")})]})]}),U?(0,e.jsx)(F,{asChild:!0,variant:"outline",size:"sm",children:(0,e.jsxs)(k,{to:ie,children:[(0,e.jsx)(V,{}),"Edit profile"]})}):null]}),(0,e.jsxs)("div",{className:"grid gap-6 sm:grid-cols-2 lg:grid-cols-4",children:[(0,e.jsx)(g,{label:"All-time tokens",value:u(R),hint:N(m?.costCents??0)+" spent"}),(0,e.jsx)(g,{label:"Completed",value:c(m?.completedIssues??0),hint:m?`${E(m)} rate`:void 0}),(0,e.jsx)(g,{label:"Open assigned",value:c(m?.assignedOpenIssues??0),hint:`${c(m?.createdIssues??0)} created`}),(0,e.jsx)(g,{label:"7-day actions",value:c(v?.activityCount??0),hint:`${c(v?.commentCount??0)} comments`})]})]}),(0,e.jsx)("section",{className:"grid gap-8 border-b border-border pb-8 lg:grid-cols-3",children:a.stats.map(t=>(0,e.jsx)(ce,{stats:t},t.key))}),(0,e.jsx)(oe,{points:a.daily}),(0,e.jsxs)("div",{className:"grid gap-10 pt-2 xl:grid-cols-2",children:[(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Recent tasks"}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:a.recentIssues.length})]}),a.recentIssues.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:"No touched tasks yet."}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:a.recentIssues.map(t=>(0,e.jsx)("li",{children:(0,e.jsxs)(k,{to:K(t),className:"grid gap-2 py-2.5 transition-colors hover:bg-accent/40 sm:grid-cols-(--gtc-58) sm:items-center",children:[(0,e.jsx)("span",{className:"font-mono text-xs text-muted-foreground",children:t.identifier??t.id.slice(0,8)}),(0,e.jsx)("span",{className:"truncate text-sm",children:t.title}),(0,e.jsxs)("span",{className:"flex items-center gap-3 sm:justify-end",children:[(0,e.jsx)(B,{...W(t)}),(0,e.jsx)("span",{className:"text-xs tabular-nums text-muted-foreground",children:T(t.updatedAt)})]})]})},t.id))})]}),(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Recent activity"}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:a.recentActivity.length})]}),a.recentActivity.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:"No direct user actions recorded yet."}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:a.recentActivity.map(t=>(0,e.jsxs)("li",{className:"grid gap-2 py-2.5 sm:grid-cols-(--gtc-17) sm:items-center",children:[(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-sm",children:t.action.replaceAll("_"," ")}),(0,e.jsxs)("div",{className:"truncate text-xs text-muted-foreground",children:[t.entityType," · ",t.entityId.slice(0,12)]})]}),(0,e.jsx)("span",{className:"text-xs tabular-nums text-muted-foreground sm:justify-self-end",children:T(t.createdAt)})]},t.id))})]})]}),(0,e.jsxs)("div",{className:"grid gap-10 xl:grid-cols-2",children:[(0,e.jsx)(S,{title:"Agent attribution",empty:"No issue-linked token usage yet.",rows:_}),(0,e.jsx)(S,{title:"Provider mix",empty:"No provider usage attributed yet.",rows:M})]})]})}i(ge,"UserProfile");export{ge as UserProfile};
|
|
1
|
+
var w=Object.defineProperty;var i=(s,n)=>w(s,"name",{value:n,configurable:!0});import{a as $}from"./rolldown-runtime-DhZMWcEn.js";import{y as B}from"./collections-B58p51lw.js";import{$A as O,ET as z,Fb as D,GS as y,Gb as k,HE as N,LS as L,NE as F,PD as H,Pb as G,QE as K,Rb as Y,UE as Q,Up as W,XE as u,YE as I,YS as X,aE as J,dC as V,iD as T,ib as Z,nD as C,nj as ee,on as A,pb as se,qE as c,ry as te,uC as ae,uE as ne,xE as P}from"./index-BJtnP7H1.js";var b=$(ee(),1),re={get:i((s,n)=>ne.get(`/companies/${s}/users/${encodeURIComponent(n)}/profile`),"get")},e=$(O(),1),le="__none__",ie="/company/settings/instance/profile";function de(s){const n=s?.trim()||"User",l=n.split(/\s+/).filter(Boolean);return l.length>1?`${l[0]?.[0]??""}${l[l.length-1]?.[0]??""}`.toUpperCase():n.slice(0,2).toUpperCase()}i(de,"initials");function x(s){return s.inputTokens+s.cachedInputTokens+s.outputTokens}i(x,"totalTokens");function E(s){return s.touchedIssues===0?"0%":`${Math.round(s.completedIssues/s.touchedIssues*100)}%`}i(E,"completionRate");function g({label:s,value:n,hint:l}){return(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"text-2xl font-semibold tabular-nums sm:text-3xl",children:n}),(0,e.jsx)("div",{className:"mt-1 text-(length:--text-micro) font-medium uppercase tracking-wide text-muted-foreground",children:s}),l?(0,e.jsx)("div",{className:"mt-0.5 text-xs text-muted-foreground/70",children:l}):null]})}i(g,"HeroStat");function ce({stats:s}){const n=x(s);return(0,e.jsxs)("div",{className:"flex min-w-0 flex-col gap-4 border-l border-border pl-5 first:border-l-0 first:pl-0",children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3",children:[(0,e.jsx)("h2",{className:"text-(length:--text-micro) font-medium uppercase tracking-wide text-muted-foreground",children:s.label}),(0,e.jsxs)("span",{className:"text-(length:--text-micro) text-muted-foreground tabular-nums",children:[E(s)," done"]})]}),(0,e.jsxs)("div",{className:"grid grid-cols-2 gap-x-5 gap-y-3",children:[(0,e.jsx)(h,{value:c(s.touchedIssues),label:"Touched"}),(0,e.jsx)(h,{value:c(s.completedIssues),label:"Completed"}),(0,e.jsx)(h,{value:c(s.commentCount),label:"Comments"}),(0,e.jsx)(h,{value:c(s.activityCount),label:"Actions"})]}),(0,e.jsxs)("div",{className:"grid grid-cols-2 gap-x-5 gap-y-1.5 pt-3 text-xs tabular-nums text-muted-foreground",children:[(0,e.jsx)("span",{children:"Tokens"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:u(n)}),(0,e.jsx)("span",{children:"Spend"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:N(s.costCents)}),(0,e.jsx)("span",{children:"Created"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:c(s.createdIssues)}),(0,e.jsx)("span",{children:"Open"}),(0,e.jsx)("span",{className:"text-right text-foreground",children:c(s.assignedOpenIssues)})]})]})}i(ce,"WindowColumn");function h({value:s,label:n}){return(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-xl font-semibold tabular-nums",children:s}),(0,e.jsx)("div",{className:"mt-0.5 text-(length:--text-micro) text-muted-foreground",children:n})]})}i(h,"Metric");function oe({points:s}){const n=s.map(r=>x(r)),l=Math.max(1,...n),o=Math.max(1,...s.map(r=>r.completedIssues)),a=n.reduce((r,d)=>r+d,0);return(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Last 14 days"}),(0,e.jsxs)("div",{className:"flex items-baseline gap-4 text-xs text-muted-foreground",children:[(0,e.jsx)("span",{className:"tabular-nums text-foreground",children:u(a)}),(0,e.jsx)("span",{children:"tokens total"})]})]}),(0,e.jsx)("div",{className:"mt-6 grid grid-cols-(--gtc-57) items-end gap-1.5 sm:gap-2",children:s.map(r=>{const d=x(r),f=d===0?0:Math.max(2,Math.round(d/l*100)),p=r.completedIssues===0?0:Math.max(8,Math.round(r.completedIssues/o*36));return(0,e.jsxs)("div",{className:"group flex h-36 flex-col justify-end",children:[(0,e.jsx)("div",{className:"w-full bg-foreground/80 transition-opacity group-hover:bg-foreground",style:{height:`${f}%`,minHeight:d===0?1:void 0},title:`${I(r.date)}: ${u(d)} tokens, ${r.completedIssues} completed`}),p>0?(0,e.jsx)("div",{className:"mt-1 w-full rounded-full bg-emerald-500/80",style:{height:2,opacity:Math.min(1,.35+p/100)}}):null]},r.date)})}),(0,e.jsx)("div",{className:"mt-2 grid grid-cols-(--gtc-57) gap-1.5 text-(length:--text-nano) tabular-nums text-muted-foreground sm:gap-2",children:s.map((r,d)=>(0,e.jsx)("div",{className:"text-center",children:d===0||d===6||d===13?I(r.date):null},r.date))}),(0,e.jsxs)("div",{className:"mt-4 flex flex-wrap items-center gap-4 text-(length:--text-nano) uppercase tracking-wide text-muted-foreground",children:[(0,e.jsxs)("span",{className:"inline-flex items-center gap-1.5",children:[(0,e.jsx)("span",{className:"h-2 w-2 bg-foreground/80"})," tokens / day"]}),(0,e.jsxs)("span",{className:"inline-flex items-center gap-1.5",children:[(0,e.jsx)("span",{className:"h-(--sz-3px) w-4 rounded-full bg-emerald-500/80"})," completions"]})]})]})}i(oe,"UsageChart");function S({title:s,empty:n,rows:l}){return(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:s}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:l.length})]}),l.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:n}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:l.map(o=>(0,e.jsxs)("li",{className:"grid gap-2 py-2.5 sm:grid-cols-(--gtc-17) sm:items-center",children:[(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-sm font-medium",children:o.label}),(0,e.jsx)("div",{className:"truncate text-xs text-muted-foreground",children:o.sublabel})]}),(0,e.jsxs)("div",{className:"flex items-baseline gap-4 text-xs tabular-nums sm:justify-end",children:[(0,e.jsx)("span",{className:"text-muted-foreground",children:u(x(o))}),(0,e.jsx)("span",{className:"font-medium",children:N(o.costCents)})]})]},o.key))})]})}i(S,"UsageList");function ge(){const{userSlug:s=""}=J(),{selectedCompanyId:n}=L(),{setBreadcrumbs:l}=Z(),o=n??le,{data:a,isLoading:r,error:d}=P({queryKey:y.userProfile(o,s),queryFn:i(()=>re.get(o,s),"queryFn"),enabled:!!n&&!!s}),{data:f}=P({queryKey:y.auth.session,queryFn:i(()=>X.getSession(),"queryFn")}),{hidden:p}=te(),U=!!a?.user.id&&a?.user.id===f?.user.id&&!H(p,"instance.profile");(0,b.useEffect)(()=>{l([{label:"Users"},{label:a?.user.name??s}])},[a?.user.name,l,s]);const m=a?.stats.find(t=>t.key==="all"),v=a?.stats.find(t=>t.key==="last7"),j=a?.user.name?.trim()||a?.user.email?.split("@")[0]||"User",_=(0,b.useMemo)(()=>(a?.topAgents??[]).map(t=>({key:t.agentId??"unknown",label:t.agentName??(t.agentId?t.agentId.slice(0,8):"Microvac services"),sublabel:"Task-linked usage",costCents:t.costCents,inputTokens:t.inputTokens,cachedInputTokens:t.cachedInputTokens,outputTokens:t.outputTokens})),[a?.topAgents]),M=(0,b.useMemo)(()=>(a?.topProviders??[]).map(t=>({key:`${t.provider}:${t.biller}:${t.model}`,label:`${C(t.provider)} / ${t.model}`,sublabel:`Billed through ${C(t.biller)}`,costCents:t.costCents,inputTokens:t.inputTokens,cachedInputTokens:t.cachedInputTokens,outputTokens:t.outputTokens})),[a?.topProviders]);if(!n)return(0,e.jsx)(A,{icon:ae,message:"Select an organization to view user profiles."});if(r)return(0,e.jsx)(se,{variant:"dashboard"});if(d||!a)return(0,e.jsx)(A,{icon:z,message:"User profile not found for this organization."});const R=m?x(m):0,q=[a.user.membershipRole??"member",a.user.membershipStatus,`joined ${Q(a.user.joinedAt)}`];return(0,e.jsxs)("div",{className:"space-y-10 pb-10",children:[(0,e.jsxs)("section",{className:"flex flex-col gap-7 border-b border-border pb-8",children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-center gap-5",children:[(0,e.jsxs)(G,{className:"size-16 border border-border",size:"lg",children:[a.user.image?(0,e.jsx)(Y,{src:a.user.image,alt:j}):null,(0,e.jsx)(D,{className:"text-lg font-semibold",children:de(j)})]}),(0,e.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,e.jsxs)("div",{className:"flex flex-wrap items-baseline gap-x-3 gap-y-1",children:[(0,e.jsx)("h1",{className:"truncate text-2xl font-semibold",children:j}),(0,e.jsxs)("span",{className:"text-sm text-muted-foreground",children:["@",a.user.slug]})]}),(0,e.jsxs)("div",{className:"mt-1.5 flex flex-wrap items-center gap-x-3 gap-y-0.5 text-xs text-muted-foreground",children:[a.user.email?(0,e.jsx)("span",{className:"truncate",children:a.user.email}):null,a.user.email?(0,e.jsx)("span",{"aria-hidden":!0,children:"·"}):null,(0,e.jsx)("span",{children:q.join(" · ")})]})]}),U?(0,e.jsx)(F,{asChild:!0,variant:"outline",size:"sm",children:(0,e.jsxs)(k,{to:ie,children:[(0,e.jsx)(V,{}),"Edit profile"]})}):null]}),(0,e.jsxs)("div",{className:"grid gap-6 sm:grid-cols-2 lg:grid-cols-4",children:[(0,e.jsx)(g,{label:"All-time tokens",value:u(R),hint:N(m?.costCents??0)+" spent"}),(0,e.jsx)(g,{label:"Completed",value:c(m?.completedIssues??0),hint:m?`${E(m)} rate`:void 0}),(0,e.jsx)(g,{label:"Open assigned",value:c(m?.assignedOpenIssues??0),hint:`${c(m?.createdIssues??0)} created`}),(0,e.jsx)(g,{label:"7-day actions",value:c(v?.activityCount??0),hint:`${c(v?.commentCount??0)} comments`})]})]}),(0,e.jsx)("section",{className:"grid gap-8 border-b border-border pb-8 lg:grid-cols-3",children:a.stats.map(t=>(0,e.jsx)(ce,{stats:t},t.key))}),(0,e.jsx)(oe,{points:a.daily}),(0,e.jsxs)("div",{className:"grid gap-10 pt-2 xl:grid-cols-2",children:[(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Recent tasks"}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:a.recentIssues.length})]}),a.recentIssues.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:"No touched tasks yet."}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:a.recentIssues.map(t=>(0,e.jsx)("li",{children:(0,e.jsxs)(k,{to:K(t),className:"grid gap-2 py-2.5 transition-colors hover:bg-accent/40 sm:grid-cols-(--gtc-58) sm:items-center",children:[(0,e.jsx)("span",{className:"font-mono text-xs text-muted-foreground",children:t.identifier??t.id.slice(0,8)}),(0,e.jsx)("span",{className:"truncate text-sm",children:t.title}),(0,e.jsxs)("span",{className:"flex items-center gap-3 sm:justify-end",children:[(0,e.jsx)(B,{...W(t)}),(0,e.jsx)("span",{className:"text-xs tabular-nums text-muted-foreground",children:T(t.updatedAt)})]})]})},t.id))})]}),(0,e.jsxs)("section",{children:[(0,e.jsxs)("div",{className:"flex items-baseline justify-between gap-3 border-b border-border pb-3",children:[(0,e.jsx)("h2",{className:"text-sm font-semibold",children:"Recent activity"}),(0,e.jsx)("span",{className:"text-xs text-muted-foreground tabular-nums",children:a.recentActivity.length})]}),a.recentActivity.length===0?(0,e.jsx)("div",{className:"pt-4 text-sm text-muted-foreground",children:"No direct user actions recorded yet."}):(0,e.jsx)("ul",{className:"divide-y divide-border",children:a.recentActivity.map(t=>(0,e.jsxs)("li",{className:"grid gap-2 py-2.5 sm:grid-cols-(--gtc-17) sm:items-center",children:[(0,e.jsxs)("div",{className:"min-w-0",children:[(0,e.jsx)("div",{className:"truncate text-sm",children:t.action.replaceAll("_"," ")}),(0,e.jsxs)("div",{className:"truncate text-xs text-muted-foreground",children:[t.entityType," · ",t.entityId.slice(0,12)]})]}),(0,e.jsx)("span",{className:"text-xs tabular-nums text-muted-foreground sm:justify-self-end",children:T(t.createdAt)})]},t.id))})]})]}),(0,e.jsxs)("div",{className:"grid gap-10 xl:grid-cols-2",children:[(0,e.jsx)(S,{title:"Agent attribution",empty:"No issue-linked token usage yet.",rows:_}),(0,e.jsx)(S,{title:"Provider mix",empty:"No provider usage attributed yet.",rows:M})]})]})}i(ge,"UserProfile");export{ge as UserProfile};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var p=Object.defineProperty;var a=(r,t)=>p(r,"name",{value:t,configurable:!0});import{a as h}from"./rolldown-runtime-DhZMWcEn.js";import{$A as u,pm as d}from"./index-
|
|
1
|
+
var p=Object.defineProperty;var a=(r,t)=>p(r,"name",{value:t,configurable:!0});import{a as h}from"./rolldown-runtime-DhZMWcEn.js";import{$A as u,pm as d}from"./index-BJtnP7H1.js";function c(r){const[t,e]=r;return t===127||t===0?"loopback":t===10||t===172&&e>=16&&e<=31||t===192&&e===168||t===169&&e===254||t===100&&e>=64&&e<=127?"private":null}a(c,"ipv4Warning");function f(r){if(!r)return null;let t;try{t=new URL(r)}catch{return"invalid"}if(t.protocol!=="http:"&&t.protocol!=="https:")return"invalid";const e=t.hostname.toLowerCase().replace(/^\[|\]$/g,"").replace(/\.$/,"");if(e==="localhost"||e.endsWith(".localhost")||e==="::1"||e==="::")return"loopback";if(e.includes(":")){const n=/^::ffff:([\da-f]{1,4}):([\da-f]{1,4})$/.exec(e);if(n){const i=parseInt(n[1],16),o=parseInt(n[2],16),l=c([i>>8,i&255,o>>8,o&255]);if(l)return l}if(/^(f[cd][\da-f]{2}|fe[89ab][\da-f]|fec[\da-f]):/.test(e))return"private"}else if(/^\d+\.\d+\.\d+\.\d+$/.test(e)){const n=c(e.split(".").map(Number));if(n)return n}else{if(e.endsWith(".ts.net"))return"tailscale";if(!e.includes(".")||/\.(local|internal|lan|home|corp|intranet|private|test)$/.test(e)||e.endsWith(".home.arpa"))return"private"}return t.protocol==="https:"?null:"https"}a(f,"webhookUrlWarningReason");var s=h(u(),1),T={loopback:{title:"Other apps can’t reach this localhost URL",message:"This address points back to the machine sending the request. Services such as GitHub can’t use it to reach Microvac on your computer."},private:{title:"This webhook URL appears to be private",message:"Only senders with access to this network can reach this address. Apps on the public internet, such as GitHub, usually can’t deliver webhooks here."},tailscale:{title:"This Tailscale URL may not be public",message:"Tailscale Serve is private to your tailnet, even with HTTPS. Apps outside your tailnet need Tailscale Funnel or another public HTTPS address. If Funnel is already enabled for this URL, you can continue."},https:{title:"Use HTTPS for webhooks from other apps",message:"This URL uses HTTP. Many apps require HTTPS, and HTTP does not encrypt webhook credentials or payloads."},invalid:{title:"Check the webhook URL",message:"This is not a valid HTTP or HTTPS URL. Your sending app needs a complete address it can reach."}};function v({url:r}){const t=f(r);if(!t)return null;const e=T[t];return(0,s.jsx)(d,{tone:"warning",title:e.title,children:(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)("p",{children:e.message}),(0,s.jsx)("p",{children:"You can continue for local or private-network use. For public senders, use a publicly reachable HTTPS URL."}),(0,s.jsx)("a",{className:"underline underline-offset-4",href:"https://docs.paperclip.ing/reference/deploy/https/",target:"_blank",rel:"noopener noreferrer",children:"Learn how to set up HTTPS and public access"})]})})}a(v,"WebhookUrlWarning");export{v as t};
|