dorkos 0.128.0 → 0.129.0
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/bin/cli.js +84 -16
- package/dist/browser/native/package-manifest.json +1 -1
- package/dist/browser/source-manifest.json +1 -1
- package/dist/client/assets/{AboutPage-CmQERFxo.js → AboutPage-CML_SdU1.js} +1 -1
- package/dist/client/assets/{ActivityErrorState-Dw231W2w.js → ActivityErrorState-TuQRJopr.js} +1 -1
- package/dist/client/assets/{ActivityPage-DVfeyA9u.js → ActivityPage-CmSxeVSK.js} +1 -1
- package/dist/client/assets/ActivityRow-DJhDehIR.js +1 -0
- package/dist/client/assets/{AdapterIcon-NqCDzgCI.js → AdapterIcon-CeRDpZGz.js} +1 -1
- package/dist/client/assets/AdapterSetupWizard-B6KkTuJo.js +2 -0
- package/dist/client/assets/{AgentOptionRow-BRJfZo2y.js → AgentOptionRow-388OJkPc.js} +1 -1
- package/dist/client/assets/{AgentPicker-B7upjYRk.js → AgentPicker-C51wqToQ.js} +1 -1
- package/dist/client/assets/{AgentRequestCard-DXJnLk6q.js → AgentRequestCard-Bz31ewIs.js} +4 -4
- package/dist/client/assets/AppearancePage-DSVeowGb.js +1 -0
- package/dist/client/assets/{ApplyToOverridesDialog-C_QQhNIf.js → ApplyToOverridesDialog-DRtcLrVY.js} +1 -1
- package/dist/client/assets/AttentionSignalRow-CqKZyoxB.js +1 -0
- package/dist/client/assets/{BaseTanStackRouterDevtoolsPanel-B-iktbLX-G7vrCqeA.js → BaseTanStackRouterDevtoolsPanel-B-iktbLX-DA1jhqFy.js} +3 -3
- package/dist/client/assets/BindingDialog-D25PAed0.js +1 -0
- package/dist/client/assets/{BlintzCanvas-DruVZcDU.js → BlintzCanvas-BgIQdpTx.js} +3 -3
- package/dist/client/assets/{CanvasCsvContent-CtLpZnTs.js → CanvasCsvContent-ZWHWmb88.js} +4 -4
- package/dist/client/assets/CanvasFileContent-DR5pUgca.js +2 -0
- package/dist/client/assets/CanvasModel3dContent-OP1ZOMui.js +2 -0
- package/dist/client/assets/ChannelComposer-BJ0nNzQb.js +45 -0
- package/dist/client/assets/{ChatAppsOff-CCZUzDIH.js → ChatAppsOff-ByitL4Xt.js} +2 -2
- package/dist/client/assets/{CodeMirrorDiff-BCpYdhgZ.js → CodeMirrorDiff-JsV_vWBa.js} +1 -1
- package/dist/client/assets/{CodeMirrorEditor-BeCubxHV.js → CodeMirrorEditor-BfCJG9hQ.js} +1 -1
- package/dist/client/assets/{CommitmentList-BZtfTnwg.js → CommitmentList-yFV3_m00.js} +1 -1
- package/dist/client/assets/{CommitmentsPage-DmurDgxV.js → CommitmentsPage-DeERVg-2.js} +1 -1
- package/dist/client/assets/{ComputerResourceView-Bik6GLKp.js → ComputerResourceView-CYMMSE8Y.js} +1 -1
- package/dist/client/assets/{ComputerViewer-CksBDqdu.js → ComputerViewer-H7kJSIj7.js} +1 -1
- package/dist/client/assets/ConnectionAccessLists-SRkf7-Y6.js +1 -0
- package/dist/client/assets/{ConnectionsPage-Cgg36gDY.js → ConnectionsPage-D6e3hd4L.js} +2 -2
- package/dist/client/assets/{ConventionPage-CNhpF6Z1.js → ConventionPage-CpvRMcSG.js} +2 -2
- package/dist/client/assets/{ExtensionPageRoute-C2zue_Pw.js → ExtensionPageRoute-CiFv6we8.js} +2 -2
- package/dist/client/assets/{FloatingTanStackRouterDevtools-CqogiFob-3v1TfY1P.js → FloatingTanStackRouterDevtools-CqogiFob-D-8CeYC7.js} +1 -1
- package/dist/client/assets/{ForwardConsentHost-Mbo0D-zk.js → ForwardConsentHost-ml3b_fsX.js} +1 -1
- package/dist/client/assets/HandlePage-Bq5qdCfY.js +1 -0
- package/dist/client/assets/HeartbeatPage-C0zSvWH4.js +1 -0
- package/dist/client/assets/{KeyEntry-C43vkwpA.js → KeyEntry-Dq6eKAbX.js} +1 -1
- package/dist/client/assets/{LexicalField-iAHcvRmI.js → LexicalField-CYOqOLpV.js} +1 -1
- package/dist/client/assets/{ManagesPage-BUIJvLmv.js → ManagesPage-DZTMD3Al.js} +1 -1
- package/dist/client/assets/Marketplace-buSfuVrY.js +36 -0
- package/dist/client/assets/{MarketplaceSourcesView-BZODwhxu.js → MarketplaceSourcesView-BxwvBWgh.js} +1 -1
- package/dist/client/assets/{McpAppFrame-D15nxVaI.js → McpAppFrame-CWiRFp8o.js} +2 -2
- package/dist/client/assets/{McpSigninBody-DmBxqgxN.js → McpSigninBody-BpYSAV1h.js} +1 -1
- package/dist/client/assets/{Model3dViewer-RGXeJd6a.js → Model3dViewer-B2KTvx6d.js} +1 -1
- package/dist/client/assets/NamePage-_yT2RQvT.js +1 -0
- package/dist/client/assets/{NewDirectMessageMenu-DBAdvv5p.js → NewDirectMessageMenu-CMp4ppiH.js} +1 -1
- package/dist/client/assets/{NotificationsPage-NRfyiinS.js → NotificationsPage-CWXIghVM.js} +1 -1
- package/dist/client/assets/{OpenMeshSwitch-CgQ6uefo.js → OpenMeshSwitch-C9hiAEHP.js} +2 -2
- package/dist/client/assets/OperatorIdentityForm-CjmMoP6n.js +1 -0
- package/dist/client/assets/{PermissionHistory-DPEPq8D9.js → PermissionHistory-D_Imuq02.js} +1 -1
- package/dist/client/assets/{PermissionsPage--k-xutbJ.js → PermissionsPage-QMLV8PfB.js} +1 -1
- package/dist/client/assets/{PersonalityPopover-DMMptmPS.js → PersonalityPopover-BL9DLK0Q.js} +1 -1
- package/dist/client/assets/PhotoPage-Djh4IZBF.js +1 -0
- package/dist/client/assets/PreviewRefusedNotice-Dt2hV0aJ.js +1 -0
- package/dist/client/assets/{ProfileFields-DbPJ7fvN.js → ProfileFields-DD6X85w2.js} +1 -1
- package/dist/client/assets/{ProfilePanelContainer-CzwhrIlw.js → ProfilePanelContainer-DuFEpNJ3.js} +1 -1
- package/dist/client/assets/{ProfileRolePicker-CZEXvlJm.js → ProfileRolePicker-CT9eJ1J0.js} +1 -1
- package/dist/client/assets/PromptSuggestionChips-C8V611-5.js +1 -0
- package/dist/client/assets/{ReportsToPopover-YOwGLJy5.js → ReportsToPopover-Bs55bP7b.js} +1 -1
- package/dist/client/assets/RoomSurface-DXZ36tmU.js +1 -0
- package/dist/client/assets/{RoomsPage-CoXjZMWL.js → RoomsPage-CDiSwt-I.js} +1 -1
- package/dist/client/assets/RunsOnPopover-CFBDa9DO.js +1 -0
- package/dist/client/assets/RuntimeConnectFlow-DsawxJN7.js +1 -0
- package/dist/client/assets/RuntimeSetupDialog-bdf844gx.js +1 -0
- package/dist/client/assets/{SeenDevices-Bh2yh-PW.js → SeenDevices-Cix5nnGQ.js} +2 -2
- package/dist/client/assets/{SessionsPage-CFvkbT9X.js → SessionsPage-CCu8rM-J.js} +1 -1
- package/dist/client/assets/SettingsDialog-D7sVluoe.js +12 -0
- package/dist/client/assets/SkillsPage-SSq7ofgp.js +1 -0
- package/dist/client/assets/TaskDialogWrapper-CBIuIbmj.js +1 -0
- package/dist/client/assets/TasksEmptyState-C0K_NOA3.js +3 -0
- package/dist/client/assets/{TasksPage-D0Zi6Mve.js → TasksPage-BpSn7GmR.js} +1 -1
- package/dist/client/assets/{TeamComputerEntry-CY9eLVad.js → TeamComputerEntry-BAi9omUC.js} +1 -1
- package/dist/client/assets/{ToolsPage-0_vx5P-F.js → ToolsPage-nkGWy6MR.js} +2 -2
- package/dist/client/assets/{TopologyGraph-DUZLZZrB.js → TopologyGraph-D6SSv0kC.js} +14 -14
- package/dist/client/assets/TourHost-CrZciWIf.js +1 -0
- package/dist/client/assets/{UnlinkDialog-ptZy3IN4.js → UnlinkDialog-B9zw8r6F.js} +1 -1
- package/dist/client/assets/{UnreadDivider-Ckey1IWn.js → UnreadDivider-BnJ06LmP.js} +1 -1
- package/dist/client/assets/WidgetErrorCard-CQKYI7oK.js +108 -0
- package/dist/client/assets/{WithheldExtensionsNotice-7Vu1Jctn.js → WithheldExtensionsNotice-VMM5NjL5.js} +1 -1
- package/dist/client/assets/WorkView-D5d8DDxS.js +51 -0
- package/dist/client/assets/_shell-CTKp94uQ.js +80 -0
- package/dist/client/assets/{_shell._home-BRIXhYLg.js → _shell._home-CcfELPIk.js} +1 -1
- package/dist/client/assets/_shell._home.activity-CGKsuLq8.js +1 -0
- package/dist/client/assets/_shell._home.index-DrJRgJCb.js +3 -0
- package/dist/client/assets/_shell._home.tasks-B_lv_-fX.js +1 -0
- package/dist/client/assets/_shell._home.workspaces-CjBJymCW.js +1 -0
- package/dist/client/assets/{_shell.channels-Bx6q9xVH.js → _shell.channels-CzQFR6pU.js} +4 -4
- package/dist/client/assets/_shell.connections-B5hafeep.js +1 -0
- package/dist/client/assets/{_shell.feedback-requests-DFznTGbN.js → _shell.feedback-requests-DtD2bH-4.js} +2 -2
- package/dist/client/assets/_shell.marketplace-DUpaCb0r.js +1 -0
- package/dist/client/assets/_shell.marketplace_.sources-C3pA7zZW.js +1 -0
- package/dist/client/assets/_shell.session-DH_9f3AK.js +1 -0
- package/dist/client/assets/{_shell.team-DmA09abY.js → _shell.team-BrGo-IxK.js} +6 -6
- package/dist/client/assets/_shell.threads-Ceq_tmNk.js +1 -0
- package/dist/client/assets/_shell.x._extensionId-DaXLhYNr.js +1 -0
- package/dist/client/assets/_shell.x._extensionId_._-DaXLhYNr.js +1 -0
- package/dist/client/assets/{abnfDiagram-WEYOIA3C-DxgtVd9I.js → abnfDiagram-WEYOIA3C-BN5bqwbu.js} +1 -1
- package/dist/client/assets/{access-copy-Dqct36mi.js → access-copy-BAhTOOsG.js} +1 -1
- package/dist/client/assets/{arc-C-67Ef0p.js → arc-BfTE_VoF.js} +1 -1
- package/dist/client/assets/{architectureDiagram-ZHVYKT53-B7TjdT-_.js → architectureDiagram-ZHVYKT53-Dc6keeDz.js} +1 -1
- package/dist/client/assets/{banner-C9qTs6-C.js → banner-DOgGDCJ5.js} +2 -2
- package/dist/client/assets/{blockDiagram-RJAE7QA3-DNqxJ3Ww.js → blockDiagram-RJAE7QA3-B4c6U-ob.js} +1 -1
- package/dist/client/assets/{c4Diagram-XDPPPE54-D3jNLV0j.js → c4Diagram-XDPPPE54-CCtD8QC8.js} +1 -1
- package/dist/client/assets/channel-CF9_Q7CV.js +1 -0
- package/dist/client/assets/{chunk-2E7WHVMD-C6OKx0ty.js → chunk-2E7WHVMD-DcDNqIJG.js} +1 -1
- package/dist/client/assets/{chunk-2Q5K7J3B-Dr_6hHrZ.js → chunk-2Q5K7J3B-DOVVK0B8.js} +1 -1
- package/dist/client/assets/{chunk-4EMNKR2T-CSrZVDEt.js → chunk-4EMNKR2T-Cg-Do982.js} +1 -1
- package/dist/client/assets/{chunk-55XCU76K-CIazeRXO.js → chunk-55XCU76K-CDmULSeY.js} +1 -1
- package/dist/client/assets/{chunk-5VM5RSS4-C8IJ3zTR.js → chunk-5VM5RSS4-Bi0yIWW1.js} +1 -1
- package/dist/client/assets/{chunk-JWPE2WC7-D9DGXb79.js → chunk-JWPE2WC7-ZHaJh6CV.js} +1 -1
- package/dist/client/assets/{chunk-VQ5W62QI-B0LNYdif.js → chunk-VQ5W62QI-DZi6GyW_.js} +1 -1
- package/dist/client/assets/{chunk-XXDRQBXY-C7IAIbvZ.js → chunk-XXDRQBXY-D18oZOrd.js} +1 -1
- package/dist/client/assets/{chunk-ZCHMQSOR-C79hvjlu.js → chunk-ZCHMQSOR-BkZ0l0fE.js} +2 -2
- package/dist/client/assets/{classDiagram-v2-4MYWR3UA-0Di1C2ZB.js → classDiagram-v2-4MYWR3UA-BfmK1buF.js} +1 -1
- package/dist/client/assets/{command-BVQb6I3_.js → command-CZqA020F.js} +1 -1
- package/dist/client/assets/copy-button-ByA00JGh.js +1 -0
- package/dist/client/assets/{cose-bilkent-JH36ORCC-rZumaV4b.js → cose-bilkent-JH36ORCC-B1NTVSbk.js} +1 -1
- package/dist/client/assets/{cpu-DeRuDMl4.js → cpu-DNvpMmNN.js} +1 -1
- package/dist/client/assets/{cynefin-EF2NZ3EQ-CI9l9xhM.js → cynefin-EF2NZ3EQ-CB_HMIZ8.js} +1 -1
- package/dist/client/assets/{cynefinDiagram-WF24UDRP-C8CdorJJ.js → cynefinDiagram-WF24UDRP-MmIWYdc2.js} +1 -1
- package/dist/client/assets/{dagre-NK4GIZVX-AHpsTq1O.js → dagre-NK4GIZVX-BQay0k4e.js} +1 -1
- package/dist/client/assets/detail-row-290qyusq.js +1 -0
- package/dist/client/assets/{diagram-CBK3MWTC-BpPLL30n.js → diagram-CBK3MWTC-C1lRH4cb.js} +1 -1
- package/dist/client/assets/{diagram-I5XIIV2D-D6loMn3G.js → diagram-I5XIIV2D-CnANa27A.js} +1 -1
- package/dist/client/assets/{diagram-ODIL2UCW-BaGNd5eN.js → diagram-ODIL2UCW-Cwt7hxes.js} +1 -1
- package/dist/client/assets/{diagram-PFBEJUXE-BnDdKu_g.js → diagram-PFBEJUXE-DZtAER77.js} +1 -1
- package/dist/client/assets/{diagram-RJA3I4VV-UXagB0_c.js → diagram-RJA3I4VV-CbVXbiGs.js} +1 -1
- package/dist/client/assets/{diagram-TYUNFSNR-C-whBP-S.js → diagram-TYUNFSNR-D-AcGdsL.js} +1 -1
- package/dist/client/assets/{ebnfDiagram-V4P3TTPT-BbG481iS.js → ebnfDiagram-V4P3TTPT-DLkrFSAy.js} +1 -1
- package/dist/client/assets/{elk-QONTBCTQ-FtssIxOc.js → elk-QONTBCTQ-DQM6Glxa.js} +1 -1
- package/dist/client/assets/{empty-state-CACt-76q.js → empty-state-BnuM8oop.js} +1 -1
- package/dist/client/assets/{erDiagram-KYQIGQAA-PpFgUf4C.js → erDiagram-KYQIGQAA-C1qgB1Mn.js} +1 -1
- package/dist/client/assets/{execution-config-CGL73sRn.js → execution-config-BjLHHc9x.js} +1 -1
- package/dist/client/assets/{file-D80JE_L0.js → file-D7_QdH_S.js} +1 -1
- package/dist/client/assets/{file-exclamation-point-CcJ_e4_m.js → file-exclamation-point-Cdt8YqyQ.js} +1 -1
- package/dist/client/assets/{file-text-Ds9edaTZ.js → file-text-CB9l6Ur-.js} +1 -1
- package/dist/client/assets/{find-latest-widget-fence-BtqFMP_f.js → find-latest-widget-fence-SQB9WgjN.js} +5 -5
- package/dist/client/assets/{flowDiagram-IUGLLWBU-BIva66g9.js → flowDiagram-IUGLLWBU-DH-ePeFu.js} +1 -1
- package/dist/client/assets/form--HjBAzX8.js +1 -0
- package/dist/client/assets/{format-cron-BpGrgPLu.js → format-cron-svkfKW5b.js} +1 -1
- package/dist/client/assets/format-tokens-DymkROvy.js +1 -0
- package/dist/client/assets/{ganttDiagram-R7GPNTJY-CZqips_4.js → ganttDiagram-R7GPNTJY-fjb_iAW1.js} +1 -1
- package/dist/client/assets/{git-branch-B8JNwQ6q.js → git-branch-CPOwiT8a.js} +1 -1
- package/dist/client/assets/{gitGraphDiagram-PDYL7XHY-DoIc3lda.js → gitGraphDiagram-PDYL7XHY-CcCqH5T3.js} +1 -1
- package/dist/client/assets/{graph-yizM0vwL.js → graph-DS3J2jnN.js} +1 -1
- package/dist/client/assets/{heart-BavUIV45.js → heart-C6uRnXx3.js} +1 -1
- package/dist/client/assets/{highlighted-body-KPVGNVTW-CGr3AgaU.js → highlighted-body-KPVGNVTW-CNygKq0i.js} +1 -1
- package/dist/client/assets/image-lightbox-BQV3i0WJ.js +1 -0
- package/dist/client/assets/{image-off-C1uTDs9-.js → image-off-B88WBkcV.js} +1 -1
- package/dist/client/assets/{index-SOKlO1zZ.js → index-3CJSEcZE.js} +1 -1
- package/dist/client/assets/index-3JL8A9YZ.css +1 -0
- package/dist/client/assets/{index-BJEt9R_G.js → index-57qzL_5b.js} +1 -1
- package/dist/client/assets/index-5RD9flqf.js +1 -0
- package/dist/client/assets/{index-FhWMRBQP.js → index-B6pmysqs.js} +1 -1
- package/dist/client/assets/{index-DEiSJbvu.js → index-BIZNH5u1.js} +1 -1
- package/dist/client/assets/{index-BOhSPP-6.js → index-BKdXHSbr.js} +1 -1
- package/dist/client/assets/{index-B36osK_S.js → index-BN3zOTbR.js} +3 -3
- package/dist/client/assets/{index-DYEmUa5t.js → index-BNq_mnok.js} +1 -1
- package/dist/client/assets/index-BPp-rj-W.js +1 -0
- package/dist/client/assets/{index-DW4KUPHp.js → index-BTqJGL1_.js} +1 -1
- package/dist/client/assets/{index-CJXMgnYp.js → index-B_YZ5cyn.js} +1 -1
- package/dist/client/assets/{index-Dcd4NqFB.js → index-B_rc9Pb1.js} +1 -1
- package/dist/client/assets/{index-56EOd-zy.js → index-B_v2l2ND.js} +1 -1
- package/dist/client/assets/{index-QSXJR98z.js → index-Bktc0aFV.js} +1 -1
- package/dist/client/assets/index-BtTqA4_d.js +1 -0
- package/dist/client/assets/{index-CiGYtR9O.js → index-BxsALYNM.js} +1 -1
- package/dist/client/assets/index-C4Uak2ha.js +1 -0
- package/dist/client/assets/{index-FI_y_dND.js → index-C7I0BjyX.js} +1 -1
- package/dist/client/assets/{index-CoNMlH37.js → index-CEicS7Zi.js} +1 -1
- package/dist/client/assets/{index-1QfQImuJ.js → index-CLTrC-a-.js} +3 -3
- package/dist/client/assets/{index-CXBYgGja.js → index-CLVvKY2v.js} +1 -1
- package/dist/client/assets/{index-BKWJiERs.js → index-COXdXByr.js} +1 -1
- package/dist/client/assets/{index-CoKNU2F9.js → index-CTJA-mZu.js} +1 -1
- package/dist/client/assets/{index-BOEPL6hN.js → index-CZmU-67J.js} +1 -1
- package/dist/client/assets/{index-LwL5BpE4.js → index-Cbbw2ByB.js} +1 -1
- package/dist/client/assets/{index-C4t0UTU-.js → index-Cbk19RQp.js} +1 -1
- package/dist/client/assets/{index-DqkFtcGQ.js → index-D0QV18E0.js} +1 -1
- package/dist/client/assets/{index-7XeZCCDI.js → index-D5fV4hrl.js} +1 -1
- package/dist/client/assets/{index-CeDn1Ak1.js → index-DBAPfYwE.js} +1 -1
- package/dist/client/assets/{index-Cdod8zEY.js → index-DK8zHloW.js} +1 -1
- package/dist/client/assets/index-DO8NbOqk.js +1 -0
- package/dist/client/assets/{index-C8ZpJXTQ.js → index-DXZ-w0Z9.js} +1 -1
- package/dist/client/assets/{index-n_pnc-CO.js → index-DYQjub9g.js} +1 -1
- package/dist/client/assets/index-Daoy3TZ8.js +1 -0
- package/dist/client/assets/{index-tgbcsB6H.js → index-DdBvjuc4.js} +1 -1
- package/dist/client/assets/{index-X282DRZf.js → index-DhqeMM58.js} +2 -2
- package/dist/client/assets/{index-YSHcMqHa.js → index-Ds9wPt9M.js} +1 -1
- package/dist/client/assets/{index-Br6xDNvu.js → index-RQhQx8gq.js} +1 -1
- package/dist/client/assets/{index-CrTmY12y.js → index-UJpgX--l.js} +2 -2
- package/dist/client/assets/index-YUtEyz7O.js +1053 -0
- package/dist/client/assets/{index-BkJlIXqM.js → index-oc-yQ5Q4.js} +1 -1
- package/dist/client/assets/index-tRdq7FGO.js +1 -0
- package/dist/client/assets/{index-ZR5f82z2.js → index-um-0KSur.js} +1 -1
- package/dist/client/assets/{index.esm-CAeUe7uQ.js → index.esm-B10OaB6F.js} +1 -1
- package/dist/client/assets/{infoDiagram-MVDRKAX5-DweUdYSy.js → infoDiagram-MVDRKAX5-CGtvYWtj.js} +1 -1
- package/dist/client/assets/{inline-code-SYHTKcle.js → inline-code-BL-6EKVP.js} +1 -1
- package/dist/client/assets/{ishikawaDiagram-HPEHV2GE-DKNQIv7P.js → ishikawaDiagram-HPEHV2GE-ICsVVT2t.js} +1 -1
- package/dist/client/assets/{journeyDiagram-BOSHW7O7-DPD7F4VO.js → journeyDiagram-BOSHW7O7-DEmSX2Hn.js} +1 -1
- package/dist/client/assets/{kanban-definition-FNSA4HC5-B_uPSwxC.js → kanban-definition-FNSA4HC5-SAV5PQOr.js} +1 -1
- package/dist/client/assets/{layers-F4mvrI2l.js → layers-Bfdpn7ZM.js} +1 -1
- package/dist/client/assets/{lightbulb-a6nNsrzy.js → lightbulb-CSPTiZoi.js} +1 -1
- package/dist/client/assets/{link-2-yI2Tlm7Q.js → link-2-ZzmN9B9k.js} +1 -1
- package/dist/client/assets/{list-runtime-types-CsGil5te.js → list-runtime-types-7qV7HQ7K.js} +1 -1
- package/dist/client/assets/{markdown-content-Cjhsscbn.js → markdown-content-CiDXslQf.js} +1 -1
- package/dist/client/assets/mention-pill-CuSUdpn7.js +1 -0
- package/dist/client/assets/{mermaid.core-9PwG-9fN.js → mermaid.core-C-qvGQ5g.js} +4 -4
- package/dist/client/assets/{message-square-off-aV4NMCjd.js → message-square-off-BehEHG9c.js} +1 -1
- package/dist/client/assets/{mindmap-definition-6OY57UG3-BRbWmQkj.js → mindmap-definition-6OY57UG3-DzU2APoo.js} +1 -1
- package/dist/client/assets/{more-details-CRLU2HN4.js → more-details-DF2dJXMV.js} +1 -1
- package/dist/client/assets/{owner-notice-CTJbhUak.js → owner-notice-DoH-_Veh.js} +1 -1
- package/dist/client/assets/{package-sPggO7Dr.js → package-Fm_v1gMn.js} +1 -1
- package/dist/client/assets/{page-container-CnfDuiDC.js → page-container-Bcz5wJVR.js} +1 -1
- package/dist/client/assets/{pane-resize-handle-63OC5vfI.js → pane-resize-handle-_EuIpxzc.js} +1 -1
- package/dist/client/assets/{paperclip-WhPo3_WD.js → paperclip-AGN67YEM.js} +1 -1
- package/dist/client/assets/path-input-jrT0Ap4j.js +1 -0
- package/dist/client/assets/{pegDiagram-ECIUJNBX-Ct9Li_PA.js → pegDiagram-ECIUJNBX-CAyGJ7fm.js} +1 -1
- package/dist/client/assets/{pieDiagram-GNMPY74T-BAB5RA5v.js → pieDiagram-GNMPY74T-tmLJe1p-.js} +1 -1
- package/dist/client/assets/{plug-_q5iqunq.js → plug-C-4o4Kb8.js} +1 -1
- package/dist/client/assets/primer-trigger-CmE4Ib-X.js +3 -0
- package/dist/client/assets/{profile-errors-COcBx7w5.js → profile-errors-vJU1kT3U.js} +1 -1
- package/dist/client/assets/{progress-77FCPL2y.js → progress-BTu_QWg8.js} +1 -1
- package/dist/client/assets/{quadrantDiagram-D57K4MC3-BqPJVmMS.js → quadrantDiagram-D57K4MC3-CUr2zJoz.js} +1 -1
- package/dist/client/assets/{query-error-state-5236P3z0.js → query-error-state-BCX32dab.js} +1 -1
- package/dist/client/assets/{radio-C8xmfoqO.js → radio-DBitPjM1.js} +1 -1
- package/dist/client/assets/{railroadDiagram-Y72NRBL7-B8U11nT6.js → railroadDiagram-Y72NRBL7-Bk9OMEWz.js} +1 -1
- package/dist/client/assets/registry-DVPRVi8T.js +34 -0
- package/dist/client/assets/registry-DiFfRDdW.js +1 -0
- package/dist/client/assets/{relay-trace-schemas-B80E4EUn.js → relay-trace-schemas-C-1Js81V.js} +2 -2
- package/dist/client/assets/{repeat-CHmB_vD7.js → repeat-B1wCYWXI.js} +1 -1
- package/dist/client/assets/{requirementDiagram-EQYSW5RA-CzJ1gzTh.js → requirementDiagram-EQYSW5RA-B2pkljrw.js} +1 -1
- package/dist/client/assets/{room-files-source-B0gc97Ri.js → room-files-source-BDkq0-fd.js} +2 -2
- package/dist/client/assets/{rotate-ccw-clock-CCU6SVnv.js → rotate-ccw-clock-Ds8cHkxD.js} +1 -1
- package/dist/client/assets/{rotate-cw-B8WQa8O-.js → rotate-cw-hUzouNTK.js} +1 -1
- package/dist/client/assets/{sankeyDiagram-SY24JHO5-D4vQwyve.js → sankeyDiagram-SY24JHO5-DEW9eIPS.js} +1 -1
- package/dist/client/assets/scroll-area-RSd8NjrE.js +1 -0
- package/dist/client/assets/{sequenceDiagram-BLEHNHQU-BVnIsPQe.js → sequenceDiagram-BLEHNHQU-CoiCdD1D.js} +1 -1
- package/dist/client/assets/{shield-x-ijIbRppV.js → shield-x-KL4ZbHfz.js} +1 -1
- package/dist/client/assets/signed-in-Dzxe2378.js +1 -0
- package/dist/client/assets/{sizeCapture-INFHLROL-DGb1rAJL.js → sizeCapture-INFHLROL-BWGf0Ghs.js} +1 -1
- package/dist/client/assets/{soul-file-CXgYs25S.js → soul-file-BQXbWArv.js} +1 -1
- package/dist/client/assets/{stateDiagram-v2-A6IESKWZ-DeX3IKTm.js → stateDiagram-v2-A6IESKWZ-aeqwGZMB.js} +1 -1
- package/dist/client/assets/{swimlanes-B3ENRKFQ-DN5ljYhG.js → swimlanes-B3ENRKFQ-BkWhAAlV.js} +1 -1
- package/dist/client/assets/swimlanesDiagram-AYQRV4AK-CS2DMvLi.js +8 -0
- package/dist/client/assets/{table-D9ww_3Ij.js → table-CfLst6CF.js} +1 -1
- package/dist/client/assets/{timeline-definition-JXYKGLGB-DpRthC3r.js → timeline-definition-JXYKGLGB-C1BUxIfq.js} +1 -1
- package/dist/client/assets/{trust-posture-Dn2ciEE0.js → trust-posture-CfEIPM4Z.js} +1 -1
- package/dist/client/assets/{unplug-BZ8zSvfB.js → unplug-B3eDst8L.js} +1 -1
- package/dist/client/assets/{unverified-catalog-notice-CGy05tAO.js → unverified-catalog-notice-BqIWxQuN.js} +1 -1
- package/dist/client/assets/{use-bindings-BLAWQRpe.js → use-bindings-DhOKnybh.js} +1 -1
- package/dist/client/assets/{use-composer-prefs-ICOpilWK.js → use-composer-prefs-_rlNL0D8.js} +1 -1
- package/dist/client/assets/{use-connector-management-DEMGZy9N.js → use-connector-management-CHLdhBhC.js} +1 -1
- package/dist/client/assets/{use-deep-link-scroll-DxGYrks3.js → use-deep-link-scroll-BVkszEn2.js} +1 -1
- package/dist/client/assets/{use-delete-binding-Bnv3J5Fu.js → use-delete-binding-BET7vH2R.js} +1 -1
- package/dist/client/assets/{use-dev-links-BOcktLiE.js → use-dev-links-BjLPuSUC.js} +1 -1
- package/dist/client/assets/{use-direct-message-panel-D38tSozW.js → use-direct-message-panel-ClXVf94w.js} +1 -1
- package/dist/client/assets/{use-external-adapter-catalog-9qiNBqpc.js → use-external-adapter-catalog-D1INoacX.js} +1 -1
- package/dist/client/assets/use-filter-state-BRlb3qG3.js +6 -0
- package/dist/client/assets/use-full-activity-feed-GWBg-_1B.js +1 -0
- package/dist/client/assets/use-is-below-desktop-BjWA-tqP.js +1 -0
- package/dist/client/assets/{use-local-browser-B1huJhdg.js → use-local-browser-C-V2n_wd.js} +1 -1
- package/dist/client/assets/{use-mesh-topology-BTYAy6zc.js → use-mesh-topology-BzSFyR_s.js} +1 -1
- package/dist/client/assets/{use-mounted-ref-CaPc6Prv.js → use-mounted-ref-1T3JbkY1.js} +1 -1
- package/dist/client/assets/{use-notification-prefs-u76DPoP0.js → use-notification-prefs-qcYeVmLQ.js} +1 -1
- package/dist/client/assets/use-pending-read-C1oA2H00.js +1 -0
- package/dist/client/assets/use-personality-commit-CJb-rqmM.js +1 -0
- package/dist/client/assets/{use-promo-activation-5HG08FlB.js → use-promo-activation-CAJItujg.js} +3 -3
- package/dist/client/assets/{use-promo-dismissals-CO7-qhEl.js → use-promo-dismissals-C6bPU5Rm.js} +1 -1
- package/dist/client/assets/{use-pulse-freshness-D07Mv-Sa.js → use-pulse-freshness-Y11Ibit1.js} +1 -1
- package/dist/client/assets/{use-room-follow-claim-DRQBuAIe.js → use-room-follow-claim-Di-yvoJD.js} +1 -1
- package/dist/client/assets/{use-room-sessions-Bzk7rM40.js → use-room-sessions-CPDRbQAW.js} +1 -1
- package/dist/client/assets/{use-roving-tab-list-CcznVldj.js → use-roving-tab-list-DK0OzOUz.js} +1 -1
- package/dist/client/assets/{use-session-canvas-CpgE7tFb.js → use-session-canvas-DA2i9Mdm.js} +6 -6
- package/dist/client/assets/use-status-budget-jMg_w0rF.js +21 -0
- package/dist/client/assets/{use-transform-ByJGn3hq.js → use-transform-BX3r518L.js} +1 -1
- package/dist/client/assets/{use-unclaimed-chats-C-z5fstJ.js → use-unclaimed-chats-B0nk8b84.js} +1 -1
- package/dist/client/assets/use-update-config-Ce7sHmp2.js +1 -0
- package/dist/client/assets/{useMutationState-BF1EFtIZ.js → useMutationState-Rlga1GBT.js} +1 -1
- package/dist/client/assets/{usecaseDiagram-WPOLBNNX-efVKbRIX.js → usecaseDiagram-WPOLBNNX-mjIwRNL1.js} +1 -1
- package/dist/client/assets/{vennDiagram-Q3Y3IDCW-Bravmwce.js → vennDiagram-Q3Y3IDCW-BcDIpVa6.js} +1 -1
- package/dist/client/assets/{wardleyDiagram-IVAIDKWA-fR77zByv.js → wardleyDiagram-IVAIDKWA-NFX31kox.js} +1 -1
- package/dist/client/assets/{xychartDiagram-4URNHDU4-BphORSLh.js → xychartDiagram-4URNHDU4-DZZY7dL1.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/drizzle/20261031012841_dor3309_file_turn_on_offer.sql +2 -0
- package/dist/drizzle/20261101122330_schedule_declined_content_key.sql +1 -0
- package/dist/drizzle/meta/20261031012841_snapshot.json +14116 -0
- package/dist/drizzle/meta/20261101122330_snapshot.json +14123 -0
- package/dist/drizzle/meta/_journal.json +14 -0
- package/dist/server/index.js +6424 -4548
- package/dist/server/index.js.map +2 -2
- package/package.json +5 -5
- package/dist/client/assets/ActivityRow-DIBH4v9c.js +0 -1
- package/dist/client/assets/AdapterSetupWizard-Dle_b9qc.js +0 -2
- package/dist/client/assets/AppearancePage-DXbhUt2e.js +0 -1
- package/dist/client/assets/AttentionSignalRow-5E7TkG98.js +0 -1
- package/dist/client/assets/BindingDialog-q--8SDJF.js +0 -1
- package/dist/client/assets/CanvasFileContent-BThy5fjD.js +0 -2
- package/dist/client/assets/CanvasModel3dContent-BbgR73jh.js +0 -2
- package/dist/client/assets/ChannelComposer-qhk0KtW7.js +0 -44
- package/dist/client/assets/ConnectionAccessLists-DRwO1v0V.js +0 -1
- package/dist/client/assets/HandlePage-B4qbFi40.js +0 -1
- package/dist/client/assets/HeartbeatPage-BnNbQLCW.js +0 -1
- package/dist/client/assets/Marketplace-DbdLWz0-.js +0 -36
- package/dist/client/assets/NamePage-fhxyWDDY.js +0 -1
- package/dist/client/assets/OperatorIdentityForm-Bls5Vo_u.js +0 -1
- package/dist/client/assets/PhotoPage-CNHcXbz4.js +0 -1
- package/dist/client/assets/PreviewRefusedNotice-Ds4IO32o.js +0 -1
- package/dist/client/assets/PromptSuggestionChips-BXxC799Q.js +0 -1
- package/dist/client/assets/RoomSurface-DgH3a_Fv.js +0 -1
- package/dist/client/assets/RunsOnPopover-CEkkjrGg.js +0 -1
- package/dist/client/assets/RuntimeConnectFlow-DXWGgvCW.js +0 -1
- package/dist/client/assets/RuntimeSetupDialog-D6L1QhMF.js +0 -1
- package/dist/client/assets/SettingsDialog-BOOqWKcj.js +0 -12
- package/dist/client/assets/SkillsPage-ntCEhUIM.js +0 -1
- package/dist/client/assets/TaskDialogWrapper-vBWAWwTY.js +0 -1
- package/dist/client/assets/TasksEmptyState-C_3UkAbA.js +0 -3
- package/dist/client/assets/TourHost-B69XAKpE.js +0 -1
- package/dist/client/assets/WidgetErrorCard-BlqaIsPK.js +0 -108
- package/dist/client/assets/WorkView-BekLkR4O.js +0 -51
- package/dist/client/assets/_shell-Du0F-5fK.js +0 -80
- package/dist/client/assets/_shell._home.activity-5rihXoYF.js +0 -1
- package/dist/client/assets/_shell._home.index-BsLNqt4f.js +0 -3
- package/dist/client/assets/_shell._home.tasks-Cxs5tLWA.js +0 -1
- package/dist/client/assets/_shell._home.workspaces-CEHDdfbP.js +0 -1
- package/dist/client/assets/_shell.connections-Bm0WmgXH.js +0 -1
- package/dist/client/assets/_shell.marketplace-CsQ60Mlc.js +0 -1
- package/dist/client/assets/_shell.marketplace_.sources-DNyShS1x.js +0 -1
- package/dist/client/assets/_shell.session-BN42bV3w.js +0 -1
- package/dist/client/assets/_shell.threads-HH4EvufJ.js +0 -1
- package/dist/client/assets/_shell.x._extensionId-3ZlJV1iu.js +0 -1
- package/dist/client/assets/_shell.x._extensionId_._-3ZlJV1iu.js +0 -1
- package/dist/client/assets/card-DUmTNXJJ.js +0 -1
- package/dist/client/assets/channel-B7zgJbnU.js +0 -1
- package/dist/client/assets/form-D93N5lrK.js +0 -1
- package/dist/client/assets/image-lightbox-vgPEvSCc.js +0 -1
- package/dist/client/assets/index-B446r3dL.js +0 -1
- package/dist/client/assets/index-BGo1YiUE.js +0 -1
- package/dist/client/assets/index-BO3yPJt-.js +0 -1
- package/dist/client/assets/index-DE6uOpn4.js +0 -1
- package/dist/client/assets/index-Dag1qeZI.js +0 -1
- package/dist/client/assets/index-Dm0Tav7v.js +0 -1
- package/dist/client/assets/index-Dry_agqN.css +0 -1
- package/dist/client/assets/index-OQuvRZTD.js +0 -1058
- package/dist/client/assets/index-eVrGefuq.js +0 -1
- package/dist/client/assets/mention-pill-BsOeTJ2f.js +0 -1
- package/dist/client/assets/path-input-C2KIXdON.js +0 -1
- package/dist/client/assets/primer-trigger-B2tjuHBx.js +0 -3
- package/dist/client/assets/registry-BzXBOE9h.js +0 -34
- package/dist/client/assets/registry-sfhDu9q2.js +0 -1
- package/dist/client/assets/scroll-area-FwZwM74Q.js +0 -1
- package/dist/client/assets/search-x-Q18Wm-C5.js +0 -6
- package/dist/client/assets/signed-in-DEOMBWVX.js +0 -1
- package/dist/client/assets/swimlanesDiagram-AYQRV4AK-D8kHFWtL.js +0 -8
- package/dist/client/assets/use-full-activity-feed-CtQquOBW.js +0 -1
- package/dist/client/assets/use-is-below-desktop-CAGEAsCC.js +0 -1
- package/dist/client/assets/use-pending-read-D0y6i7G9.js +0 -1
- package/dist/client/assets/use-personality-commit-C3h8upDo.js +0 -1
- package/dist/client/assets/use-status-budget-Xn2sIeM1.js +0 -16
- package/dist/client/assets/use-update-config-L5NCTj3t.js +0 -1
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import{O as Y,aO as $e,a5 as fs,a7 as Be,a8 as gs,aI as js,aJ as O,r as h,m1 as Ns,j as s,G as g,Z as le,_ as ce,ej as bs,m2 as ne,m3 as ys,cJ as vs,m4 as ks,jy as Fe,m5 as Ts,m6 as Ss,bW as de,gO as ws,y as We,aZ as Cs,iv as Ge,cP as $,gW as Es,m7 as Is,m8 as _s,gU as As,m9 as F,dh as _,di as A,dj as R,by as ue,bz as me,bA as pe,bC as he,gY as Rs,aR as He,gV as Ds,ma as be,mb as Ms,mc as Os,g8 as Xe,g9 as Ps,ga as qe,e7 as Qe,md as Us,me as ie,mf as zs,fz as Ls,bb as $s,B as P,mg as Bs,mh as Fs,ab as Ws,mi as Ke,eN as Gs,ea as Hs,mj as ye,mk as Xs,k7 as qs,k8 as Qs,k9 as Ks,ka as Vs,ml as Ys,mm as Js,kb as ve,mn as Zs,f as et,ec as ee,jX as st,hh as xe,mo as tt,mp as nt,mq as Ve,mr as Ye,ms as it,bI as rt,bJ as at,bK as ot,bL as lt,a2 as Q,bM as ct,bN as dt,bO as ut,bQ as mt,e as H,eP as Je,lm as ke,dS as pt,I as ht,ln as xt,jW as ft,e9 as gt,aW as Ze,aT as fe,cw as jt,mt as Nt,e6 as U,mu as re,mv as ge,mw as es,mx as bt,cK as yt,my as ss,mz as K,mA as vt,cx as ts,mB as kt,mC as Tt,mD as St,lX as wt,bD as X,cz as ns,mE as Ct,kh as Et,as as It,f_ as _t,gZ as At,mF as Rt,mG as Dt,is as Mt,Y as Ot,J as Pt,X as Ut,af as zt,h8 as Lt,g1 as $t,ig as Bt,ew as Ft,hU as Wt,k4 as Gt,a3 as Ht,hl as Xt}from"./index-YUtEyz7O.js";import{G as q}from"./git-branch-CPOwiT8a.js";import{u as qt}from"./use-update-config-Ce7sHmp2.js";import{s as Qt}from"./settings-for-runtime-BoOa-ZFG.js";import{R as Kt,H as Vt,a as Yt,b as Jt}from"./RuntimeSetupDialog-bdf844gx.js";import{r as Zt}from"./RuntimeConnectFlow-DsawxJN7.js";import{U as Te}from"./unverified-catalog-notice-BqIWxQuN.js";import{f as se,a as en}from"./format-tokens-DymkROvy.js";import{L as sn}from"./layers-Bfdpn7ZM.js";import{D as L}from"./detail-row-290qyusq.js";import{C as tn,a as nn}from"./cpu-DNvpMmNN.js";/**
|
|
2
|
+
* @license lucide-react v1.48.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const is={name:"chart-column",size:24,node:[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],aliases:["bar-chart-3"]};is.node;const rn=Y(is);/**
|
|
7
|
+
* @license lucide-react v1.48.0 - ISC
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the ISC license.
|
|
10
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/const rs={name:"clipboard-copy",size:24,node:[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M8 4H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-2",key:"4jdomd"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v4",key:"3hqy98"}],["path",{d:"M21 14H11",key:"1bme5i"}],["path",{d:"m15 10-4 4 4 4",key:"5dvupr"}]]};rs.node;const an=Y(rs);/**
|
|
12
|
+
* @license lucide-react v1.48.0 - ISC
|
|
13
|
+
*
|
|
14
|
+
* This source code is licensed under the ISC license.
|
|
15
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
16
|
+
*/const as={name:"dollar-sign",size:24,node:[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]};as.node;const Se=Y(as);/**
|
|
17
|
+
* @license lucide-react v1.48.0 - ISC
|
|
18
|
+
*
|
|
19
|
+
* This source code is licensed under the ISC license.
|
|
20
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
21
|
+
*/const os={name:"wifi",size:24,node:[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]]};os.node;const B=Y(os);function on(e){var t;return((t=e==null?void 0:e.ui)==null?void 0:t.statusBar)??Ns}function ln(){const{data:e}=$e();return on(e)}function cn(){const e=fs(),t=Be(),n=gs({mutationKey:js,mutationFn:r=>e.updateConfig({ui:{statusBar:{pins:[...r]}}}),onMutate:async r=>{await t.cancelQueries({queryKey:O.current()});const a=t.getQueryData(O.current());return t.setQueryData(O.current(),o=>o!=null&&o.ui?{...o,ui:{...o.ui,statusBar:{pins:[...r]}}}:o),{previous:a}},onError:(r,a,o)=>{o&&o.previous!==void 0&&t.setQueryData(O.current(),o.previous)},onSettled:()=>{t.invalidateQueries({queryKey:O.current()})}});return{setPins:h.useCallback(r=>n.mutate(r),[n]),isPending:n.isPending}}const dn={duration:.2,ease:[.4,0,.2,1]},un="pointer-coarse:[&_button]:py-3",mn=1e3;function Fi({items:e,trailing:t,nameFirst:n}){const i=e.filter(a=>a.cluster==="left"),r=e.filter(a=>a.cluster==="right");return s.jsxs("div",{role:"toolbar","aria-label":"Chat status","aria-live":"polite","data-testid":"status-line",className:"text-muted-foreground flex items-center gap-2 overflow-hidden px-1 text-xs whitespace-nowrap pointer-coarse:min-h-11",children:[s.jsx(we,{items:i,className:g("flex-auto",n&&i.length>0?"min-w-10":"min-w-0"),style:n?{flexShrink:mn}:void 0}),s.jsx(we,{items:r,className:"min-w-0 shrink"}),t!==void 0&&s.jsx("span",{className:"flex shrink-0 items-center",children:t})]})}const pn=8;function hn(e,t){return pn**Math.max(0,t.indexOf(e.key))}function we({items:e,className:t,style:n}){const i=[...e].sort((r,a)=>a.severity-r.severity).map(r=>r.key);return s.jsx("div",{className:g("flex items-center gap-2",t),style:n,children:s.jsx(le,{initial:!1,mode:"popLayout",children:e.map((r,a)=>s.jsxs(ce.div,{"data-testid":`status-item-${r.key}`,"data-rigid":r.rigid?"true":void 0,"data-held":r.held?"true":void 0,"data-snug":r.snug?"true":void 0,layout:"position",initial:{opacity:0,scale:.8,filter:"blur(4px)"},animate:{opacity:1,scale:1,filter:"blur(0px)"},exit:{opacity:0,scale:.8,filter:"blur(4px)"},transition:dn,style:r.rigid||r.held||r.snug?void 0:{flexShrink:hn(r,i)},className:g("inline-flex items-center gap-2",r.rigid||r.held||r.snug?"shrink-0":"min-w-10",un),children:[a>0&&s.jsx(xn,{}),r.node]},r.key))})})}function xn(){return s.jsx("span",{className:"text-muted-foreground/30 shrink-0","aria-hidden":"true",children:"·"})}function Wi({cwd:e}){const t=e.split("/").filter(Boolean).pop()??e;return s.jsxs("span",{className:"inline-flex min-w-0 items-center gap-1",title:e,children:[s.jsx(bs,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"truncate",children:t})]})}function V(e){const t=e.trim(),n=Array.from(t);return n.length<=ne?t:`${n.slice(0,ne-1).join("").trimEnd()}…`}function fn(e){return e.replace(/\s*\([^()]*\)\s*$/,"").split("·")[0].trim()}function gn(e,t){return V(jn(e,t))}function jn(e,t){const n=t.find(r=>r.value===e);if(n)return fn(n.displayName);const i=/claude-(\w+)-/.exec(e);return i?`${i[1].charAt(0).toUpperCase()}${i[1].slice(1)}`:e==="default"?"Default":ys(e)??e}function Gi({data:e,workspace:t,compact:n}){if(!e)return null;if(!vs(e))return s.jsxs("span",{className:"text-muted-foreground/50 inline-flex min-w-0 items-center gap-1",title:"Not a git repository",children:[s.jsx(q,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"truncate",children:"No repo"})]});const i=e.modified+e.staged+e.untracked,r=i===1?"1 change":`${i} changes`,a=[];if(e.modified>0&&a.push(`${e.modified} modified`),e.staged>0&&a.push(`${e.staged} staged`),e.untracked>0&&a.push(`${e.untracked} untracked`),e.conflicted>0&&a.push(`${e.conflicted} conflicted`),t){const u=ks(t.portBase),c=[`${t.key} · ${t.projectKey}`,`${t.branch??e.branch} · ${t.provider}`,e.ahead>0?`↑${e.ahead}`:"",e.behind>0?`↓${e.behind}`:"",a.length>0?a.join(", "):"clean",`ports ${u.DORKOS_PORT} / ${u.VITE_PORT} / ${u.SITE_PORT}`,t.pinned?"pinned":""].filter(Boolean);return s.jsxs("span",{className:"inline-flex min-w-0 items-center gap-1",title:c.join(" · "),children:[s.jsx(q,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"max-w-[20ch] truncate font-medium",children:n?V(t.key):t.key}),!n&&s.jsxs("span",{className:"text-muted-foreground truncate",children:["· ",t.projectKey]}),t.pinned&&s.jsx(Fe,{className:"text-muted-foreground size-(--size-icon-xs) shrink-0"}),i>0&&(n?s.jsx(Ce,{label:r}):s.jsxs("span",{className:"text-muted-foreground shrink-0",children:["· ",r]}))]})}const o=a.length>0?`${e.branch} · ${a.join(", ")}`:`${e.branch} · clean`;return s.jsxs("span",{className:"inline-flex min-w-0 items-center gap-1",title:o,children:[s.jsx(q,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"max-w-[25ch] truncate",children:n?V(e.branch):e.branch}),e.ahead>0&&s.jsxs("span",{className:"text-muted-foreground inline-flex shrink-0 items-center gap-0.5",children:[s.jsx(Ts,{className:"size-(--size-icon-xs)"}),e.ahead]}),e.behind>0&&s.jsxs("span",{className:"text-muted-foreground inline-flex shrink-0 items-center gap-0.5",children:[s.jsx(Ss,{className:"size-(--size-icon-xs)"}),e.behind]}),i>0&&(n?s.jsx(Ce,{label:r}):s.jsxs("span",{className:"text-muted-foreground shrink-0",children:["· ",r]}))]})}function Ce({label:e}){return s.jsx("span",{role:"img","aria-label":e,title:e,className:"bg-muted-foreground/70 size-1 shrink-0 rounded-full"})}function Nn({stop:e,onMakeDefault:t,onDismiss:n,pending:i,error:r,placement:a="inline"}){const o=a==="overlay";return o&&!e?null:s.jsx("div",{className:g("flex items-center px-1",o?"bg-background/95 pointer-events-auto absolute right-0 bottom-full left-0 z-20 mb-1 rounded-md py-0.5 backdrop-blur-sm":"min-h-5"),"data-testid":o?"make-default-slot-overlay":"make-default-slot",children:e&&s.jsxs("p",{role:"status","data-testid":"make-default-offer",className:g("animate-in fade-in-0 flex min-w-0 items-center gap-1.5 text-xs duration-200 motion-reduce:animate-none",r?"text-destructive":"text-muted-foreground"),children:[s.jsx("span",{className:"min-w-0 flex-1 truncate",children:r?s.jsxs(s.Fragment,{children:[s.jsx(de,{className:"mr-1 inline size-3 shrink-0 align-[-2px]","aria-hidden":!0}),r]}):s.jsxs(s.Fragment,{children:["Start every new chat in ",ws(e),"?"]})})," ",s.jsxs("span",{className:"flex shrink-0 items-center gap-1 whitespace-nowrap",children:[r?s.jsx("button",{type:"button",disabled:i,onClick:t,"data-testid":"make-default-retry",className:"focus-ring text-foreground rounded-sm underline underline-offset-2 disabled:opacity-50",children:"Try again"}):s.jsx("button",{type:"button",disabled:i,onClick:t,"data-testid":"make-default-confirm",className:"focus-ring text-foreground rounded-sm underline underline-offset-2 disabled:opacity-50",children:"Make default"}),s.jsx("span",{"aria-hidden":!0,children:"·"}),s.jsx("button",{type:"button",onClick:n,"data-testid":"make-default-dismiss",className:"focus-ring hover:text-foreground rounded-sm underline underline-offset-2",children:"Dismiss"})]})]})})}function bn(e,t,n){const i=be(e,t),r=be(e,n);return!i||!r?!1:Ms(r,i)?i.auto===!0&&r.auto!==!0&&r.asks!=="never":!0}const yn="Auto mode needs Opus 4.6+ or Sonnet 4.6";function Hi({mode:e,onChangeMode:t,disabled:n,pending:i,runtime:r,modelSupportsAutoMode:a,planActive:o,compact:u,makeDefault:c,onOpenChange:m}){var C;const l=We(r),p=Cs(f=>f.setControlCenterOpen),d=Ge(),v=$(f=>f.open),b=$(f=>f.setOpen),k=$(f=>f.setAvailable),N=!(l&&!l.permissionModes.supported)&&n!==!0&&i!==!0;h.useEffect(()=>(k(N),()=>k(!1)),[N,k]);const y=h.useRef(m);if(h.useEffect(()=>{y.current=m},[m]),h.useEffect(()=>()=>{var f;b(!1),(f=y.current)==null||f.call(y,!1)},[b]),l&&!l.permissionModes.supported)return null;const S=(l==null?void 0:l.permissionModes.values)??[],M=!a&&S.some(f=>f.id==="auto"),D=M?S.filter(f=>f.id!=="auto"):S,E=D.find(f=>f.id===e),w=d?S.find(f=>f.id===(l==null?void 0:l.permissionModes.default)):void 0,T=w!==void 0&&E!==void 0&&l!==void 0&&bn(l.permissionModes,E.id,w.id),x=T?w:E,I=T?`${w.label} (Wi-Fi)`:(x==null?void 0:x.label)??Es(e),J=u?V(T?w.label:I):I,Z=Is(x),W=(C=_s(D).find(f=>f.mode.id===e))==null?void 0:C.stop,G=M&&(W==="act"||e==="auto"),z=s.jsxs("button",{disabled:n,"data-testid":"permission-mode-trigger","aria-label":`Permissions: ${I}`,className:g(F,"items-center gap-1 disabled:cursor-not-allowed disabled:opacity-40",Z),children:[s.jsx(As,{descriptor:x,className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"truncate",children:J})]});return n?s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsx("span",{className:"inline-flex",children:z})}),s.jsx(R,{side:"top",children:"Send a message first"})]}):i?s.jsxs("span",{"data-testid":"permission-mode-pending","aria-busy":"true","aria-label":"Permissions: still loading",className:g(F,"items-center gap-1 opacity-40"),children:[s.jsx("span",{className:"bg-muted-foreground/30 size-(--size-icon-xs) shrink-0 animate-pulse rounded-full"}),s.jsx("span",{className:"bg-muted-foreground/30 h-2 w-10 animate-pulse rounded"})]}):s.jsxs(ue,{open:v,onOpenChange:f=>{b(f),m==null||m(f)},children:[s.jsx(me,{asChild:!0,children:z}),s.jsxs(pe,{side:"top",align:"start",className:"w-80 p-3","aria-label":"Permissions",children:[s.jsx(he,{children:"Permissions"}),s.jsx(Rs,{mode:e,descriptors:D,onChangeMode:t,planActive:o,onUnlock:()=>p(!0)}),c&&s.jsx(Nn,{...c}),G&&s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsxs("p",{"data-testid":"auto-unsupported-hint",className:"text-muted-foreground text-3xs mt-2 flex items-center gap-1.5 px-1",children:[s.jsx(He,{className:"size-(--size-icon-xs) shrink-0"}),"Auto unavailable on this model"]})}),s.jsx(R,{side:"top",children:yn})]}),s.jsx(Ds,{mode:e,descriptor:E,className:"mt-2 px-1"})]})]})}const Ee="On Wi-Fi · agents ask or only read",te="Over Wi-Fi, every file or shell step needs your OK, or agents only read.",vn="relative after:absolute after:top-1/2 after:left-1/2 after:size-11 after:-translate-x-1/2 after:-translate-y-1/2 after:content-['']";function Xi({compact:e}){const t=Ge(),n=Os();if(!t)return null;const i=s.jsxs("button",{type:"button","data-testid":"wifi-turn-cap","aria-label":`${Ee}. ${te}`,className:g("border-border text-muted-foreground inline-flex items-center gap-1 rounded-full border py-0.5",vn,n?"cursor-pointer":"cursor-default",e?"mx-1.5 px-1":"px-2","focus-visible:ring-ring outline-none focus-visible:ring-[3px]"),children:[s.jsx(B,{"aria-hidden":!0,className:"size-(--size-icon-xs) shrink-0"}),!e&&s.jsx("span",{children:Ee})]});return n?s.jsxs(Xe,{children:[s.jsx(Ps,{asChild:!0,children:i}),s.jsx(qe,{side:"top",collisionPadding:8,"data-testid":"wifi-turn-cap-detail",className:"w-auto max-w-70 p-3 text-xs",children:te})]}):s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:i}),s.jsx(R,{side:"top",children:te})]})}const kn=6e3;function Tn(e){return e instanceof Error&&e.message||"Couldn’t save that. Try again."}function qi(e){var W,G,z;const{sessionId:t,runtime:n,declaredModes:i,runtimeDefaultMode:r}=e,{data:a}=$e(),{data:o}=Qe(),u=qt(),c=Be(),m=Us(t),l=ie(C=>C.dismissDefaultStopOffer),[p,d]=h.useState(null),[v,b]=h.useState(null),[k,N]=h.useState(t);k!==t&&(N(t),d(null),b(null));const y=a==null?void 0:a.executionDefaults,S=n??(y==null?void 0:y.runtime),M=(W=y==null?void 0:y.perRuntime.find(C=>C.runtime===S))==null?void 0:W.trustStop,D=M??(y==null?void 0:y.trustStop)??null,E=(G=i.find(C=>C.id===r))==null?void 0:G.stop,w=D??E,T=M!=null?(z=Qt(o,S))==null?void 0:z.configSection:void 0,x=a!==void 0;h.useEffect(()=>{if(!p)return;const C=setTimeout(()=>d(null),kn);return()=>clearTimeout(C)},[p]);const I=h.useCallback(C=>{const f=i.find(xs=>xs.id===C);!f||zs(f)||!x||m||f.stop!==w&&(b(null),d(f.stop))},[i,x,m,w,d,b]),J=h.useCallback(()=>{if(!p)return;const C=p;b(null),u.mutate({runtimes:T?{[T]:{defaultTrustStop:C}}:{defaultTrustStop:C}},{onSuccess:()=>{c.invalidateQueries({queryKey:O.all}),d(null)},onError:f=>b(Tn(f))})},[p,u,c,T,d,b]),Z=h.useCallback(()=>{l(t),d(null)},[l,t,d]);return{line:x?{stop:p,onMakeDefault:J,onDismiss:Z,pending:u.isPending,error:v}:null,offerFor:I}}function Qi({runtimeLabel:e,onShown:t,onDismiss:n}){const i=$(a=>a.available),r=$(a=>a.setOpen);return h.useEffect(()=>{t==null||t()},[t]),s.jsxs(Ls,{"data-slot":"read-only-mode-notice","data-testid":"read-only-mode-notice",gap:"none",className:"flex-row flex-wrap items-center gap-x-3 gap-y-2 px-3 py-2",children:[s.jsx($s,{className:"text-muted-foreground size-4 shrink-0","aria-hidden":!0}),s.jsxs("p",{className:"text-muted-foreground min-w-0 flex-1 text-xs",children:["In this mode, ",e," reads files but won’t change them. Asking won’t help."]}),s.jsxs("div",{className:"flex w-full shrink-0 flex-wrap items-center justify-end gap-1.5 sm:w-auto",children:[s.jsx(P,{variant:"ghost",size:"sm",responsive:!1,className:"h-7 px-2 text-xs",onClick:n,children:"Dismiss"}),i&&s.jsx(P,{variant:"outline",size:"sm",responsive:!1,className:"h-7 px-2 text-xs",onClick:()=>r(!0),children:"Change permissions"})]})]})}function Ki(e,t,n){const i=We(t??void 0),r=ie(p=>p.recordReadOnlyHintShown),a=ie(p=>p.spendReadOnlyHint),o=Bs(e??""),u=i==null?void 0:i.permissionModes.values.find(p=>p.id===n),c=u!==void 0&&Fs(u);h.useEffect(()=>{c||!e||o!=="shown"||a(e)},[c,e,o,a]);const m=h.useCallback(()=>{e&&r(e)},[e,r]),l=h.useCallback(()=>{e&&a(e)},[e,a]);return h.useMemo(()=>({eligible:!!e&&c&&o!=="spent",runtimeLabel:t?Ws(t):"This agent",markShown:m,dismiss:l}),[e,c,o,t,m,l])}function Vi({descriptor:e,active:t,onToggle:n,disabled:i}){return s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsxs("button",{type:"button","aria-pressed":t,disabled:i,onClick:()=>n(!t),className:g(F,"items-center gap-1","disabled:cursor-not-allowed disabled:opacity-40",t&&"text-foreground"),children:[s.jsx(Ke,{className:"size-(--size-icon-xs) shrink-0","aria-hidden":!0}),s.jsx("span",{className:"shrink-0",children:e.label})]})}),s.jsx(R,{side:"top",children:i?"Send a message first":e.promise})]})}function Yi({runtime:e,model:t,onChangeRuntime:n,canSelect:i,compact:r,iconOnly:a,account:o}){const{data:u}=Qe(),{data:c}=Gs(),{nameFor:m}=Hs(),[l,p]=h.useState({open:!1}),d=Object.keys((u==null?void 0:u.capabilities)??{}),v=d.filter(x=>ye(c,x)),b=d.filter(x=>!ye(c,x)),k=u!==void 0&&Object.values(Xs).some(x=>x.setup&&!d.includes(x.type)),N=!!n&&(d.length>1||b.length>0||k),y=r?null:t,S=ee(e),M=S.icon,D=a?s.jsx(M,{"aria-hidden":!0,className:"size-(--size-icon-xs) shrink-0"}):s.jsx(st,{runtime:e,model:y,iconClassName:"size-(--size-icon-xs)"}),E=a?s.jsx("span",{className:"block",children:S.label}):null,w=a?s.jsx("span",{role:"img","aria-label":S.label,"data-testid":"runtime-item-icon",className:"inline-flex items-center",children:D}):D,T=o?`Account: ${m(o)}`:null;return i?N?s.jsxs(s.Fragment,{children:[s.jsxs(qs,{children:[s.jsx(Qs,{asChild:!0,children:s.jsx("button",{className:F,"aria-label":a?`Runs on: ${S.label}`:void 0,title:a?S.label:void 0,children:D})}),s.jsxs(Ks,{side:"top",align:"start",className:"w-56",children:[s.jsx(Vs,{children:"Runs on"}),s.jsx(Ys,{value:e,onValueChange:x=>n==null?void 0:n(x),children:v.map(x=>{const I=ee(x);return s.jsx(Js,{value:x,icon:I.icon,children:I.label},x)})}),b.map(x=>{const I=ee(x);return s.jsx(ve,{icon:I.icon,description:"Connect",onSelect:()=>p({open:!0,runtime:x}),children:I.label},x)}),k&&s.jsxs(s.Fragment,{children:[s.jsx(Zs,{}),s.jsx(ve,{icon:et,onSelect:()=>p({open:!0}),children:"Add a runtime"})]})]})]}),s.jsx(Kt,{runtime:l.runtime,open:l.open,onOpenChange:x=>p(I=>({...I,open:x})),renderConnect:Zt,showConnectSuccess:!0,onRuntimeReady:x=>{n==null||n(x)}})]}):!T&&!E?w:s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:w}),s.jsxs(R,{side:"top",children:[E,T&&s.jsx("span",{className:"block",children:T})]})]}):s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:w}),s.jsxs(R,{side:"top",children:[E,s.jsx("span",{className:"block",children:"Set when the chat starts. It can’t change after."}),T&&s.jsx("span",{className:"block",children:T})]})]})}function Ji(e,t,n){const i=xe(),r=tt(e),a=new Date(i),o=t.pending?null:t.usage;return{...nt({liveTurnUsage:n,liveTurnAt:r,accountStatus:it(o,a),accountObservedAt:Ve(Ye(o))}),accountUsage:o}}function Zi({open:e,onOpenChange:t,onConfirm:n}){return s.jsx(rt,{open:e,onOpenChange:t,children:s.jsxs(at,{children:[s.jsxs(ot,{children:[s.jsxs(lt,{className:"flex items-center gap-2",children:[s.jsx(He,{className:"text-muted-foreground size-4"}),"Turn on Auto mode?",s.jsx(Q,{size:"xs",variant:"secondary",className:"tracking-wide uppercase",children:"Preview"})]}),s.jsx(ct,{children:"Asks only before risky steps, like deleting files. Switch back anytime."})]}),s.jsxs(dt,{children:[s.jsx(ut,{children:"Cancel"}),s.jsx(mt,{onClick:n,children:"Turn on Auto mode"})]})]})})}const Ie=[{slug:"frontier",label:"Frontier"},{slug:"solid-coders",label:"Solid coders"},{slug:"quick-helpers",label:"Quick helpers"},{slug:"more-models",label:"More models"},{slug:"no-tools",label:"Can’t do agent work"}],Sn=10,wn="Can’t use tools, so it can’t read files or run commands.",Cn="Makes images DorkOS can’t show yet.",En=["openrouter/openrouter/auto","openrouter/auto"];function In(e){return En.some(t=>e.value===t||e.value.startsWith(`${t}-`))}function ls(e){return e.supportsToolUse!==!1}function _n(e){return e.supportsImageOutput===!0&&!In(e)?Cn:ls(e)?null:wn}function An(e){if(!ls(e))return"no-tools";switch(e.tier){case"frontier":return"frontier";case"solid-coder":return"solid-coders";case"quick-helper":return"quick-helpers";default:return"more-models"}}function Rn(e){return e.some(t=>t.tier!=null)||e.length>Sn}function Dn(e,t){const n=t.trim().toLowerCase();return n?e.value.toLowerCase().includes(n)||e.displayName.toLowerCase().includes(n):!0}function Mn(e){const t=new Map(Ie.map(n=>[n.slug,[]]));for(const n of e)t.get(An(n)).push(n);return Ie.map(n=>({...n,models:t.get(n.slug)})).filter(n=>n.models.length>0)}function On(e){return e>=1e6?`${Math.round(e/1e6)}M`:e>=1e3?`${Math.round(e/1e3)}K`:String(e)}function Pn(){return s.jsx("div",{className:"space-y-2","data-testid":"model-cards-skeleton",children:Array.from({length:3}).map((e,t)=>s.jsxs("div",{className:"flex items-center gap-3 rounded-xl p-3",children:[s.jsx(H,{className:"size-4 rounded-full"}),s.jsxs("div",{className:"flex-1 space-y-1.5",children:[s.jsx(H,{className:"h-3.5 w-24"}),s.jsx(H,{className:"h-2.5 w-32"})]}),s.jsx(H,{className:"h-5 w-10 rounded-md"})]},t))})}function Un({onRetry:e,message:t}){return s.jsxs("div",{className:"flex flex-col items-center gap-3 py-6 text-center","data-testid":"model-load-error",children:[s.jsx(de,{className:"text-muted-foreground size-5"}),s.jsx("p",{className:"text-muted-foreground text-xs",children:t??"Couldn’t load the model list."}),s.jsxs("button",{onClick:e,className:"text-foreground hover:bg-accent inline-flex items-center gap-1.5 rounded-md px-3 py-1.5 text-xs transition-colors",children:[s.jsx(Je,{className:"size-3"}),"Retry"]})]})}function zn(e){const t=e.slice(e.lastIndexOf(" ")+1);return t.includes("/")||t.includes(":")}function cs({text:e,className:t}){return zn(e)?s.jsx("div",{dir:"rtl",className:g("truncate text-left",t),title:e,children:s.jsx("bdi",{dir:"ltr",children:e})}):s.jsx("div",{className:g("truncate",t),title:e,children:e})}function _e({model:e,isSelected:t}){const n=_n(e);return s.jsxs("label",{className:g("flex w-full cursor-pointer items-center gap-3 rounded-xl border p-3 transition-colors duration-150",t?"bg-secondary border-foreground/15":"border-border hover:border-muted-foreground/30 hover:bg-muted/50 opacity-70"),children:[s.jsx(xt,{value:e.value,className:"shrink-0"}),s.jsxs("div",{className:"min-w-0 flex-1",children:[s.jsxs("div",{className:"text-foreground line-clamp-2 text-sm font-medium break-words",children:[e.displayName,e.local&&s.jsxs("span",{className:"text-muted-foreground text-3xs ml-1.5 font-normal",children:[ft()," · private"]})]}),s.jsx(cs,{text:e.description,className:"text-muted-foreground text-2xs leading-tight"}),n&&s.jsx("div",{className:"text-2xs text-status-warning-fg mt-0.5 leading-tight","data-testid":`model-limitation-${e.value}`,children:n})]}),e.contextWindow&&s.jsx(Q,{size:"xs",variant:"secondary",className:"shrink-0",children:On(e.contextWindow)})]})}function Ln({value:e}){return s.jsxs("div",{className:"space-y-1.5","data-testid":"model-unavailable-saved",children:[s.jsxs("div",{className:"border-border flex w-full items-center gap-3 rounded-xl border border-dashed p-3 opacity-80",children:[s.jsx(de,{className:"text-status-warning-fg size-4 shrink-0"}),s.jsxs("div",{className:"flex min-w-0 flex-1 items-baseline gap-1.5",children:[s.jsx(cs,{text:e,className:"text-foreground min-w-0 text-sm font-medium"}),s.jsx("span",{className:"text-muted-foreground text-2xs shrink-0 font-normal",children:"(not available)"})]})]}),s.jsx("p",{className:"text-muted-foreground text-2xs leading-snug",children:"This model isn’t available anymore. Pick another."})]})}function $n({slug:e,label:t}){return s.jsx("div",{className:"text-muted-foreground text-2xs mt-2 mb-1 font-medium tracking-wide uppercase first:mt-0","data-testid":`model-group-${e}`,children:t})}function Bn({models:e,selectedModel:t,onChangeModel:n,emptyMessage:i}){const[r,a]=h.useState(""),o=Rn(e),c=e.length>0&&t.length>0&&!e.some(d=>d.value===t)?s.jsx(Ln,{value:t}):null,m=e.some(d=>d.unverified),l=h.useMemo(()=>o?e.filter(d=>Dn(d,r)):e,[e,r,o]),p=h.useMemo(()=>o?Mn(l):[],[l,o]);return e.length===0?s.jsx("div",{className:"border-border text-muted-foreground text-2xs rounded-xl border border-dashed p-3 leading-snug","data-testid":"model-catalog-unavailable",children:i??"Couldn’t load models. Check Settings, then try again."}):o?s.jsxs("div",{className:"space-y-2",children:[c,m&&s.jsx(Te,{}),s.jsxs("div",{className:"relative",children:[s.jsx(pt,{className:"text-muted-foreground pointer-events-none absolute top-1/2 left-2.5 size-3.5 -translate-y-1/2"}),s.jsx(ht,{type:"text",value:r,onChange:d=>a(d.target.value),placeholder:"Search models…","aria-label":"Search models","data-testid":"model-search",className:"h-8 pl-8 text-xs"})]}),p.length===0?s.jsx("p",{className:"text-muted-foreground py-4 text-center text-xs","data-testid":"model-search-empty",children:m?"No match in this short list. Connect a provider to see more.":"No models match"}):s.jsx(ke,{value:t,onValueChange:n,className:"grid-cols-1 gap-1.5","aria-label":"Model selection","data-testid":"model-card-list",children:p.map(d=>s.jsxs(h.Fragment,{children:[s.jsx($n,{slug:d.slug,label:d.label}),d.models.map(v=>s.jsx(_e,{model:v,isSelected:v.value===t},v.value))]},d.slug))})]}):s.jsxs("div",{className:"space-y-2",children:[c,m&&s.jsx(Te,{}),s.jsx(ke,{value:t,onValueChange:n,className:"grid-cols-1 gap-1.5","aria-label":"Model selection","data-testid":"model-card-list",children:e.map(d=>s.jsx(_e,{model:d,isSelected:d.value===t},d.value))})]})}const ae={none:{label:"None",description:"No reasoning"},minimal:{label:"Minimal",description:"Near-zero thinking"},low:{label:"Low",description:"Fastest responses"},medium:{label:"Medium",description:"Moderate thinking"},high:{label:"High",description:"Deep reasoning"},max:{label:"Max",description:"Maximum thinking"},xhigh:{label:"XHigh",description:"Beyond maximum"}},Fn={duration:.15,ease:"easeOut"};function Wn({effortLevels:e,effort:t,onChangeEffort:n}){return s.jsxs("div",{children:[s.jsx("div",{className:"text-muted-foreground text-2xs mb-2 font-medium tracking-wide uppercase",children:"Effort"}),s.jsxs("div",{className:"flex flex-wrap gap-1.5",role:"radiogroup","aria-label":"Effort level",children:[s.jsx(oe,{role:"radio",label:"Default",isSelected:t===null,onClick:()=>n(null)}),e.map(i=>s.jsx(oe,{role:"radio",label:ae[i].label,description:ae[i].description,isSelected:t===i,onClick:()=>n(i)},i))]})]})}function Gn({supportsFastMode:e,fastMode:t,onChangeFastMode:n}){return e?s.jsxs("div",{children:[s.jsx("div",{className:"text-muted-foreground text-2xs mb-2 font-medium tracking-wide uppercase",children:"Mode"}),s.jsx("div",{className:"flex gap-1.5",children:s.jsx(oe,{role:"switch",label:"Fast",icon:s.jsx(fe,{className:"size-3"}),isSelected:t,onClick:()=>n(!t)})})]}):null}function oe({role:e,label:t,description:n,icon:i,isSelected:r,onClick:a}){const o=s.jsxs("button",{role:e,"aria-checked":r,onClick:a,className:g("inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-xs font-medium transition-colors duration-150",r?"bg-primary text-primary-foreground":"bg-muted text-muted-foreground hover:bg-muted/80 hover:text-foreground"),children:[i,t]});return n?s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:o}),s.jsx(R,{side:"top",className:"text-xs",children:n})]}):o}function er({model:e,onChangeModel:t,effort:n,onChangeEffort:i,fastMode:r,onChangeFastMode:a,disabled:o,sessionId:u,runtime:c,onCredits:m,compact:l}){var w;const{data:p,isLoading:d,isError:v,refetch:b}=gt({sessionId:u,runtime:c??void 0}),k=p??[],N=k.find(T=>T.value===e),y=!!(N!=null&&N.supportsEffort&&(((w=N.supportedEffortLevels)==null?void 0:w.length)??0)>0),S=(N==null?void 0:N.supportsFastMode)??!1,M=!l&&y&&n?ae[n].label:null,D=!l&&r,E=s.jsxs("button",{disabled:o,className:g(F,"items-center gap-1 disabled:cursor-not-allowed disabled:opacity-40"),"data-testid":"model-config-trigger",children:[s.jsx(Ze,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"truncate",children:gn(e,k)}),M&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"text-muted-foreground text-2xs",children:"·"}),s.jsx(Q,{size:"xs",variant:"secondary",children:M})]}),D&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"text-muted-foreground text-2xs",children:"·"}),s.jsxs(Q,{size:"xs",variant:"secondary",children:[s.jsx(fe,{className:"mr-0.5 inline size-2.5"}),"Fast"]})]})]});return o?s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsx("span",{className:"inline-flex",children:E})}),s.jsx(R,{side:"top",children:"Send a message first"})]}):s.jsxs(ue,{children:[s.jsx(me,{asChild:!0,children:E}),s.jsxs(pe,{side:"top",align:"start",className:"w-120 max-w-[calc(100vw-1.5rem)] p-3","data-testid":"model-config-popover",children:[s.jsx(he,{children:"Model"}),k.some(T=>T.paidFromCredits)&&s.jsx("p",{className:"text-muted-foreground text-2xs mb-2","data-testid":"model-credits-note",children:k.some(T=>T.creditsListOutOfDate)?"Models your DorkOS credits cover. This list may be out of date.":"Models your DorkOS credits cover"}),d&&s.jsx(Pn,{}),v&&s.jsx(Un,{onRetry:()=>b(),message:m?"Couldn’t load the models DorkOS credits cover. Your model stays as it is.":void 0}),!d&&!v&&s.jsx(Bn,{models:k,selectedModel:e,onChangeModel:t,emptyMessage:m?"DorkOS credits don’t cover a model for this runtime yet.":void 0}),s.jsx(le,{children:!d&&!v&&(y||S)&&s.jsxs(ce.div,{initial:{opacity:0,y:4},animate:{opacity:1,y:0},exit:{opacity:0,y:4},transition:Fn,children:[s.jsx(jt,{className:"my-3"}),s.jsx("div",{className:"text-muted-foreground text-2xs mb-3 font-medium tracking-wide uppercase",children:"Configuration"}),s.jsxs("div",{className:"space-y-3",children:[y&&s.jsx(Wn,{effortLevels:N.supportedEffortLevels,effort:n,onChangeEffort:i}),S&&s.jsx(Gn,{supportsFastMode:(N==null?void 0:N.supportsFastMode)??!1,fastMode:r,onChangeFastMode:a})]})]},"config")})]})]})}function sr({percent:e,contextUsage:t,compact:n,reading:i,now:r}){const a=Nt(e,t)??e,o=bt(a),u=o==="critical"?U.error:o==="warning"?U.warning:"",c=n!=null&&a>=es,m=t?{total:t.totalTokens,max:t.maxTokens}:i&&i.maxTokens>0?{total:i.totalTokens,max:i.maxTokens}:null,l=(i==null?void 0:i.observedAt)??null,p=m!==null,d=s.jsxs("span",{"aria-label":p?"Context window usage":void 0,className:g("inline-flex shrink-0 items-center gap-1",p&&"cursor-default",u),children:[s.jsx(sn,{className:"size-(--size-icon-xs) shrink-0"}),s.jsxs("span",{children:[a,"%"]})]});return s.jsxs("span",{className:"inline-flex min-w-0 items-center gap-1.5",children:[m?s.jsx(Hn,{totals:m,categories:(t==null?void 0:t.categories)??[],observedAt:l,now:r,children:d}):d,s.jsx(le,{initial:!1,children:c&&s.jsxs(ce.button,{type:"button",onClick:n.onCompact,disabled:n.pending,"aria-label":n.pending?"Compacting chat…":`Context ${a}% full. Compact now`,"aria-busy":n.pending,"data-testid":"compaction-chip",initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.15},className:"bg-secondary text-muted-foreground hover:text-foreground hover:bg-muted inline-flex min-w-0 shrink items-center gap-1 rounded-md px-1.5 py-0.5 transition-colors duration-150 disabled:cursor-not-allowed disabled:opacity-60",children:[s.jsx(Je,{"aria-hidden":"true",className:g("size-(--size-icon-xs) shrink-0",n.pending&&"animate-spin")}),s.jsx("span",{className:"truncate",children:"Compact"})]},"compact")})]})}function Hn({totals:e,categories:t,observedAt:n,now:i,children:r}){const a=t.filter(o=>o.tokens>0).sort((o,u)=>u.tokens-o.tokens);return s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:r}),s.jsx(R,{side:"top",className:"max-w-64",children:s.jsxs("div",{className:"space-y-1.5",children:[s.jsxs("div",{className:"text-xs font-medium",children:[se(e.total)," / ",se(e.max)," tokens"]}),a.length>0&&s.jsx("div",{className:"space-y-0.5",children:a.map(o=>s.jsxs("div",{className:"text-3xs flex items-center justify-between gap-3",children:[s.jsxs("span",{className:"flex items-center gap-1 truncate",children:[s.jsx("span",{className:"inline-block size-1.5 shrink-0 rounded-full",style:{backgroundColor:o.color}}),o.name]}),s.jsx("span",{className:g(re,"shrink-0"),children:se(o.tokens)})]},o.name))}),n!==null&&s.jsx(ge,{observedAt:n,now:i,surface:"tooltip"})]})})]})}const Xn={panel:{warning:U.warning,error:U.error},tooltip:{warning:"",error:""}};function je(e){if(e.costUsd==null)return null;switch(e.costBasis){case"unknown":return"Estimated. This model has no listed price.";case"managed":return"Charged at your organization’s own rates.";default:return null}}function Ne(e){return e.costBasis==="unknown"?"Estimated chat cost":"Chat cost"}function ds({usage:e,surface:t="panel"}){const n=je(e),i=Xn[t],r=K[t];return s.jsxs(s.Fragment,{children:[e.costUsd!=null&&s.jsx(L,{label:Ne(e),labelClassName:r,children:`$${e.costUsd.toFixed(2)}`}),n&&s.jsx("div",{className:r,children:n}),e.detail&&s.jsx("div",{"data-slot":"usage-detail-note",className:i.warning||void 0,children:e.detail}),e.state==="exhausted"&&s.jsx("div",{"data-slot":"usage-limit-note",className:i.error||void 0,children:"Rate limit reached"})]})}function us({usage:e,surface:t="panel"}){const n=je(e),i=K[t];if(e.kind==="subscription"&&e.utilization!=null){const r=Math.round(e.utilization*100),a=e.resetsAt?new Date(e.resetsAt).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}):null;return s.jsxs("div",{className:"space-y-1",children:[s.jsx("div",{className:"text-xs font-medium",children:"Subscription usage"}),s.jsxs("div",{className:"text-3xs space-y-0.5",children:[s.jsx(L,{label:"Utilization",labelClassName:i,children:`${r}%`}),e.windowLabel&&s.jsx(L,{label:"Window",labelClassName:i,children:e.windowLabel}),a&&s.jsx(L,{label:"Resets at",labelClassName:i,children:a}),s.jsx(ds,{usage:e,surface:t})]})]})}return s.jsxs("div",{className:"space-y-1",children:[s.jsx("div",{className:"text-xs font-medium",children:Ne(e)}),s.jsxs("div",{className:"text-3xs space-y-0.5",children:[e.costUsd!=null&&s.jsx(L,{label:"Cost",labelClassName:i,children:`$${e.costUsd.toFixed(2)}`}),n&&s.jsx("div",{className:i,children:n}),e.detail&&s.jsx("div",{className:i,children:e.detail})]})]})}function tr({usage:e,observedAt:t=null,now:n}){const i=xe(),r=n??new Date(i);if(e.kind==="subscription"&&e.utilization!=null){const m=Math.round(e.utilization*100),l=e.state==="exhausted",p=e.state==="warning"||m>=80,d=l?"text-destructive":p?"text-status-warning-fg":"",v=yt(e,t,r),b=vt(v);return s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsxs("span",{className:g("inline-flex shrink-0 cursor-default items-center gap-1",d),"aria-label":"Subscription usage","data-stale":v||void 0,children:[s.jsx(ss,{className:"size-(--size-icon-xs)"}),s.jsxs("span",{className:b,children:[m,"%"]}),v&&s.jsx("span",{className:b,children:"· old"})]})}),s.jsx(R,{side:"top",className:"max-w-56",children:s.jsxs("div",{className:"space-y-1",children:[s.jsx(us,{usage:e,surface:"tooltip"}),t!==null&&s.jsx(ge,{observedAt:t,now:r,surface:"tooltip"})]})})]})}if(e.costUsd==null)return null;const o=en(e.costUsd),u=je(e),c=Ne(e);return!e.detail&&!u?s.jsxs("span",{className:"inline-flex shrink-0 items-center gap-1","aria-label":c,children:[s.jsx(Se,{className:"size-(--size-icon-xs)"}),s.jsx("span",{children:o})]}):s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsxs("span",{className:"inline-flex shrink-0 cursor-default items-center gap-1","aria-label":c,children:[s.jsx(Se,{className:"size-(--size-icon-xs)"}),s.jsx("span",{children:o})]})}),s.jsx(R,{side:"top",className:"max-w-56",children:s.jsxs("div",{className:"space-y-1",children:[s.jsx("div",{className:"text-xs font-medium",children:c}),u&&s.jsx("div",{className:g(K.tooltip,"text-3xs"),children:u}),e.detail&&s.jsx("div",{className:g(K.tooltip,"text-3xs"),children:e.detail})]})})]})}function nr({usage:e,accountUsage:t=null,observedAt:n=null,open:i,onOpenChange:r,now:a}){const o=xe(),u=a??new Date(o),c=Ye(t),m=c.length>0?Ve(c):n,l=e!=null&&ts(e);let p;return c.length>0?p=s.jsxs("div",{className:"space-y-2",children:[s.jsx("div",{className:"text-xs font-medium",children:"Subscription usage"}),s.jsx("div",{className:"flex flex-col gap-2.5",children:c.map(d=>s.jsx(kt,{window:d,label:Tt(d.key,d.label),now:u},d.key))}),e&&s.jsx("div",{className:"text-3xs space-y-0.5",children:s.jsx(ds,{usage:e})})]}):l?p=s.jsx(us,{usage:e}):p=s.jsx("p",{className:"text-muted-foreground text-xs",children:"No usage yet."}),s.jsxs(Xe,{open:i,onOpenChange:r,children:[s.jsx(St,{asChild:!0,children:s.jsx("span",{"aria-hidden":!0,className:"inline-block h-0 w-0"})}),s.jsx(qe,{side:"top",align:"end",className:"w-72 max-w-[calc(100vw-1.5rem)]","aria-label":"Usage and cost",children:s.jsxs("div",{className:"space-y-2",children:[p,m!==null&&(c.length>0||l)&&s.jsx(ge,{observedAt:m,now:u})]})})]})}const qn={connecting:{color:X.warning,label:"Connecting",shortLabel:"Connecting",icon:B,tasks:!0},connected:{color:X.success,label:"Connected",shortLabel:"Connected",icon:B,tasks:!1},reconnecting:{color:X.warning,label:"Reconnecting",shortLabel:"Reconnecting",icon:B,tasks:!0},disconnected:{color:X.error,label:"Live updates lost",shortLabel:"Offline",icon:wt,tasks:!1}};function ir({connectionState:e,compact:t}){const n=qn[e],i=n.icon;return s.jsxs(Vt,{openDelay:200,children:[s.jsx(Yt,{asChild:!0,children:s.jsxs("span",{className:"flex min-w-0 cursor-default items-center gap-1.5 text-xs",children:[s.jsx("span",{className:g("size-1.5 shrink-0 rounded-full",n.color,n.tasks&&"animate-breath")}),s.jsx("span",{className:"text-muted-foreground truncate",children:t?n.shortLabel:n.label})]})}),s.jsx(Jt,{side:"top",align:"center",className:"w-72 p-3",children:s.jsxs("div",{className:"flex items-start gap-2.5",children:[s.jsx(i,{className:g("mt-0.5 size-4 shrink-0",e==="disconnected"?U.error:U.warning)}),s.jsxs("div",{className:"min-w-0 space-y-1.5",children:[s.jsx("p",{className:"text-sm font-medium",children:n.label}),s.jsx(Qn,{connectionState:e})]})]})})]})}function Qn({connectionState:e}){const t="text-muted-foreground text-xs leading-relaxed";return e==="connecting"?s.jsx("p",{className:t,children:"Connecting to live updates. New messages appear once connected."}):e==="reconnecting"?s.jsxs("div",{className:"space-y-1.5",children:[s.jsx("p",{className:t,children:"Live updates dropped and are reconnecting. Nothing is lost."}),s.jsx("p",{className:g(t,"text-muted-foreground/70"),children:"No action needed."})]}):s.jsxs("div",{className:"space-y-1.5",children:[s.jsx("p",{className:t,children:"Can’t reach live updates. New messages appear once they’re back."}),s.jsx("p",{className:g(t,"text-muted-foreground/70"),children:"Still trying. If this lasts, check that DorkOS is running."})]})}function rr({count:e,running:t,waiting:n}){const i=e===1?"":"s",r=e-t.length,a=`${e} subagent${i} running`;return s.jsxs(_,{children:[s.jsx(A,{asChild:!0,children:s.jsxs("span",{className:"inline-flex min-w-0 items-center gap-1","aria-label":a,children:[s.jsx(ns,{className:"size-(--size-icon-xs) shrink-0"}),s.jsx("span",{className:"shrink-0 tabular-nums",children:e})]})}),s.jsxs(R,{side:"top",className:"max-w-64",children:[n&&s.jsx("p",{className:"mb-1 font-medium",children:"Still working. The agent continues when they finish."}),s.jsx("ul",{className:"space-y-1",children:t.map(o=>s.jsxs("li",{children:[s.jsx("span",{className:"font-medium",children:o.description??"Working…"}),s.jsxs("p",{className:g(re,"text-3xs leading-tight"),children:[o.toolUses??0," tool",o.toolUses===1?"":"s",o.lastToolName?` · last ${o.lastToolName}`:""]})]},o.taskId))}),r>0&&s.jsx("p",{className:g(re,"text-3xs leading-tight"),children:t.length>0?`and ${r} more`:`${r} task${i} from earlier`})]})]})}const Ae=648,Kn=440,Vn=340,Yn=3,Jn=3,Zn=2,ei=4,si=8,ti=20,ni=ne*si+ti,ii=Number.POSITIVE_INFINITY,Re=[],ri=["cwd"],De=["cwd","git"];function ai(e){if(e===null||e<=0)return{density:"full",rightBudget:ii,dropped:Re};if(e>=Ae){const t=Math.floor((e-Ae)/ni);return{density:"full",rightBudget:ei+t,dropped:Re}}return e>=Kn?{density:"compact",rightBudget:Yn,dropped:ri}:e>=Vn?{density:"identity",rightBudget:Jn,dropped:De}:{density:"avatar",rightBudget:Zn,dropped:De}}function oi(e){return e==="identity"||e==="avatar"}function li(e,t){return t.severity!==e.severity?t.severity-e.severity:Number(t.pinned)-Number(e.pinned)}const ci=2,di=2;function ar(e,t){const n=new Set(t.dropped),i=t.density!=="full",r=l=>i&&l.held,a=e.filter(l=>l.cluster==="right"),o=new Set;let u=0,c=0;const m=[...a].sort((l,p)=>Number(r(p))-Number(r(l))||li(l,p));for(const l of m){if(c>=t.rightBudget)break;const p=l.rigid||r(l);p&&u>=ci||(p&&(u+=1),o.add(l.key),c+=l.wide?Math.min(di,t.rightBudget-c):1)}return{items:e.filter(l=>l.cluster==="right"?o.has(l.key):!n.has(l.key)).map(l=>l.held===r(l)?l:{...l,held:r(l)}),overflow:a.length-o.size}}const ui=new Set(["main","master"]);function or(e,t,n){return{dirty:!t,onDefaultBranch:!n&&ui.has(e)}}const j={AGENT_ANCHOR:1e3,CONNECTION_LOST:100,CONTEXT_CRITICAL:90,ACCOUNT_ATTENTION:85,USAGE_EXHAUSTED:80,PERMISSION_BYPASS:70,CONTEXT_WARNING:50,USAGE_WARNING:50,PERMISSION_ELEVATED:40,PLAN_ACTIVE:40,SUBAGENTS_RUNNING:35,EXTENSION_ITEM:35,RUNTIME_NON_DEFAULT:30,GIT_DIRTY:20,MODEL:10,CWD:5,QUIET:0},mi={session:"Session",diagnostics:"Diagnostics"};function Me(e){return e.runtime&&!e.runtime.isDefault?j.RUNTIME_NON_DEFAULT:j.QUIET}function pi(e){return e.account!==null}const hi=new Set(["near","model-out","out"]);function Oe(e){return e.permissionDescriptor?e.permissionDescriptor.stop!=="ask":e.permissionMode!=="default"}const ms=[{key:"agent",label:"Agent",description:"Who you are talking to",cluster:"left",group:null,icon:Et,promote:()=>!0,severity:()=>j.AGENT_ANCHOR},{key:"cwd",label:"Directory",description:"The folder this chat can touch",cluster:"left",group:"session",icon:It,promote:e=>e.cwd!==null,severity:()=>j.CWD},{key:"git",label:"Git",description:"Branch and uncommitted changes",cluster:"left",group:"session",icon:q,promote:e=>e.git!==null&&(e.git.dirty||!e.git.onDefaultBranch),severity:e=>{var t;return(t=e.git)!=null&&t.dirty?j.GIT_DIRTY:j.QUIET}},{key:"runtime",label:"Runs on",description:"What runs this chat",cluster:"right",group:"session",icon:tn,promote:e=>e.runtime!==null&&e.runtime.type!=="doe"&&(!e.runtime.isDefault||e.runtime.canSelect),severity:Me,snug:oi},{key:"account",label:"Account",description:"Which Claude account this uses, and what’s left",cluster:"right",group:null,icon:nn,promote:e=>e.account!==null,severity:e=>e.account&&hi.has(e.account.chipState)?j.ACCOUNT_ATTENTION:Me(e)},{key:"extensions",label:"Add-ons",description:"What your extensions show here",cluster:"right",group:null,icon:_t,promote:e=>e.extensionItems.some(t=>t.visible),severity:e=>e.extensionItems.some(t=>t.visible&&t.urgent)?j.ACCOUNT_ATTENTION:j.EXTENSION_ITEM},{key:"model",label:"Model",description:"The model answering you",cluster:"right",group:"session",icon:Ze,promote:()=>!1,severity:()=>j.MODEL},{key:"cache",label:"Cache",description:"How much came from cache",cluster:"right",group:"session",icon:fe,promote:()=>!1,severity:()=>j.QUIET,neverInLine:!0},{key:"context",label:"Context",description:"How full the context window is",cluster:"right",group:"session",icon:rn,rigid:!0,promote:e=>e.contextPercent!==null,severity:e=>e.contextPercent===null?j.QUIET:e.contextPercent>=es?j.CONTEXT_CRITICAL:e.contextPercent>=Rt?j.CONTEXT_WARNING:j.QUIET},{key:"usage",label:"Usage & cost",description:"Plan limits or chat cost",cluster:"right",group:"session",icon:ss,rigid:!0,promote:e=>e.usage!==null&&ts(e.usage)&&!pi(e),wide:e=>e.usageStale,severity:e=>{var t,n;return((t=e.usage)==null?void 0:t.state)==="exhausted"?j.USAGE_EXHAUSTED:((n=e.usage)==null?void 0:n.state)==="warning"?j.USAGE_WARNING:j.QUIET}},{key:"permission",label:"Permissions",description:"How freely the agent acts",cluster:"right",group:"session",icon:At,held:!0,promote:e=>Oe(e)||e.permissionPickerOpen===!0||e.onWifi===!0,severity:e=>(e.permissionDescriptor?Dt(e.permissionDescriptor):Mt(e.permissionMode))?j.PERMISSION_BYPASS:Oe(e)||e.permissionPickerOpen===!0||e.onWifi===!0?j.PERMISSION_ELEVATED:j.QUIET},{key:"plan",label:"Plan",description:"Plan first, change nothing until approved",cluster:"right",group:"session",icon:Ke,promote:e=>e.plan!==null,severity:e=>{var t;return(t=e.plan)!=null&&t.active?j.PLAN_ACTIVE:j.QUIET},snug:()=>!0},{key:"subagents",label:"Subagents",description:"Subagents working on this turn",cluster:"right",group:"diagnostics",icon:ns,rigid:!0,promote:e=>e.subagentsInFlight>0,severity:e=>e.subagentsInFlight>0?j.SUBAGENTS_RUNNING:j.QUIET},{key:"connection",label:"Live updates",description:"The live link that delivers messages",cluster:"right",group:"diagnostics",icon:B,promote:e=>e.connectionState!=="connected",severity:e=>e.connectionState==="connected"?j.QUIET:j.CONNECTION_LOST}];function ps(e){return e.group==="session"&&e.neverInLine!==!0}function xi(){const{pins:e}=ln(),{setPins:t}=cn(),n=h.useCallback(r=>{const a=Ct.find(o=>o===r);a&&t(e.includes(a)?e.filter(o=>o!==a):[...e,a])},[e,t]),i=h.useCallback(()=>t([]),[t]);return{pins:e,toggle:n,reset:i}}function fi(){return["session","diagnostics"].map(t=>({group:t,label:mi[t],items:ms.filter(n=>n.group===t)})).filter(t=>t.items.length>0)}function hs(e){const t=e.contextTokens??e.readTokens+e.creationTokens;return t<=0?0:Math.round(e.readTokens/t*100)}function gi(e){return e?e.kind==="subscription"&&e.utilization!=null?`${Math.round(e.utilization*100)}% of ${e.windowLabel??"your plan"}`:e.costUsd!=null?`$${e.costUsd.toFixed(2)}`:null:null}function ji(e){return e.split("/").filter(Boolean).pop()??e}function Ni(e,t){switch(e){case"cwd":return t.cwd?ji(t.cwd):null;case"git":return t.git.state==="unknown"?null:t.git.state==="no-repo"?"No repo":t.git.dirty?`${t.git.branch} · changed`:t.git.branch;case"runtime":return t.runtime;case"model":return t.model;case"context":return t.contextPercent===null?null:`${t.contextPercent}% full`;case"cache":return t.cache===null?null:`${hs(t.cache)}% from cache`;case"usage":return gi(t.usage);case"permission":return t.permissionMode;case"connection":return`${t.connectionState} · event ${t.lastEventSeq}`;default:return null}}function bi(e){return JSON.stringify({sessionId:e.sessionId,cwd:e.cwd,git:e.git,runtime:e.runtime,model:e.model,selectedModel:e.selectedModel,effort:e.effort,fastMode:e.fastMode,permissionMode:e.permissionMode,contextPercent:e.contextPercent,contextUsage:e.contextUsage,cache:e.cache===null?null:{readTokens:e.cache.readTokens,creationTokens:e.cache.creationTokens,contextTokens:e.cache.contextTokens??null,hitPercent:hs(e.cache)},usage:e.usage,connectionState:e.connectionState,streaming:e.streaming,lifecycle:e.lifecycle,triggerPending:e.triggerPending,lastEventSeq:e.lastEventSeq,snapshotCursor:e.snapshotCursor,lastEventAt:e.lastEventAt===null?null:new Date(e.lastEventAt).toISOString(),queueDepth:e.queueDepth,subagents:e.subagents.map(t=>t.name),activeSubagents:e.activeSubagents,runningSubagentCount:e.runningSubagentCount,clientVersion:e.clientVersion,capturedAt:new Date().toISOString()},null,2)}function yi({copied:e,failed:t}){return e?s.jsx(Pt,{className:"text-status-success size-3.5","aria-hidden":!0}):t?s.jsx(Ut,{className:"text-destructive size-3.5","aria-hidden":!0}):s.jsx(an,{className:"size-3.5","aria-hidden":!0})}function vi(e,t){return e?"Copied":t?"Couldn’t copy":"Copy diagnostics"}function ki({diagnostics:e,className:t}){const{copied:n,failed:i,copy:r}=Ot(),a=()=>void r(bi(e));return s.jsxs(P,{variant:"ghost",size:"sm",className:g("gap-1.5 text-xs",t),onClick:a,children:[s.jsx(yi,{copied:n,failed:i}),vi(n,i)]})}function lr({open:e,onOpenChange:t,diagnostics:n,controls:i,promotionContext:r,urgentAction:a,overflowCount:o=0,addOns:u}){const c=zt(),{pins:m,toggle:l,reset:p}=xi(),d=fi(),v=new Set(m),b=o>0;return s.jsxs(ue,{open:e,onOpenChange:t,children:[s.jsx(Lt,{children:s.jsxs(_,{children:[s.jsx(me,{asChild:!0,children:s.jsx(A,{asChild:!0,children:s.jsxs("button",{type:"button","data-testid":"status-reveal","aria-label":b?`Chat details, ${o} more`:"Chat details",className:"text-muted-foreground/50 hover:text-muted-foreground inline-flex shrink-0 items-center justify-center gap-0.5 transition-colors duration-150 pointer-coarse:min-h-11 pointer-coarse:min-w-11",children:[s.jsx($t,{className:"size-4"}),b&&s.jsxs("span",{className:"tabular-nums",children:["+",o]})]})})}),s.jsx(R,{side:"top",children:b?`Chat details, ${o} more`:"Chat details"})]})}),s.jsxs(pe,{side:"top",align:"end",className:"w-80 p-3","aria-label":"Chat",children:[s.jsx(he,{children:"Chat"}),a&&s.jsx(P,{variant:"secondary",className:"mb-3 w-full",disabled:a.pending,onClick:()=>{a.onAction(),t(!1)},children:a.label}),s.jsxs("div",{className:"flex flex-col gap-4",children:[u&&s.jsxs("section",{className:"space-y-1","data-testid":"session-add-ons",children:[s.jsx("h3",{className:"text-muted-foreground px-1 text-xs font-medium tracking-wide uppercase",children:"Add-ons"}),u]}),d.map(k=>s.jsxs("section",{className:"space-y-1",children:[s.jsx("h3",{className:"text-muted-foreground px-1 text-xs font-medium tracking-wide uppercase",children:k.label}),Ti(Si(k.items,i),c?r:null).map(N=>s.jsx(Ci,{item:N,value:Ni(N.key,n),pinned:v.has(N.key),onTogglePin:ps(N)?()=>l(N.key):null,control:wi(N.key,i)},N.key)),k.group==="diagnostics"&&s.jsxs(s.Fragment,{children:[s.jsx(Pe,{label:"Queued messages",value:String(n.queueDepth)}),s.jsx(Pe,{label:"Chat ID",value:n.sessionId||"—"})]})]},k.group))]}),n.sessionId!==""&&s.jsxs(P,{variant:"ghost",size:"sm",className:"text-muted-foreground mt-3 h-7 w-full justify-start gap-1.5 text-xs",onClick:()=>{t(!1),Ft({sessionId:n.sessionId})},children:[s.jsx(Bt,{className:"size-3.5","aria-hidden":!0}),"View notifications"]}),s.jsxs("div",{className:"mt-4 flex items-center justify-between gap-2",children:[s.jsx(ki,{diagnostics:n}),s.jsxs(P,{variant:"ghost",size:"sm",className:"text-muted-foreground gap-1.5 text-xs",disabled:m.length===0,onClick:p,children:[s.jsx(Wt,{className:"size-3.5","aria-hidden":!0}),"Reset pins"]})]})]})]})}function Ti(e,t){return t?[...e].sort((n,i)=>i.severity(t)-n.severity(t)):e}function Si(e,t){return e.filter(n=>n.key!=="plan"||t.plan!==null)}function wi(e,t){return e==="plan"&&t.plan?s.jsx(Ht,{checked:t.plan.active,onCheckedChange:t.plan.onToggle,"aria-label":"Plan first, change nothing until approved"}):null}function Ci({item:e,value:t,pinned:n,onTogglePin:i,control:r}){const a=e.icon;return s.jsxs("div",{"data-testid":`session-row-${e.key}`,className:"flex items-center gap-2 px-1 py-1 text-sm",children:[s.jsx(a,{className:"text-muted-foreground size-3.5 shrink-0","aria-hidden":!0}),s.jsx("span",{className:"shrink-0",children:e.label}),s.jsx("span",{className:"min-w-0 flex-1"}),s.jsx("span",{className:"text-muted-foreground truncate text-xs",title:t??void 0,children:t??"—"}),r,i&&s.jsx("button",{type:"button",onClick:i,"aria-pressed":n,"aria-label":n?`Stop keeping ${e.label} in the status bar`:`Keep ${e.label} in the status bar`,className:g("hover:text-foreground inline-flex size-6 shrink-0 items-center justify-center rounded-md transition-colors duration-150",n?"text-foreground":"text-muted-foreground/50"),children:n?s.jsx(Fe,{className:"size-3.5"}):s.jsx(Gt,{className:"size-3.5"})})]})}function Pe({label:e,value:t}){return s.jsxs("div",{className:"flex items-center gap-2 px-1 py-1 text-sm",children:[s.jsx("span",{className:"w-3.5 shrink-0","aria-hidden":!0}),s.jsx("span",{className:"shrink-0",children:e}),s.jsx("span",{className:"min-w-0 flex-1"}),s.jsx("span",{className:"text-muted-foreground truncate text-xs",title:t,children:t})]})}function cr(e){const t=h.useRef(e);h.useEffect(()=>{t.current=e},[e]),h.useEffect(()=>{const n=i=>{const r=i.key==="."||i.key===">";(i.metaKey||i.ctrlKey)&&i.shiftKey&&r&&(i.preventDefault(),t.current())};return document.addEventListener("keydown",n),()=>document.removeEventListener("keydown",n)},[])}const Ue=new WeakMap;function ze(e,t,n){let i=Ue.get(e);i||(i=new Set,Ue.set(e,i)),!i.has(t)&&(i.add(t),n())}function Le(e,t,n){let i;try{i=n()}catch(r){return ze(e,`${t}:throw`,()=>console.warn(`[extensions] ${e.extensionId}'s status-bar item "${e.id}" threw in ${t}(); it is hidden until it stops throwing.`,r)),!1}return typeof i!="boolean"?(ze(e,`${t}:type`,()=>console.warn(`[extensions] ${e.extensionId}'s status-bar item "${e.id}": ${t}() must return true or false, synchronously, reading only its ctx; it returned ${Ei(i)}, read as false.`)),!1):i}function Ei(e){return e instanceof Promise?"a Promise":e===null?"null":typeof e=="object"?"an object":`a ${typeof e}`}function Ii(e,t){const n=[],i=[];for(const r of e){const a=r.when?Le(r,"when",()=>r.when(t)):!0,o=a&&r.urgent?Le(r,"urgent",()=>r.urgent(t)):!1;n.push({id:r.id,visible:a,urgent:o}),a&&i.push(r)}return i.sort((r,a)=>(r.priority??0)-(a.priority??0)),{promotion:n,visible:i}}function dr(e){const t=Xt("status-bar");return h.useMemo(()=>Ii(t,e),[t,e])}function _i(e){return e!=null&&e!==!1}function ur({ctx:e,pins:t,nodes:n,density:i="full"}){var o,u;const r=new Set(t),a=[];for(const c of ms){if(c.neverInLine)continue;const m=n[c.key];if(!_i(m))continue;const l=r.has(c.key)&&ps(c);!l&&!c.promote(e)||a.push({key:c.key,cluster:c.cluster,severity:c.severity(e),pinned:l,rigid:c.rigid===!0,wide:((o=c.wide)==null?void 0:o.call(c,e))===!0,held:c.held===!0,snug:((u=c.snug)==null?void 0:u.call(c,i))===!0,node:m})}return a}function mr(){const e=h.useRef(null),[t,n]=h.useState(null);h.useLayoutEffect(()=>{const r=e.current;if(!r)return;n(r.getBoundingClientRect().width);const a=new ResizeObserver(o=>{var m,l;const u=o.at(0);if(!u)return;const c=((l=(m=u.contentBoxSize)==null?void 0:m.at(0))==null?void 0:l.inlineSize)??u.contentRect.width;n(c)});return a.observe(r),()=>a.disconnect()},[]);const i=h.useMemo(()=>ai(t),[t]);return{ref:e,budget:i}}export{Zi as A,mr as B,ki as C,Ji as D,Gi as G,Nn as M,Hi as P,Qi as R,lr as S,us as U,Xi as W,qn as a,ir as b,hs as c,sr as d,Wi as e,er as f,Vi as g,Yi as h,Fi as i,rr as j,nr as k,tr as l,ar as m,Ii as n,bi as o,or as p,oi as q,pi as r,ai as s,ur as t,gn as u,dr as v,qi as w,Ki as x,cr as y,xi as z};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{f4 as A,f5 as u,f6 as h,r as i,f7 as C,f8 as V,f9 as k,fa as x,fb as l}from"./index-YUtEyz7O.js";function E(...t){const s=!Array.isArray(t[0]),e=s?0:-1,n=t[0+e],o=t[1+e],r=t[2+e],c=t[3+e],f=A(o,r,c);return s?f(n):f}function b(t){const s=u(()=>h(t)),{isStatic:e}=i.useContext(C);if(e){const[,n]=i.useState(t);i.useEffect(()=>s.on("change",n),[])}return s}function d(t,s){const e=b(s()),n=()=>e.set(s());return n(),V(()=>{const o=()=>x.preRender(n,!1,!0),r=t.map(c=>c.on("change",o));return()=>{r.forEach(c=>c()),k(n)}}),e}function L(t){l.current=[],t();const s=d(l.current,t);return l.current=void 0,s}function I(t,s,e,n){if(typeof t=="function")return L(t);if(e!==void 0&&!Array.isArray(e)&&typeof s!="function")return S(t,s,e,n);const c=typeof s=="function"?s:E(s,e,n),f=Array.isArray(t)?y(t,c):y([t],([m])=>c(m)),a=Array.isArray(t)?void 0:t.accelerate;return a&&!a.isTransformed&&typeof s!="function"&&Array.isArray(e)&&(n==null?void 0:n.clamp)!==!1&&(f.accelerate={...a,times:s,keyframes:e,isTransformed:!0}),f}function y(t,s){const e=u(()=>[]);return d(t,()=>{e.length=0;const n=t.length;for(let o=0;o<n;o++)e[o]=t[o].get();return s(e)})}function S(t,s,e,n){const o=u(()=>Object.keys(e)),r=u(()=>({}));for(const c of o)r[c]=I(t,s,e[c],n);return r}export{I as a,b as u};
|
package/dist/client/assets/{use-unclaimed-chats-C-z5fstJ.js → use-unclaimed-chats-B0nk8b84.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{a5 as a,a6 as l,a7 as r,ar as o,a8 as s}from"./index-YUtEyz7O.js";import{B as d}from"./use-bindings-DhOKnybh.js";const u=["relay","unclaimed-chats"];function m(e){return[...u,e]}function y(e="pending",t=!0){const n=a();return l({queryKey:m(e),queryFn:()=>n.listUnclaimedChats(e),enabled:t})}function U(){const e=r(),t=()=>{e.invalidateQueries({queryKey:[...u]})};o("relay_chat_unclaimed",t),o("relay_chat_unclaimed_burst",t)}function i(e){e.invalidateQueries({queryKey:[...u]})}function p(){const e=a(),t=r();return s({mutationFn:({id:n,input:c})=>e.claimUnclaimedChat(n,c),meta:{suppressErrorToast:!0},onSuccess:()=>{i(t),t.invalidateQueries({queryKey:[...d]})}})}function v(){const e=a(),t=r();return s({mutationFn:n=>e.ignoreUnclaimedChat(n),meta:{errorLabel:"Couldn’t ignore this chat"},onSuccess:()=>i(t)})}function f(){const e=a(),t=r();return s({mutationFn:n=>e.blockUnclaimedChat(n),meta:{errorLabel:"Couldn’t block this chat"},onSuccess:()=>i(t)})}function q(){const e=a(),t=r();return s({mutationFn:n=>e.leaveUnclaimedChat(n),meta:{errorLabel:"Couldn’t leave this chat"},onSuccess:()=>i(t)})}export{u as U,U as a,p as b,v as c,f as d,q as e,y as u};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a5 as n,a7 as s,a8 as u,aI as o,aJ as r}from"./index-YUtEyz7O.js";function c(){const e=n(),t=s();return u({mutationKey:o,mutationFn:a=>e.updateConfig(a),onSuccess:()=>{t.invalidateQueries({queryKey:r.current()})}})}export{c as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{a7 as f,r as n,ap as i,aq as o}from"./index-YUtEyz7O.js";function a(r,u){return r.findAll(u.filters).map(e=>u.select?u.select(e):e.state)}function p(r={},u){const e=f(u).getMutationCache(),c=n.useRef(r),t=n.useRef(null);return t.current===null&&(t.current=a(e,r)),n.useEffect(()=>{c.current=r}),n.useSyncExternalStore(n.useCallback(l=>e.subscribe(()=>{const s=i(t.current,a(e,c.current));t.current!==s&&(t.current=s,o.schedule(l))}),[e]),()=>t.current,()=>t.current)}export{p as u};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as Ni}from"./chunk-XXDRQBXY-
|
|
1
|
+
import{g as Ni}from"./chunk-XXDRQBXY-D18oZOrd.js";import{s as Ci}from"./chunk-VQ5W62QI-DZi6GyW_.js";import{g as Zs,s as jt,a as Qs,b as Gt,v as bi,t as vi,_ as u,E as je,l as _i,c as en,q as Mi,r as xi,u as wi,j as Ui,A as Pi,P as Di,D as Fi,M as Bi,F as $i,K as ji,bj as Gi}from"./mermaid.core-C-qvGQ5g.js";import{s as Wi}from"./transform-BqqRT-Iy.js";import"./index-YUtEyz7O.js";import"./BlintzCanvas-BgIQdpTx.js";import"./index-Bktc0aFV.js";import"./index-CLTrC-a-.js";function Wt(s){console&&console.error&&console.error(`Error: ${s}`)}function tn(s){console&&console.warn&&console.warn(`Warning: ${s}`)}function sn(s){const e=new Date().getTime(),t=s();return{time:new Date().getTime()-e,value:t}}function nn(s){function e(){}e.prototype=s;const t=new e;function n(){return typeof t.bar}return n(),n(),s}function Ki(s){return Vi(s)?s.LABEL:s.name}function Vi(s){return typeof s.LABEL=="string"&&s.LABEL!==""}class te{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),this.definition.forEach(t=>{t.accept(e)})}}class K extends te{constructor(e){super([]),this.idx=1,Object.assign(this,ie(e))}set definition(e){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(e){e.visit(this)}}class _e extends te{constructor(e){super(e.definition),this.orgText="",Object.assign(this,ie(e))}}class W extends te{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,Object.assign(this,ie(e))}}class G extends te{constructor(e){super(e.definition),this.idx=1,Object.assign(this,ie(e))}}class se extends te{constructor(e){super(e.definition),this.idx=1,Object.assign(this,ie(e))}}class ne extends te{constructor(e){super(e.definition),this.idx=1,Object.assign(this,ie(e))}}class x extends te{constructor(e){super(e.definition),this.idx=1,Object.assign(this,ie(e))}}class J extends te{constructor(e){super(e.definition),this.idx=1,Object.assign(this,ie(e))}}class Z extends te{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,Object.assign(this,ie(e))}}class k{constructor(e){this.idx=1,Object.assign(this,ie(e))}accept(e){e.visit(this)}}function zi(s){return s.map(at)}function at(s){function e(t){return t.map(at)}if(s instanceof K){const t={type:"NonTerminal",name:s.nonTerminalName,idx:s.idx};return typeof s.label=="string"&&(t.label=s.label),t}else{if(s instanceof W)return{type:"Alternative",definition:e(s.definition)};if(s instanceof G)return{type:"Option",idx:s.idx,definition:e(s.definition)};if(s instanceof se)return{type:"RepetitionMandatory",idx:s.idx,definition:e(s.definition)};if(s instanceof ne)return{type:"RepetitionMandatoryWithSeparator",idx:s.idx,separator:at(new k({terminalType:s.separator})),definition:e(s.definition)};if(s instanceof J)return{type:"RepetitionWithSeparator",idx:s.idx,separator:at(new k({terminalType:s.separator})),definition:e(s.definition)};if(s instanceof x)return{type:"Repetition",idx:s.idx,definition:e(s.definition)};if(s instanceof Z)return{type:"Alternation",idx:s.idx,definition:e(s.definition)};if(s instanceof k){const t={type:"Terminal",name:s.terminalType.name,label:Ki(s.terminalType),idx:s.idx};typeof s.label=="string"&&(t.terminalLabel=s.label);const n=s.terminalType.PATTERN;return s.terminalType.PATTERN&&(t.pattern=n instanceof RegExp?n.source:n),t}else{if(s instanceof _e)return{type:"Rule",name:s.name,orgText:s.orgText,definition:e(s.definition)};throw Error("non exhaustive match")}}}function ie(s){return Object.fromEntries(Object.entries(s).filter(([,e])=>e!==void 0))}class Me{visit(e){const t=e;switch(t.constructor){case K:return this.visitNonTerminal(t);case W:return this.visitAlternative(t);case G:return this.visitOption(t);case se:return this.visitRepetitionMandatory(t);case ne:return this.visitRepetitionMandatoryWithSeparator(t);case J:return this.visitRepetitionWithSeparator(t);case x:return this.visitRepetition(t);case Z:return this.visitAlternation(t);case k:return this.visitTerminal(t);case _e:return this.visitRule(t);default:throw Error("non exhaustive match")}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}}function Hi(s){return s instanceof W||s instanceof G||s instanceof x||s instanceof se||s instanceof ne||s instanceof J||s instanceof k||s instanceof _e}function Tt(s,e=[]){return s instanceof G||s instanceof x||s instanceof J?!0:s instanceof Z?s.definition.some(n=>Tt(n,e)):s instanceof K&&e.includes(s)?!1:s instanceof te?(s instanceof K&&e.push(s),s.definition.every(n=>Tt(n,e))):!1}function Xi(s){return s instanceof Z}function ee(s){if(s instanceof K)return"SUBRULE";if(s instanceof G)return"OPTION";if(s instanceof Z)return"OR";if(s instanceof se)return"AT_LEAST_ONE";if(s instanceof ne)return"AT_LEAST_ONE_SEP";if(s instanceof J)return"MANY_SEP";if(s instanceof x)return"MANY";if(s instanceof k)return"CONSUME";throw Error("non exhaustive match")}class kt{walk(e,t=[]){e.definition.forEach((n,i)=>{const a=e.definition.slice(i+1);if(n instanceof K)this.walkProdRef(n,a,t);else if(n instanceof k)this.walkTerminal(n,a,t);else if(n instanceof W)this.walkFlat(n,a,t);else if(n instanceof G)this.walkOption(n,a,t);else if(n instanceof se)this.walkAtLeastOne(n,a,t);else if(n instanceof ne)this.walkAtLeastOneSep(n,a,t);else if(n instanceof J)this.walkManySep(n,a,t);else if(n instanceof x)this.walkMany(n,a,t);else if(n instanceof Z)this.walkOr(n,a,t);else throw Error("non exhaustive match")})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){const i=t.concat(n);this.walk(e,i)}walkOption(e,t,n){const i=t.concat(n);this.walk(e,i)}walkAtLeastOne(e,t,n){const i=[new G({definition:e.definition})].concat(t,n);this.walk(e,i)}walkAtLeastOneSep(e,t,n){const i=ys(e,t,n);this.walk(e,i)}walkMany(e,t,n){const i=[new G({definition:e.definition})].concat(t,n);this.walk(e,i)}walkManySep(e,t,n){const i=ys(e,t,n);this.walk(e,i)}walkOr(e,t,n){const i=t.concat(n);e.definition.forEach(a=>{const r=new W({definition:[a]});this.walk(r,i)})}}function ys(s,e,t){return[new G({definition:[new k({terminalType:s.separator})].concat(s.definition)})].concat(e,t)}function qe(s){if(s instanceof K)return qe(s.referencedRule);if(s instanceof k)return Ji(s);if(Hi(s))return Yi(s);if(Xi(s))return qi(s);throw Error("non exhaustive match")}function Yi(s){let e=[];const t=s.definition;let n=0,i=t.length>n,a,r=!0;for(;i&&r;)a=t[n],r=Tt(a),e=e.concat(qe(a)),n=n+1,i=t.length>n;return[...new Set(e)]}function qi(s){const e=s.definition.map(t=>qe(t));return[...new Set(e.flat())]}function Ji(s){return[s.terminalType]}const an="_~IN~_";class Zi extends kt{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){const i=ea(e.referencedRule,e.idx)+this.topProd.name,a=t.concat(n),r=new W({definition:a}),o=qe(r);this.follows[i]=o}}function Qi(s){const e={};return s.forEach(t=>{const n=new Zi(t).startWalking();Object.assign(e,n)}),e}function ea(s,e){return s.name+e+an}function y(s){return s.charCodeAt(0)}function Pt(s,e){Array.isArray(s)?s.forEach(function(t){e.push(t)}):e.push(s)}function Fe(s,e){if(s[e]===!0)throw"duplicate flag "+e;s[e],s[e]=!0}function Se(s){if(s===void 0)throw Error("Internal Error - Should never get here!");return!0}function ta(){throw Error("Internal Error - Should never get here!")}function Rs(s){return s.type==="Character"}const gt=[];for(let s=y("0");s<=y("9");s++)gt.push(s);const At=[y("_")].concat(gt);for(let s=y("a");s<=y("z");s++)At.push(s);for(let s=y("A");s<=y("Z");s++)At.push(s);const Os=[y(" "),y("\f"),y(`
|
|
2
2
|
`),y("\r"),y(" "),y("\v"),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y(" "),y("\u2028"),y("\u2029"),y(" "),y(" "),y(" "),y("\uFEFF")],sa=/[0-9a-fA-F]/,tt=/[0-9]/,na=/[1-9]/;class ia{constructor(){this.idx=0,this.input="",this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar("/");const t=this.disjunction();this.consumeChar("/");const n={type:"Flags",loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case"g":Fe(n,"global");break;case"i":Fe(n,"ignoreCase");break;case"m":Fe(n,"multiLine");break;case"u":Fe(n,"unicode");break;case"y":Fe(n,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:n,value:t,loc:this.loc(0)}}disjunction(){const e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),e.push(this.alternative());return{type:"Disjunction",value:e,loc:this.loc(t)}}alternative(){const e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:"Alternative",value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){const e=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(e)};case"$":return{type:"EndAnchor",loc:this.loc(e)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(e)};case"B":return{type:"NonWordBoundary",loc:this.loc(e)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");let t;switch(this.popChar()){case"=":t="Lookahead";break;case"!":t="NegativeLookahead";break;case"<":{switch(this.popChar()){case"=":t="Lookbehind";break;case"!":t="NegativeLookbehind"}break}}Se(t);const n=this.disjunction();return this.consumeChar(")"),{type:t,value:n,loc:this.loc(e)}}return ta()}quantifier(e=!1){let t;const n=this.idx;switch(this.popChar()){case"*":t={atLeast:0,atMost:1/0};break;case"+":t={atLeast:1,atMost:1/0};break;case"?":t={atLeast:0,atMost:1};break;case"{":const i=this.integerIncludingZero();switch(this.popChar()){case"}":t={atLeast:i,atMost:i};break;case",":let a;this.isDigit()?(a=this.integerIncludingZero(),t={atLeast:i,atMost:a}):t={atLeast:i,atMost:1/0},this.consumeChar("}");break}if(e===!0&&t===void 0)return;Se(t);break}if(!(e===!0&&t===void 0)&&Se(t))return this.peekChar(0)==="?"?(this.consumeChar("?"),t.greedy=!1):t.greedy=!0,t.type="Quantifier",t.loc=this.loc(n),t}atom(){let e;const t=this.idx;switch(this.peekChar()){case".":e=this.dotAll();break;case"\\":e=this.atomEscape();break;case"[":e=this.characterClass();break;case"(":e=this.group();break}if(e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),Se(e))return e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e}dotAll(){return this.consumeChar("."),{type:"Set",complement:!0,value:[y(`
|
|
3
3
|
`),y("\r"),y("\u2028"),y("\u2029")]}}atomEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:"GroupBackReference",value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case"d":e=gt;break;case"D":e=gt,t=!0;break;case"s":e=Os;break;case"S":e=Os,t=!0;break;case"w":e=At;break;case"W":e=At,t=!0;break}if(Se(e))return{type:"Set",value:e,complement:t}}controlEscapeAtom(){let e;switch(this.popChar()){case"f":e=y("\f");break;case"n":e=y(`
|
|
4
4
|
`);break;case"r":e=y("\r");break;case"t":e=y(" ");break;case"v":e=y("\v");break}if(Se(e))return{type:"Character",value:e}}controlLetterEscapeAtom(){this.consumeChar("c");const e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error("Invalid ");return{type:"Character",value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar("0"),{type:"Character",value:y("\0")}}hexEscapeSequenceAtom(){return this.consumeChar("x"),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar("u"),this.parseHexDigits(4)}identityEscapeAtom(){const e=this.popChar();return{type:"Character",value:y(e)}}classPatternCharacterAtom(){switch(this.peekChar()){case`
|
package/dist/client/assets/{vennDiagram-Q3Y3IDCW-Bravmwce.js → vennDiagram-Q3Y3IDCW-BcDIpVa6.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{b8 as Wt,s as Kt,g as Ht,v as Yt,t as Xt,a as Zt,b as Jt,_ as S,M as St,R as Qt,ar as $t,ag as te,ah as ee,ai as ne,d as se,A as ie,O as re,P as oe}from"./mermaid.core-9PwG-9fN.js";import{s as rt}from"./transform-BqqRT-Iy.js";import"./index-OQuvRZTD.js";import"./BlintzCanvas-DruVZcDU.js";import"./index-QSXJR98z.js";import"./index-1QfQImuJ.js";const kt=(t,n)=>Wt(t,"a",-n),_t=1e-10;function st(t,n){const s=le(t),e=s.filter(l=>ae(l,t));let i=0,r=0;const o=[];if(e.length>1){const l=Et(e);for(let u=0;u<e.length;++u){const a=e[u];a.angle=Math.atan2(a.x-l.x,a.y-l.y)}e.sort((u,a)=>a.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];r+=(h.x+a.x)*(a.y-h.y);const p={x:(a.x+h.x)/2,y:(a.y+h.y)/2};let d=null;for(let m=0;m<a.parentIndex.length;++m)if(h.parentIndex.includes(a.parentIndex[m])){const y=t[a.parentIndex[m]],M=Math.atan2(a.x-y.x,a.y-y.y),E=Math.atan2(h.x-y.x,h.y-y.y);let T=E-M;T<0&&(T+=2*Math.PI);const w=E-T/2;let g=K(p,{x:y.x+y.radius*Math.sin(w),y:y.y+y.radius*Math.cos(w)});g>y.radius*2&&(g=y.radius*2),(d==null||d.width>g)&&(d={circle:y,width:g,p1:a,p2:h,large:g>y.radius,sweep:!0})}d!=null&&(o.push(d),i+=lt(d.circle.radius,d.width),h=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(K(t[u],l)>Math.abs(l.radius-t[u].radius)){h=!0;break}h?i=r=0:(i=l.radius*l.radius*Math.PI,o.push({circle:l,p1:{x:l.x,y:l.y+l.radius},p2:{x:l.x-_t,y:l.y+l.radius},width:l.radius*2,large:!0,sweep:!0}))}return r/=2,n&&(n.area=i+r,n.arcArea=i,n.polygonArea=r,n.arcs=o,n.innerPoints=e,n.intersectionPoints=s),i+r}function ae(t,n){return n.every(s=>K(t,s)<s.radius+_t)}function le(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const r of i)r.parentIndex=[s,e],n.push(r)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function K(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=K(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const r=(e*e-i*i+s*s)/(2*s),o=Math.sqrt(e*e-r*r),l=t.x+r*(n.x-t.x)/s,h=t.y+r*(n.y-t.y)/s,u=-(n.y-t.y)*(o/s),a=-(n.x-t.x)*(o/s);return[{x:l+u,y:h-a},{x:l-u,y:h+a}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function ce(t,n,s,e){e=e||{};const i=e.maxIterations||100,r=e.tolerance||1e-10,o=t(n),l=t(s);let h=s-n;if(o*l>0)throw"Initial bisect points must have opposite signs";if(o===0)return n;if(l===0)return s;for(let u=0;u<i;++u){h/=2;const a=n+h,p=t(a);if(p*o>=0&&(n=a),Math.abs(h)<r||p===0)return a}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function tt(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt(tt(t,t))}function ht(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let r=0;r<t.length;++r)t[r]=n*s[r]+e*i[r]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,r=s.zeroDelta||.001,o=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,p=s.sigma!==void 0?s.sigma:.5;let d;const m=n.length,y=new Array(m+1);y[0]=n,y[0].fx=t(n),y[0].id=0;for(let v=0;v<m;++v){const c=n.slice();c[v]=c[v]?c[v]*i:r,y[v+1]=c,y[v+1].fx=t(c),y[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)y[m][c]=v[c];y[m].fx=v.fx}const E=(v,c)=>v.fx-c.fx,T=n.slice(),w=n.slice(),g=n.slice(),b=n.slice();for(let v=0;v<e;++v){if(y.sort(E),s.history){const x=y.map(f=>{const O=f.slice();return O.fx=f.fx,O.id=f.id,O});x.sort((f,O)=>f.id-O.id),s.history.push({x:y[0].slice(),fx:y[0].fx,simplex:x})}d=0;for(let x=0;x<m;++x)d=Math.max(d,Math.abs(y[0][x]-y[1][x]));if(Math.abs(y[0].fx-y[m].fx)<o&&d<l)break;for(let x=0;x<m;++x){T[x]=0;for(let f=0;f<m;++f)T[x]+=y[f][x];T[x]/=m}const c=y[m];if(J(w,1+h,T,-h,c),w.fx=t(w),w.fx<y[0].fx)J(b,1+u,T,-u,c),b.fx=t(b),b.fx<w.fx?M(b):M(w);else if(w.fx>=y[m-1].fx){let x=!1;if(w.fx>c.fx?(J(g,1+a,T,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(J(g,1-a*h,T,a*h,c),g.fx=t(g),g.fx<w.fx?M(g):x=!0),x){if(p>=1)break;for(let f=1;f<y.length;++f)J(y[f],1-p,y[0],p,y[f]),y[f].fx=t(y[f])}}else M(w)}return y.sort(E),{fx:y[0].fx,x:y[0]}}function ue(t,n,s,e,i,r,o){const l=s.fx,h=tt(s.fxprime,n);let u=l,a=l,p=h,d=0;i=i||1,r=r||1e-6,o=o||.1;function m(y,M,E){for(let T=0;T<16;++T)if(i=(y+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||u>=E)M=i;else{if(Math.abs(p)<=-o*h)return i;p*(M-y)>=0&&(M=y),y=i,E=u}return 0}for(let y=0;y<10;++y){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||y&&u>=a)return m(d,i,a);if(Math.abs(p)<=-o*h)return i;if(p>=0)return m(i,d,u);a=u,d=i,i*=2}return i}function he(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const r=n.slice();let o,l,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),o=e.fxprime.slice(),ht(o,e.fxprime,-1);for(let a=0;a<u;++a){if(h=ue(t,o,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ht(o,e.fxprime,-1);else{J(r,1,i.fxprime,-1,e.fxprime);const p=tt(e.fxprime,e.fxprime),d=Math.max(0,tt(r,i.fxprime)/p);J(o,d,o,-1,i.fxprime),l=e,e=i,i=l}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||et,i=fe(t,n),r=s(i,n),o=Object.keys(r),l=[];for(const a of o)l.push(r[a].x),l.push(r[a].y);const u=zt(a=>{const p={};for(let d=0;d<o.length;++d){const m=o[d];p[m]={x:a[2*d],y:a[2*d+1],radius:r[m].radius}}return e(p,i)},l,n).x;for(let a=0;a<o.length;++a){const p=o[a];r[p].x=u[2*a],r[p].y=u[2*a+1]}return r}const Rt=1e-10;function ft(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):ce(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(l=>Object.assign({},l));function i(l){return l.join(";")}if(s){const l=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const a=String(h.sets[u]);l.set(a,h.size+(l.get(a)||0));for(let p=u+1;p<h.sets.length;p++){const d=String(h.sets[p]),m=`${a};${d}`,y=`${d};${a}`;l.set(m,h.size+(l.get(m)||0)),l.set(y,h.size+(l.get(y)||0))}}for(const h of e)h.sets.length<3&&(h.size=l.get(i(h.sets)))}const r=[],o=new Set;for(const l of e)if(l.sets.length===1)r.push(l.sets[0]);else if(l.sets.length===2){const h=l.sets[0],u=l.sets[1];o.add(i(l.sets)),o.add(i([u,h]))}r.sort((l,h)=>l===h?0:l<h?-1:1);for(let l=0;l<r.length;++l){const h=r[l];for(let u=l+1;u<r.length;++u){const a=r[u];o.has(i([h,a]))||e.push({sets:[h,a],size:0})}}return e}function de(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(r=>r.sets.length===2).forEach(r=>{const o=s[r.sets[0]],l=s[r.sets[1]],h=Math.sqrt(n[o].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ft(h,u,r.size);e[o][l]=e[l][o]=a;let p=0;r.size+1e-10>=Math.min(n[o].size,n[l].size)?p=1:r.size<=1e-10&&(p=-1),i[o][l]=i[l][o]=p}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let r=0;r<n.length;++r)n[r]=0;let i=0;for(let r=0;r<s.length;++r){const o=t[2*r],l=t[2*r+1];for(let h=r+1;h<s.length;++h){const u=t[2*h],a=t[2*h+1],p=s[r][h],d=e[r][h],m=(u-o)*(u-o)+(a-l)*(a-l),y=Math.sqrt(m),M=m-p*p;d>0&&y<=p||d<0&&y>=p||(i+=2*M*M,n[2*r]+=4*M*(o-u),n[2*r+1]+=4*M*(l-a),n[2*h]+=4*M*(u-o),n[2*h+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||et;if(t.length>=8){const i=ye(t,n),r=e(i,t),o=e(s,t);r+1e-8<o&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:r,constraints:o}=de(t,e,i);const l=ut(r.map(ut))/r.length;r=r.map(d=>d.map(m=>m/l));const h=(d,m)=>ge(d,m,r,o);let u=null;for(let d=0;d<s;++d){const m=ct(r.length*2).map(Math.random),y=he(h,m,n);(!u||y.fx<u.fx)&&(u=y)}const a=u.x,p={};for(let d=0;d<e.length;++d){const m=e[d];p[m.sets[0]]={x:a[2*d]*l,y:a[2*d+1]*l,radius:Math.sqrt(m.size/Math.PI)}}if(n.history)for(const d of n.history)ht(d.x,l);return p}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:et,e={},i={};for(const p of t)if(p.sets.length===1){const d=p.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:p.size,radius:Math.sqrt(p.size/Math.PI)},i[d]=[]}t=t.filter(p=>p.sets.length===2);for(const p of t){let d=p.weight!=null?p.weight:1;const m=p.sets[0],y=p.sets[1];p.size+Rt>=Math.min(e[m].size,e[y].size)&&(d=0),i[m].push({set:y,size:p.size,weight:d}),i[y].push({set:m,size:p.size,weight:d})}const r=[];Object.keys(i).forEach(p=>{let d=0;for(let m=0;m<i[p].length;++m)d+=i[p][m].size*i[p][m].weight;r.push({set:p,size:d})});function o(p,d){return d.size-p.size}r.sort(o);const l={};function h(p){return p.set in l}function u(p,d){e[d].x=p.x,e[d].y=p.y,l[d]=!0}u({x:0,y:0},r[0].set);for(let p=1;p<r.length;++p){const d=r[p].set,m=i[d].filter(h),y=e[d];if(m.sort(o),m.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<m.length;++a){const w=e[m[a].set],g=ft(y.radius,w.radius,m[a].size);M.push({x:w.x+g,y:w.y}),M.push({x:w.x-g,y:w.y}),M.push({y:w.y+g,x:w.x}),M.push({y:w.y-g,x:w.x});for(let b=a+1;b<m.length;++b){const v=e[m[b].set],c=ft(y.radius,v.radius,m[b].size),x=Tt({x:w.x,y:w.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let E=1e50,T=M[0];for(const w of M){e[d].x=w.x,e[d].y=w.y;const g=s(e,t);g<E&&(E=g,T=w)}u(T,d)}return e}function et(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const o=t[e.sets[0]],l=t[e.sets[1]];i=xt(o.radius,l.radius,K(o,l))}else i=st(e.sets.map(o=>t[o]));const r=e.weight!=null?e.weight:1;s+=r*(i-e.size)*(i-e.size)}return s}function Ct(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const l=t[e.sets[0]],h=t[e.sets[1]];i=xt(l.radius,h.radius,K(l,h))}else i=st(e.sets.map(l=>t[l]));const r=e.weight!=null?e.weight:1,o=Math.log((i+1)/(e.size+1));s+=r*o*o}return s}function me(t,n,s){if(s==null?t.sort((i,r)=>r.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,r=t[0].y;for(const o of t)o.x-=i,o.y-=r}if(t.length===2&&K(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,r=Math.cos(i),o=Math.sin(i);for(const l of t){const h=l.x,u=l.y;l.x=r*h-o*u,l.y=o*h+r*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const r=t[1].y/(1e-10+t[1].x);for(const o of t){var e=(o.x+r*o.y)/(1+r*r);o.x=2*e-o.x,o.y=2*e*r-o.y}}}}function be(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,r){const o=n(i),l=n(r);o.parent=l}for(let i=0;i<t.length;++i)for(let r=i+1;r<t.length;++r){const o=t[i].radius+t[r].radius;K(t[i],t[r])+1e-10<o&&s(t[r],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const r=n(t[i]).parent.setid;e.has(r)||e.set(r,[]),e.get(r).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((r,o)=>Math.max(r,o[s]+o.radius),Number.NEGATIVE_INFINITY),i=t.reduce((r,o)=>Math.min(r,o[s]-o.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Dt(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=be(e);for(const u of i){me(u,n,s);const a=dt(u);u.size=(a.xRange.max-a.xRange.min)*(a.yRange.max-a.yRange.min),u.bounds=a}i.sort((u,a)=>a.size-u.size),e=i[0];let r=e.bounds;const o=(r.xRange.max-r.xRange.min)/50;function l(u,a,p){if(!u)return;const d=u.bounds;let m,y;if(a)m=r.xRange.max-d.xRange.min+o;else{m=r.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(r.xRange.max-r.xRange.min)/2;M<0&&(m+=M)}if(p)y=r.yRange.max-d.yRange.min+o;else{y=r.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(r.yRange.max-r.yRange.min)/2;M<0&&(y+=M)}for(const M of u)M.x+=m,M.y+=y,e.push(M)}let h=1;for(;h<i.length;)l(i[h],!0,!1),l(i[h+1],!1,!0),l(i[h+2],!0,!0),h+=3,r=dt(e);return Nt(e)}function Ot(t,n,s,e,i){const r=Ft(t);n-=2*e,s-=2*e;const{xRange:o,yRange:l}=dt(r);if(o.max===o.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const m=Math.sqrt(i/Math.PI)*2;h=n/m,u=s/m}else h=n/(o.max-o.min),u=s/(l.max-l.min);const a=Math.min(u,h),p=(n-(o.max-o.min)*a)/2,d=(s-(l.max-l.min)*a)/2;return Nt(r.map(m=>({radius:a*m.radius,x:e+p+(m.x-o.min)*a,y:e+d+(m.y-l.min)*a,setid:m.setid})))}function Nt(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function ve(t={}){let n=!1,s=600,e=350,i=15,r=1e3,o=Math.PI/2,l=!0,h=null,u=!0,a=!0,p=null,d=null,m=!1,y=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,E={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],w=0,g=function(x){if(x in E)return E[x];var f=E[x]=T[w];return w+=1,w>=T.length&&(w=0),f},b=At,v=et;function c(x){let f=x.datum();const O=new Set;f.forEach(I=>{I.size==0&&I.sets.length==1&&O.add(I.sets[0])}),f=f.filter(I=>!I.sets.some(C=>O.has(C)));let k={},D={};if(f.length>0){let I=b(f,{lossFunction:v,distinct:m});l&&(I=Dt(I,o,d)),k=Ot(I,s,e,i,h),D=Lt(k,f,M)}const X={};f.forEach(I=>{I.label&&(X[I.sets]=I.label)});function G(I){if(I.sets in X)return X[I.sets];if(I.sets.length==1)return""+I.sets[0]}x.selectAll("svg").data([k]).enter().append("svg");const B=x.select("svg");n?B.attr("viewBox",`0 0 ${s} ${e}`):B.attr("width",s).attr("height",e);const V={};let z=!1;B.selectAll(".venn-area path").each(function(I){const C=this.getAttribute("d");I.sets.length==1&&C&&!m&&(z=!0,V[I.sets[0]]=Me(C))});function q(I){return C=>{const H=I.sets.map(Q=>{let W=V[Q],Y=k[Q];return W||(W={x:s/2,y:e/2,radius:1}),Y||(Y={x:s/2,y:e/2,radius:1}),{x:W.x*(1-C)+Y.x*C,y:W.y*(1-C)+Y.y*C,radius:W.radius*(1-C)+Y.radius*C}});return wt(H,y)}}const R=B.selectAll(".venn-area").data(f,I=>I.sets),N=R.enter().append("g").attr("class",I=>`venn-area venn-${I.sets.length==1?"circle":"intersection"}${I.colour||I.color?" venn-coloured":""}`).attr("data-venn-sets",I=>I.sets.join("_")),j=N.append("path"),L=N.append("text").attr("class","label").text(I=>G(I)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(j.style("fill-opacity","0").filter(I=>I.sets.length==1).style("fill",I=>I.colour?I.colour:I.color?I.color:g(I.sets)).style("fill-opacity",".25"),L.style("fill",I=>I.colour||I.color?"#FFF":t.textFill?t.textFill:I.sets.length==1?g(I.sets):"#444"));function P(I){return typeof I.transition=="function"?I.transition("venn").duration(r):I}let _=x;z&&typeof _.transition=="function"?(_=P(x),_.selectAll("path").attrTween("d",q)):_.selectAll("path").attr("d",I=>wt(I.sets.map(C=>k[C])),y);const F=_.selectAll("text").filter(I=>I.sets in D).text(I=>G(I)).attr("x",I=>Math.floor(D[I.sets].x)).attr("y",I=>Math.floor(D[I.sets].y));u&&(z?"on"in F?F.on("end",ot(k,G)):F.each("end",ot(k,G)):F.each(ot(k,G)));const A=P(R.exit()).remove();typeof R.transition=="function"&&A.selectAll("path").attrTween("d",q);const Z=A.selectAll("text").attr("x",s/2).attr("y",e/2);return p!==null&&(L.style("font-size","0px"),F.style("font-size",p),Z.style("font-size","0px")),{circles:k,textCentres:D,nodes:R,enter:N,update:_,exit:A}}return c.wrap=function(x){return arguments.length?(u=x,c):u},c.useViewBox=function(){return n=!0,c},c.width=function(x){return arguments.length?(s=x,c):s},c.height=function(x){return arguments.length?(e=x,c):e},c.padding=function(x){return arguments.length?(i=x,c):i},c.distinct=function(x){return arguments.length?(m=x,c):m},c.colours=function(x){return arguments.length?(g=x,c):g},c.colors=function(x){return arguments.length?(g=x,c):g},c.fontSize=function(x){return arguments.length?(p=x,c):p},c.round=function(x){return arguments.length?(y=x,c):y},c.duration=function(x){return arguments.length?(r=x,c):r},c.layoutFunction=function(x){return arguments.length?(b=x,c):b},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(h=x,c):h},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(o=x,c):o},c.orientationOrder=function(x){return arguments.length?(d=x,c):d},c.lossFunction=function(x){return arguments.length?(v=x==="default"?et:x==="logRatio"?Ct:x,c):v},c}function ot(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,r=n(s)||"",o=r.split(/\s+/).reverse(),h=(r.length+o.length)/3;let u=o.pop(),a=[u],p=0;const d=1.1;e.textContent=null;const m=[];function y(g){const b=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return b.textContent=g,m.push(b),e.append(b),b}let M=y(u);for(;u=o.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=y(u),p++)}const E=.35-p*d/2,T=e.getAttribute("x"),w=e.getAttribute("y");m.forEach((g,b)=>{g.setAttribute("x",T),g.setAttribute("y",w),g.setAttribute("dy",`${E+b*d}em`)})}}function at(t,n,s){let e=n[0].radius-K(n[0],t);for(let i=1;i<n.length;++i){const r=n[i].radius-K(n[i],t);r<=e&&(e=r)}for(let i=0;i<s.length;++i){const r=K(s[i],t)-s[i].radius;r<=e&&(e=r)}return e}function jt(t,n,s){const e=[];for(const a of t)e.push({x:a.x,y:a.y}),e.push({x:a.x+a.radius/2,y:a.y}),e.push({x:a.x-a.radius/2,y:a.y}),e.push({x:a.x,y:a.y+a.radius/2}),e.push({x:a.x,y:a.y-a.radius/2});let i=e[0],r=at(e[0],t,n);for(let a=1;a<e.length;++a){const p=at(e[a],t,n);p>=r&&(i=e[a],r=p)}const o=zt(a=>-1*at({x:a[0],y:a[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,l={x:s?0:o[0],y:o[1]};let h=!0;for(const a of t)if(K(l,a)>a.radius){h=!1;break}for(const a of n)if(K(l,a)<a.radius){h=!1;break}if(h)return l;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?jt(t,[]):Et(u.arcs.map(a=>a.p1))}function Ie(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],r=t[i];for(let o=e+1;o<s.length;++o){const l=s[o],h=t[l],u=K(r,h);u+h.radius<=r.radius+1e-10?n[l].push(i):u+r.radius<=h.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=Ie(t);for(let r=0;r<n.length;++r){const o=n[r].sets,l={},h={};for(let d=0;d<o.length;++d){l[o[d]]=!0;const m=i[o[d]];for(let y=0;y<m.length;++y)h[m[y]]=!0}const u=[],a=[];for(let d in t)d in l?u.push(t[d]):d in h||a.push(t[d]);const p=jt(u,a,s);e[o]=p,p.disjoint&&n[r].size>0&&console.log("WARNING: area "+o+" not represented on screen")}return e}function ke(t,n,s){const e=[];return e.push(`
|
|
1
|
+
import{b8 as Wt,s as Kt,g as Ht,v as Yt,t as Xt,a as Zt,b as Jt,_ as S,M as St,R as Qt,ar as $t,ag as te,ah as ee,ai as ne,d as se,A as ie,O as re,P as oe}from"./mermaid.core-C-qvGQ5g.js";import{s as rt}from"./transform-BqqRT-Iy.js";import"./index-YUtEyz7O.js";import"./BlintzCanvas-BgIQdpTx.js";import"./index-Bktc0aFV.js";import"./index-CLTrC-a-.js";const kt=(t,n)=>Wt(t,"a",-n),_t=1e-10;function st(t,n){const s=le(t),e=s.filter(l=>ae(l,t));let i=0,r=0;const o=[];if(e.length>1){const l=Et(e);for(let u=0;u<e.length;++u){const a=e[u];a.angle=Math.atan2(a.x-l.x,a.y-l.y)}e.sort((u,a)=>a.angle-u.angle);let h=e[e.length-1];for(let u=0;u<e.length;++u){const a=e[u];r+=(h.x+a.x)*(a.y-h.y);const p={x:(a.x+h.x)/2,y:(a.y+h.y)/2};let d=null;for(let m=0;m<a.parentIndex.length;++m)if(h.parentIndex.includes(a.parentIndex[m])){const y=t[a.parentIndex[m]],M=Math.atan2(a.x-y.x,a.y-y.y),E=Math.atan2(h.x-y.x,h.y-y.y);let T=E-M;T<0&&(T+=2*Math.PI);const w=E-T/2;let g=K(p,{x:y.x+y.radius*Math.sin(w),y:y.y+y.radius*Math.cos(w)});g>y.radius*2&&(g=y.radius*2),(d==null||d.width>g)&&(d={circle:y,width:g,p1:a,p2:h,large:g>y.radius,sweep:!0})}d!=null&&(o.push(d),i+=lt(d.circle.radius,d.width),h=a)}}else{let l=t[0];for(let u=1;u<t.length;++u)t[u].radius<l.radius&&(l=t[u]);let h=!1;for(let u=0;u<t.length;++u)if(K(t[u],l)>Math.abs(l.radius-t[u].radius)){h=!0;break}h?i=r=0:(i=l.radius*l.radius*Math.PI,o.push({circle:l,p1:{x:l.x,y:l.y+l.radius},p2:{x:l.x-_t,y:l.y+l.radius},width:l.radius*2,large:!0,sweep:!0}))}return r/=2,n&&(n.area=i+r,n.arcArea=i,n.polygonArea=r,n.arcs=o,n.innerPoints=e,n.intersectionPoints=s),i+r}function ae(t,n){return n.every(s=>K(t,s)<s.radius+_t)}function le(t){const n=[];for(let s=0;s<t.length;++s)for(let e=s+1;e<t.length;++e){const i=Tt(t[s],t[e]);for(const r of i)r.parentIndex=[s,e],n.push(r)}return n}function lt(t,n){return t*t*Math.acos(1-n/t)-(t-n)*Math.sqrt(n*(2*t-n))}function K(t,n){return Math.sqrt((t.x-n.x)*(t.x-n.x)+(t.y-n.y)*(t.y-n.y))}function xt(t,n,s){if(s>=t+n)return 0;if(s<=Math.abs(t-n))return Math.PI*Math.min(t,n)*Math.min(t,n);const e=t-(s*s-n*n+t*t)/(2*s),i=n-(s*s-t*t+n*n)/(2*s);return lt(t,e)+lt(n,i)}function Tt(t,n){const s=K(t,n),e=t.radius,i=n.radius;if(s>=e+i||s<=Math.abs(e-i))return[];const r=(e*e-i*i+s*s)/(2*s),o=Math.sqrt(e*e-r*r),l=t.x+r*(n.x-t.x)/s,h=t.y+r*(n.y-t.y)/s,u=-(n.y-t.y)*(o/s),a=-(n.x-t.x)*(o/s);return[{x:l+u,y:h-a},{x:l-u,y:h+a}]}function Et(t){const n={x:0,y:0};for(const s of t)n.x+=s.x,n.y+=s.y;return n.x/=t.length,n.y/=t.length,n}function ce(t,n,s,e){e=e||{};const i=e.maxIterations||100,r=e.tolerance||1e-10,o=t(n),l=t(s);let h=s-n;if(o*l>0)throw"Initial bisect points must have opposite signs";if(o===0)return n;if(l===0)return s;for(let u=0;u<i;++u){h/=2;const a=n+h,p=t(a);if(p*o>=0&&(n=a),Math.abs(h)<r||p===0)return a}return n+h}function ct(t){const n=new Array(t);for(let s=0;s<t;++s)n[s]=0;return n}function Mt(t,n){return ct(t).map(()=>ct(n))}function tt(t,n){let s=0;for(let e=0;e<t.length;++e)s+=t[e]*n[e];return s}function ut(t){return Math.sqrt(tt(t,t))}function ht(t,n,s){for(let e=0;e<n.length;++e)t[e]=n[e]*s}function J(t,n,s,e,i){for(let r=0;r<t.length;++r)t[r]=n*s[r]+e*i[r]}function zt(t,n,s){s=s||{};const e=s.maxIterations||n.length*200,i=s.nonZeroDelta||1.05,r=s.zeroDelta||.001,o=s.minErrorDelta||1e-6,l=s.minErrorDelta||1e-5,h=s.rho!==void 0?s.rho:1,u=s.chi!==void 0?s.chi:2,a=s.psi!==void 0?s.psi:-.5,p=s.sigma!==void 0?s.sigma:.5;let d;const m=n.length,y=new Array(m+1);y[0]=n,y[0].fx=t(n),y[0].id=0;for(let v=0;v<m;++v){const c=n.slice();c[v]=c[v]?c[v]*i:r,y[v+1]=c,y[v+1].fx=t(c),y[v+1].id=v+1}function M(v){for(let c=0;c<v.length;c++)y[m][c]=v[c];y[m].fx=v.fx}const E=(v,c)=>v.fx-c.fx,T=n.slice(),w=n.slice(),g=n.slice(),b=n.slice();for(let v=0;v<e;++v){if(y.sort(E),s.history){const x=y.map(f=>{const O=f.slice();return O.fx=f.fx,O.id=f.id,O});x.sort((f,O)=>f.id-O.id),s.history.push({x:y[0].slice(),fx:y[0].fx,simplex:x})}d=0;for(let x=0;x<m;++x)d=Math.max(d,Math.abs(y[0][x]-y[1][x]));if(Math.abs(y[0].fx-y[m].fx)<o&&d<l)break;for(let x=0;x<m;++x){T[x]=0;for(let f=0;f<m;++f)T[x]+=y[f][x];T[x]/=m}const c=y[m];if(J(w,1+h,T,-h,c),w.fx=t(w),w.fx<y[0].fx)J(b,1+u,T,-u,c),b.fx=t(b),b.fx<w.fx?M(b):M(w);else if(w.fx>=y[m-1].fx){let x=!1;if(w.fx>c.fx?(J(g,1+a,T,-a,c),g.fx=t(g),g.fx<c.fx?M(g):x=!0):(J(g,1-a*h,T,a*h,c),g.fx=t(g),g.fx<w.fx?M(g):x=!0),x){if(p>=1)break;for(let f=1;f<y.length;++f)J(y[f],1-p,y[0],p,y[f]),y[f].fx=t(y[f])}}else M(w)}return y.sort(E),{fx:y[0].fx,x:y[0]}}function ue(t,n,s,e,i,r,o){const l=s.fx,h=tt(s.fxprime,n);let u=l,a=l,p=h,d=0;i=i||1,r=r||1e-6,o=o||.1;function m(y,M,E){for(let T=0;T<16;++T)if(i=(y+M)/2,J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||u>=E)M=i;else{if(Math.abs(p)<=-o*h)return i;p*(M-y)>=0&&(M=y),y=i,E=u}return 0}for(let y=0;y<10;++y){if(J(e.x,1,s.x,i,n),u=e.fx=t(e.x,e.fxprime),p=tt(e.fxprime,n),u>l+r*i*h||y&&u>=a)return m(d,i,a);if(Math.abs(p)<=-o*h)return i;if(p>=0)return m(i,d,u);a=u,d=i,i*=2}return i}function he(t,n,s){let e={x:n.slice(),fx:0,fxprime:n.slice()},i={x:n.slice(),fx:0,fxprime:n.slice()};const r=n.slice();let o,l,h=1,u;s=s||{},u=s.maxIterations||n.length*20,e.fx=t(e.x,e.fxprime),o=e.fxprime.slice(),ht(o,e.fxprime,-1);for(let a=0;a<u;++a){if(h=ue(t,o,e,i,h),s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),!h)ht(o,e.fxprime,-1);else{J(r,1,i.fxprime,-1,e.fxprime);const p=tt(e.fxprime,e.fxprime),d=Math.max(0,tt(r,i.fxprime)/p);J(o,d,o,-1,i.fxprime),l=e,e=i,i=l}if(ut(e.fxprime)<=1e-5)break}return s.history&&s.history.push({x:e.x.slice(),fx:e.fx,fxprime:e.fxprime.slice(),alpha:h}),e}function At(t,n={}){n.maxIterations=n.maxIterations||500;const s=n.initialLayout||xe,e=n.lossFunction||et,i=fe(t,n),r=s(i,n),o=Object.keys(r),l=[];for(const a of o)l.push(r[a].x),l.push(r[a].y);const u=zt(a=>{const p={};for(let d=0;d<o.length;++d){const m=o[d];p[m]={x:a[2*d],y:a[2*d+1],radius:r[m].radius}}return e(p,i)},l,n).x;for(let a=0;a<o.length;++a){const p=o[a];r[p].x=u[2*a],r[p].y=u[2*a+1]}return r}const Rt=1e-10;function ft(t,n,s){return Math.min(t,n)*Math.min(t,n)*Math.PI<=s+Rt?Math.abs(t-n):ce(e=>xt(t,n,e)-s,0,t+n)}function fe(t,n={}){const s=n.distinct,e=t.map(l=>Object.assign({},l));function i(l){return l.join(";")}if(s){const l=new Map;for(const h of e)for(let u=0;u<h.sets.length;u++){const a=String(h.sets[u]);l.set(a,h.size+(l.get(a)||0));for(let p=u+1;p<h.sets.length;p++){const d=String(h.sets[p]),m=`${a};${d}`,y=`${d};${a}`;l.set(m,h.size+(l.get(m)||0)),l.set(y,h.size+(l.get(y)||0))}}for(const h of e)h.sets.length<3&&(h.size=l.get(i(h.sets)))}const r=[],o=new Set;for(const l of e)if(l.sets.length===1)r.push(l.sets[0]);else if(l.sets.length===2){const h=l.sets[0],u=l.sets[1];o.add(i(l.sets)),o.add(i([u,h]))}r.sort((l,h)=>l===h?0:l<h?-1:1);for(let l=0;l<r.length;++l){const h=r[l];for(let u=l+1;u<r.length;++u){const a=r[u];o.has(i([h,a]))||e.push({sets:[h,a],size:0})}}return e}function de(t,n,s){const e=Mt(n.length,n.length),i=Mt(n.length,n.length);return t.filter(r=>r.sets.length===2).forEach(r=>{const o=s[r.sets[0]],l=s[r.sets[1]],h=Math.sqrt(n[o].size/Math.PI),u=Math.sqrt(n[l].size/Math.PI),a=ft(h,u,r.size);e[o][l]=e[l][o]=a;let p=0;r.size+1e-10>=Math.min(n[o].size,n[l].size)?p=1:r.size<=1e-10&&(p=-1),i[o][l]=i[l][o]=p}),{distances:e,constraints:i}}function ge(t,n,s,e){for(let r=0;r<n.length;++r)n[r]=0;let i=0;for(let r=0;r<s.length;++r){const o=t[2*r],l=t[2*r+1];for(let h=r+1;h<s.length;++h){const u=t[2*h],a=t[2*h+1],p=s[r][h],d=e[r][h],m=(u-o)*(u-o)+(a-l)*(a-l),y=Math.sqrt(m),M=m-p*p;d>0&&y<=p||d<0&&y>=p||(i+=2*M*M,n[2*r]+=4*M*(o-u),n[2*r+1]+=4*M*(l-a),n[2*h]+=4*M*(u-o),n[2*h+1]+=4*M*(a-l))}}return i}function xe(t,n={}){let s=pe(t,n);const e=n.lossFunction||et;if(t.length>=8){const i=ye(t,n),r=e(i,t),o=e(s,t);r+1e-8<o&&(s=i)}return s}function ye(t,n={}){const s=n.restarts||10,e=[],i={};for(const d of t)d.sets.length===1&&(i[d.sets[0]]=e.length,e.push(d));let{distances:r,constraints:o}=de(t,e,i);const l=ut(r.map(ut))/r.length;r=r.map(d=>d.map(m=>m/l));const h=(d,m)=>ge(d,m,r,o);let u=null;for(let d=0;d<s;++d){const m=ct(r.length*2).map(Math.random),y=he(h,m,n);(!u||y.fx<u.fx)&&(u=y)}const a=u.x,p={};for(let d=0;d<e.length;++d){const m=e[d];p[m.sets[0]]={x:a[2*d]*l,y:a[2*d+1]*l,radius:Math.sqrt(m.size/Math.PI)}}if(n.history)for(const d of n.history)ht(d.x,l);return p}function pe(t,n){const s=n&&n.lossFunction?n.lossFunction:et,e={},i={};for(const p of t)if(p.sets.length===1){const d=p.sets[0];e[d]={x:1e10,y:1e10,rowid:e.length,size:p.size,radius:Math.sqrt(p.size/Math.PI)},i[d]=[]}t=t.filter(p=>p.sets.length===2);for(const p of t){let d=p.weight!=null?p.weight:1;const m=p.sets[0],y=p.sets[1];p.size+Rt>=Math.min(e[m].size,e[y].size)&&(d=0),i[m].push({set:y,size:p.size,weight:d}),i[y].push({set:m,size:p.size,weight:d})}const r=[];Object.keys(i).forEach(p=>{let d=0;for(let m=0;m<i[p].length;++m)d+=i[p][m].size*i[p][m].weight;r.push({set:p,size:d})});function o(p,d){return d.size-p.size}r.sort(o);const l={};function h(p){return p.set in l}function u(p,d){e[d].x=p.x,e[d].y=p.y,l[d]=!0}u({x:0,y:0},r[0].set);for(let p=1;p<r.length;++p){const d=r[p].set,m=i[d].filter(h),y=e[d];if(m.sort(o),m.length===0)throw"ERROR: missing pairwise overlap information";const M=[];for(var a=0;a<m.length;++a){const w=e[m[a].set],g=ft(y.radius,w.radius,m[a].size);M.push({x:w.x+g,y:w.y}),M.push({x:w.x-g,y:w.y}),M.push({y:w.y+g,x:w.x}),M.push({y:w.y-g,x:w.x});for(let b=a+1;b<m.length;++b){const v=e[m[b].set],c=ft(y.radius,v.radius,m[b].size),x=Tt({x:w.x,y:w.y,radius:g},{x:v.x,y:v.y,radius:c});M.push(...x)}}let E=1e50,T=M[0];for(const w of M){e[d].x=w.x,e[d].y=w.y;const g=s(e,t);g<E&&(E=g,T=w)}u(T,d)}return e}function et(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const o=t[e.sets[0]],l=t[e.sets[1]];i=xt(o.radius,l.radius,K(o,l))}else i=st(e.sets.map(o=>t[o]));const r=e.weight!=null?e.weight:1;s+=r*(i-e.size)*(i-e.size)}return s}function Ct(t,n){let s=0;for(const e of n){if(e.sets.length===1)continue;let i;if(e.sets.length===2){const l=t[e.sets[0]],h=t[e.sets[1]];i=xt(l.radius,h.radius,K(l,h))}else i=st(e.sets.map(l=>t[l]));const r=e.weight!=null?e.weight:1,o=Math.log((i+1)/(e.size+1));s+=r*o*o}return s}function me(t,n,s){if(s==null?t.sort((i,r)=>r.radius-i.radius):t.sort(s),t.length>0){const i=t[0].x,r=t[0].y;for(const o of t)o.x-=i,o.y-=r}if(t.length===2&&K(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){const i=Math.atan2(t[1].x,t[1].y)-n,r=Math.cos(i),o=Math.sin(i);for(const l of t){const h=l.x,u=l.y;l.x=r*h-o*u,l.y=o*h+r*u}}if(t.length>2){let i=Math.atan2(t[2].x,t[2].y)-n;for(;i<0;)i+=2*Math.PI;for(;i>2*Math.PI;)i-=2*Math.PI;if(i>Math.PI){const r=t[1].y/(1e-10+t[1].x);for(const o of t){var e=(o.x+r*o.y)/(1+r*r);o.x=2*e-o.x,o.y=2*e*r-o.y}}}}function be(t){t.forEach(i=>{i.parent=i});function n(i){return i.parent!==i&&(i.parent=n(i.parent)),i.parent}function s(i,r){const o=n(i),l=n(r);o.parent=l}for(let i=0;i<t.length;++i)for(let r=i+1;r<t.length;++r){const o=t[i].radius+t[r].radius;K(t[i],t[r])+1e-10<o&&s(t[r],t[i])}const e=new Map;for(let i=0;i<t.length;++i){const r=n(t[i]).parent.setid;e.has(r)||e.set(r,[]),e.get(r).push(t[i])}return t.forEach(i=>{delete i.parent}),Array.from(e.values())}function dt(t){const n=s=>{const e=t.reduce((r,o)=>Math.max(r,o[s]+o.radius),Number.NEGATIVE_INFINITY),i=t.reduce((r,o)=>Math.min(r,o[s]-o.radius),Number.POSITIVE_INFINITY);return{max:e,min:i}};return{xRange:n("x"),yRange:n("y")}}function Dt(t,n,s){n==null&&(n=Math.PI/2);let e=Ft(t).map(u=>Object.assign({},u));const i=be(e);for(const u of i){me(u,n,s);const a=dt(u);u.size=(a.xRange.max-a.xRange.min)*(a.yRange.max-a.yRange.min),u.bounds=a}i.sort((u,a)=>a.size-u.size),e=i[0];let r=e.bounds;const o=(r.xRange.max-r.xRange.min)/50;function l(u,a,p){if(!u)return;const d=u.bounds;let m,y;if(a)m=r.xRange.max-d.xRange.min+o;else{m=r.xRange.max-d.xRange.max;const M=(d.xRange.max-d.xRange.min)/2-(r.xRange.max-r.xRange.min)/2;M<0&&(m+=M)}if(p)y=r.yRange.max-d.yRange.min+o;else{y=r.yRange.max-d.yRange.max;const M=(d.yRange.max-d.yRange.min)/2-(r.yRange.max-r.yRange.min)/2;M<0&&(y+=M)}for(const M of u)M.x+=m,M.y+=y,e.push(M)}let h=1;for(;h<i.length;)l(i[h],!0,!1),l(i[h+1],!1,!0),l(i[h+2],!0,!0),h+=3,r=dt(e);return Nt(e)}function Ot(t,n,s,e,i){const r=Ft(t);n-=2*e,s-=2*e;const{xRange:o,yRange:l}=dt(r);if(o.max===o.min||l.max===l.min)return console.log("not scaling solution: zero size detected"),t;let h,u;if(i){const m=Math.sqrt(i/Math.PI)*2;h=n/m,u=s/m}else h=n/(o.max-o.min),u=s/(l.max-l.min);const a=Math.min(u,h),p=(n-(o.max-o.min)*a)/2,d=(s-(l.max-l.min)*a)/2;return Nt(r.map(m=>({radius:a*m.radius,x:e+p+(m.x-o.min)*a,y:e+d+(m.y-l.min)*a,setid:m.setid})))}function Nt(t){const n={};for(const s of t)n[s.setid]=s;return n}function Ft(t){return Object.keys(t).map(s=>Object.assign(t[s],{setid:s}))}function ve(t={}){let n=!1,s=600,e=350,i=15,r=1e3,o=Math.PI/2,l=!0,h=null,u=!0,a=!0,p=null,d=null,m=!1,y=null,M=t&&t.symmetricalTextCentre?t.symmetricalTextCentre:!1,E={},T=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],w=0,g=function(x){if(x in E)return E[x];var f=E[x]=T[w];return w+=1,w>=T.length&&(w=0),f},b=At,v=et;function c(x){let f=x.datum();const O=new Set;f.forEach(I=>{I.size==0&&I.sets.length==1&&O.add(I.sets[0])}),f=f.filter(I=>!I.sets.some(C=>O.has(C)));let k={},D={};if(f.length>0){let I=b(f,{lossFunction:v,distinct:m});l&&(I=Dt(I,o,d)),k=Ot(I,s,e,i,h),D=Lt(k,f,M)}const X={};f.forEach(I=>{I.label&&(X[I.sets]=I.label)});function G(I){if(I.sets in X)return X[I.sets];if(I.sets.length==1)return""+I.sets[0]}x.selectAll("svg").data([k]).enter().append("svg");const B=x.select("svg");n?B.attr("viewBox",`0 0 ${s} ${e}`):B.attr("width",s).attr("height",e);const V={};let z=!1;B.selectAll(".venn-area path").each(function(I){const C=this.getAttribute("d");I.sets.length==1&&C&&!m&&(z=!0,V[I.sets[0]]=Me(C))});function q(I){return C=>{const H=I.sets.map(Q=>{let W=V[Q],Y=k[Q];return W||(W={x:s/2,y:e/2,radius:1}),Y||(Y={x:s/2,y:e/2,radius:1}),{x:W.x*(1-C)+Y.x*C,y:W.y*(1-C)+Y.y*C,radius:W.radius*(1-C)+Y.radius*C}});return wt(H,y)}}const R=B.selectAll(".venn-area").data(f,I=>I.sets),N=R.enter().append("g").attr("class",I=>`venn-area venn-${I.sets.length==1?"circle":"intersection"}${I.colour||I.color?" venn-coloured":""}`).attr("data-venn-sets",I=>I.sets.join("_")),j=N.append("path"),L=N.append("text").attr("class","label").text(I=>G(I)).attr("text-anchor","middle").attr("dy",".35em").attr("x",s/2).attr("y",e/2);a&&(j.style("fill-opacity","0").filter(I=>I.sets.length==1).style("fill",I=>I.colour?I.colour:I.color?I.color:g(I.sets)).style("fill-opacity",".25"),L.style("fill",I=>I.colour||I.color?"#FFF":t.textFill?t.textFill:I.sets.length==1?g(I.sets):"#444"));function P(I){return typeof I.transition=="function"?I.transition("venn").duration(r):I}let _=x;z&&typeof _.transition=="function"?(_=P(x),_.selectAll("path").attrTween("d",q)):_.selectAll("path").attr("d",I=>wt(I.sets.map(C=>k[C])),y);const F=_.selectAll("text").filter(I=>I.sets in D).text(I=>G(I)).attr("x",I=>Math.floor(D[I.sets].x)).attr("y",I=>Math.floor(D[I.sets].y));u&&(z?"on"in F?F.on("end",ot(k,G)):F.each("end",ot(k,G)):F.each(ot(k,G)));const A=P(R.exit()).remove();typeof R.transition=="function"&&A.selectAll("path").attrTween("d",q);const Z=A.selectAll("text").attr("x",s/2).attr("y",e/2);return p!==null&&(L.style("font-size","0px"),F.style("font-size",p),Z.style("font-size","0px")),{circles:k,textCentres:D,nodes:R,enter:N,update:_,exit:A}}return c.wrap=function(x){return arguments.length?(u=x,c):u},c.useViewBox=function(){return n=!0,c},c.width=function(x){return arguments.length?(s=x,c):s},c.height=function(x){return arguments.length?(e=x,c):e},c.padding=function(x){return arguments.length?(i=x,c):i},c.distinct=function(x){return arguments.length?(m=x,c):m},c.colours=function(x){return arguments.length?(g=x,c):g},c.colors=function(x){return arguments.length?(g=x,c):g},c.fontSize=function(x){return arguments.length?(p=x,c):p},c.round=function(x){return arguments.length?(y=x,c):y},c.duration=function(x){return arguments.length?(r=x,c):r},c.layoutFunction=function(x){return arguments.length?(b=x,c):b},c.normalize=function(x){return arguments.length?(l=x,c):l},c.scaleToFit=function(x){return arguments.length?(h=x,c):h},c.styled=function(x){return arguments.length?(a=x,c):a},c.orientation=function(x){return arguments.length?(o=x,c):o},c.orientationOrder=function(x){return arguments.length?(d=x,c):d},c.lossFunction=function(x){return arguments.length?(v=x==="default"?et:x==="logRatio"?Ct:x,c):v},c}function ot(t,n){return function(s){const e=this,i=t[s.sets[0]].radius||50,r=n(s)||"",o=r.split(/\s+/).reverse(),h=(r.length+o.length)/3;let u=o.pop(),a=[u],p=0;const d=1.1;e.textContent=null;const m=[];function y(g){const b=e.ownerDocument.createElementNS(e.namespaceURI,"tspan");return b.textContent=g,m.push(b),e.append(b),b}let M=y(u);for(;u=o.pop(),!!u;){a.push(u);const g=a.join(" ");M.textContent=g,g.length>h&&M.getComputedTextLength()>i&&(a.pop(),M.textContent=a.join(" "),a=[u],M=y(u),p++)}const E=.35-p*d/2,T=e.getAttribute("x"),w=e.getAttribute("y");m.forEach((g,b)=>{g.setAttribute("x",T),g.setAttribute("y",w),g.setAttribute("dy",`${E+b*d}em`)})}}function at(t,n,s){let e=n[0].radius-K(n[0],t);for(let i=1;i<n.length;++i){const r=n[i].radius-K(n[i],t);r<=e&&(e=r)}for(let i=0;i<s.length;++i){const r=K(s[i],t)-s[i].radius;r<=e&&(e=r)}return e}function jt(t,n,s){const e=[];for(const a of t)e.push({x:a.x,y:a.y}),e.push({x:a.x+a.radius/2,y:a.y}),e.push({x:a.x-a.radius/2,y:a.y}),e.push({x:a.x,y:a.y+a.radius/2}),e.push({x:a.x,y:a.y-a.radius/2});let i=e[0],r=at(e[0],t,n);for(let a=1;a<e.length;++a){const p=at(e[a],t,n);p>=r&&(i=e[a],r=p)}const o=zt(a=>-1*at({x:a[0],y:a[1]},t,n),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,l={x:s?0:o[0],y:o[1]};let h=!0;for(const a of t)if(K(l,a)>a.radius){h=!1;break}for(const a of n)if(K(l,a)<a.radius){h=!1;break}if(h)return l;if(t.length==1)return{x:t[0].x,y:t[0].y};const u={};return st(t,u),u.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:u.arcs.length==1?{x:u.arcs[0].circle.x,y:u.arcs[0].circle.y}:n.length?jt(t,[]):Et(u.arcs.map(a=>a.p1))}function Ie(t){const n={},s=Object.keys(t);for(const e of s)n[e]=[];for(let e=0;e<s.length;e++){const i=s[e],r=t[i];for(let o=e+1;o<s.length;++o){const l=s[o],h=t[l],u=K(r,h);u+h.radius<=r.radius+1e-10?n[l].push(i):u+r.radius<=h.radius+1e-10&&n[i].push(l)}}return n}function Lt(t,n,s){const e={},i=Ie(t);for(let r=0;r<n.length;++r){const o=n[r].sets,l={},h={};for(let d=0;d<o.length;++d){l[o[d]]=!0;const m=i[o[d]];for(let y=0;y<m.length;++y)h[m[y]]=!0}const u=[],a=[];for(let d in t)d in l?u.push(t[d]):d in h||a.push(t[d]);const p=jt(u,a,s);e[o]=p,p.disjoint&&n[r].size>0&&console.log("WARNING: area "+o+" not represented on screen")}return e}function ke(t,n,s){const e=[];return e.push(`
|
|
2
2
|
M`,t,n),e.push(`
|
|
3
3
|
m`,-s,0),e.push(`
|
|
4
4
|
a`,s,s,0,1,0,s*2,0),e.push(`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{p as zt}from"./chunk-JWPE2WC7-
|
|
1
|
+
import{p as zt}from"./chunk-JWPE2WC7-ZHaJh6CV.js";import{s as Lt,g as Tt,v as At,t as Xt,a as Et,b as Yt,_ as y,a7 as It,M as Bt,O as Q,l as et,R as Ft,d as Rt,A as Ot,c as V}from"./mermaid.core-C-qvGQ5g.js";import{p as Wt}from"./cynefin-EF2NZ3EQ-CB_HMIZ8.js";import"./index-YUtEyz7O.js";import"./BlintzCanvas-BgIQdpTx.js";import"./index-Bktc0aFV.js";import"./index-CLTrC-a-.js";import"./transform-BqqRT-Iy.js";var G=y((a,o)=>{const e=a<=1?a*100:a;if(e<0||e>100)throw new Error(`${o} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${a}`);return e},"toPercent"),E=y((a,o,e)=>({x:G(o,`${e} evolution`),y:G(a,`${e} visibility`)}),"toCoordinates"),tt=y(a=>{if(a){if(a==="+<>")return"bidirectional";if(a==="+<")return"backward";if(a==="+>")return"forward"}},"getFlowFromPort"),Dt=y(a=>{if(!(a!=null&&a.startsWith("+")))return{};const o=/^\+'([^']*)'/.exec(a),e=o==null?void 0:o[1];return a.includes("<>")?{flow:"bidirectional",label:e}:a.includes("<")?{flow:"backward",label:e}:a.includes(">")?{flow:"forward",label:e}:{label:e}},"extractFlowFromArrow"),Gt=y((a,o)=>{if(zt(a,o),a.size&&o.setSize(a.size.width,a.size.height),a.evolution){const e=a.evolution.stages.map(r=>r.secondName?`${r.name.trim()} / ${r.secondName.trim()}`:r.name.trim()),p=a.evolution.stages.filter(r=>r.boundary!==void 0).map(r=>r.boundary);o.updateAxes({stages:e,stageBoundaries:p})}if(a.anchors.forEach(e=>{const p=E(e.visibility,e.evolution,`Anchor "${e.name}"`);o.addNode(e.name,e.name,p.x,p.y,"anchor")}),a.components.forEach(e=>{var v;const p=E(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,d=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,m=(v=e.decorator)==null?void 0:v.strategy;o.addNode(e.name,e.name,p.x,p.y,"component",r,d,e.inertia,m)}),a.notes.forEach(e=>{const p=E(e.visibility,e.evolution,`Note "${e.text}"`);o.addNote(e.text,p.x,p.y)}),a.pipelines.forEach(e=>{const p=o.getNode(e.parent);if(!p||typeof p.y!="number")throw new Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);const r=p.y;o.startPipeline(e.parent),e.components.forEach(d=>{const m=`${e.parent}_${d.name}`,v=d.label?(d.label.negX?-1:1)*d.label.offsetX:void 0,g=d.label?(d.label.negY?-1:1)*d.label.offsetY:void 0,L=G(d.evolution,`Pipeline component "${d.name}" evolution`);o.addNode(m,d.name,L,r,"pipeline-component",v,g),o.addPipelineComponent(e.parent,m)})}),a.links.forEach(e=>{const p=!!e.arrow&&(e.arrow.includes("-.->")||e.arrow.includes(".-."));let r=tt(e.fromPort)??tt(e.toPort);const{flow:d,label:m}=Dt(e.arrow);!r&&d&&(r=d);const v=e.linkLabel,g=m??v;o.addLink(o.resolveNodeId(e.from),o.resolveNodeId(e.to),p,g,r)}),a.evolves.forEach(e=>{const p=o.getNode(e.component);if((p==null?void 0:p.y)!==void 0){const r=G(e.target,`Evolve target for "${e.component}"`);o.addTrend(e.component,r,p.y)}}),a.annotations.length>0){const e=a.annotations[0],p=E(e.x,e.y,"Annotations box");o.setAnnotationsBox(p.x,p.y)}a.annotation.forEach(e=>{const p=E(e.x,e.y,`Annotation ${e.number}`);o.addAnnotation(e.number,[{x:p.x,y:p.y}],e.text)}),a.accelerators.forEach(e=>{const p=E(e.x,e.y,`Accelerator "${e.name}"`);o.addAccelerator(e.name,p.x,p.y)}),a.deaccelerators.forEach(e=>{const p=E(e.x,e.y,`Deaccelerator "${e.name}"`);o.addDeaccelerator(e.name,p.x,p.y)})},"populateDb"),at={parser:{yy:void 0},parse:y(async a=>{var p;const o=await Wt("wardley",a);et.debug(o);const e=(p=at.parser)==null?void 0:p.yy;if(!e||typeof e.addNode!="function")throw new Error("parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");Gt(o,e)},"parse")},I,qt=(I=class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}addNode(o){const e=this.nodes.get(o.id)??{id:o.id,label:o.label},p={...e,...o,className:o.className??e.className,labelOffsetX:o.labelOffsetX??e.labelOffsetX,labelOffsetY:o.labelOffsetY??e.labelOffsetY};this.nodes.set(o.id,p)}addLink(o){this.links.push(o)}addTrend(o){this.trends.set(o.nodeId,o)}startPipeline(o){this.pipelines.set(o,{nodeId:o,componentIds:[]});const e=this.nodes.get(o);e&&(e.isPipelineParent=!0)}addPipelineComponent(o,e){const p=this.pipelines.get(o);p&&p.componentIds.push(e);const r=this.nodes.get(e);r&&(r.inPipeline=!0)}addAnnotation(o){this.annotations.push(o)}addNote(o){this.notes.push(o)}addAccelerator(o){this.accelerators.push(o)}addDeaccelerator(o){this.deaccelerators.push(o)}setAnnotationsBox(o,e){this.annotationsBox={x:o,y:e}}setAxes(o){this.axes={...this.axes,...o}}setSize(o,e){this.size={width:o,height:e}}getNode(o){return this.nodes.get(o)}resolveNodeId(o){if(this.nodes.has(o))return o;for(const[e,p]of this.nodes)if(p.label===o)return e;return o}build(){const o=[];for(const e of this.nodes.values()){if(typeof e.x!="number"||typeof e.y!="number")throw new Error(`Node "${e.label}" is missing coordinates`);o.push(e)}return{nodes:o,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}},y(I,"WardleyBuilder"),I),b=new qt;function rt(){return V()["wardley-beta"]}y(rt,"getConfig");function ot(a,o,e,p,r,d,m,v,g){b.addNode({id:a,label:o,x:e,y:p,className:r,labelOffsetX:d,labelOffsetY:m,inertia:v,sourceStrategy:g})}y(ot,"addNode");function st(a,o,e=!1,p,r){b.addLink({source:a,target:o,dashed:e,label:p,flow:r})}y(st,"addLink");function nt(a,o,e){b.addTrend({nodeId:a,targetX:o,targetY:e})}y(nt,"addTrend");function it(a,o,e){b.addAnnotation({number:a,coordinates:o,text:e})}y(it,"addAnnotation");function dt(a,o,e){b.addNote({text:a,x:o,y:e})}y(dt,"addNote");function lt(a,o,e){b.addAccelerator({name:a,x:o,y:e})}y(lt,"addAccelerator");function ct(a,o,e){b.addDeaccelerator({name:a,x:o,y:e})}y(ct,"addDeaccelerator");function pt(a,o){b.setAnnotationsBox(a,o)}y(pt,"setAnnotationsBox");function ht(a,o){b.setSize(a,o)}y(ht,"setSize");function xt(a){b.startPipeline(a)}y(xt,"startPipeline");function ft(a,o){b.addPipelineComponent(a,o)}y(ft,"addPipelineComponent");function gt(a){b.setAxes(a)}y(gt,"updateAxes");function ut(a){return b.getNode(a)}y(ut,"getNode");function yt(a){return b.resolveNodeId(a)}y(yt,"resolveNodeId");function mt(){return b.build()}y(mt,"getWardleyData");function wt(){b.clear(),Ot()}y(wt,"clear");var Ht={getConfig:rt,addNode:ot,addLink:st,addTrend:nt,addAnnotation:it,addNote:dt,addAccelerator:lt,addDeaccelerator:ct,setAnnotationsBox:pt,setSize:ht,startPipeline:xt,addPipelineComponent:ft,updateAxes:gt,getNode:ut,resolveNodeId:yt,getWardleyData:mt,clear:wt,setAccTitle:Yt,getAccTitle:Et,setDiagramTitle:Xt,getDiagramTitle:At,getAccDescription:Tt,setAccDescription:Lt},jt=["Genesis","Custom Built","Product","Commodity"],Vt=y(()=>{var o,e,p,r,d,m,v,g,L,M,k,N;const{themeVariables:a}=V();return{backgroundColor:((o=a.wardley)==null?void 0:o.backgroundColor)??a.background??"#fff",axisColor:((e=a.wardley)==null?void 0:e.axisColor)??"#000",axisTextColor:((p=a.wardley)==null?void 0:p.axisTextColor)??a.primaryTextColor??"#222",gridColor:((r=a.wardley)==null?void 0:r.gridColor)??"rgba(100, 100, 100, 0.2)",componentFill:((d=a.wardley)==null?void 0:d.componentFill)??"#fff",componentStroke:((m=a.wardley)==null?void 0:m.componentStroke)??"#000",componentLabelColor:((v=a.wardley)==null?void 0:v.componentLabelColor)??a.primaryTextColor??"#222",linkStroke:((g=a.wardley)==null?void 0:g.linkStroke)??"#000",evolutionStroke:((L=a.wardley)==null?void 0:L.evolutionStroke)??"#dc3545",annotationStroke:((M=a.wardley)==null?void 0:M.annotationStroke)??"#000",annotationTextColor:((k=a.wardley)==null?void 0:k.annotationTextColor)??a.primaryTextColor??"#222",annotationFill:((N=a.wardley)==null?void 0:N.annotationFill)??a.background??"#fff"}},"getTheme"),_t=y(()=>{const a=V()["wardley-beta"];return{width:(a==null?void 0:a.width)??900,height:(a==null?void 0:a.height)??600,padding:(a==null?void 0:a.padding)??48,nodeRadius:(a==null?void 0:a.nodeRadius)??6,nodeLabelOffset:(a==null?void 0:a.nodeLabelOffset)??8,axisFontSize:(a==null?void 0:a.axisFontSize)??12,labelFontSize:(a==null?void 0:a.labelFontSize)??10,showGrid:(a==null?void 0:a.showGrid)??!1,useMaxWidth:(a==null?void 0:a.useMaxWidth)??!0}},"getConfigValues"),Zt=y((a,o,e,p)=>{var J,K;et.debug(`Rendering Wardley map
|
|
2
2
|
`+a);const r=_t(),d=Vt(),m=r.nodeRadius*1.6,v=p.db,g=v.getWardleyData(),L=v.getDiagramTitle(),M=((J=g.size)==null?void 0:J.width)??r.width,k=((K=g.size)==null?void 0:K.height)??r.height,N=Ft(o);N.selectAll("*").remove(),Rt(N,k,M,r.useMaxWidth),N.attr("viewBox",`0 0 ${M} ${k}`);const P=N.append("g").attr("class","wardley-map"),q=N.append("defs");q.append("marker").attr("id",`arrow-${o}`).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",6).attr("markerHeight",6).attr("orient","auto-start-reverse").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("fill",d.evolutionStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-end-${o}`).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("fill",d.linkStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-start-${o}`).attr("viewBox","0 0 10 10").attr("refX",1).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z").attr("fill",d.linkStroke).attr("stroke","none"),P.append("rect").attr("class","wardley-background").attr("width",M).attr("height",k).attr("fill",d.backgroundColor);const B=M-r.padding*2,F=k-r.padding*2;L&&P.append("text").attr("class","wardley-title").attr("x",M/2).attr("y",r.padding/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize*1.05).attr("font-weight","bold").attr("text-anchor","middle").attr("dominant-baseline","middle").text(L);const T=y(t=>r.padding+t/100*B,"projectX"),A=y(t=>k-r.padding-t/100*F,"projectY"),O=P.append("g").attr("class","wardley-axes");O.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1),O.append("line").attr("x1",r.padding).attr("x2",r.padding).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1);const kt=g.axes.xLabel??"Evolution",bt=g.axes.yLabel??"Visibility";O.append("text").attr("class","wardley-axis-label wardley-axis-label-x").attr("x",r.padding+B/2).attr("y",k-r.padding/4).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").text(kt),O.append("text").attr("class","wardley-axis-label wardley-axis-label-y").attr("x",r.padding/3).attr("y",r.padding+F/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("transform",`rotate(-90 ${r.padding/3} ${r.padding+F/2})`).text(bt);const R=g.axes.stages&&g.axes.stages.length>0?g.axes.stages:jt;if(R.length>0){const t=P.append("g").attr("class","wardley-stages"),n=g.axes.stageBoundaries,s=[];if(n&&n.length===R.length){let i=0;n.forEach(h=>{s.push({start:i,end:h}),i=h})}else{const i=1/R.length;R.forEach((h,l)=>{s.push({start:l*i,end:(l+1)*i})})}R.forEach((i,h)=>{const l=s[h],x=r.padding+l.start*B,f=r.padding+l.end*B,u=(x+f)/2;h>0&&t.append("line").attr("x1",x).attr("x2",x).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke","#000").attr("stroke-width",1).attr("stroke-dasharray","5 5").attr("opacity",.8),t.append("text").attr("class","wardley-stage-label").attr("x",u).attr("y",k-r.padding/1.5).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize-2).attr("text-anchor","middle").text(i)})}if(r.showGrid){const t=P.append("g").attr("class","wardley-grid");for(let n=1;n<4;n++){const s=n/4,i=r.padding+B*s;t.append("line").attr("x1",i).attr("x2",i).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6"),t.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding-F*s).attr("y2",k-r.padding-F*s).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6")}}const c=new Map;if(g.nodes.forEach(t=>{c.set(t.id,{x:T(t.x),y:A(t.y),node:t})}),g.pipelines.length>0){const t=P.append("g").attr("class","wardley-pipelines"),n=P.append("g").attr("class","wardley-pipeline-links");g.pipelines.forEach(s=>{if(s.componentIds.length===0)return;const i=s.componentIds.map(f=>({id:f,pos:c.get(f),node:g.nodes.find(u=>u.id===f)})).filter(f=>f.pos&&f.node).sort((f,u)=>f.node.x-u.node.x);for(let f=0;f<i.length-1;f++){const u=i[f],w=i[f+1];n.append("line").attr("class","wardley-pipeline-evolution-link").attr("x1",u.pos.x).attr("y1",u.pos.y).attr("x2",w.pos.x).attr("y2",w.pos.y).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4")}let h=1/0,l=-1/0,x=0;if(s.componentIds.forEach(f=>{const u=c.get(f);u&&(h=Math.min(h,u.x),l=Math.max(l,u.x),x=u.y)}),h!==1/0&&l!==-1/0){const u=r.nodeRadius*4,w=x-u/2,S=c.get(s.nodeId);if(S){const z=(h+l)/2;S.x=z,S.y=w-m/6}t.append("rect").attr("class","wardley-pipeline-box").attr("x",h-15).attr("y",w).attr("width",l-h+30).attr("height",u).attr("fill","none").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}})}const _=P.append("g").attr("class","wardley-links"),Z=new Map;g.pipelines.forEach(t=>{Z.set(t.nodeId,new Set(t.componentIds))});const U=g.links.filter(t=>{if(!c.has(t.source)||!c.has(t.target))return!1;const n=Z.get(t.target);return!(n!=null&&n.has(t.source))});_.selectAll("line").data(U).enter().append("line").attr("class",t=>`wardley-link${t.dashed?" wardley-link--dashed":""}`).attr("x1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.x+l/f*h}).attr("y1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.y+x/f*h}).attr("x2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.x+l/f*h}).attr("y2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.y+x/f*h}).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray",t=>t.dashed?"6 6":null).attr("marker-end",t=>t.flow==="forward"||t.flow==="bidirectional"?`url(#link-arrow-end-${o})`:null).attr("marker-start",t=>t.flow==="backward"||t.flow==="bidirectional"?`url(#link-arrow-start-${o})`:null),_.selectAll("text").data(U.filter(t=>t.label)).enter().append("text").attr("class","wardley-link-label").attr("x",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=s.y-n.y,l=s.x-n.x,x=Math.sqrt(l*l+h*h),f=8,u=h/x;return i+u*f}).attr("y",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.y+s.y)/2,h=s.x-n.x,l=s.y-n.y,x=Math.sqrt(h*h+l*l),f=8,u=-h/x;return i+u*f}).attr("fill",d.axisTextColor).attr("font-size",r.labelFontSize).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("transform",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=(n.y+s.y)/2,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x),u=8,w=x/f,S=-l/f,z=i+w*u,W=h+S*u;let Y=Math.atan2(x,l)*180/Math.PI;return(Y>90||Y<-90)&&(Y+=180),`rotate(${Y} ${z} ${W})`}).text(t=>t.label);const $t=P.append("g").attr("class","wardley-trends"),vt=g.trends.map(t=>{const n=c.get(t.nodeId);if(!n)return null;const s=T(t.targetX),i=A(t.targetY),h=s-n.x,l=i-n.y,x=Math.sqrt(h*h+l*l),f=r.nodeRadius+2,u=x>f?s-h/x*f:s,w=x>f?i-l/x*f:i;return{origin:n,targetX:s,targetY:i,adjustedX2:u,adjustedY2:w}}).filter(t=>t!==null);$t.selectAll("line").data(vt).enter().append("line").attr("class","wardley-trend").attr("x1",t=>t.origin.x).attr("y1",t=>t.origin.y).attr("x2",t=>t.adjustedX2).attr("y2",t=>t.adjustedY2).attr("stroke",d.evolutionStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4").attr("marker-end",`url(#arrow-${o})`);const C=P.append("g").attr("class","wardley-nodes").selectAll("g").data(g.nodes).enter().append("g").attr("class",t=>["wardley-node",t.className?`wardley-node--${t.className}`:""].filter(Boolean).join(" "));C.filter(t=>t.sourceStrategy==="outsource").append("circle").attr("class","wardley-outsource-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#666").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="buy").append("circle").attr("class","wardley-buy-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#ccc").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="build").append("circle").attr("class","wardley-build-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#eee").attr("stroke","#000").attr("stroke-width",1);const X=C.filter(t=>t.sourceStrategy==="market");X.append("circle").attr("class","wardley-market-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>!t.isPipelineParent&&t.sourceStrategy!=="market"&&t.className!=="anchor").append("circle").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1);const H=r.nodeRadius*.7,$=r.nodeRadius*1.2;if(X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x).attr("y1",t=>c.get(t.id).y-$).attr("x2",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x).attr("y2",t=>c.get(t.id).y-$).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y-$).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),C.filter(t=>t.isPipelineParent===!0).append("rect").attr("x",t=>c.get(t.id).x-m/2).attr("y",t=>c.get(t.id).y-m/2).attr("width",m).attr("height",m).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.inertia===!0).append("line").attr("class","wardley-inertia").attr("x1",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y1",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y-s/2}).attr("x2",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y2",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y+s/2}).attr("stroke",d.componentStroke).attr("stroke-width",6),C.append("text").attr("x",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetX!==void 0?n.x+t.labelOffsetX:n.x;let s=r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetX===void 0&&(s+=10);const i=t.labelOffsetX??s;return n.x+i}).attr("y",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetY!==void 0?n.y+t.labelOffsetY:n.y-3;let s=-r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetY===void 0&&(s-=10);const i=t.labelOffsetY??s;return n.y+i}).attr("class","wardley-node-label").attr("fill",t=>t.className==="evolved"?d.evolutionStroke:t.className==="anchor"?"#000":d.componentLabelColor).attr("font-size",r.labelFontSize).attr("font-weight",t=>t.className==="anchor"?"bold":"normal").attr("text-anchor",t=>t.className==="anchor"?"middle":"start").attr("dominant-baseline",t=>t.className==="anchor"?"middle":"auto").text(t=>t.label),g.annotations.length>0){const t=P.append("g").attr("class","wardley-annotations");if(g.annotations.forEach(n=>{const s=n.coordinates.map(i=>({x:T(i.x),y:A(i.y)}));if(s.length>1)for(let i=0;i<s.length-1;i++)t.append("line").attr("class","wardley-annotation-line").attr("x1",s[i].x).attr("y1",s[i].y).attr("x2",s[i+1].x).attr("y2",s[i+1].y).attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("stroke-dasharray","4 4");s.forEach(i=>{const h=t.append("g").attr("class","wardley-annotation");h.append("circle").attr("cx",i.x).attr("cy",i.y).attr("r",10).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5),h.append("text").attr("x",i.x).attr("y",i.y).attr("text-anchor","middle").attr("dominant-baseline","central").attr("font-size",10).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.number)})}),g.annotationsBox){let n=T(g.annotationsBox.x),s=A(g.annotationsBox.y);const i=10,h=16,l=11,x=t.append("g").attr("class","wardley-annotations-box"),f=[...g.annotations].filter(w=>w.text).sort((w,S)=>w.number-S.number),u=[];if(f.forEach((w,S)=>{const z=x.append("text").attr("x",n+i).attr("y",s+i+(S+1)*h).attr("font-size",l).attr("fill",d.axisTextColor).attr("text-anchor","start").attr("dominant-baseline","middle").text(`${w.number}. ${w.text}`);u.push(z)}),u.length>0){let w=0,S=0;u.forEach(j=>{const D=j.node(),Nt=D.getComputedTextLength();w=Math.max(w,Nt);const Ct=D.getBBox();S=Math.max(S,Ct.height)});const z=w+i*2+105,W=f.length*h+i*2+S/2,Y=r.padding,Pt=M-r.padding-z,St=r.padding,Mt=k-r.padding-W;n=Math.max(Y,Math.min(n,Pt)),s=Math.max(St,Math.min(s,Mt)),u.forEach((j,D)=>{j.attr("x",n+i).attr("y",s+i+(D+1)*h)}),x.insert("rect","text").attr("x",n).attr("y",s).attr("width",z).attr("height",W).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}}}if(g.notes.length>0){const t=P.append("g").attr("class","wardley-notes");g.notes.forEach(n=>{const s=T(n.x),i=A(n.y);t.append("text").attr("x",s).attr("y",i).attr("text-anchor","start").attr("font-size",11).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.text)})}if(g.accelerators.length>0){const t=P.append("g").attr("class","wardley-accelerators");g.accelerators.forEach(n=>{const s=T(n.x),i=A(n.y),h=60,l=30,x=20,f=`
|
|
3
3
|
M ${s} ${i-l/2}
|
|
4
4
|
L ${s+h-x} ${i-l/2}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{s as pi,g as mi,v as $t,t as yi,a as bi,b as wi,_ as a,l as Ut,R as Ai,d as Ci,A as Si,M as Dt,j as Ri,O as Gt,P as _i,a7 as ki,aF as Ti,aG as Xt}from"./mermaid.core-
|
|
1
|
+
import{s as pi,g as mi,v as $t,t as yi,a as bi,b as wi,_ as a,l as Ut,R as Ai,d as Ci,A as Si,M as Dt,j as Ri,O as Gt,P as _i,a7 as ki,aF as Ti,aG as Xt}from"./mermaid.core-C-qvGQ5g.js";import"./transform-BqqRT-Iy.js";import{i as Di}from"./init-Gi6I4Gst.js";import{o as Pi}from"./ordinal-Cboi1Yqb.js";import{l as Yt}from"./linear-BT-xgETh.js";import"./index-YUtEyz7O.js";import"./BlintzCanvas-BgIQdpTx.js";import"./index-Bktc0aFV.js";import"./index-CLTrC-a-.js";import"./value-wA6veExk.js";import"./defaultLocale-DX6XiGOO.js";function vi(e,t,i){e=+e,t=+t,i=(n=arguments.length)<2?(t=e,e=0,1):n<3?1:+i;for(var s=-1,n=Math.max(0,Math.ceil((t-e)/i))|0,o=new Array(n);++s<n;)o[s]=e+s*i;return o}function St(){var e=Pi().unknown(void 0),t=e.domain,i=e.range,s=0,n=1,o,l,m=!1,u=0,d=0,S=.5;delete e.unknown;function y(){var f=t().length,L=n<s,D=L?n:s,E=L?s:n;o=(E-D)/Math.max(1,f-u+d*2),m&&(o=Math.floor(o)),D+=(E-D-o*(f-u))*S,l=o*(1-u),m&&(D=Math.round(D),l=Math.round(l));var M=vi(f).map(function(w){return D+o*w});return i(L?M.reverse():M)}return e.domain=function(f){return arguments.length?(t(f),y()):t()},e.range=function(f){return arguments.length?([s,n]=f,s=+s,n=+n,y()):[s,n]},e.rangeRound=function(f){return[s,n]=f,s=+s,n=+n,m=!0,y()},e.bandwidth=function(){return l},e.step=function(){return o},e.round=function(f){return arguments.length?(m=!!f,y()):m},e.padding=function(f){return arguments.length?(u=Math.min(1,d=+f),y()):u},e.paddingInner=function(f){return arguments.length?(u=Math.min(1,f),y()):u},e.paddingOuter=function(f){return arguments.length?(d=+f,y()):d},e.align=function(f){return arguments.length?(S=Math.max(0,Math.min(1,f)),y()):S},e.copy=function(){return St(t(),[s,n]).round(m).paddingInner(u).paddingOuter(d).align(S)},Di.apply(y(),arguments)}var Rt=(function(){var e=a(function(F,r,g,x){for(g=g||{},x=F.length;x--;g[F[x]]=r);return g},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],n=[1,5],o=[1,6],l=[1,7],m=[1,5,10,12,14,16,18,19,21,23,36,37,38],u=[1,25],d=[1,26],S=[1,28],y=[1,29],f=[1,30],L=[1,31],D=[1,32],E=[1,33],M=[1,34],w=[1,35],P=[1,36],c=[1,37],B=[1,43],W=[1,42],X=[1,47],Y=[1,50],k=[1,10,12,14,16,18,19,21,23,36,37,38],H=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38],C=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38,42,43,44,45,46,47,48,49,50,51],R=[1,65],O=[26,28],T={trace:a(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,dataPoints:25,SQUARE_BRACES_END:26,dataPoint:27,COMMA:28,NUMBER_WITH_DECIMAL:29,STR:30,xAxisData:31,bandData:32,ARROW_DELIMITER:33,commaSeparatedTexts:34,yAxisData:35,NEWLINE:36,SEMI:37,EOF:38,alphaNum:39,MD_STR:40,alphaNumToken:41,AMP:42,NUM:43,ALPHA:44,PLUS:45,EQUALS:46,MULT:47,DOT:48,BRKT:49,MINUS:50,UNDERSCORE:51,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",28:"COMMA",29:"NUMBER_WITH_DECIMAL",30:"STR",33:"ARROW_DELIMITER",36:"NEWLINE",37:"SEMI",38:"EOF",40:"MD_STR",42:"AMP",43:"NUM",44:"ALPHA",45:"PLUS",46:"EQUALS",47:"MULT",48:"DOT",49:"BRKT",50:"MINUS",51:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[27,2],[27,1],[13,1],[13,2],[13,1],[31,1],[31,3],[32,3],[34,3],[34,1],[15,1],[15,2],[15,1],[35,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[39,1],[39,2],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1]],performAction:a(function(r,g,x,p,_,h,lt){var b=h.length-1;switch(_){case 5:p.setOrientation(h[b]);break;case 9:p.setDiagramTitle(h[b].text.trim());break;case 12:p.setLineData({text:"",type:"text"},h[b]);break;case 13:p.setLineData(h[b-1],h[b]);break;case 14:p.setBarData({text:"",type:"text"},h[b]);break;case 15:p.setBarData(h[b-1],h[b]);break;case 16:this.$=h[b].trim(),p.setAccTitle(this.$);break;case 17:case 18:this.$=h[b].trim(),p.setAccDescription(this.$);break;case 19:this.$=h[b-1];break;case 20:case 30:this.$=[h[b-2],...h[b]];break;case 21:case 31:this.$=[h[b]];break;case 22:this.$={value:Number(h[b-1]),label:h[b]};break;case 23:this.$={value:Number(h[b]),label:""};break;case 24:p.setXAxisTitle(h[b]);break;case 25:p.setXAxisTitle(h[b-1]);break;case 26:p.setXAxisTitle({type:"text",text:""});break;case 27:p.setXAxisBand(h[b]);break;case 28:p.setXAxisRangeData(Number(h[b-2]),Number(h[b]));break;case 29:this.$=h[b-1];break;case 32:p.setYAxisTitle(h[b]);break;case 33:p.setYAxisTitle(h[b-1]);break;case 34:p.setYAxisTitle({type:"text",text:""});break;case 35:p.setYAxisRangeData(Number(h[b-2]),Number(h[b]));break;case 39:this.$={text:h[b],type:"text"};break;case 40:this.$={text:h[b],type:"text"};break;case 41:this.$={text:h[b],type:"markdown"};break;case 42:this.$=h[b];break;case 43:this.$=h[b-1]+""+h[b];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,36:n,37:o,38:l}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,36:n,37:o,38:l}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],36:n,37:o,38:l}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(m,[2,36]),e(m,[2,37]),e(m,[2,38]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,36:n,37:o,38:l}),{1:[2,3]},e(m,[2,5]),e(t,[2,7],{4:22,36:n,37:o,38:l}),{11:23,30:u,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},{11:39,13:38,24:B,29:W,30:u,31:40,32:41,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},{11:45,15:44,29:X,30:u,35:46,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},{11:49,17:48,24:Y,30:u,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},{11:52,17:51,24:Y,30:u,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},{20:[1,53]},{22:[1,54]},e(k,[2,18]),{1:[2,2]},e(k,[2,8]),e(k,[2,9]),e(H,[2,39],{41:55,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c}),e(H,[2,40]),e(H,[2,41]),e(C,[2,42]),e(C,[2,44]),e(C,[2,45]),e(C,[2,46]),e(C,[2,47]),e(C,[2,48]),e(C,[2,49]),e(C,[2,50]),e(C,[2,51]),e(C,[2,52]),e(C,[2,53]),e(k,[2,10]),e(k,[2,24],{32:41,31:56,24:B,29:W}),e(k,[2,26]),e(k,[2,27]),{33:[1,57]},{11:59,30:u,34:58,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},e(k,[2,11]),e(k,[2,32],{35:60,29:X}),e(k,[2,34]),{33:[1,61]},e(k,[2,12]),{17:62,24:Y},{25:63,27:64,29:R},e(k,[2,14]),{17:66,24:Y},e(k,[2,16]),e(k,[2,17]),e(C,[2,43]),e(k,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},e(k,[2,33]),{29:[1,70]},e(k,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},e(O,[2,23],{30:[1,73]}),e(k,[2,15]),e(k,[2,28]),e(k,[2,29]),{11:59,30:u,34:74,39:24,40:d,41:27,42:S,43:y,44:f,45:L,46:D,47:E,48:M,49:w,50:P,51:c},e(k,[2,35]),e(k,[2,19]),{25:75,27:64,29:R},e(O,[2,22]),{26:[2,30]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],74:[2,30],75:[2,20]},parseError:a(function(r,g){if(g.recoverable)this.trace(r);else{var x=new Error(r);throw x.hash=g,x}},"parseError"),parse:a(function(r){var g=this,x=[0],p=[],_=[null],h=[],lt=this.table,b="",dt=0,Ot=0,ui=2,Vt=1,di=h.slice.call(arguments,1),v=Object.create(this.lexer),$={yy:{}};for(var bt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,bt)&&($.yy[bt]=this.yy[bt]);v.setInput(r,$.yy),$.yy.lexer=v,$.yy.parser=this,typeof v.yylloc>"u"&&(v.yylloc={});var wt=v.yylloc;h.push(wt);var xi=v.options&&v.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function fi(z){x.length=x.length-2*z,_.length=_.length-z,h.length=h.length-z}a(fi,"popStack");function Wt(){var z;return z=p.pop()||v.lex()||Vt,typeof z!="number"&&(z instanceof Array&&(p=z,z=p.pop()),z=g.symbols_[z]||z),z}a(Wt,"lex");for(var I,U,V,At,j={},xt,N,Ft,ft;;){if(U=x[x.length-1],this.defaultActions[U]?V=this.defaultActions[U]:((I===null||typeof I>"u")&&(I=Wt()),V=lt[U]&<[U][I]),typeof V>"u"||!V.length||!V[0]){var Ct="";ft=[];for(xt in lt[U])this.terminals_[xt]&&xt>ui&&ft.push("'"+this.terminals_[xt]+"'");v.showPosition?Ct="Parse error on line "+(dt+1)+`:
|
|
2
2
|
`+v.showPosition()+`
|
|
3
3
|
Expecting `+ft.join(", ")+", got '"+(this.terminals_[I]||I)+"'":Ct="Parse error on line "+(dt+1)+": Unexpected "+(I==Vt?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(Ct,{text:v.match,token:this.terminals_[I]||I,line:v.yylineno,loc:wt,expected:ft})}if(V[0]instanceof Array&&V.length>1)throw new Error("Parse Error: multiple actions possible at state: "+U+", token: "+I);switch(V[0]){case 1:x.push(I),_.push(v.yytext),h.push(v.yylloc),x.push(V[1]),I=null,Ot=v.yyleng,b=v.yytext,dt=v.yylineno,wt=v.yylloc;break;case 2:if(N=this.productions_[V[1]][1],j.$=_[_.length-N],j._$={first_line:h[h.length-(N||1)].first_line,last_line:h[h.length-1].last_line,first_column:h[h.length-(N||1)].first_column,last_column:h[h.length-1].last_column},xi&&(j._$.range=[h[h.length-(N||1)].range[0],h[h.length-1].range[1]]),At=this.performAction.apply(j,[b,Ot,dt,$.yy,V[1],_,h].concat(di)),typeof At<"u")return At;N&&(x=x.slice(0,-1*N*2),_=_.slice(0,-1*N),h=h.slice(0,-1*N)),x.push(this.productions_[V[1]][0]),_.push(j.$),h.push(j._$),Ft=lt[x[x.length-2]][x[x.length-1]],x.push(Ft);break;case 3:return!0}}return!0},"parse")},rt=(function(){var F={EOF:1,parseError:a(function(g,x){if(this.yy.parser)this.yy.parser.parseError(g,x);else throw new Error(g)},"parseError"),setInput:a(function(r,g){return this.yy=g||this.yy||{},this._input=r,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:a(function(){var r=this._input[0];this.yytext+=r,this.yyleng++,this.offset++,this.match+=r,this.matched+=r;var g=r.match(/(?:\r\n?|\n).*/g);return g?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),r},"input"),unput:a(function(r){var g=r.length,x=r.split(/(?:\r\n?|\n)/g);this._input=r+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-g),this.offset-=g;var p=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),x.length-1&&(this.yylineno-=x.length-1);var _=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:x?(x.length===p.length?this.yylloc.first_column:0)+p[p.length-x.length].length-x[0].length:this.yylloc.first_column-g},this.options.ranges&&(this.yylloc.range=[_[0],_[0]+this.yyleng-g]),this.yyleng=this.yytext.length,this},"unput"),more:a(function(){return this._more=!0,this},"more"),reject:a(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:a(function(r){this.unput(this.match.slice(r))},"less"),pastInput:a(function(){var r=this.matched.substr(0,this.matched.length-this.match.length);return(r.length>20?"...":"")+r.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:a(function(){var r=this.match;return r.length<20&&(r+=this._input.substr(0,20-r.length)),(r.substr(0,20)+(r.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:a(function(){var r=this.pastInput(),g=new Array(r.length+1).join("-");return r+this.upcomingInput()+`
|
package/dist/client/index.html
CHANGED
|
@@ -524,8 +524,8 @@
|
|
|
524
524
|
}
|
|
525
525
|
})();
|
|
526
526
|
</script>
|
|
527
|
-
<script type="module" crossorigin src="/assets/index-
|
|
528
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
527
|
+
<script type="module" crossorigin src="/assets/index-YUtEyz7O.js"></script>
|
|
528
|
+
<link rel="stylesheet" crossorigin href="/assets/index-3JL8A9YZ.css">
|
|
529
529
|
</head>
|
|
530
530
|
<body>
|
|
531
531
|
<div id="root"></div>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ALTER TABLE `pulse_schedules` ADD `declined_content_key` text;
|