@opengeni/react 4.2.1-canary.39642758903001 → 4.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/app-state.js +27 -27
- package/dist/app/components/Composer.js +27 -26
- package/dist/app/components/agent/agent-capability-picker.js +5 -5
- package/dist/app/components/artifacts/artifact-library.js +19 -19
- package/dist/app/components/artifacts/chat-interactive-block.js +16 -16
- package/dist/app/components/artifacts/inline-chat-image.js +31 -30
- package/dist/app/components/artifacts/retained-file-preview.js +35 -34
- package/dist/app/components/artifacts/retained-text-preview.js +5 -5
- package/dist/app/components/artifacts/site-audience.js +5 -5
- package/dist/app/components/artifacts/site-conversations.js +24 -22
- package/dist/app/components/artifacts/site-data.js +20 -20
- package/dist/app/components/artifacts/site-publishing.js +39 -39
- package/dist/app/components/artifacts/site-settings.js +48 -48
- package/dist/app/components/billing-class-mark.js +5 -5
- package/dist/app/components/capabilities/capability-detail-sheet.js +9 -9
- package/dist/app/components/capabilities/capability-logo-source.js +13 -12
- package/dist/app/components/capabilities/connection-account-picker.js +2 -2
- package/dist/app/components/capabilities/connector-tool-permissions.js +5 -5
- package/dist/app/components/capabilities/native-connect-setup.js +14 -13
- package/dist/app/components/capabilities/native-connect-setup.js.map +1 -1
- package/dist/app/components/capabilities/perform-capability-action.js +3 -3
- package/dist/app/components/capabilities/prepared-mcp-setup-card.js +15 -14
- package/dist/app/components/capabilities/session-capability-card.js +78 -77
- package/dist/app/components/capabilities/session-capability-card.js.map +1 -1
- package/dist/app/components/capabilities/session-custom-mcp-card.js +20 -19
- package/dist/app/components/capabilities/session-github-card.js +25 -24
- package/dist/app/components/capabilities/session-machine-card.js +38 -38
- package/dist/app/components/capabilities/use-capabilities-catalog.js +3 -3
- package/dist/app/components/capabilities/use-connection-accounts.js +1 -1
- package/dist/app/components/command-menu/chat-switcher.d.ts +12 -0
- package/dist/app/components/command-menu/chat-switcher.js +142 -0
- package/dist/app/components/command-menu/chat-switcher.js.map +1 -0
- package/dist/app/components/command-menu/command-menu.d.ts +15 -0
- package/dist/app/components/command-menu/command-menu.js +812 -0
- package/dist/app/components/command-menu/command-menu.js.map +1 -0
- package/dist/app/components/command-menu/keycaps.d.ts +21 -0
- package/dist/app/components/command-menu/keycaps.js +12 -0
- package/dist/app/components/command-menu/shortcut-sheet.d.ts +12 -0
- package/dist/app/components/command-menu/shortcut-sheet.js +150 -0
- package/dist/app/components/command-menu/shortcut-sheet.js.map +1 -0
- package/dist/app/components/composer-capabilities-menu-body.js +3 -3
- package/dist/app/components/composer-mobile-plus-panel.js +21 -21
- package/dist/app/components/composer-mobile-plus.js +3 -3
- package/dist/app/components/credit-required-gate.js +1 -1
- package/dist/app/components/credit-required-prompt.js +16 -16
- package/dist/app/components/credits/coupon-redeem.js +2 -2
- package/dist/app/components/credits/credit-refusal-notice.d.ts +18 -0
- package/dist/app/components/credits/credit-refusal-notice.js +17 -0
- package/dist/app/components/cross-slot-deep-link-recovery.js +1 -1
- package/dist/app/components/desktop/app-shots.js +6 -6
- package/dist/app/components/desktop/this-computer.js +4 -4
- package/dist/app/components/feedback.js +5 -5
- package/dist/app/components/follow-up-repository-menu-body.js +7 -7
- package/dist/app/components/follow-up-repository-picker.js +3 -3
- package/dist/app/components/github-app-connect-launcher.js +1 -1
- package/dist/app/components/knowledge/agent-learning-settings.js +6 -6
- package/dist/app/components/machines/connect-machine-dialog.js +18 -18
- package/dist/app/components/manual-repository-editor.js +2 -2
- package/dist/app/components/markdown.js +10 -9
- package/dist/app/components/message-context-pills.js +2 -2
- package/dist/app/components/models/models-ui.js +10 -10
- package/dist/app/components/pickers.js +10 -10
- package/dist/app/components/rail/rail-context.d.ts +6 -0
- package/dist/app/components/rail/rail-context.js +3 -3
- package/dist/app/components/rail/rail-sections.js +61 -55
- package/dist/app/components/rail/session-browse-order-controls.js +2 -2
- package/dist/app/components/rail/session-header.js +50 -36
- package/dist/app/components/rail/session-list.js +59 -52
- package/dist/app/components/rail/session-row-hover-details.js +25 -23
- package/dist/app/components/rail/session-shell.js +96 -91
- package/dist/app/components/repository-picker.js +7 -7
- package/dist/app/components/secrets/session-secrets-panel.js +4 -4
- package/dist/app/components/session/agent-configuration-panel.js +34 -34
- package/dist/app/components/session/banners.js +12 -11
- package/dist/app/components/session/codex-account-indicator.js +12 -12
- package/dist/app/components/session/composer-menu-radio.js +2 -2
- package/dist/app/components/session/conversation-find.js +1 -1
- package/dist/app/components/session/editable-artifacts-workspace.js +45 -45
- package/dist/app/components/session/failed-session-banner.js +12 -12
- package/dist/app/components/session/human-input.js +48 -47
- package/dist/app/components/session/inspector.js +80 -79
- package/dist/app/components/session/inspector.js.map +1 -1
- package/dist/app/components/session/message-actions.js +5 -5
- package/dist/app/components/session/message-resource-attachments.js +21 -20
- package/dist/app/components/session/message-resource-attachments.js.map +1 -1
- package/dist/app/components/session/model-account-indicator.js +11 -11
- package/dist/app/components/session/model-context-inspector.js +2 -2
- package/dist/app/components/session/model-recovery-notice.js +3 -3
- package/dist/app/components/session/new-session-settings-menu.js +13 -13
- package/dist/app/components/session/sandbox-switcher.js +16 -16
- package/dist/app/components/session/sandbox-workspace.js +68 -67
- package/dist/app/components/session/search-markdown-highlight.js +11 -10
- package/dist/app/components/session/search-results-view.js +12 -11
- package/dist/app/components/session/session-admin-access.js +11 -11
- package/dist/app/components/session/session-retention.js +4 -4
- package/dist/app/components/session/session-search-dialog.d.ts +5 -0
- package/dist/app/components/session/session-search-dialog.js +22 -12
- package/dist/app/components/session/session-search-dialog.js.map +1 -1
- package/dist/app/components/session/session-skill-reviews.js +3 -3
- package/dist/app/components/session/session-tenancy-control.js +25 -25
- package/dist/app/components/session/session-usage-limit-section.js +9 -9
- package/dist/app/components/session/session-wait-status.js +11 -9
- package/dist/app/components/session/session-wait-status.js.map +1 -1
- package/dist/app/components/session/subagents.js +17 -15
- package/dist/app/components/session/subscription-account-menu.js +2 -2
- package/dist/app/components/session-connectors-menu-body.js +6 -6
- package/dist/app/components/settings/row-select.js +1 -1
- package/dist/app/components/transcription-settings.js +2 -2
- package/dist/app/components/ui/destructive-confirm.js +8 -8
- package/dist/app/components/usage/usage-entry.js +6 -6
- package/dist/app/components/workspace-composer-plus.js +22 -21
- package/dist/app/embed/session-app.js +264 -258
- package/dist/app/lib/actions/actions-provider.d.ts +30 -0
- package/dist/app/lib/actions/actions-provider.js +32 -0
- package/dist/app/lib/actions/chat-directory.d.ts +30 -0
- package/dist/app/lib/actions/chat-operations.d.ts +11 -0
- package/dist/app/lib/actions/chat-switcher.d.ts +31 -0
- package/dist/app/lib/actions/chords.d.ts +40 -0
- package/dist/app/lib/actions/events.d.ts +6 -0
- package/dist/app/lib/actions/rank.d.ts +17 -0
- package/dist/app/lib/actions/registry.d.ts +71 -0
- package/dist/app/lib/codex-usage-query.js +3 -3
- package/dist/app/lib/composer-connectors.js +14 -13
- package/dist/app/lib/console-text.js +2 -2
- package/dist/app/lib/credit-coverage.d.ts +21 -0
- package/dist/app/lib/credit-coverage.js +15 -0
- package/dist/app/lib/deployment-free-model.js +2 -2
- package/dist/app/lib/events.js +19 -18
- package/dist/app/lib/failed-session-copy.js +5 -5
- package/dist/app/lib/free-credit-gap.d.ts +9 -0
- package/dist/app/lib/free-credit-gap.js +4 -2
- package/dist/app/lib/integration-connect-analytics.d.ts +1 -1
- package/dist/app/lib/integration-connect-analytics.js +1 -1
- package/dist/app/lib/integration-connect-redirect.js +1 -1
- package/dist/app/lib/model-access-onboarding.js +4 -4
- package/dist/app/lib/model-policy.js +1 -1
- package/dist/app/lib/models-route.d.ts +6 -2
- package/dist/app/lib/models-route.js +6 -3
- package/dist/app/lib/models-route.js.map +1 -1
- package/dist/app/lib/move-chat-to-machine.js +3 -3
- package/dist/app/lib/session-branch-cache.js +15 -13
- package/dist/app/lib/session-create.js +2 -2
- package/dist/app/lib/session-group-pagination.js +15 -13
- package/dist/app/lib/session-hover-facts.js +16 -14
- package/dist/app/lib/session-model.js +3 -3
- package/dist/app/lib/session-rail.js +11 -9
- package/dist/app/lib/session-rename.js +3 -3
- package/dist/app/lib/session-search-route.d.ts +1 -1
- package/dist/app/lib/session-search-route.js +1 -1
- package/dist/app/lib/session-ui-features.d.ts +11 -3
- package/dist/app/lib/session-ui-features.js +1 -1
- package/dist/app/lib/sessions-group.js +15 -13
- package/dist/app/lib/turn-failure-analytics.js +7 -7
- package/dist/app/lib/unavailable-session-model.js +2 -2
- package/dist/app/lib/use-duplicate-site.js +2 -2
- package/dist/app/lib/use-follow-up-repositories.js +3 -3
- package/dist/app/lib/use-workspace-machines.js +8 -8
- package/dist/app/lib/use-workspace-model-catalog.js +6 -6
- package/dist/app/lib/use-workspace-rigs.js +4 -4
- package/dist/app/lib/workspace-navigation-preference.js +5 -5
- package/dist/app/lib/workspace-scope-context.js +4 -4
- package/dist/app/routes/artifacts.js +124 -122
- package/dist/app/routes/artifacts.js.map +1 -1
- package/dist/app/routes/retained-artifact.js +69 -68
- package/dist/app/routes/retained-artifact.js.map +1 -1
- package/dist/app/routes/session-unavailable.js +3 -3
- package/dist/app/routes/session.js +168 -166
- package/dist/app/routes/sessions-index-hydration.js +3 -3
- package/dist/app/routes/sessions-index.js +122 -116
- package/dist/artifacts-document.js +4 -4
- package/dist/artifacts-presentation.js +4 -4
- package/dist/artifacts-spreadsheet.js +4 -4
- package/dist/artifacts.js +39 -39
- package/dist/{browser-viewer-ZRFZX3VN.js → browser-viewer-HPUMK7UP.js} +7 -7
- package/dist/{chat-interactive-block-HUMYWVCK.js → chat-interactive-block-22PPECCT.js} +6 -6
- package/dist/{chunk-GVIQ7H62.js → chunk-2LUBBDZV.js} +5 -5
- package/dist/{chunk-SWWYYGQO.js → chunk-325C2TCI.js} +5 -2
- package/dist/chunk-325C2TCI.js.map +1 -0
- package/dist/{chunk-XMMVIY7B.js → chunk-3CCJWHQY.js} +2 -2
- package/dist/{chunk-XS2FZ6DX.js → chunk-3F5ZPIWI.js} +2 -2
- package/dist/{chunk-72US6QNB.js → chunk-3J2YZRY5.js} +2 -2
- package/dist/{chunk-D4YQF4E3.js → chunk-3SMJ2BIQ.js} +2 -2
- package/dist/{chunk-TBJINQXA.js → chunk-3WCYK36X.js} +17 -17
- package/dist/{chunk-WPCF34V6.js → chunk-3WG3CRL7.js} +14 -14
- package/dist/{chunk-JI5BYQKO.js → chunk-3X46PNBX.js} +14 -14
- package/dist/{chunk-UO36FC3S.js → chunk-46I7MMAL.js} +6 -2
- package/dist/chunk-46I7MMAL.js.map +1 -0
- package/dist/{chunk-PBK44WJC.js → chunk-4GJ37O6G.js} +2 -2
- package/dist/chunk-4IWBQUQU.js +152 -0
- package/dist/chunk-4IWBQUQU.js.map +1 -0
- package/dist/{chunk-LEXPBQ56.js → chunk-4SKJX3C4.js} +6 -6
- package/dist/{chunk-ZA6YD2LW.js → chunk-57SYK776.js} +2 -2
- package/dist/{chunk-22LBKJDE.js → chunk-5DIAN5GQ.js} +12 -12
- package/dist/{chunk-LJ3TDK2L.js → chunk-5FA455GR.js} +4 -4
- package/dist/{chunk-N2BEUKXT.js → chunk-5FBZDEHE.js} +228 -228
- package/dist/chunk-5FBZDEHE.js.map +1 -0
- package/dist/{chunk-YPR5INHV.js → chunk-5X3E2Z3D.js} +4 -4
- package/dist/{chunk-OXNWZTEU.js → chunk-5ZJCL6X4.js} +5 -5
- package/dist/{chunk-62OAZ4LO.js → chunk-6C5GQQMC.js} +12 -12
- package/dist/{chunk-VGITH57T.js → chunk-6ERTXDZM.js} +4 -4
- package/dist/{chunk-ZQ7XQZCF.js → chunk-6FX73Y4I.js} +8 -8
- package/dist/{chunk-QZO2KK2F.js → chunk-6P44NG6Y.js} +2 -2
- package/dist/{chunk-N2DDJLTM.js → chunk-6T7Y33JA.js} +3 -3
- package/dist/{chunk-RBAGC2MJ.js → chunk-75VE5QUS.js} +22 -22
- package/dist/{chunk-MRXOGI3O.js → chunk-77CUDSHG.js} +9 -9
- package/dist/{chunk-F2GXK2Z6.js → chunk-7G446JFO.js} +431 -348
- package/dist/chunk-7G446JFO.js.map +1 -0
- package/dist/{chunk-GZ65XQR5.js → chunk-7T7FHSGS.js} +3 -3
- package/dist/{chunk-YGAH34CD.js → chunk-A3S26JSP.js} +8 -8
- package/dist/{chunk-GYPAO6RS.js → chunk-A664GSDM.js} +8 -8
- package/dist/{chunk-JSZSNMDR.js → chunk-ASUYLXKO.js} +2 -2
- package/dist/{chunk-RTK7SUPL.js → chunk-AUUJLVA3.js} +7 -7
- package/dist/{chunk-OOTBYSCA.js → chunk-BBWKPNJB.js} +5 -5
- package/dist/{chunk-BGZIMIUU.js → chunk-BCUYWOQU.js} +2 -2
- package/dist/{chunk-EKN4N4LS.js → chunk-BDFMNJZJ.js} +2 -2
- package/dist/{chunk-YZKGOWCC.js → chunk-BIDXQAGO.js} +2 -2
- package/dist/{chunk-Q2UUANHF.js → chunk-BIKAJ4DY.js} +5 -5
- package/dist/{chunk-5IQBF2X3.js → chunk-BJPJ2OUX.js} +3 -3
- package/dist/{chunk-EY2EMHZW.js → chunk-BPM2OTYK.js} +8 -8
- package/dist/{chunk-MT4TBRQB.js → chunk-BSWS2RUZ.js} +2 -2
- package/dist/{chunk-T7YD3VGK.js → chunk-C52MNKXU.js} +12 -12
- package/dist/{chunk-THNW33K7.js → chunk-CEUDV4OA.js} +18 -18
- package/dist/{chunk-GRLPRM56.js → chunk-CFEFYPNR.js} +8 -2
- package/dist/chunk-CFEFYPNR.js.map +1 -0
- package/dist/{chunk-LHGIS6SZ.js → chunk-CVK74BH7.js} +2 -2
- package/dist/{chunk-DFO2UCYG.js → chunk-CW5I65ZX.js} +11 -11
- package/dist/chunk-DKNTQDVL.js +86 -0
- package/dist/chunk-DKNTQDVL.js.map +1 -0
- package/dist/{chunk-SKRLKQEG.js → chunk-DOSC2HRQ.js} +79 -79
- package/dist/{chunk-KVB6XDLP.js → chunk-DPJ2CWVN.js} +2 -2
- package/dist/{chunk-4J6V4DH7.js → chunk-DXMRO2MU.js} +3 -3
- package/dist/{chunk-42I4O4WQ.js → chunk-EE55IDDR.js} +26 -26
- package/dist/{chunk-2RA6XABP.js → chunk-EEERTLFF.js} +12 -12
- package/dist/{chunk-PTOTKUKO.js → chunk-EEO744XR.js} +8 -8
- package/dist/{chunk-LD3HVI2J.js → chunk-EMFGBAQL.js} +6 -6
- package/dist/{chunk-FQGUK4ST.js → chunk-ENPJKVMN.js} +38 -38
- package/dist/{chunk-HDHK3SXK.js → chunk-EU6RLHMP.js} +4 -4
- package/dist/{chunk-G7VLL3PG.js → chunk-F2YABPRJ.js} +13 -4
- package/dist/chunk-F2YABPRJ.js.map +1 -0
- package/dist/{chunk-MRUWRQBX.js → chunk-FET6XHGS.js} +2 -2
- package/dist/{chunk-M6KUY3YH.js → chunk-FIICQA55.js} +2 -2
- package/dist/{chunk-NLWLCYCT.js → chunk-FTZXCPE3.js} +19 -19
- package/dist/{chunk-FN2KA3MJ.js → chunk-FUS76DO4.js} +3 -3
- package/dist/{chunk-AM4IIPWI.js → chunk-G7N5NPRJ.js} +2 -2
- package/dist/{chunk-CCQ7YKOD.js → chunk-GBYZ6653.js} +2 -2
- package/dist/{chunk-SOOWLNC5.js → chunk-GJUPLSC5.js} +330 -109
- package/dist/chunk-GJUPLSC5.js.map +1 -0
- package/dist/{chunk-YKKVIJVX.js → chunk-GQDSC6QZ.js} +5 -5
- package/dist/chunk-GQGNRL2L.js +53 -0
- package/dist/chunk-GQGNRL2L.js.map +1 -0
- package/dist/{chunk-5X6JP75Q.js → chunk-GRSODLVO.js} +4 -4
- package/dist/{chunk-73YP3R5X.js → chunk-GSESCQFY.js} +4 -4
- package/dist/{chunk-KWB5U3ZT.js → chunk-GWRW4N3T.js} +199 -137
- package/dist/chunk-GWRW4N3T.js.map +1 -0
- package/dist/{chunk-RTR7RNG4.js → chunk-GYRU4PNM.js} +9 -7
- package/dist/{chunk-RTR7RNG4.js.map → chunk-GYRU4PNM.js.map} +1 -1
- package/dist/{chunk-MZLEBFUZ.js → chunk-GZD6VBIK.js} +3 -3
- package/dist/{chunk-IZR2QRFF.js → chunk-H3HH5AHS.js} +4 -4
- package/dist/{chunk-DN3TKURW.js → chunk-H3LIIAGE.js} +4 -54
- package/dist/chunk-H3LIIAGE.js.map +1 -0
- package/dist/{chunk-NPLEQMNM.js → chunk-H5GWAG4I.js} +7 -5
- package/dist/{chunk-NPLEQMNM.js.map → chunk-H5GWAG4I.js.map} +1 -1
- package/dist/{chunk-OJPUVUB6.js → chunk-HAOZCLLA.js} +3 -3
- package/dist/{chunk-ZBHDGAYL.js → chunk-HEFE4OZJ.js} +2 -2
- package/dist/{chunk-WTG34JVA.js → chunk-HI75UTI6.js} +2 -2
- package/dist/{chunk-OMBIG3NC.js → chunk-HM633ROV.js} +14 -14
- package/dist/{chunk-WDFZWSKD.js → chunk-HRIP4M6H.js} +3 -3
- package/dist/{chunk-A2BCW6CQ.js → chunk-HU2DRFFI.js} +3 -3
- package/dist/{chunk-PO35PBAB.js → chunk-HVH7FFJH.js} +2 -2
- package/dist/{chunk-EG7KNUF7.js → chunk-HYTXTKST.js} +18 -18
- package/dist/{chunk-TFHG75A4.js → chunk-I4XMDFUJ.js} +7 -7
- package/dist/{chunk-IZHVZZQA.js → chunk-ICAUYWSL.js} +9 -9
- package/dist/{chunk-ZSERYHHT.js → chunk-IDMXEPHL.js} +150 -150
- package/dist/chunk-IDMXEPHL.js.map +1 -0
- package/dist/{chunk-DCLPWYP3.js → chunk-IEVPJ3G6.js} +2 -2
- package/dist/{chunk-EVWZHDSF.js → chunk-IKH3VTA4.js} +2 -2
- package/dist/{chunk-L5UCO2UV.js → chunk-ILBSBZGC.js} +13 -4
- package/dist/chunk-ILBSBZGC.js.map +1 -0
- package/dist/{chunk-IO6K6UYJ.js → chunk-IQ64BNAG.js} +4 -2
- package/dist/chunk-IQ64BNAG.js.map +1 -0
- package/dist/{chunk-TYHLEFD2.js → chunk-IZJNMRIR.js} +9 -9
- package/dist/{chunk-D2SR3TEB.js → chunk-J243WGUA.js} +2 -2
- package/dist/{chunk-QGSGIYE3.js → chunk-J2C6LB6W.js} +4 -4
- package/dist/{chunk-MT6TRTXF.js → chunk-J5MEDX7C.js} +9 -9
- package/dist/{chunk-6QHUKBJP.js → chunk-J7SKOO44.js} +2 -2
- package/dist/{chunk-W2QK7PYS.js → chunk-JAAST75A.js} +11 -11
- package/dist/{chunk-NQCMS4AJ.js → chunk-JQCGPTZ6.js} +9 -9
- package/dist/chunk-JRJUSKDY.js +832 -0
- package/dist/chunk-JRJUSKDY.js.map +1 -0
- package/dist/{chunk-CMUXJHGH.js → chunk-JRSCWQMC.js} +9 -9
- package/dist/{chunk-Q4OHNGGB.js → chunk-JRXHSVD5.js} +4 -4
- package/dist/{chunk-SD2K5ZN5.js → chunk-JXYLDT6X.js} +4 -4
- package/dist/{chunk-S3M5WCZW.js → chunk-KA4LV7G6.js} +35 -50
- package/dist/chunk-KA4LV7G6.js.map +1 -0
- package/dist/{chunk-IXX6ZOL2.js → chunk-KGTMHEAP.js} +7 -7
- package/dist/{chunk-22OBGVEJ.js → chunk-KOXVGPW4.js} +3 -3
- package/dist/{chunk-NOZ5CGZE.js → chunk-L5GPPMUB.js} +2 -2
- package/dist/{chunk-KIHYJM5F.js → chunk-LXJT4WAW.js} +58 -58
- package/dist/{chunk-KIHYJM5F.js.map → chunk-LXJT4WAW.js.map} +1 -1
- package/dist/{chunk-4FOOHMTU.js → chunk-LY6727IF.js} +1 -1
- package/dist/{chunk-PT7MTXRE.js → chunk-MAOCN7J6.js} +2 -2
- package/dist/{chunk-4K2JSJNX.js → chunk-MB5LZVDO.js} +2 -2
- package/dist/chunk-MF464AKA.js +139 -0
- package/dist/chunk-MF464AKA.js.map +1 -0
- package/dist/{chunk-UYSZKDQY.js → chunk-MK54JLE4.js} +1 -1
- package/dist/chunk-MK54JLE4.js.map +1 -0
- package/dist/{chunk-5LES64PP.js → chunk-MKOQAVOE.js} +21 -21
- package/dist/{chunk-BMV2SNYX.js → chunk-MUPWNSEJ.js} +18 -18
- package/dist/{chunk-Y5TRG22C.js → chunk-NRXIECWC.js} +2 -2
- package/dist/{chunk-GOE7G5JX.js → chunk-NWSAF6P5.js} +2 -2
- package/dist/chunk-OB3YGXHQ.js +158 -0
- package/dist/chunk-OB3YGXHQ.js.map +1 -0
- package/dist/{chunk-DUM363VS.js → chunk-OFZQJNF6.js} +5 -5
- package/dist/{chunk-CKN5QPEL.js → chunk-OMF7POEY.js} +2 -2
- package/dist/{chunk-MVXKO2BD.js → chunk-OXD6ET34.js} +1 -1
- package/dist/{chunk-47JUEVME.js → chunk-PALX6HWV.js} +21 -21
- package/dist/{chunk-B6OGSG7I.js → chunk-PE3BLBDT.js} +3 -3
- package/dist/{chunk-RVISSNVE.js → chunk-PMZKJOG6.js} +15 -15
- package/dist/{chunk-CESAMXWX.js → chunk-PQUTMG3S.js} +2 -2
- package/dist/{chunk-7VFCOKPG.js → chunk-PWBGODZU.js} +3 -3
- package/dist/{chunk-MOPAXD2H.js → chunk-QCADUTYX.js} +2 -2
- package/dist/{chunk-CT5FBO7E.js → chunk-RPOUJI25.js} +1 -1
- package/dist/{chunk-VE3FKXJ7.js → chunk-RUSXEE7X.js} +35 -32
- package/dist/chunk-RUSXEE7X.js.map +1 -0
- package/dist/{chunk-WKHYOS72.js → chunk-RW4GFE56.js} +3 -3
- package/dist/{chunk-FH4GO7HO.js → chunk-RYLVVDR7.js} +1 -1
- package/dist/{chunk-QZRDCFHI.js → chunk-S66SBBFQ.js} +5 -5
- package/dist/{chunk-CQJFIPAH.js → chunk-S7TNV2I7.js} +14 -14
- package/dist/{chunk-ZBQSIGGR.js → chunk-SC773IMJ.js} +13 -13
- package/dist/{chunk-RZV7SXED.js → chunk-SF3M27AN.js} +37 -12
- package/dist/chunk-SF3M27AN.js.map +1 -0
- package/dist/{chunk-FBJ2HK7A.js → chunk-SGPJ3YS2.js} +20 -20
- package/dist/{chunk-A2EWJQXX.js → chunk-SM5QX6UK.js} +4 -4
- package/dist/chunk-SWCLN6JE.js +40 -0
- package/dist/chunk-SWCLN6JE.js.map +1 -0
- package/dist/{chunk-OS3EQOIS.js → chunk-T4F5TW2X.js} +29 -24
- package/dist/chunk-T4F5TW2X.js.map +1 -0
- package/dist/{chunk-RKZWCTXV.js → chunk-TAEKDMEF.js} +2 -2
- package/dist/{chunk-6AVCAUGL.js → chunk-TASEV25T.js} +3 -3
- package/dist/{chunk-3XOISKZC.js → chunk-TLGDPMUX.js} +6 -6
- package/dist/{chunk-MOF3XSUM.js → chunk-TREHTIBD.js} +3 -2
- package/dist/chunk-TREHTIBD.js.map +1 -0
- package/dist/{chunk-HUQHJSPV.js → chunk-TTPXGD5S.js} +68 -33
- package/dist/chunk-TTPXGD5S.js.map +1 -0
- package/dist/{chunk-NFCYIZHX.js → chunk-TXIIBNCA.js} +7 -3
- package/dist/{chunk-NFCYIZHX.js.map → chunk-TXIIBNCA.js.map} +1 -1
- package/dist/{chunk-5IUW34PG.js → chunk-TY3QYPJ6.js} +7 -7
- package/dist/{chunk-VQFR4EU4.js → chunk-U3JK5VJV.js} +2 -2
- package/dist/{chunk-2AWMJO54.js → chunk-U42P3RMZ.js} +5 -5
- package/dist/{chunk-2RIUMV7S.js → chunk-UBIJBLUK.js} +234 -234
- package/dist/chunk-UBIJBLUK.js.map +1 -0
- package/dist/{chunk-GUU75DES.js → chunk-UEJTOPLW.js} +8 -8
- package/dist/{chunk-QWCTYLMD.js → chunk-URDONAEJ.js} +240 -204
- package/dist/chunk-URDONAEJ.js.map +1 -0
- package/dist/{chunk-OZOEWLGR.js → chunk-UT6JAORE.js} +4 -4
- package/dist/{chunk-5TELOQA6.js → chunk-UTHPUINA.js} +3 -3
- package/dist/{chunk-SOV7DTTU.js → chunk-V6HZ2HJZ.js} +67 -67
- package/dist/{chunk-SOV7DTTU.js.map → chunk-V6HZ2HJZ.js.map} +1 -1
- package/dist/{chunk-26RQ6JBR.js → chunk-VBVCNH6D.js} +5 -5
- package/dist/{chunk-P646DND6.js → chunk-VCMQPCME.js} +2 -2
- package/dist/{chunk-LV7FMIMM.js → chunk-VGUHAHHV.js} +2 -2
- package/dist/{chunk-GYVXARCY.js → chunk-VIBPFVU4.js} +41 -41
- package/dist/{chunk-KHPOKZ6Z.js → chunk-VMAC66JX.js} +6 -6
- package/dist/{chunk-SHKRS6I5.js → chunk-VRPNETPK.js} +3 -3
- package/dist/{chunk-6U4J6RVS.js → chunk-WCHW4XN7.js} +14 -14
- package/dist/{chunk-CJH6QUQJ.js → chunk-WD3UXNJV.js} +3 -3
- package/dist/{chunk-H5EVWF6L.js → chunk-WR67FJMX.js} +4 -4
- package/dist/{chunk-XLIJ36RG.js → chunk-WRMQ7EX4.js} +5 -5
- package/dist/{chunk-VVFWOBAM.js → chunk-WTJUKYB2.js} +15 -16
- package/dist/chunk-WTJUKYB2.js.map +1 -0
- package/dist/{chunk-7KLCFJ5G.js → chunk-X4PPGXQG.js} +2 -2
- package/dist/{chunk-ZE2JTVCQ.js → chunk-X5BMQXFD.js} +11 -11
- package/dist/{chunk-OYJY4Y4A.js → chunk-XFNLU7EW.js} +14 -7
- package/dist/chunk-XFNLU7EW.js.map +1 -0
- package/dist/{chunk-UECU6LZI.js → chunk-XXRBOSWV.js} +3 -3
- package/dist/{chunk-SPKAIDWX.js → chunk-XZEFCPBL.js} +2 -2
- package/dist/{chunk-EZ5NYRHK.js → chunk-YL6N7QLA.js} +5 -5
- package/dist/{chunk-Q2ZJOECN.js → chunk-YMVTIV5L.js} +19 -19
- package/dist/chunk-YMVTIV5L.js.map +1 -0
- package/dist/{chunk-VAIESMPY.js → chunk-YVBHGMKC.js} +4 -4
- package/dist/{chunk-AR62NQXE.js → chunk-Z2S5VQG7.js} +2 -2
- package/dist/{chunk-2MXUB3ZO.js → chunk-Z5OGTWMZ.js} +15 -2
- package/dist/chunk-Z5OGTWMZ.js.map +1 -0
- package/dist/{chunk-7UQJEADK.js → chunk-ZL2O4BYP.js} +2 -2
- package/dist/{chunk-FOOITLHR.js → chunk-ZZHBT5WQ.js} +2 -2
- package/dist/{chunk-X6VJQJYY.js → chunk-ZZWHKC6A.js} +3 -3
- package/dist/components/timeline-annotation-shared.d.ts +1 -9
- package/dist/composer-messages.js +2 -2
- package/dist/composer.js +15 -15
- package/dist/{computer-viewer-D4NHQB5D.js → computer-viewer-S6TE6TN7.js} +8 -8
- package/dist/connect.js +12 -11
- package/dist/desktop.js +2 -2
- package/dist/editor.js +2 -2
- package/dist/{embedded-new-voice-X4ZW6SY4.js → embedded-new-voice-ZDZPGX25.js} +8 -8
- package/dist/{embedded-voice-4OD6Z3HU.js → embedded-voice-FKCUXSJO.js} +8 -8
- package/dist/{fleet-decision-row-5UCJXTDP.js → fleet-decision-row-VCGWYJAV.js} +2 -2
- package/dist/hooks/page-wake.d.ts +21 -0
- package/dist/hooks/use-session-events.d.ts +1 -0
- package/dist/index.js +206 -205
- package/dist/interaction.js +9 -9
- package/dist/{latest-question-VGVNUGAU.js → latest-question-SINEV4U6.js} +3 -3
- package/dist/lib/format.d.ts +3 -2
- package/dist/machines.js +6 -6
- package/dist/messages/en.d.ts +12 -3
- package/dist/messages.js +1 -1
- package/dist/model-picker-model.js +2 -2
- package/dist/{model-policy-picker-menu-XOPYY6YA.js → model-policy-picker-menu-66JPM3G5.js} +6 -6
- package/dist/model-policy-picker-menu-66JPM3G5.js.map +1 -0
- package/dist/model-policy.js +1 -1
- package/dist/native-previews.js +3 -3
- package/dist/{platform-activity-row-56XOVTRA.js → platform-activity-row-LU5WABI2.js} +2 -2
- package/dist/{queue-surface-implementation-OZDOBJ6W.js → queue-surface-implementation-Y4OUVS7N.js} +8 -7
- package/dist/{queue-surface-implementation-OZDOBJ6W.js.map → queue-surface-implementation-Y4OUVS7N.js.map} +1 -1
- package/dist/realtime.js +7 -7
- package/dist/{sandbox-files-LJCR437H.js → sandbox-files-NBIVKVCZ.js} +11 -11
- package/dist/sandbox-files-NBIVKVCZ.js.map +1 -0
- package/dist/session-app.js +266 -260
- package/dist/session-list-model.js +3 -3
- package/dist/{session-realtime-UISLBZ4A.js → session-realtime-3PALSNMJ.js} +3 -3
- package/dist/session-realtime-3PALSNMJ.js.map +1 -0
- package/dist/session-realtime.js +2 -2
- package/dist/session-ui.js +62 -61
- package/dist/session.d.ts +1 -1
- package/dist/session.js +17 -17
- package/dist/sites.js +2 -2
- package/dist/terminal.js +2 -2
- package/dist/this-computer.js +3 -3
- package/dist/timeline/annotation-model.d.ts +48 -0
- package/dist/{timeline-annotation-markers-ACT7XRMW.js → timeline-annotation-markers-6526H2NM.js} +11 -9
- package/dist/{timeline-annotation-markers-ACT7XRMW.js.map → timeline-annotation-markers-6526H2NM.js.map} +1 -1
- package/dist/{timeline-annotation-selection-2IA7T5VR.js → timeline-annotation-selection-KV5SM6TA.js} +16 -62
- package/dist/timeline-annotation-selection-KV5SM6TA.js.map +1 -0
- package/dist/{timeline-annotations-dialog-W5B2HMYY.js → timeline-annotations-dialog-7CDHWC7Y.js} +12 -10
- package/dist/{timeline-annotations-dialog-W5B2HMYY.js.map → timeline-annotations-dialog-7CDHWC7Y.js.map} +1 -1
- package/dist/timeline-model.d.ts +3 -0
- package/dist/timeline-model.js +40 -14
- package/dist/ui/access-list.js +24 -24
- package/dist/ui/choice-cards.js +2 -2
- package/dist/ui/composer-menu-action.js +2 -2
- package/dist/ui/context-menu.d.ts +3 -1
- package/dist/ui/context-menu.js +3 -1
- package/dist/ui/detail-page.js +3 -3
- package/dist/ui/detail-sheet.js +3 -3
- package/dist/ui/diff-view.js +3 -3
- package/dist/ui/disclosure.js +5 -5
- package/dist/ui/dropdown-menu.js +1 -1
- package/dist/ui/flush-form-page.js +5 -5
- package/dist/ui/form-dialog.js +4 -4
- package/dist/ui/list-row.js +5 -5
- package/dist/ui/load-failure.js +3 -3
- package/dist/ui/page-actions.js +3 -3
- package/dist/ui/revision-history.js +11 -11
- package/dist/ui/role-select.js +8 -8
- package/dist/ui/segmented-control.js +1 -1
- package/dist/ui/settings-nav.js +3 -3
- package/dist/ui/toolbar.js +3 -3
- package/dist/usage.js +2 -2
- package/dist/workbench.js +11 -11
- package/package.json +4 -4
- package/src/app/app-state.tsx +2 -1
- package/src/app/components/command-menu/chat-switcher.tsx +135 -0
- package/src/app/components/command-menu/command-menu.tsx +840 -0
- package/src/app/components/command-menu/keycaps.tsx +56 -0
- package/src/app/components/command-menu/shortcut-sheet.tsx +155 -0
- package/src/app/components/credits/credit-refusal-notice.test.tsx +132 -0
- package/src/app/components/credits/credit-refusal-notice.tsx +92 -0
- package/src/app/components/rail/rail-context.tsx +28 -5
- package/src/app/components/rail/rail-sections.tsx +3 -5
- package/src/app/components/rail/session-header-mute.test.tsx +23 -1
- package/src/app/components/rail/session-header.test.tsx +21 -2
- package/src/app/components/rail/session-header.tsx +31 -1
- package/src/app/components/rail/session-list.tsx +89 -16
- package/src/app/components/rail/session-shell.tsx +0 -14
- package/src/app/components/session/session-search-dialog.tsx +12 -1
- package/src/app/embed/session-app.tsx +6 -3
- package/src/app/lib/actions/actions-provider.tsx +486 -0
- package/src/app/lib/actions/actions.test.ts +249 -0
- package/src/app/lib/actions/chat-directory.ts +231 -0
- package/src/app/lib/actions/chat-operations.ts +145 -0
- package/src/app/lib/actions/chat-switcher.ts +62 -0
- package/src/app/lib/actions/chords.ts +185 -0
- package/src/app/lib/actions/events.ts +10 -0
- package/src/app/lib/actions/rank.ts +119 -0
- package/src/app/lib/actions/registry.ts +333 -0
- package/src/app/lib/credit-coverage.test.ts +83 -0
- package/src/app/lib/credit-coverage.tsx +48 -0
- package/src/app/lib/free-credit-gap.test.ts +32 -1
- package/src/app/lib/free-credit-gap.tsx +32 -2
- package/src/app/lib/integration-connect-analytics.test.ts +1 -0
- package/src/app/lib/integration-connect-analytics.tsx +4 -0
- package/src/app/lib/models-route.test.ts +18 -0
- package/src/app/lib/models-route.tsx +26 -4
- package/src/app/lib/session-search-route.tsx +6 -1
- package/src/app/lib/session-ui-features.tsx +28 -9
- package/src/app/routes/session.tsx +74 -16
- package/src/app/routes/sessions-index.tsx +83 -4
- package/src/components/timeline-annotation-selection.tsx +9 -64
- package/src/components/timeline-annotation-shared.ts +9 -57
- package/src/hooks/page-wake.ts +80 -0
- package/src/hooks/use-session-events.ts +309 -81
- package/src/lib/format.ts +3 -2
- package/src/messages/en.ts +13 -3
- package/src/model-picker-model.ts +3 -0
- package/src/model-policy.ts +9 -1
- package/src/session.ts +1 -0
- package/src/timeline/annotation-model.ts +217 -0
- package/src/timeline/projection.ts +27 -21
- package/src/timeline-model.ts +14 -0
- package/src/ui/context-menu.tsx +16 -0
- package/src/ui/dropdown-menu.tsx +4 -1
- package/src/ui/segmented-control.tsx +3 -0
- package/styles/compiled.css +92 -0
- package/dist/app/lib/keyboard-shortcuts.d.ts +0 -51
- package/dist/app/lib/keyboard-shortcuts.js +0 -16
- package/dist/chunk-2MXUB3ZO.js.map +0 -1
- package/dist/chunk-2RIUMV7S.js.map +0 -1
- package/dist/chunk-53IXIUYP.js +0 -39
- package/dist/chunk-53IXIUYP.js.map +0 -1
- package/dist/chunk-DN3TKURW.js.map +0 -1
- package/dist/chunk-F2GXK2Z6.js.map +0 -1
- package/dist/chunk-G7VLL3PG.js.map +0 -1
- package/dist/chunk-GRLPRM56.js.map +0 -1
- package/dist/chunk-HUQHJSPV.js.map +0 -1
- package/dist/chunk-IO6K6UYJ.js.map +0 -1
- package/dist/chunk-KWB5U3ZT.js.map +0 -1
- package/dist/chunk-L5UCO2UV.js.map +0 -1
- package/dist/chunk-MOF3XSUM.js.map +0 -1
- package/dist/chunk-N2BEUKXT.js.map +0 -1
- package/dist/chunk-OS3EQOIS.js.map +0 -1
- package/dist/chunk-OYJY4Y4A.js.map +0 -1
- package/dist/chunk-Q2ZJOECN.js.map +0 -1
- package/dist/chunk-QWCTYLMD.js.map +0 -1
- package/dist/chunk-RZV7SXED.js.map +0 -1
- package/dist/chunk-S3M5WCZW.js.map +0 -1
- package/dist/chunk-SOOWLNC5.js.map +0 -1
- package/dist/chunk-SWWYYGQO.js.map +0 -1
- package/dist/chunk-UO36FC3S.js.map +0 -1
- package/dist/chunk-UYSZKDQY.js.map +0 -1
- package/dist/chunk-VE3FKXJ7.js.map +0 -1
- package/dist/chunk-VVFWOBAM.js.map +0 -1
- package/dist/chunk-ZSERYHHT.js.map +0 -1
- package/dist/timeline-annotation-selection-2IA7T5VR.js.map +0 -1
- package/src/app/lib/keyboard-shortcuts.test.ts +0 -47
- package/src/app/lib/keyboard-shortcuts.tsx +0 -58
- /package/dist/app/{lib/keyboard-shortcuts.js.map → components/command-menu/keycaps.js.map} +0 -0
- /package/dist/{browser-viewer-ZRFZX3VN.js.map → app/components/credits/credit-refusal-notice.js.map} +0 -0
- /package/dist/{chat-interactive-block-HUMYWVCK.js.map → app/lib/actions/actions-provider.js.map} +0 -0
- /package/dist/{computer-viewer-D4NHQB5D.js.map → app/lib/credit-coverage.js.map} +0 -0
- /package/dist/{embedded-new-voice-X4ZW6SY4.js.map → browser-viewer-HPUMK7UP.js.map} +0 -0
- /package/dist/{embedded-voice-4OD6Z3HU.js.map → chat-interactive-block-22PPECCT.js.map} +0 -0
- /package/dist/{chunk-GVIQ7H62.js.map → chunk-2LUBBDZV.js.map} +0 -0
- /package/dist/{chunk-XMMVIY7B.js.map → chunk-3CCJWHQY.js.map} +0 -0
- /package/dist/{chunk-XS2FZ6DX.js.map → chunk-3F5ZPIWI.js.map} +0 -0
- /package/dist/{chunk-72US6QNB.js.map → chunk-3J2YZRY5.js.map} +0 -0
- /package/dist/{chunk-D4YQF4E3.js.map → chunk-3SMJ2BIQ.js.map} +0 -0
- /package/dist/{chunk-TBJINQXA.js.map → chunk-3WCYK36X.js.map} +0 -0
- /package/dist/{chunk-WPCF34V6.js.map → chunk-3WG3CRL7.js.map} +0 -0
- /package/dist/{chunk-JI5BYQKO.js.map → chunk-3X46PNBX.js.map} +0 -0
- /package/dist/{chunk-PBK44WJC.js.map → chunk-4GJ37O6G.js.map} +0 -0
- /package/dist/{chunk-LEXPBQ56.js.map → chunk-4SKJX3C4.js.map} +0 -0
- /package/dist/{chunk-ZA6YD2LW.js.map → chunk-57SYK776.js.map} +0 -0
- /package/dist/{chunk-22LBKJDE.js.map → chunk-5DIAN5GQ.js.map} +0 -0
- /package/dist/{chunk-LJ3TDK2L.js.map → chunk-5FA455GR.js.map} +0 -0
- /package/dist/{chunk-YPR5INHV.js.map → chunk-5X3E2Z3D.js.map} +0 -0
- /package/dist/{chunk-OXNWZTEU.js.map → chunk-5ZJCL6X4.js.map} +0 -0
- /package/dist/{chunk-62OAZ4LO.js.map → chunk-6C5GQQMC.js.map} +0 -0
- /package/dist/{chunk-VGITH57T.js.map → chunk-6ERTXDZM.js.map} +0 -0
- /package/dist/{chunk-ZQ7XQZCF.js.map → chunk-6FX73Y4I.js.map} +0 -0
- /package/dist/{chunk-QZO2KK2F.js.map → chunk-6P44NG6Y.js.map} +0 -0
- /package/dist/{chunk-N2DDJLTM.js.map → chunk-6T7Y33JA.js.map} +0 -0
- /package/dist/{chunk-RBAGC2MJ.js.map → chunk-75VE5QUS.js.map} +0 -0
- /package/dist/{chunk-MRXOGI3O.js.map → chunk-77CUDSHG.js.map} +0 -0
- /package/dist/{chunk-GZ65XQR5.js.map → chunk-7T7FHSGS.js.map} +0 -0
- /package/dist/{chunk-YGAH34CD.js.map → chunk-A3S26JSP.js.map} +0 -0
- /package/dist/{chunk-GYPAO6RS.js.map → chunk-A664GSDM.js.map} +0 -0
- /package/dist/{chunk-JSZSNMDR.js.map → chunk-ASUYLXKO.js.map} +0 -0
- /package/dist/{chunk-RTK7SUPL.js.map → chunk-AUUJLVA3.js.map} +0 -0
- /package/dist/{chunk-OOTBYSCA.js.map → chunk-BBWKPNJB.js.map} +0 -0
- /package/dist/{chunk-BGZIMIUU.js.map → chunk-BCUYWOQU.js.map} +0 -0
- /package/dist/{chunk-EKN4N4LS.js.map → chunk-BDFMNJZJ.js.map} +0 -0
- /package/dist/{chunk-YZKGOWCC.js.map → chunk-BIDXQAGO.js.map} +0 -0
- /package/dist/{chunk-Q2UUANHF.js.map → chunk-BIKAJ4DY.js.map} +0 -0
- /package/dist/{chunk-5IQBF2X3.js.map → chunk-BJPJ2OUX.js.map} +0 -0
- /package/dist/{chunk-EY2EMHZW.js.map → chunk-BPM2OTYK.js.map} +0 -0
- /package/dist/{chunk-MT4TBRQB.js.map → chunk-BSWS2RUZ.js.map} +0 -0
- /package/dist/{chunk-T7YD3VGK.js.map → chunk-C52MNKXU.js.map} +0 -0
- /package/dist/{chunk-THNW33K7.js.map → chunk-CEUDV4OA.js.map} +0 -0
- /package/dist/{chunk-LHGIS6SZ.js.map → chunk-CVK74BH7.js.map} +0 -0
- /package/dist/{chunk-DFO2UCYG.js.map → chunk-CW5I65ZX.js.map} +0 -0
- /package/dist/{chunk-SKRLKQEG.js.map → chunk-DOSC2HRQ.js.map} +0 -0
- /package/dist/{chunk-KVB6XDLP.js.map → chunk-DPJ2CWVN.js.map} +0 -0
- /package/dist/{chunk-4J6V4DH7.js.map → chunk-DXMRO2MU.js.map} +0 -0
- /package/dist/{chunk-42I4O4WQ.js.map → chunk-EE55IDDR.js.map} +0 -0
- /package/dist/{chunk-2RA6XABP.js.map → chunk-EEERTLFF.js.map} +0 -0
- /package/dist/{chunk-PTOTKUKO.js.map → chunk-EEO744XR.js.map} +0 -0
- /package/dist/{chunk-LD3HVI2J.js.map → chunk-EMFGBAQL.js.map} +0 -0
- /package/dist/{chunk-FQGUK4ST.js.map → chunk-ENPJKVMN.js.map} +0 -0
- /package/dist/{chunk-HDHK3SXK.js.map → chunk-EU6RLHMP.js.map} +0 -0
- /package/dist/{chunk-MRUWRQBX.js.map → chunk-FET6XHGS.js.map} +0 -0
- /package/dist/{chunk-M6KUY3YH.js.map → chunk-FIICQA55.js.map} +0 -0
- /package/dist/{chunk-NLWLCYCT.js.map → chunk-FTZXCPE3.js.map} +0 -0
- /package/dist/{chunk-FN2KA3MJ.js.map → chunk-FUS76DO4.js.map} +0 -0
- /package/dist/{chunk-AM4IIPWI.js.map → chunk-G7N5NPRJ.js.map} +0 -0
- /package/dist/{chunk-CCQ7YKOD.js.map → chunk-GBYZ6653.js.map} +0 -0
- /package/dist/{chunk-YKKVIJVX.js.map → chunk-GQDSC6QZ.js.map} +0 -0
- /package/dist/{chunk-5X6JP75Q.js.map → chunk-GRSODLVO.js.map} +0 -0
- /package/dist/{chunk-73YP3R5X.js.map → chunk-GSESCQFY.js.map} +0 -0
- /package/dist/{chunk-MZLEBFUZ.js.map → chunk-GZD6VBIK.js.map} +0 -0
- /package/dist/{chunk-IZR2QRFF.js.map → chunk-H3HH5AHS.js.map} +0 -0
- /package/dist/{chunk-OJPUVUB6.js.map → chunk-HAOZCLLA.js.map} +0 -0
- /package/dist/{chunk-ZBHDGAYL.js.map → chunk-HEFE4OZJ.js.map} +0 -0
- /package/dist/{chunk-WTG34JVA.js.map → chunk-HI75UTI6.js.map} +0 -0
- /package/dist/{chunk-OMBIG3NC.js.map → chunk-HM633ROV.js.map} +0 -0
- /package/dist/{chunk-WDFZWSKD.js.map → chunk-HRIP4M6H.js.map} +0 -0
- /package/dist/{chunk-A2BCW6CQ.js.map → chunk-HU2DRFFI.js.map} +0 -0
- /package/dist/{chunk-PO35PBAB.js.map → chunk-HVH7FFJH.js.map} +0 -0
- /package/dist/{chunk-EG7KNUF7.js.map → chunk-HYTXTKST.js.map} +0 -0
- /package/dist/{chunk-TFHG75A4.js.map → chunk-I4XMDFUJ.js.map} +0 -0
- /package/dist/{chunk-IZHVZZQA.js.map → chunk-ICAUYWSL.js.map} +0 -0
- /package/dist/{chunk-DCLPWYP3.js.map → chunk-IEVPJ3G6.js.map} +0 -0
- /package/dist/{chunk-EVWZHDSF.js.map → chunk-IKH3VTA4.js.map} +0 -0
- /package/dist/{chunk-TYHLEFD2.js.map → chunk-IZJNMRIR.js.map} +0 -0
- /package/dist/{chunk-D2SR3TEB.js.map → chunk-J243WGUA.js.map} +0 -0
- /package/dist/{chunk-QGSGIYE3.js.map → chunk-J2C6LB6W.js.map} +0 -0
- /package/dist/{chunk-MT6TRTXF.js.map → chunk-J5MEDX7C.js.map} +0 -0
- /package/dist/{chunk-6QHUKBJP.js.map → chunk-J7SKOO44.js.map} +0 -0
- /package/dist/{chunk-W2QK7PYS.js.map → chunk-JAAST75A.js.map} +0 -0
- /package/dist/{chunk-NQCMS4AJ.js.map → chunk-JQCGPTZ6.js.map} +0 -0
- /package/dist/{chunk-CMUXJHGH.js.map → chunk-JRSCWQMC.js.map} +0 -0
- /package/dist/{chunk-Q4OHNGGB.js.map → chunk-JRXHSVD5.js.map} +0 -0
- /package/dist/{chunk-SD2K5ZN5.js.map → chunk-JXYLDT6X.js.map} +0 -0
- /package/dist/{chunk-IXX6ZOL2.js.map → chunk-KGTMHEAP.js.map} +0 -0
- /package/dist/{chunk-22OBGVEJ.js.map → chunk-KOXVGPW4.js.map} +0 -0
- /package/dist/{chunk-NOZ5CGZE.js.map → chunk-L5GPPMUB.js.map} +0 -0
- /package/dist/{chunk-4FOOHMTU.js.map → chunk-LY6727IF.js.map} +0 -0
- /package/dist/{chunk-PT7MTXRE.js.map → chunk-MAOCN7J6.js.map} +0 -0
- /package/dist/{chunk-4K2JSJNX.js.map → chunk-MB5LZVDO.js.map} +0 -0
- /package/dist/{chunk-5LES64PP.js.map → chunk-MKOQAVOE.js.map} +0 -0
- /package/dist/{chunk-BMV2SNYX.js.map → chunk-MUPWNSEJ.js.map} +0 -0
- /package/dist/{chunk-Y5TRG22C.js.map → chunk-NRXIECWC.js.map} +0 -0
- /package/dist/{chunk-GOE7G5JX.js.map → chunk-NWSAF6P5.js.map} +0 -0
- /package/dist/{chunk-DUM363VS.js.map → chunk-OFZQJNF6.js.map} +0 -0
- /package/dist/{chunk-CKN5QPEL.js.map → chunk-OMF7POEY.js.map} +0 -0
- /package/dist/{chunk-MVXKO2BD.js.map → chunk-OXD6ET34.js.map} +0 -0
- /package/dist/{chunk-47JUEVME.js.map → chunk-PALX6HWV.js.map} +0 -0
- /package/dist/{chunk-B6OGSG7I.js.map → chunk-PE3BLBDT.js.map} +0 -0
- /package/dist/{chunk-RVISSNVE.js.map → chunk-PMZKJOG6.js.map} +0 -0
- /package/dist/{chunk-CESAMXWX.js.map → chunk-PQUTMG3S.js.map} +0 -0
- /package/dist/{chunk-7VFCOKPG.js.map → chunk-PWBGODZU.js.map} +0 -0
- /package/dist/{chunk-MOPAXD2H.js.map → chunk-QCADUTYX.js.map} +0 -0
- /package/dist/{chunk-CT5FBO7E.js.map → chunk-RPOUJI25.js.map} +0 -0
- /package/dist/{chunk-WKHYOS72.js.map → chunk-RW4GFE56.js.map} +0 -0
- /package/dist/{chunk-FH4GO7HO.js.map → chunk-RYLVVDR7.js.map} +0 -0
- /package/dist/{chunk-QZRDCFHI.js.map → chunk-S66SBBFQ.js.map} +0 -0
- /package/dist/{chunk-CQJFIPAH.js.map → chunk-S7TNV2I7.js.map} +0 -0
- /package/dist/{chunk-ZBQSIGGR.js.map → chunk-SC773IMJ.js.map} +0 -0
- /package/dist/{chunk-FBJ2HK7A.js.map → chunk-SGPJ3YS2.js.map} +0 -0
- /package/dist/{chunk-A2EWJQXX.js.map → chunk-SM5QX6UK.js.map} +0 -0
- /package/dist/{chunk-RKZWCTXV.js.map → chunk-TAEKDMEF.js.map} +0 -0
- /package/dist/{chunk-6AVCAUGL.js.map → chunk-TASEV25T.js.map} +0 -0
- /package/dist/{chunk-3XOISKZC.js.map → chunk-TLGDPMUX.js.map} +0 -0
- /package/dist/{chunk-5IUW34PG.js.map → chunk-TY3QYPJ6.js.map} +0 -0
- /package/dist/{chunk-VQFR4EU4.js.map → chunk-U3JK5VJV.js.map} +0 -0
- /package/dist/{chunk-2AWMJO54.js.map → chunk-U42P3RMZ.js.map} +0 -0
- /package/dist/{chunk-GUU75DES.js.map → chunk-UEJTOPLW.js.map} +0 -0
- /package/dist/{chunk-OZOEWLGR.js.map → chunk-UT6JAORE.js.map} +0 -0
- /package/dist/{chunk-5TELOQA6.js.map → chunk-UTHPUINA.js.map} +0 -0
- /package/dist/{chunk-26RQ6JBR.js.map → chunk-VBVCNH6D.js.map} +0 -0
- /package/dist/{chunk-P646DND6.js.map → chunk-VCMQPCME.js.map} +0 -0
- /package/dist/{chunk-LV7FMIMM.js.map → chunk-VGUHAHHV.js.map} +0 -0
- /package/dist/{chunk-GYVXARCY.js.map → chunk-VIBPFVU4.js.map} +0 -0
- /package/dist/{chunk-KHPOKZ6Z.js.map → chunk-VMAC66JX.js.map} +0 -0
- /package/dist/{chunk-SHKRS6I5.js.map → chunk-VRPNETPK.js.map} +0 -0
- /package/dist/{chunk-6U4J6RVS.js.map → chunk-WCHW4XN7.js.map} +0 -0
- /package/dist/{chunk-CJH6QUQJ.js.map → chunk-WD3UXNJV.js.map} +0 -0
- /package/dist/{chunk-H5EVWF6L.js.map → chunk-WR67FJMX.js.map} +0 -0
- /package/dist/{chunk-XLIJ36RG.js.map → chunk-WRMQ7EX4.js.map} +0 -0
- /package/dist/{chunk-7KLCFJ5G.js.map → chunk-X4PPGXQG.js.map} +0 -0
- /package/dist/{chunk-ZE2JTVCQ.js.map → chunk-X5BMQXFD.js.map} +0 -0
- /package/dist/{chunk-UECU6LZI.js.map → chunk-XXRBOSWV.js.map} +0 -0
- /package/dist/{chunk-SPKAIDWX.js.map → chunk-XZEFCPBL.js.map} +0 -0
- /package/dist/{chunk-EZ5NYRHK.js.map → chunk-YL6N7QLA.js.map} +0 -0
- /package/dist/{chunk-VAIESMPY.js.map → chunk-YVBHGMKC.js.map} +0 -0
- /package/dist/{chunk-AR62NQXE.js.map → chunk-Z2S5VQG7.js.map} +0 -0
- /package/dist/{chunk-7UQJEADK.js.map → chunk-ZL2O4BYP.js.map} +0 -0
- /package/dist/{chunk-FOOITLHR.js.map → chunk-ZZHBT5WQ.js.map} +0 -0
- /package/dist/{chunk-X6VJQJYY.js.map → chunk-ZZWHKC6A.js.map} +0 -0
- /package/dist/{model-policy-picker-menu-XOPYY6YA.js.map → computer-viewer-S6TE6TN7.js.map} +0 -0
- /package/dist/{sandbox-files-LJCR437H.js.map → embedded-new-voice-ZDZPGX25.js.map} +0 -0
- /package/dist/{session-realtime-UISLBZ4A.js.map → embedded-voice-FKCUXSJO.js.map} +0 -0
- /package/dist/{fleet-decision-row-5UCJXTDP.js.map → fleet-decision-row-VCGWYJAV.js.map} +0 -0
- /package/dist/{latest-question-VGVNUGAU.js.map → latest-question-SINEV4U6.js.map} +0 -0
- /package/dist/{platform-activity-row-56XOVTRA.js.map → platform-activity-row-LU5WABI2.js.map} +0 -0
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Keyboard chords: matching, platform notation and desktop accelerators.
|
|
3
|
+
*
|
|
4
|
+
* A chord always has ⌘ (Mac) or Ctrl (Windows and Linux) unless it is a
|
|
5
|
+
* navigation chord with ⌥/Alt, so it never fights with typing. Chords match on
|
|
6
|
+
* `KeyboardEvent.code`, which names the physical key, so they work on every
|
|
7
|
+
* keyboard layout. Punctuation also matches the character typed, because many
|
|
8
|
+
* layouts put it elsewhere: "/" is ⇧7 on Nordic and German keyboards.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
export type ChordPlatform = "mac" | "other";
|
|
12
|
+
export type ActionSurface = "web" | "desktop";
|
|
13
|
+
|
|
14
|
+
export type Chord = {
|
|
15
|
+
/** `KeyboardEvent.code`, e.g. `"KeyO"`, `"Comma"`, `"ArrowDown"`, `"Digit1"`. */
|
|
16
|
+
code: string;
|
|
17
|
+
/** ⌘ on Mac, Ctrl elsewhere. */
|
|
18
|
+
mod?: boolean;
|
|
19
|
+
shift?: boolean;
|
|
20
|
+
/** ⌥ on Mac, Alt elsewhere. */
|
|
21
|
+
alt?: boolean;
|
|
22
|
+
/** The Control key itself on Mac (⌃). Ignored elsewhere, where `mod` is Ctrl. */
|
|
23
|
+
control?: boolean;
|
|
24
|
+
/** Only on this surface (browsers reserve some keys). */
|
|
25
|
+
only?: ActionSurface;
|
|
26
|
+
/** Only on this platform. */
|
|
27
|
+
platform?: ChordPlatform;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export function currentPlatform(): ChordPlatform {
|
|
31
|
+
if (typeof navigator === "undefined") return "other";
|
|
32
|
+
const uaData = (navigator as Navigator & { userAgentData?: { platform?: string } }).userAgentData;
|
|
33
|
+
const platform = uaData?.platform ?? navigator.platform ?? "";
|
|
34
|
+
return /Mac|iPhone|iPad|iPod/i.test(platform) ? "mac" : "other";
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/** The chords that apply on this surface and platform, in priority order. */
|
|
38
|
+
export function applicableChords(
|
|
39
|
+
chords: readonly Chord[] | undefined,
|
|
40
|
+
surface: ActionSurface,
|
|
41
|
+
platform: ChordPlatform,
|
|
42
|
+
): Chord[] {
|
|
43
|
+
return (chords ?? []).filter(
|
|
44
|
+
(chord) =>
|
|
45
|
+
(!chord.only || chord.only === surface) && (!chord.platform || chord.platform === platform),
|
|
46
|
+
);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function matchesChord(
|
|
50
|
+
event: Pick<
|
|
51
|
+
KeyboardEvent,
|
|
52
|
+
"code" | "key" | "metaKey" | "ctrlKey" | "shiftKey" | "altKey" | "repeat" | "isComposing"
|
|
53
|
+
>,
|
|
54
|
+
chord: Chord,
|
|
55
|
+
platform: ChordPlatform,
|
|
56
|
+
): boolean {
|
|
57
|
+
if (event.repeat || event.isComposing) return false;
|
|
58
|
+
if (event.code === chord.code) {
|
|
59
|
+
if (Boolean(chord.shift) !== event.shiftKey) return false;
|
|
60
|
+
} else {
|
|
61
|
+
// The character on another key: whatever Shift it took to type it is part
|
|
62
|
+
// of typing the character, so only a chord without Shift can match this way.
|
|
63
|
+
const character = PUNCTUATION[chord.code];
|
|
64
|
+
if (!character || chord.shift || event.key !== character) return false;
|
|
65
|
+
}
|
|
66
|
+
if (Boolean(chord.alt) !== event.altKey) return false;
|
|
67
|
+
if (platform === "mac") {
|
|
68
|
+
if (Boolean(chord.mod) !== event.metaKey) return false;
|
|
69
|
+
if (Boolean(chord.control) !== event.ctrlKey) return false;
|
|
70
|
+
} else {
|
|
71
|
+
if (Boolean(chord.mod) !== event.ctrlKey) return false;
|
|
72
|
+
if (event.metaKey) return false;
|
|
73
|
+
}
|
|
74
|
+
return true;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
const PUNCTUATION: Record<string, string> = {
|
|
78
|
+
Comma: ",",
|
|
79
|
+
Period: ".",
|
|
80
|
+
Slash: "/",
|
|
81
|
+
Backslash: "\\",
|
|
82
|
+
BracketLeft: "[",
|
|
83
|
+
BracketRight: "]",
|
|
84
|
+
Semicolon: ";",
|
|
85
|
+
Quote: "'",
|
|
86
|
+
Minus: "-",
|
|
87
|
+
Equal: "=",
|
|
88
|
+
Backquote: "`",
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
const KEY_NAMES: Record<string, { mac: string; other: string; accelerator: string }> = {
|
|
92
|
+
Comma: { mac: ",", other: ",", accelerator: "," },
|
|
93
|
+
Period: { mac: ".", other: ".", accelerator: "." },
|
|
94
|
+
Slash: { mac: "/", other: "/", accelerator: "/" },
|
|
95
|
+
Backslash: { mac: "\\", other: "\\", accelerator: "\\" },
|
|
96
|
+
BracketLeft: { mac: "[", other: "[", accelerator: "[" },
|
|
97
|
+
BracketRight: { mac: "]", other: "]", accelerator: "]" },
|
|
98
|
+
Semicolon: { mac: ";", other: ";", accelerator: ";" },
|
|
99
|
+
Quote: { mac: "'", other: "'", accelerator: "'" },
|
|
100
|
+
Minus: { mac: "-", other: "-", accelerator: "-" },
|
|
101
|
+
Equal: { mac: "=", other: "=", accelerator: "=" },
|
|
102
|
+
Backquote: { mac: "`", other: "`", accelerator: "`" },
|
|
103
|
+
ArrowUp: { mac: "↑", other: "↑", accelerator: "Up" },
|
|
104
|
+
ArrowDown: { mac: "↓", other: "↓", accelerator: "Down" },
|
|
105
|
+
ArrowLeft: { mac: "←", other: "←", accelerator: "Left" },
|
|
106
|
+
ArrowRight: { mac: "→", other: "→", accelerator: "Right" },
|
|
107
|
+
Enter: { mac: "↩", other: "Enter", accelerator: "Return" },
|
|
108
|
+
Escape: { mac: "Esc", other: "Esc", accelerator: "Escape" },
|
|
109
|
+
Tab: { mac: "⇥", other: "Tab", accelerator: "Tab" },
|
|
110
|
+
Space: { mac: "Space", other: "Space", accelerator: "Space" },
|
|
111
|
+
Backspace: { mac: "⌫", other: "Backspace", accelerator: "Backspace" },
|
|
112
|
+
};
|
|
113
|
+
|
|
114
|
+
function keyName(code: string, platform: ChordPlatform | "accelerator"): string {
|
|
115
|
+
const known = KEY_NAMES[code];
|
|
116
|
+
if (known) return known[platform];
|
|
117
|
+
if (/^Key[A-Z]$/.test(code)) return code.slice(3);
|
|
118
|
+
if (/^Digit[0-9]$/.test(code)) return code.slice(5);
|
|
119
|
+
if (/^F[0-9]{1,2}$/.test(code)) return code;
|
|
120
|
+
return code;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/** The chord as keycaps, in the platform's own notation: `["⌘", "⇧", "O"]` or `["Ctrl", "Shift", "O"]`. */
|
|
124
|
+
export function chordKeys(chord: Chord, platform: ChordPlatform): string[] {
|
|
125
|
+
if (platform === "mac") {
|
|
126
|
+
// Apple's order: Control, Option, Shift, Command.
|
|
127
|
+
return [
|
|
128
|
+
...(chord.control ? ["⌃"] : []),
|
|
129
|
+
...(chord.alt ? ["⌥"] : []),
|
|
130
|
+
...(chord.shift ? ["⇧"] : []),
|
|
131
|
+
...(chord.mod ? ["⌘"] : []),
|
|
132
|
+
keyName(chord.code, "mac"),
|
|
133
|
+
];
|
|
134
|
+
}
|
|
135
|
+
return [
|
|
136
|
+
...(chord.mod ? ["Ctrl"] : []),
|
|
137
|
+
...(chord.alt ? ["Alt"] : []),
|
|
138
|
+
...(chord.shift ? ["Shift"] : []),
|
|
139
|
+
keyName(chord.code, "other"),
|
|
140
|
+
];
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/** One string for tooltips and `title`s: `⌘⇧O` on Mac, `Ctrl+Shift+O` elsewhere. */
|
|
144
|
+
export function chordLabel(chord: Chord, platform: ChordPlatform): string {
|
|
145
|
+
const keys = chordKeys(chord, platform);
|
|
146
|
+
return platform === "mac" ? keys.join("") : keys.join("+");
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
/** The `aria-keyshortcuts` value for a chord. */
|
|
150
|
+
export function chordAriaKeys(chord: Chord, platform: ChordPlatform): string {
|
|
151
|
+
const key = keyName(chord.code, "accelerator");
|
|
152
|
+
const named =
|
|
153
|
+
key === "Up" || key === "Down" || key === "Left" || key === "Right" ? `Arrow${key}` : key;
|
|
154
|
+
return [
|
|
155
|
+
...(chord.control && platform === "mac" ? ["Control"] : []),
|
|
156
|
+
...(chord.mod ? [platform === "mac" ? "Meta" : "Control"] : []),
|
|
157
|
+
...(chord.alt ? ["Alt"] : []),
|
|
158
|
+
...(chord.shift ? ["Shift"] : []),
|
|
159
|
+
named,
|
|
160
|
+
].join("+");
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/** An Electron accelerator for the desktop menu bar. */
|
|
164
|
+
export function chordAccelerator(chord: Chord): string {
|
|
165
|
+
return [
|
|
166
|
+
...(chord.control ? ["Ctrl"] : []),
|
|
167
|
+
...(chord.mod ? ["CmdOrCtrl"] : []),
|
|
168
|
+
...(chord.alt ? ["Alt"] : []),
|
|
169
|
+
...(chord.shift ? ["Shift"] : []),
|
|
170
|
+
keyName(chord.code, "accelerator"),
|
|
171
|
+
].join("+");
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
/** True when typing into this element would insert text (so bare keys belong to it). */
|
|
175
|
+
export function isTextEntry(target: EventTarget | null): boolean {
|
|
176
|
+
if (!(target instanceof HTMLElement)) return false;
|
|
177
|
+
if (target.isContentEditable) return true;
|
|
178
|
+
if (target instanceof HTMLTextAreaElement) return !target.readOnly;
|
|
179
|
+
if (target instanceof HTMLInputElement) {
|
|
180
|
+
return !["button", "checkbox", "radio", "range", "color", "file", "submit", "reset"].includes(
|
|
181
|
+
target.type,
|
|
182
|
+
);
|
|
183
|
+
}
|
|
184
|
+
return false;
|
|
185
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** Page events that reach the action system from outside React's tree. */
|
|
2
|
+
|
|
3
|
+
/** Opens the ⌘K menu (older desktop menu commands, buttons). Sent on the window target. */
|
|
4
|
+
export const OPEN_COMMAND_MENU_EVENT = "opengeni:open-command-menu";
|
|
5
|
+
/** Asks the chat header to start renaming the chat on screen. Sent on the document target. */
|
|
6
|
+
export const RENAME_CURRENT_CHAT_EVENT = "opengeni:rename-current-chat";
|
|
7
|
+
|
|
8
|
+
export function requestCommandMenu(target: EventTarget): void {
|
|
9
|
+
target.dispatchEvent(new Event(OPEN_COMMAND_MENU_EVENT));
|
|
10
|
+
}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Ranks short labels (chat titles, action names) against what someone typed.
|
|
3
|
+
*
|
|
4
|
+
* Higher is better; `null` means no match. Tiers, best first:
|
|
5
|
+
* whole label starts with the query, a word starts with it, it appears
|
|
6
|
+
* anywhere, every query word appears in some order, and finally the query's
|
|
7
|
+
* letters appear in order ("kbsh" → "Keyboard shortcuts"). Within a tier,
|
|
8
|
+
* shorter labels and earlier positions win. Letters-in-order matches rank below
|
|
9
|
+
* `LOOSE_MATCH_BELOW`, so a list can drop them once it has real matches.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
const COMBINING_MARKS = /[\u0300-\u036f]/g;
|
|
13
|
+
|
|
14
|
+
/** Ranks below this are letters-in-order guesses rather than real matches. */
|
|
15
|
+
export const LOOSE_MATCH_BELOW = 400;
|
|
16
|
+
|
|
17
|
+
/** Case- and accent-insensitive form used for matching. */
|
|
18
|
+
export function foldForSearch(value: string): string {
|
|
19
|
+
return value
|
|
20
|
+
.normalize("NFD")
|
|
21
|
+
.replace(COMBINING_MARKS, "")
|
|
22
|
+
.toLowerCase()
|
|
23
|
+
.replace(/\s+/g, " ")
|
|
24
|
+
.trim();
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
function wordStarts(label: string): number[] {
|
|
28
|
+
const starts: number[] = [];
|
|
29
|
+
for (let index = 0; index < label.length; index++) {
|
|
30
|
+
const previous = index === 0 ? " " : label[index - 1]!;
|
|
31
|
+
const current = label[index]!;
|
|
32
|
+
if (/[\p{L}\p{N}]/u.test(current) && !/[\p{L}\p{N}]/u.test(previous)) starts.push(index);
|
|
33
|
+
}
|
|
34
|
+
return starts;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
function subsequenceScore(label: string, query: string): number | null {
|
|
38
|
+
// Letters in order, read the way people abbreviate: the first letter starts a
|
|
39
|
+
// word, and moving on to a later word means landing on its first letter
|
|
40
|
+
// ("kbsh" → Keyboard shortcuts). Consecutive letters are worth more.
|
|
41
|
+
const startList = wordStarts(label);
|
|
42
|
+
const starts = new Set(startList);
|
|
43
|
+
const wordOf = (index: number) => {
|
|
44
|
+
let word = -1;
|
|
45
|
+
for (const start of startList) {
|
|
46
|
+
if (start > index) break;
|
|
47
|
+
word++;
|
|
48
|
+
}
|
|
49
|
+
return word;
|
|
50
|
+
};
|
|
51
|
+
let position = 0;
|
|
52
|
+
let score = 0;
|
|
53
|
+
let previous = -2;
|
|
54
|
+
// Prefer the next letter inside the current word; otherwise only the start
|
|
55
|
+
// of a later word counts.
|
|
56
|
+
const fits = (found: number) =>
|
|
57
|
+
found === previous + 1 ||
|
|
58
|
+
starts.has(found) ||
|
|
59
|
+
(previous >= 0 && wordOf(found) === wordOf(previous));
|
|
60
|
+
for (const character of query) {
|
|
61
|
+
if (character === " ") continue;
|
|
62
|
+
let found = label.indexOf(character, position);
|
|
63
|
+
while (found >= 0 && !fits(found)) found = label.indexOf(character, found + 1);
|
|
64
|
+
if (found < 0) return null;
|
|
65
|
+
score += found === previous + 1 ? 3 : starts.has(found) ? 2 : 0;
|
|
66
|
+
previous = found;
|
|
67
|
+
position = found + 1;
|
|
68
|
+
}
|
|
69
|
+
return score;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function rankLabel(rawLabel: string, rawQuery: string): number | null {
|
|
73
|
+
const query = foldForSearch(rawQuery);
|
|
74
|
+
if (!query) return 0;
|
|
75
|
+
const label = foldForSearch(rawLabel);
|
|
76
|
+
if (!label) return null;
|
|
77
|
+
const lengthPenalty = Math.min(label.length, 200) / 1000;
|
|
78
|
+
if (label === query) return 1000;
|
|
79
|
+
if (label.startsWith(query)) return 900 - lengthPenalty;
|
|
80
|
+
const at = label.indexOf(query);
|
|
81
|
+
if (at >= 0) {
|
|
82
|
+
const starts = wordStarts(label);
|
|
83
|
+
if (starts.includes(at)) return 800 - at / 100 - lengthPenalty;
|
|
84
|
+
return 600 - at / 100 - lengthPenalty;
|
|
85
|
+
}
|
|
86
|
+
const words = query.split(" ").filter(Boolean);
|
|
87
|
+
if (words.length > 1 && words.every((word) => label.includes(word))) {
|
|
88
|
+
const starts = wordStarts(label);
|
|
89
|
+
const wordStartHits = words.filter((word) =>
|
|
90
|
+
starts.some((start) => label.startsWith(word, start)),
|
|
91
|
+
).length;
|
|
92
|
+
return 500 + (wordStartHits / words.length) * 50 - lengthPenalty;
|
|
93
|
+
}
|
|
94
|
+
if (query.replace(/ /g, "").length < 2) return null;
|
|
95
|
+
const subsequence = subsequenceScore(label, query);
|
|
96
|
+
if (subsequence === null) return null;
|
|
97
|
+
// Only keep loose matches that hit word starts or runs; random letters scattered
|
|
98
|
+
// across a long title are noise.
|
|
99
|
+
const letters = query.replace(/ /g, "").length;
|
|
100
|
+
if (subsequence < letters) return null;
|
|
101
|
+
return 100 + Math.min(subsequence, 200) - lengthPenalty * 10;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/** The best rank across a label and extra keywords (a keyword match ranks below the same match on the name). */
|
|
105
|
+
export function rankWithKeywords(
|
|
106
|
+
label: string,
|
|
107
|
+
keywords: readonly string[] | undefined,
|
|
108
|
+
query: string,
|
|
109
|
+
): number | null {
|
|
110
|
+
let best = rankLabel(label, query);
|
|
111
|
+
for (const keyword of keywords ?? []) {
|
|
112
|
+
const rank = rankLabel(keyword, query);
|
|
113
|
+
if (rank !== null) {
|
|
114
|
+
const discounted = rank - 150;
|
|
115
|
+
if (best === null || discounted > best) best = discounted;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
return best;
|
|
119
|
+
}
|
|
@@ -0,0 +1,333 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The action registry: everything a person can do from the keyboard, the ⌘K
|
|
3
|
+
* menu, menus and the desktop menu bar. Each action is defined once here, with
|
|
4
|
+
* its name, keys and availability, so every surface shows and runs it the same
|
|
5
|
+
* way. See docs/command-menu-and-shortcuts.md.
|
|
6
|
+
*/
|
|
7
|
+
import {
|
|
8
|
+
ArchiveIcon,
|
|
9
|
+
ArchiveRestoreIcon,
|
|
10
|
+
ArrowDownIcon,
|
|
11
|
+
ArrowUpIcon,
|
|
12
|
+
CommandIcon,
|
|
13
|
+
HistoryIcon,
|
|
14
|
+
InboxIcon,
|
|
15
|
+
KeyboardIcon,
|
|
16
|
+
LinkIcon,
|
|
17
|
+
MailIcon,
|
|
18
|
+
MailOpenIcon,
|
|
19
|
+
PanelLeftIcon,
|
|
20
|
+
PencilIcon,
|
|
21
|
+
PinIcon,
|
|
22
|
+
PinOffIcon,
|
|
23
|
+
PlusIcon,
|
|
24
|
+
SearchIcon,
|
|
25
|
+
TextSearchIcon,
|
|
26
|
+
type LucideIcon,
|
|
27
|
+
} from "lucide-react";
|
|
28
|
+
import type { SessionListRow } from "../../../session-list-model";
|
|
29
|
+
import type { ActionSurface, Chord, ChordPlatform } from "./chords";
|
|
30
|
+
import type { ChatOperations } from "./chat-operations";
|
|
31
|
+
|
|
32
|
+
export type ActionGroup = "chat" | "navigate" | "view" | "help";
|
|
33
|
+
|
|
34
|
+
/** Where the desktop menu bar shows an action. */
|
|
35
|
+
export type DesktopMenuPlacement = "file" | "view" | "go" | "chat" | "help";
|
|
36
|
+
|
|
37
|
+
export type ActionEnv = {
|
|
38
|
+
workspaceId: string;
|
|
39
|
+
subjectId: string;
|
|
40
|
+
surface: ActionSurface;
|
|
41
|
+
platform: ChordPlatform;
|
|
42
|
+
/** The chat on screen, if any. */
|
|
43
|
+
currentChat: SessionListRow | null;
|
|
44
|
+
ops: ChatOperations;
|
|
45
|
+
/** Whether the sidebar's chat list is part of this surface. */
|
|
46
|
+
chatList: boolean;
|
|
47
|
+
newChat(): void;
|
|
48
|
+
openChat(chatId: string): void;
|
|
49
|
+
openInbox(): void;
|
|
50
|
+
toggleSidebar(): void;
|
|
51
|
+
findInChat(): void;
|
|
52
|
+
searchMessages(query?: string): void;
|
|
53
|
+
renameCurrentChat(): void;
|
|
54
|
+
openCommandMenu(): void;
|
|
55
|
+
openShortcutSheet(): void;
|
|
56
|
+
/** Back to the most recently viewed other chat (a quick Control+Tab). */
|
|
57
|
+
switchToRecentChat(): void;
|
|
58
|
+
/** Chats in sidebar order, and the pinned ones in their order. */
|
|
59
|
+
sidebarOrder(): readonly string[];
|
|
60
|
+
pinnedOrder(): readonly string[];
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
export type AppAction = {
|
|
64
|
+
id: string;
|
|
65
|
+
/** Plain words; chat actions may read the chat (Pin or Unpin). */
|
|
66
|
+
title: string | ((env: ActionEnv, chat: SessionListRow | null) => string);
|
|
67
|
+
group: ActionGroup;
|
|
68
|
+
icon: LucideIcon;
|
|
69
|
+
/** A different icon for some chats (Unpin for a pinned chat). */
|
|
70
|
+
iconFor?: (chat: SessionListRow | null) => LucideIcon;
|
|
71
|
+
/** Extra words the ⌘K menu matches, e.g. "share" for Copy link. */
|
|
72
|
+
keywords?: readonly string[];
|
|
73
|
+
chords?: readonly Chord[];
|
|
74
|
+
/** The cheat sheet's own key text when one action has many chords (⌘1 to ⌘9). */
|
|
75
|
+
chordSummary?: (platform: ChordPlatform) => string;
|
|
76
|
+
/** Acts on a chat: the current one, or the one a menu or ⌘K row points at. */
|
|
77
|
+
forChat?: boolean;
|
|
78
|
+
/** Listed in the ⌘K menu (some exist only as keys). Default true. */
|
|
79
|
+
inCommandMenu?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Opens a dialog of its own. From ⌘K it runs once the menu has handed focus
|
|
82
|
+
* back, so the new dialog returns focus to the same place when it closes.
|
|
83
|
+
*/
|
|
84
|
+
opensDialog?: boolean;
|
|
85
|
+
/** Offered in ⌘K before anything is typed. */
|
|
86
|
+
suggested?: boolean;
|
|
87
|
+
/** The desktop menu bar section, when it appears there. */
|
|
88
|
+
desktopMenu?: DesktopMenuPlacement;
|
|
89
|
+
available(env: ActionEnv, chat: SessionListRow | null): boolean;
|
|
90
|
+
run(env: ActionEnv, chat: SessionListRow | null, chord?: Chord): void | Promise<void>;
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
export function actionTitle(
|
|
94
|
+
action: AppAction,
|
|
95
|
+
env: ActionEnv,
|
|
96
|
+
chat: SessionListRow | null,
|
|
97
|
+
): string {
|
|
98
|
+
return typeof action.title === "string" ? action.title : action.title(env, chat);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export function actionIcon(action: AppAction, chat: SessionListRow | null): LucideIcon {
|
|
102
|
+
return action.iconFor?.(chat) ?? action.icon;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
const ALWAYS = () => true;
|
|
106
|
+
|
|
107
|
+
function stepChat(env: ActionEnv, direction: 1 | -1): void {
|
|
108
|
+
const order = env.sidebarOrder();
|
|
109
|
+
if (order.length === 0) return;
|
|
110
|
+
const index = env.currentChat ? order.indexOf(env.currentChat.id) : -1;
|
|
111
|
+
const next = index < 0 ? (direction === 1 ? 0 : order.length - 1) : index + direction;
|
|
112
|
+
if (next < 0 || next >= order.length) return;
|
|
113
|
+
env.openChat(order[next]!);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
const PINNED_CHORDS: Chord[] = Array.from({ length: 9 }, (_, index) => ({
|
|
117
|
+
code: `Digit${index + 1}`,
|
|
118
|
+
mod: true,
|
|
119
|
+
only: "desktop" as const,
|
|
120
|
+
}));
|
|
121
|
+
|
|
122
|
+
export const APP_ACTIONS: readonly AppAction[] = [
|
|
123
|
+
{
|
|
124
|
+
id: "commandMenu.open",
|
|
125
|
+
title: "Command menu",
|
|
126
|
+
group: "help",
|
|
127
|
+
icon: CommandIcon,
|
|
128
|
+
chords: [{ code: "KeyK", mod: true }],
|
|
129
|
+
inCommandMenu: false,
|
|
130
|
+
desktopMenu: "go",
|
|
131
|
+
available: ALWAYS,
|
|
132
|
+
run: (env) => env.openCommandMenu(),
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
id: "chat.new",
|
|
136
|
+
title: "New chat",
|
|
137
|
+
group: "chat",
|
|
138
|
+
icon: PlusIcon,
|
|
139
|
+
keywords: ["start", "create", "session"],
|
|
140
|
+
// The desktop menu shows its first key, the familiar ⌘N; browsers keep ⌘N for windows.
|
|
141
|
+
chords: [
|
|
142
|
+
{ code: "KeyN", mod: true, only: "desktop" },
|
|
143
|
+
{ code: "KeyO", mod: true, shift: true },
|
|
144
|
+
],
|
|
145
|
+
suggested: true,
|
|
146
|
+
desktopMenu: "file",
|
|
147
|
+
available: ALWAYS,
|
|
148
|
+
run: (env) => env.newChat(),
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
id: "chat.copyLink",
|
|
152
|
+
title: "Copy link",
|
|
153
|
+
group: "chat",
|
|
154
|
+
icon: LinkIcon,
|
|
155
|
+
keywords: ["share", "url", "address"],
|
|
156
|
+
chords: [{ code: "Comma", mod: true, shift: true }],
|
|
157
|
+
forChat: true,
|
|
158
|
+
suggested: true,
|
|
159
|
+
desktopMenu: "chat",
|
|
160
|
+
available: (_env, chat) => chat !== null,
|
|
161
|
+
run: (env, chat) => (chat ? env.ops.copyLink(chat) : undefined),
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
id: "chat.pin",
|
|
165
|
+
title: (_env, chat) => (chat?.pinned ? "Unpin" : "Pin"),
|
|
166
|
+
group: "chat",
|
|
167
|
+
icon: PinIcon,
|
|
168
|
+
iconFor: (chat) => (chat?.pinned ? PinOffIcon : PinIcon),
|
|
169
|
+
keywords: ["unpin", "favorite", "star"],
|
|
170
|
+
chords: [{ code: "KeyP", mod: true, alt: true }],
|
|
171
|
+
forChat: true,
|
|
172
|
+
suggested: true,
|
|
173
|
+
desktopMenu: "chat",
|
|
174
|
+
available: (_env, chat) => chat !== null && !chat.archived,
|
|
175
|
+
run: (env, chat) => (chat ? env.ops.setPinned(chat, !chat.pinned) : undefined),
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
id: "chat.rename",
|
|
179
|
+
title: "Rename",
|
|
180
|
+
group: "chat",
|
|
181
|
+
icon: PencilIcon,
|
|
182
|
+
keywords: ["title", "name"],
|
|
183
|
+
forChat: true,
|
|
184
|
+
desktopMenu: "chat",
|
|
185
|
+
// Renaming happens in the chat's own title, so only for the chat on screen.
|
|
186
|
+
available: (env, chat) => chat !== null && env.currentChat?.id === chat.id,
|
|
187
|
+
run: (env) => env.renameCurrentChat(),
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
id: "chat.unread",
|
|
191
|
+
title: (_env, chat) => (chat?.unread ? "Mark as read" : "Mark as unread"),
|
|
192
|
+
group: "chat",
|
|
193
|
+
icon: MailIcon,
|
|
194
|
+
iconFor: (chat) => (chat?.unread ? MailOpenIcon : MailIcon),
|
|
195
|
+
keywords: ["read", "unread"],
|
|
196
|
+
forChat: true,
|
|
197
|
+
desktopMenu: "chat",
|
|
198
|
+
available: (_env, chat) => chat !== null && !chat.archived,
|
|
199
|
+
run: (env, chat) => (chat ? env.ops.setUnread(chat, !chat.unread) : undefined),
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
id: "chat.archive",
|
|
203
|
+
title: (_env, chat) => (chat?.archived ? "Restore" : "Archive"),
|
|
204
|
+
group: "chat",
|
|
205
|
+
icon: ArchiveIcon,
|
|
206
|
+
iconFor: (chat) => (chat?.archived ? ArchiveRestoreIcon : ArchiveIcon),
|
|
207
|
+
keywords: ["restore", "hide", "done"],
|
|
208
|
+
forChat: true,
|
|
209
|
+
desktopMenu: "chat",
|
|
210
|
+
available: (_env, chat) => chat !== null && chat.parentSessionId === null,
|
|
211
|
+
run: (env, chat) => (chat ? env.ops.setArchived(chat, !chat.archived) : undefined),
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
id: "chat.find",
|
|
215
|
+
title: "Find in chat",
|
|
216
|
+
group: "chat",
|
|
217
|
+
icon: TextSearchIcon,
|
|
218
|
+
keywords: ["search", "find"],
|
|
219
|
+
chords: [{ code: "KeyF", mod: true }],
|
|
220
|
+
desktopMenu: "chat",
|
|
221
|
+
// The conversation owns ⌘F itself; the registry lists it so it is discoverable.
|
|
222
|
+
available: (env) => env.currentChat !== null,
|
|
223
|
+
run: (env) => env.findInChat(),
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
id: "go.inbox",
|
|
227
|
+
title: "Inbox",
|
|
228
|
+
group: "navigate",
|
|
229
|
+
icon: InboxIcon,
|
|
230
|
+
keywords: ["notifications", "replies", "needs you"],
|
|
231
|
+
chords: [
|
|
232
|
+
{ code: "KeyI", mod: true, shift: true, platform: "mac" },
|
|
233
|
+
// Browsers on Windows and Linux open developer tools with Ctrl+Shift+I.
|
|
234
|
+
{ code: "KeyI", mod: true, shift: true, platform: "other", only: "desktop" },
|
|
235
|
+
],
|
|
236
|
+
suggested: true,
|
|
237
|
+
desktopMenu: "go",
|
|
238
|
+
available: ALWAYS,
|
|
239
|
+
run: (env) => env.openInbox(),
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
id: "go.previousChat",
|
|
243
|
+
title: "Previous chat",
|
|
244
|
+
group: "navigate",
|
|
245
|
+
icon: ArrowUpIcon,
|
|
246
|
+
chords: [{ code: "ArrowUp", alt: true }],
|
|
247
|
+
inCommandMenu: false,
|
|
248
|
+
available: (env) => env.chatList,
|
|
249
|
+
run: (env) => stepChat(env, -1),
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
id: "go.nextChat",
|
|
253
|
+
title: "Next chat",
|
|
254
|
+
group: "navigate",
|
|
255
|
+
icon: ArrowDownIcon,
|
|
256
|
+
chords: [{ code: "ArrowDown", alt: true }],
|
|
257
|
+
inCommandMenu: false,
|
|
258
|
+
available: (env) => env.chatList,
|
|
259
|
+
run: (env) => stepChat(env, 1),
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
// Hold Control to see recent chats and keep pressing Tab; release to open.
|
|
263
|
+
// The actions provider runs the switcher itself because it needs Control's
|
|
264
|
+
// release, so the desktop menu bar never owns this key.
|
|
265
|
+
id: "go.recentChat",
|
|
266
|
+
title: "Switch to recent chat",
|
|
267
|
+
group: "navigate",
|
|
268
|
+
icon: HistoryIcon,
|
|
269
|
+
chords: [
|
|
270
|
+
{ code: "Tab", control: true, platform: "mac", only: "desktop" },
|
|
271
|
+
// Browsers keep Control+Tab for their own tabs.
|
|
272
|
+
{ code: "Tab", mod: true, platform: "other", only: "desktop" },
|
|
273
|
+
],
|
|
274
|
+
inCommandMenu: false,
|
|
275
|
+
available: ALWAYS,
|
|
276
|
+
run: (env) => env.switchToRecentChat(),
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
id: "go.pinnedChat",
|
|
280
|
+
title: "Pinned chat 1 to 9",
|
|
281
|
+
group: "navigate",
|
|
282
|
+
icon: PinIcon,
|
|
283
|
+
chords: PINNED_CHORDS,
|
|
284
|
+
chordSummary: (platform) => (platform === "mac" ? "⌘1 – ⌘9" : "Ctrl+1 – Ctrl+9"),
|
|
285
|
+
inCommandMenu: false,
|
|
286
|
+
available: (env) => env.chatList,
|
|
287
|
+
run: (env, _chat, chord) => {
|
|
288
|
+
const index = chord ? Number(chord.code.slice(5)) - 1 : 0;
|
|
289
|
+
const id = env.pinnedOrder()[index];
|
|
290
|
+
if (id) env.openChat(id);
|
|
291
|
+
},
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
id: "go.searchMessages",
|
|
295
|
+
title: "Search messages",
|
|
296
|
+
group: "navigate",
|
|
297
|
+
icon: SearchIcon,
|
|
298
|
+
keywords: ["find", "history", "full text"],
|
|
299
|
+
opensDialog: true,
|
|
300
|
+
desktopMenu: "go",
|
|
301
|
+
available: ALWAYS,
|
|
302
|
+
run: (env) => env.searchMessages(),
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
id: "view.sidebar",
|
|
306
|
+
title: "Toggle sidebar",
|
|
307
|
+
group: "view",
|
|
308
|
+
icon: PanelLeftIcon,
|
|
309
|
+
keywords: ["hide", "show", "collapse", "rail"],
|
|
310
|
+
chords: [
|
|
311
|
+
{ code: "KeyS", mod: true, control: true, platform: "mac" },
|
|
312
|
+
{ code: "KeyS", mod: true, shift: true, platform: "other" },
|
|
313
|
+
],
|
|
314
|
+
desktopMenu: "view",
|
|
315
|
+
available: (env) => env.chatList,
|
|
316
|
+
run: (env) => env.toggleSidebar(),
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
id: "help.shortcuts",
|
|
320
|
+
title: "Keyboard shortcuts",
|
|
321
|
+
group: "help",
|
|
322
|
+
icon: KeyboardIcon,
|
|
323
|
+
keywords: ["keys", "hotkeys", "cheat sheet", "help"],
|
|
324
|
+
chords: [{ code: "Slash", mod: true }],
|
|
325
|
+
desktopMenu: "help",
|
|
326
|
+
available: ALWAYS,
|
|
327
|
+
run: (env) => env.openShortcutSheet(),
|
|
328
|
+
},
|
|
329
|
+
];
|
|
330
|
+
|
|
331
|
+
export function findAction(id: string): AppAction | undefined {
|
|
332
|
+
return APP_ACTIONS.find((action) => action.id === id);
|
|
333
|
+
}
|