@yuriai/web 0.2.40-beta.3 → 0.2.40-beta.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{AgentAvatar-kQhfwlay.js → AgentAvatar-B7KbxN8Y.js} +1 -1
- package/dist/assets/AssistantConversationSurface-BnK_KTBO.js +3 -0
- package/dist/assets/{AssistantUnreadBadge-B2SY-_-u.js → AssistantUnreadBadge-vu4ZhTft.js} +1 -1
- package/dist/assets/{AssistantView-C_hiAuTd.js → AssistantView-CEfEWUIr.js} +1 -1
- package/dist/assets/DiagramView-Dlzr08J_.js +1 -0
- package/dist/assets/{FadeInOnReveal-CMeIdEKz.js → FadeInOnReveal-DMRmNsau.js} +1 -1
- package/dist/assets/{GuiPluginPage-WXqykPAg.js → GuiPluginPage-DVug4z_p.js} +1 -1
- package/dist/assets/GuiPluginSurface-L43o6Xv8.js +1 -0
- package/dist/assets/{GuiPluginWindow-BLzchKn7.js → GuiPluginWindow-tHXkS18H.js} +1 -1
- package/dist/assets/{Icon-DygEqfgq.js → Icon-DizeYahT.js} +1 -1
- package/dist/assets/{ImageLoadingPlaceholder-kbBRpDSD.js → ImageLoadingPlaceholder-BZC5m_km.js} +1 -1
- package/dist/assets/LoadingImage-Csw4L-Dr.js +1 -0
- package/dist/assets/MarkdownRenderer-D_0iKhQN.js +2 -0
- package/dist/assets/MarkdownRendererImpl-BZ0XgjS0.js +10 -0
- package/dist/assets/MarkstreamRendererImpl-DBd6Glg9.js +3 -0
- package/dist/assets/MobileDetailNavigation-xgwvsQuR.js +1 -0
- package/dist/assets/{MobileResizableSheet-Dt2U0JHY.js → MobileResizableSheet-CQQ7O-2X.js} +1 -1
- package/dist/assets/MobileShareBridge-IO45gM2G.js +3 -0
- package/dist/assets/MobileSurface-DmYgZONB.js +2 -0
- package/dist/assets/{MultiRunWindow-BuRo90Ma.js → MultiRunWindow-fJ3XfntS.js} +1 -1
- package/dist/assets/OnboardingScreen-MJS5T5rL.js +1 -0
- package/dist/assets/{OverlayScrollbar-B0X61qR-.js → OverlayScrollbar-jtMYTn1y.js} +1 -1
- package/dist/assets/SettingsView-ZWFLpPSI.js +29 -0
- package/dist/assets/{SettingsWindow-kCbf8IoB.js → SettingsWindow-DGRmrIWz.js} +1 -1
- package/dist/assets/SetupTourDialog-BYbAubwA.js +1 -0
- package/dist/assets/TerminalView-CoJ6_9P1.js +8 -0
- package/dist/assets/ToolOutputDialog-5xBwOJ6a.js +16 -0
- package/dist/assets/VoiceSettings-CN33koSc.js +2 -0
- package/dist/assets/{YuriLogo-B58GIl2v.js → YuriLogo-CvyJy_R9.js} +1 -1
- package/dist/assets/YuriWordmark-DnFAS-Ko.js +1 -0
- package/dist/assets/{assistant-attachment-cache-Cmzt4xXE.js → assistant-attachment-cache-D-LmCflm.js} +1 -1
- package/dist/assets/bootstrap-eLlfzqAI.js +1 -0
- package/dist/assets/{capgoAdapter-DO1rEVQf.js → capgoAdapter-CCLtBZL1.js} +1 -1
- package/dist/assets/{checkbox-BW80bcK5.js → checkbox-rOV6DjeG.js} +1 -1
- package/dist/assets/client-uz8O6TPX.js +7 -0
- package/dist/assets/{collapsible-BOL5Wx2J.js → collapsible-CKswuqAw.js} +1 -1
- package/dist/assets/{context-menu-CiFnjP1q.js → context-menu-B4njwT_M.js} +1 -1
- package/dist/assets/{desktopHosts-DovfbQPm.js → desktopHosts-135cuRCE.js} +1 -1
- package/dist/assets/{desktopRelayRestore-D4pbpNKN.js → desktopRelayRestore-1aUztDPU.js} +1 -1
- package/dist/assets/{device-DNG0cNwQ.js → device-QL8KNSLM.js} +1 -1
- package/dist/assets/{diagram-DRn8iIs1.js → diagram-BppQ_USn.js} +1 -1
- package/dist/assets/{dialog-DQp289fr.js → dialog-Bg8MJnOV.js} +1 -1
- package/dist/assets/{es-D0Q_CV0t.js → es-Ba3NUCtE.js} +3 -3
- package/dist/assets/{fileMentionTouchSelection-582p0uCX.js → fileMentionTouchSelection-D-AdTJVr.js} +1 -1
- package/dist/assets/fileReferenceActions-cYqdsXFz.js +1 -0
- package/dist/assets/{fr-DrO5SAKl.js → fr-CRhp3hyT.js} +3 -3
- package/dist/assets/{gitApi-vYBmQIuU.js → gitApi-DVx_V1x6.js} +11 -7
- package/dist/assets/gitApiHttp-DvTBxvX8.js +3 -0
- package/dist/assets/historyImportQueries-D_9RlrLp.js +1 -0
- package/dist/assets/host-DrGjjO6K.js +1 -0
- package/dist/assets/{i18n-UaLestuf.js → i18n-RH7UieOS.js} +1 -1
- package/dist/assets/image-loading-DBqnxgDH.js +1 -0
- package/dist/assets/{input-B281XcMR.js → input-DRjuZMeA.js} +1 -1
- package/dist/assets/input-store-CjUOfpyA.js +1 -0
- package/dist/assets/insertionBoundaries-DZtQt2Ah.js +1 -0
- package/dist/assets/{ja-BNeP9_GU.js → ja-D-UPjDY2.js} +3 -3
- package/dist/assets/{ko-DRRFD_7l.js → ko-x-z9J5z7.js} +3 -3
- package/dist/assets/main-BMFY9mtb.js +2 -0
- package/dist/assets/main-D2s9J_jN.js +169 -0
- package/dist/assets/{markdownHeightCache-BgYJswDy.js → markdownHeightCache-BL99DlhC.js} +1 -1
- package/dist/assets/{markdownTheme-CHNl6tUv.js → markdownTheme-DFDWa8Gh.js} +1 -1
- package/dist/assets/mcpQueries-HzYMEVWd.js +1 -0
- package/dist/assets/miniChat-BbJ0GKpk.js +2 -0
- package/dist/assets/mobile-_zUth69Z.js +2 -0
- package/dist/assets/mobileBackNavigation--ZdrI-Yj.js +1 -0
- package/dist/assets/mobileConnections-C3eGEOPy.js +2 -0
- package/dist/assets/multirun-CDYNyLBH.js +3 -0
- package/dist/assets/{native-config-BOaqa45X.js → native-config-DOawZfln.js} +1 -1
- package/dist/assets/navigation-Ibk_Pw-q.js +2 -0
- package/dist/assets/{pl-BnW5wJrl.js → pl-Cqo1FJwM.js} +3 -3
- package/dist/assets/platform-wF65ZFgV.js +1 -0
- package/dist/assets/project-preview-2H-TmJkd.js +1 -0
- package/dist/assets/projectActions-50e_f9dI.js +1 -0
- package/dist/assets/projectMeta-D1Ytss9U.js +1 -0
- package/dist/assets/prompt-attachment-upload-BNhDXymd.js +1 -0
- package/dist/assets/{pt-BR-fZW8CCVQ.js → pt-BR-C930XU1k.js} +3 -3
- package/dist/assets/pwa-CXupOTsD.js +2 -0
- package/dist/assets/queue-abort-optimistic-CQXpIlq6.js +1 -0
- package/dist/assets/{react-DPhQUTaH.js → react-CgRToPwO.js} +1 -1
- package/dist/assets/{readiness-BpVAjFhF.js → readiness-BfuZm6Yw.js} +2 -2
- package/dist/assets/relay-preview-frame-src-BPyz3nXA.js +1 -0
- package/dist/assets/remote-input-store-BOdCWpQY.js +1 -0
- package/dist/assets/remoteProjectQueries-CkxdZNw4.js +1 -0
- package/dist/assets/renderElectronMiniChatApp-pJ59iC34.js +2 -0
- package/dist/assets/renderMobileApp-BQFC-gOA.js +29 -0
- package/dist/assets/{runtime-file-download-DMY1k1af.js → runtime-file-download-D11Nnedg.js} +1 -1
- package/dist/assets/runtime-file-resource-CuLP3xp7.js +6 -0
- package/dist/assets/runtimeConfig-tHm7o_0I.js +2 -0
- package/dist/assets/{runtimeEndpointReset-BOdd_mJM.css → runtimeEndpointReset-BUGfn7y0.css} +1 -1
- package/dist/assets/runtimeEndpointReset-BhHWFNvo.js +150 -0
- package/dist/assets/safeStorage-DTOhKN0V.js +1 -0
- package/dist/assets/scheduledTaskNavigation-BIDtQ4wN.js +1 -0
- package/dist/assets/{select-CyPxbnW8.js → select-B1On-Y4Z.js} +1 -1
- package/dist/assets/sessionLookup-RcyTTDOy.js +1 -0
- package/dist/assets/sortable-tabs-strip-nD1Me06z.js +1 -0
- package/dist/assets/{speechSettingsQueries-CTsBn-Ib.js → speechSettingsQueries-BYhNpzDJ.js} +1 -1
- package/dist/assets/src-BZCFf9_1.css +2 -0
- package/dist/assets/{store-CzVMz42v.js → store-DunGyOfe.js} +4 -4
- package/dist/assets/terminalApi-madXrfqA.js +1 -0
- package/dist/assets/{textarea-CjJsstUF.js → textarea-Qt06OhhX.js} +1 -1
- package/dist/assets/{tooltip-Di_DSZ8p.js → tooltip-D382RCy1.js} +1 -1
- package/dist/assets/tour-CQMBn8gJ.js +1 -0
- package/dist/assets/{types-wnqkJWYs.js → types-CHszLAS3.js} +1 -1
- package/dist/assets/{uk-C4OKsNRv.js → uk-OXQSdzuT.js} +3 -3
- package/dist/assets/{useAppFontEffects-BRMf55oN.js → useAppFontEffects-CqXrCJVt.js} +63 -58
- package/dist/assets/useAppFontEffects-K31q-1OV.css +1 -0
- package/dist/assets/useAssistantUIStore-jOKVcBK8.js +1 -0
- package/dist/assets/useDesktopWindowControlsLayout-KH4UP7Gj.js +1 -0
- package/dist/assets/{useDictation-Sk20Gi0T.js → useDictation-Bs7TWO9r.js} +1 -1
- package/dist/assets/useEffectiveDirectory-CCKRdyK9.js +1 -0
- package/dist/assets/useFontPreferences-CPrl1_3z.js +1 -0
- package/dist/assets/{useMobileHtmlPreviewStore-C03uVLfX.js → useMobileHtmlPreviewStore-EOAzZiAy.js} +1 -1
- package/dist/assets/useMobileNavigationStore-BNtVrnSw.js +13 -0
- package/dist/assets/usePluginsStore-bMuGciUE.js +1 -0
- package/dist/assets/useProjectRuntimeAPIs-BFCXBu2J.js +1 -0
- package/dist/assets/{useStreamingTextThrottle-CjMALEr7.js → useStreamingTextThrottle-C8xAqcgP.js} +1 -1
- package/dist/assets/{useThemeSystem-CNzUUkFn.js → useThemeSystem-C57Z9mV2.js} +1 -1
- package/dist/assets/useUIStore-Cfmg-aDQ.js +1 -0
- package/dist/assets/uuid-D-SDZijH.js +1 -0
- package/dist/assets/{vendor-base-ui-CzHs0bHY.js → vendor-base-ui-z2M4boRm.js} +1 -1
- package/dist/assets/{vendor-cmdk-C_tivUtr.js → vendor-cmdk-BgHvMv5l.js} +1 -1
- package/dist/assets/{vendor-dnd-kit-accessibility-BOtnpZt5.js → vendor-dnd-kit-accessibility-gVi9ga0x.js} +1 -1
- package/dist/assets/{vendor-dnd-kit-core-DK4OoOTr.js → vendor-dnd-kit-core-Dd5yS2-T.js} +1 -1
- package/dist/assets/{vendor-dnd-kit-sortable-Cv69eQm1.js → vendor-dnd-kit-sortable-CV-SGi8y.js} +1 -1
- package/dist/assets/{vendor-framer-motion-DDMKlXiP.js → vendor-framer-motion-CF9BQLta.js} +1 -1
- package/dist/assets/{vendor-markstream-react-6zxyQLCD.js → vendor-markstream-react-TwEpkgfP.js} +3 -3
- package/dist/assets/vendor-motion-Dv27UnOI.js +1 -0
- package/dist/assets/{vendor-pierre-diffs-BFiZ3IhI.js → vendor-pierre-diffs-tqo4Z3TC.js} +1 -1
- package/dist/assets/{vendor-react-DlzBev0S.js → vendor-react-P8wFrkcT.js} +1 -1
- package/dist/assets/{vendor-react-drawio-Dyg1-39Q.js → vendor-react-drawio-CQW1YP2l.js} +1 -1
- package/dist/assets/vendor-reactuses-core-Dyjw5sZR.js +1 -0
- package/dist/assets/{vendor-sonner-BEHGipm5.js → vendor-sonner-B5HgJenP.js} +1 -1
- package/dist/assets/{vendor-stream-diffs-wcQxoPZk.js → vendor-stream-diffs-DCMtZcS3.js} +2 -2
- package/dist/assets/vendor-tanstack-query-core-BSjXNgF_.js +1 -0
- package/dist/assets/vendor-tanstack-react-query-B-KblYBV.js +1 -0
- package/dist/assets/{vendor-tanstack-react-virtual-DSFNK3qc.js → vendor-tanstack-react-virtual-BkuqzrEV.js} +1 -1
- package/dist/assets/{vendor-zustand-vDaAPGfl.js → vendor-zustand-Cwko4FG1.js} +1 -1
- package/dist/assets/{zh-CN-ieAs59w6.js → zh-CN-B5X8yCZV.js} +3 -3
- package/dist/assets/{zh-TW-WWTW1fkP.js → zh-TW-CF6zr1fk.js} +3 -3
- package/dist/index.html +32 -27
- package/dist/mini-chat.html +32 -27
- package/dist/mobile.html +2 -2
- package/package.json +3 -2
- package/server/index.d.ts +19 -0
- package/server/index.js +35 -5
- package/server/lib/assistants/builtin-skills.js +1 -1
- package/server/lib/assistants/builtin-skills.test.js +2 -0
- package/server/lib/client-auth/remote-clients.js +11 -0
- package/server/lib/content-search/DOCUMENTATION.md +5 -0
- package/server/lib/content-search/routes.js +4 -0
- package/server/lib/content-search/routes.test.js +10 -0
- package/server/lib/event-stream/DOCUMENTATION.md +5 -0
- package/server/lib/event-stream/runtime.js +3 -0
- package/server/lib/event-stream/upstream-reader.js +1 -1
- package/server/lib/gui-customization/DOCUMENTATION.md +25 -1
- package/server/lib/gui-customization/projects-client.mjs +59 -0
- package/server/lib/gui-customization/projects.js +43 -0
- package/server/lib/gui-customization/projects.test.js +103 -0
- package/server/lib/gui-customization/remote-connections-client.mjs +2 -8
- package/server/lib/gui-customization/session-skill-command.mjs +8 -0
- package/server/lib/gui-customization/session-skill.js +15 -10
- package/server/lib/gui-customization/session-skill.test.js +21 -2
- package/server/lib/gui-customization/skill/SKILL.md +3 -1
- package/server/lib/gui-customization/skill/references/projects.md +63 -0
- package/server/lib/gui-customization/skill/references/remote-connections.md +11 -0
- package/server/lib/message-queue/DOCUMENTATION.md +4 -0
- package/server/lib/message-queue/service.js +2 -1
- package/server/lib/message-queue/service.test.js +11 -0
- package/server/lib/notifications/DOCUMENTATION.md +12 -0
- package/server/lib/notifications/emitter-runtime.js +5 -0
- package/server/lib/notifications/runtime.js +20 -2
- package/server/lib/notifications/runtime.test.js +21 -0
- package/server/lib/notifications/session-unread-runtime.js +51 -13
- package/server/lib/notifications/session-unread.test.js +113 -1
- package/server/lib/opencode/DOCUMENTATION.md +28 -0
- package/server/lib/opencode/core-routes.js +16 -3
- package/server/lib/opencode/core-routes.test.js +28 -0
- package/server/lib/opencode/feature-routes-runtime.js +12 -1
- package/server/lib/opencode/feature-routes-runtime.test.js +4 -0
- package/server/lib/opencode/proxy.js +1 -0
- package/server/lib/opencode/routes.js +18 -4
- package/server/lib/opencode/routes.test.js +22 -0
- package/server/lib/opencode/settings-helpers.js +26 -0
- package/server/lib/opencode/settings-helpers.test.js +20 -0
- package/server/lib/opencode/settings-runtime.js +5 -3
- package/server/lib/opencode/settings-runtime.test.js +35 -0
- package/server/lib/preview/DOCUMENTATION.md +73 -0
- package/server/lib/preview/file-preview-path.js +37 -0
- package/server/lib/preview/file-target.js +38 -0
- package/server/lib/preview/file-target.test.js +111 -0
- package/server/lib/preview/proxy-runtime.js +110 -17
- package/server/lib/projects/DOCUMENTATION.md +12 -3
- package/server/lib/relay/tunnel-host.js +1 -0
- package/server/lib/remote-hosts/DOCUMENTATION.md +269 -0
- package/server/lib/remote-hosts/configuration.js +15 -0
- package/server/lib/remote-hosts/deadline.js +22 -0
- package/server/lib/remote-hosts/deadline.test.js +64 -0
- package/server/lib/remote-hosts/fixtures/settings-server.mjs +26 -0
- package/server/lib/remote-hosts/gateway.js +644 -0
- package/server/lib/remote-hosts/json-lifecycle.test.js +55 -0
- package/server/lib/remote-hosts/preview-scope.js +23 -0
- package/server/lib/remote-hosts/relay-client.ts +3 -0
- package/server/lib/remote-hosts/routes.js +432 -0
- package/server/lib/remote-hosts/routes.test.js +1176 -0
- package/server/lib/remote-hosts/settings-production.test.js +145 -0
- package/server/lib/remote-hosts/store.js +110 -0
- package/server/lib/remote-hosts/store.test.js +33 -0
- package/server/lib/remote-hosts/transport.js +113 -0
- package/server/lib/scheduled-tasks/session-skill.js +2 -1
- package/server/lib/scheduled-tasks/session-skill.test.js +34 -1
- package/server/lib/session-folders/routes.js +1 -0
- package/server/lib/session-index/DOCUMENTATION.md +4 -1
- package/server/lib/session-index/event-ingest.js +8 -0
- package/server/lib/session-index/event-ingest.test.js +16 -0
- package/server/lib/session-index/service.js +1 -0
- package/server/lib/session-index/service.test.js +3 -1
- package/server/lib/session-metadata/DOCUMENTATION.md +18 -1
- package/server/lib/session-title/DOCUMENTATION.md +3 -0
- package/server/lib/session-title/runtime.js +1 -0
- package/server/lib/session-title/runtime.test.js +2 -0
- package/server/lib/transcript-cache/DOCUMENTATION.md +4 -0
- package/server/lib/transcript-cache/routes.js +3 -0
- package/server/lib/transcript-cache/service.js +15 -0
- package/server/lib/transcript-cache/service.test.js +13 -0
- package/server/lib/ui-auth/DOCUMENTATION.md +18 -0
- package/server/lib/ui-auth/ui-auth.js +30 -2
- package/server/lib/ui-auth/ui-auth.test.js +46 -1
- package/dist/assets/AssistantConversationSurface-CW3U6Lhp.js +0 -3
- package/dist/assets/DiagramView-CzhdZEw4.js +0 -1
- package/dist/assets/GuiPluginSurface-BG3hENTt.js +0 -1
- package/dist/assets/LoadingImage-DmucvXdY.js +0 -1
- package/dist/assets/MarkdownRenderer-BkOMcK8x.js +0 -2
- package/dist/assets/MarkdownRendererImpl-B5vJtPoa.js +0 -10
- package/dist/assets/MarkstreamRendererImpl-1J-Gu2M2.js +0 -3
- package/dist/assets/MobileDetailNavigation-48o8aG28.js +0 -1
- package/dist/assets/MobileShareBridge-DnYT3Dbz.js +0 -3
- package/dist/assets/MobileTabPageHeader-D6kqRFm0.js +0 -2
- package/dist/assets/OnboardingScreen-Bn0RgrJU.js +0 -1
- package/dist/assets/SettingsView-Bla2lVqS.js +0 -29
- package/dist/assets/SetupTourDialog-GDRS3gDa.js +0 -1
- package/dist/assets/TerminalView-B1u3s7IN.js +0 -8
- package/dist/assets/ToolOutputDialog-CYUPmbtq.js +0 -10
- package/dist/assets/VoiceSettings-Dy6-nkQo.js +0 -2
- package/dist/assets/YuriWordmark--S-QEpRp.js +0 -1
- package/dist/assets/appThemeRegistry--G1XaYmo.js +0 -1
- package/dist/assets/bootstrap-BhC95qVC.js +0 -1
- package/dist/assets/fileQueries-D9l0crnM.js +0 -1
- package/dist/assets/fileReferenceActions-BmquJskG.js +0 -1
- package/dist/assets/gitApiHttp-D4d-rgcR.js +0 -9
- package/dist/assets/historyImportQueries-DkB2_92i.js +0 -1
- package/dist/assets/host-kMLXU0hK.js +0 -1
- package/dist/assets/image-loading-BrDob6MW.js +0 -1
- package/dist/assets/insertionBoundaries-CB4gv9rr.js +0 -1
- package/dist/assets/main-B1KrAdkh.js +0 -2
- package/dist/assets/main-Caf-6KmT.js +0 -169
- package/dist/assets/mcpQueries-CQyOFjX2.js +0 -1
- package/dist/assets/miniChat-zEoOVjOQ.js +0 -2
- package/dist/assets/mobile-Dt8wAkc4.js +0 -2
- package/dist/assets/mobileBackNavigation-BbKMa0Jb.js +0 -1
- package/dist/assets/mobileConnections-CXYj4P9M.js +0 -2
- package/dist/assets/multirun-9v2r_beX.js +0 -3
- package/dist/assets/pathNormalization-ewtPqJWn.js +0 -1
- package/dist/assets/platform-DMsFWy1a.js +0 -1
- package/dist/assets/projectActions-C-9Z8R7y.js +0 -1
- package/dist/assets/projectMeta-ZouOo-T_.js +0 -1
- package/dist/assets/pwa-syKJBLoe.js +0 -2
- package/dist/assets/queue-abort-optimistic-BYH5yLM2.js +0 -1
- package/dist/assets/renderElectronMiniChatApp-DprABvit.js +0 -2
- package/dist/assets/renderMobileApp-DQmX6iak.js +0 -29
- package/dist/assets/runtime-file-resource-CL7EVzOG.js +0 -2
- package/dist/assets/runtimeConfig-7Umh9QWi.js +0 -2
- package/dist/assets/runtimeEndpointReset-BYtLmSuX.js +0 -149
- package/dist/assets/scheduledTaskNavigation-FMDNRUnX.js +0 -1
- package/dist/assets/sessionLookup-D_fPlqqT.js +0 -1
- package/dist/assets/sortable-tabs-strip-BclS0Hnd.js +0 -1
- package/dist/assets/src-HgtAe3Q4.css +0 -2
- package/dist/assets/terminalApi-DK4KmfFn.js +0 -1
- package/dist/assets/touch-gestures-CErgaXZ7.js +0 -1
- package/dist/assets/tour-DDI0Zg7l.js +0 -1
- package/dist/assets/useAppFontEffects-RpgNbjA4.css +0 -1
- package/dist/assets/useAssistantUIStore-nNYL140o.js +0 -1
- package/dist/assets/useDesktopWindowControlsLayout-Bq9DFNYn.js +0 -1
- package/dist/assets/useEffectiveDirectory-5RwQ_nuK.js +0 -1
- package/dist/assets/useFontPreferences-DxzruDDQ.js +0 -1
- package/dist/assets/useMobileNavigationStore-ePbEoQwb.js +0 -17
- package/dist/assets/usePluginsStore-HJJZ65gd.js +0 -1
- package/dist/assets/useUIStore-vvNwcOk3.js +0 -1
- package/dist/assets/useWorkerHighlightedLines-6x1R4afJ.js +0 -7
- package/dist/assets/vendor-motion-C9oiAdx-.js +0 -1
- package/dist/assets/vendor-reactuses-core-CuTmqEMK.js +0 -1
- package/dist/assets/vendor-tanstack-query-core-Y_YoRHtC.js +0 -1
- package/dist/assets/vendor-tanstack-react-query-B-Wpqq5J.js +0 -1
package/dist/index.html
CHANGED
|
@@ -571,7 +571,7 @@
|
|
|
571
571
|
opacity: 0.72;
|
|
572
572
|
}
|
|
573
573
|
</style>
|
|
574
|
-
<script type="module" crossorigin src="/assets/main-
|
|
574
|
+
<script type="module" crossorigin src="/assets/main-BMFY9mtb.js"></script>
|
|
575
575
|
<link rel="modulepreload" crossorigin href="/assets/modulepreload-polyfill-P2Xu9kJm.js">
|
|
576
576
|
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-hePW80VL.js">
|
|
577
577
|
<link rel="modulepreload" crossorigin href="/assets/vendor-aparajita-capacitor-secure-storage-xol_6BsB.js">
|
|
@@ -580,36 +580,41 @@
|
|
|
580
580
|
<link rel="modulepreload" crossorigin href="/assets/reasoning-projection-client-BEhVknv9.js">
|
|
581
581
|
<link rel="modulepreload" crossorigin href="/assets/runtime-fetch-DKZOpfzo.js">
|
|
582
582
|
<link rel="modulepreload" crossorigin href="/assets/runtimeAPIRegistry-C2VogTny.js">
|
|
583
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
584
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
585
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
586
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
587
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
588
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
589
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-opencode-client-cQ47ywrT.js">
|
|
583
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-pathe-vBmvQE8f.js">
|
|
584
|
+
<link rel="modulepreload" crossorigin href="/assets/platform-wF65ZFgV.js">
|
|
585
|
+
<link rel="modulepreload" crossorigin href="/assets/desktopHosts-135cuRCE.js">
|
|
586
|
+
<link rel="modulepreload" crossorigin href="/assets/desktopRelayRestore-1aUztDPU.js">
|
|
587
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-base-ui-z2M4boRm.js">
|
|
588
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-zustand-Cwko4FG1.js">
|
|
590
589
|
<link rel="modulepreload" crossorigin href="/assets/brand-storage-migration-Bhz6UOBJ.js">
|
|
591
590
|
<link rel="modulepreload" crossorigin href="/assets/brand-storage-bootstrap-D4BW3w-M.js">
|
|
592
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
593
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
594
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
595
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
596
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-query-core-
|
|
597
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-react-query-B-
|
|
598
|
-
<link rel="modulepreload" crossorigin href="/assets/fileQueries-D9l0crnM.js">
|
|
599
|
-
<link rel="modulepreload" crossorigin href="/assets/runtime-file-store-BVRgEtI-.js">
|
|
591
|
+
<link rel="modulepreload" crossorigin href="/assets/safeStorage-DTOhKN0V.js">
|
|
592
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-effect-X1Hqc7ba.js">
|
|
593
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-opencode-client-cQ47ywrT.js">
|
|
594
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-react-P8wFrkcT.js">
|
|
595
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-query-core-BSjXNgF_.js">
|
|
596
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-react-query-B-KblYBV.js">
|
|
600
597
|
<link rel="modulepreload" crossorigin href="/assets/path-utils-jGozTg9d.js">
|
|
601
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
598
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-lodash-es-BS45jPoZ.js">
|
|
599
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-js-cookie-hSOiFTtX.js">
|
|
600
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-reactuses-core-Dyjw5sZR.js">
|
|
601
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-store-BVRgEtI-.js">
|
|
602
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-resource-CuLP3xp7.js">
|
|
603
|
+
<link rel="modulepreload" crossorigin href="/assets/prompt-attachment-upload-BNhDXymd.js">
|
|
604
|
+
<link rel="modulepreload" crossorigin href="/assets/client-uz8O6TPX.js">
|
|
605
|
+
<link rel="modulepreload" crossorigin href="/assets/useMobileHtmlPreviewStore-EOAzZiAy.js">
|
|
606
|
+
<link rel="modulepreload" crossorigin href="/assets/useUIStore-Cfmg-aDQ.js">
|
|
607
|
+
<link rel="modulepreload" crossorigin href="/assets/uuid-D-SDZijH.js">
|
|
608
|
+
<link rel="modulepreload" crossorigin href="/assets/gitApiHttp-DvTBxvX8.js">
|
|
609
|
+
<link rel="modulepreload" crossorigin href="/assets/terminalApi-madXrfqA.js">
|
|
610
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-download-D11Nnedg.js">
|
|
611
|
+
<link rel="modulepreload" crossorigin href="/assets/types-CHszLAS3.js">
|
|
612
|
+
<link rel="modulepreload" crossorigin href="/assets/capgoAdapter-CCLtBZL1.js">
|
|
613
|
+
<link rel="modulepreload" crossorigin href="/assets/native-config-DOawZfln.js">
|
|
602
614
|
<link rel="modulepreload" crossorigin href="/assets/runtime-ead7P81A.js">
|
|
603
|
-
<link rel="modulepreload" crossorigin href="/assets/bootstrap-
|
|
604
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
605
|
-
<link rel="
|
|
606
|
-
<link rel="modulepreload" crossorigin href="/assets/terminalApi-DK4KmfFn.js">
|
|
607
|
-
<link rel="modulepreload" crossorigin href="/assets/runtime-file-download-DMY1k1af.js">
|
|
608
|
-
<link rel="modulepreload" crossorigin href="/assets/types-wnqkJWYs.js">
|
|
609
|
-
<link rel="modulepreload" crossorigin href="/assets/capgoAdapter-DO1rEVQf.js">
|
|
610
|
-
<link rel="modulepreload" crossorigin href="/assets/native-config-BOaqa45X.js">
|
|
611
|
-
<link rel="modulepreload" crossorigin href="/assets/runtimeConfig-7Umh9QWi.js">
|
|
612
|
-
<link rel="stylesheet" crossorigin href="/assets/src-HgtAe3Q4.css">
|
|
615
|
+
<link rel="modulepreload" crossorigin href="/assets/bootstrap-eLlfzqAI.js">
|
|
616
|
+
<link rel="modulepreload" crossorigin href="/assets/runtimeConfig-tHm7o_0I.js">
|
|
617
|
+
<link rel="stylesheet" crossorigin href="/assets/src-BZCFf9_1.css">
|
|
613
618
|
</head>
|
|
614
619
|
<body class="h-full bg-background text-foreground">
|
|
615
620
|
<!-- Keep the startup layer outside #root. React replaces every child of
|
package/dist/mini-chat.html
CHANGED
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
.dark #initial-loading img { filter: invert(1); }
|
|
78
78
|
</style>
|
|
79
79
|
|
|
80
|
-
<script type="module" crossorigin src="/assets/miniChat-
|
|
80
|
+
<script type="module" crossorigin src="/assets/miniChat-BbJ0GKpk.js"></script>
|
|
81
81
|
<link rel="modulepreload" crossorigin href="/assets/modulepreload-polyfill-P2Xu9kJm.js">
|
|
82
82
|
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-hePW80VL.js">
|
|
83
83
|
<link rel="modulepreload" crossorigin href="/assets/vendor-aparajita-capacitor-secure-storage-xol_6BsB.js">
|
|
@@ -86,36 +86,41 @@
|
|
|
86
86
|
<link rel="modulepreload" crossorigin href="/assets/reasoning-projection-client-BEhVknv9.js">
|
|
87
87
|
<link rel="modulepreload" crossorigin href="/assets/runtime-fetch-DKZOpfzo.js">
|
|
88
88
|
<link rel="modulepreload" crossorigin href="/assets/runtimeAPIRegistry-C2VogTny.js">
|
|
89
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
90
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
91
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
92
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
93
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
94
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
95
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-opencode-client-cQ47ywrT.js">
|
|
89
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-pathe-vBmvQE8f.js">
|
|
90
|
+
<link rel="modulepreload" crossorigin href="/assets/platform-wF65ZFgV.js">
|
|
91
|
+
<link rel="modulepreload" crossorigin href="/assets/desktopHosts-135cuRCE.js">
|
|
92
|
+
<link rel="modulepreload" crossorigin href="/assets/desktopRelayRestore-1aUztDPU.js">
|
|
93
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-base-ui-z2M4boRm.js">
|
|
94
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-zustand-Cwko4FG1.js">
|
|
96
95
|
<link rel="modulepreload" crossorigin href="/assets/brand-storage-migration-Bhz6UOBJ.js">
|
|
97
96
|
<link rel="modulepreload" crossorigin href="/assets/brand-storage-bootstrap-D4BW3w-M.js">
|
|
98
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
99
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
100
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
101
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-
|
|
102
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-query-core-
|
|
103
|
-
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-react-query-B-
|
|
104
|
-
<link rel="modulepreload" crossorigin href="/assets/fileQueries-D9l0crnM.js">
|
|
105
|
-
<link rel="modulepreload" crossorigin href="/assets/runtime-file-store-BVRgEtI-.js">
|
|
97
|
+
<link rel="modulepreload" crossorigin href="/assets/safeStorage-DTOhKN0V.js">
|
|
98
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-effect-X1Hqc7ba.js">
|
|
99
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-opencode-client-cQ47ywrT.js">
|
|
100
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-react-P8wFrkcT.js">
|
|
101
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-query-core-BSjXNgF_.js">
|
|
102
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-tanstack-react-query-B-KblYBV.js">
|
|
106
103
|
<link rel="modulepreload" crossorigin href="/assets/path-utils-jGozTg9d.js">
|
|
107
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
104
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-lodash-es-BS45jPoZ.js">
|
|
105
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-js-cookie-hSOiFTtX.js">
|
|
106
|
+
<link rel="modulepreload" crossorigin href="/assets/vendor-reactuses-core-Dyjw5sZR.js">
|
|
107
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-store-BVRgEtI-.js">
|
|
108
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-resource-CuLP3xp7.js">
|
|
109
|
+
<link rel="modulepreload" crossorigin href="/assets/prompt-attachment-upload-BNhDXymd.js">
|
|
110
|
+
<link rel="modulepreload" crossorigin href="/assets/client-uz8O6TPX.js">
|
|
111
|
+
<link rel="modulepreload" crossorigin href="/assets/useMobileHtmlPreviewStore-EOAzZiAy.js">
|
|
112
|
+
<link rel="modulepreload" crossorigin href="/assets/useUIStore-Cfmg-aDQ.js">
|
|
113
|
+
<link rel="modulepreload" crossorigin href="/assets/uuid-D-SDZijH.js">
|
|
114
|
+
<link rel="modulepreload" crossorigin href="/assets/gitApiHttp-DvTBxvX8.js">
|
|
115
|
+
<link rel="modulepreload" crossorigin href="/assets/terminalApi-madXrfqA.js">
|
|
116
|
+
<link rel="modulepreload" crossorigin href="/assets/runtime-file-download-D11Nnedg.js">
|
|
117
|
+
<link rel="modulepreload" crossorigin href="/assets/types-CHszLAS3.js">
|
|
118
|
+
<link rel="modulepreload" crossorigin href="/assets/capgoAdapter-CCLtBZL1.js">
|
|
119
|
+
<link rel="modulepreload" crossorigin href="/assets/native-config-DOawZfln.js">
|
|
108
120
|
<link rel="modulepreload" crossorigin href="/assets/runtime-ead7P81A.js">
|
|
109
|
-
<link rel="modulepreload" crossorigin href="/assets/bootstrap-
|
|
110
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
111
|
-
<link rel="
|
|
112
|
-
<link rel="modulepreload" crossorigin href="/assets/terminalApi-DK4KmfFn.js">
|
|
113
|
-
<link rel="modulepreload" crossorigin href="/assets/runtime-file-download-DMY1k1af.js">
|
|
114
|
-
<link rel="modulepreload" crossorigin href="/assets/types-wnqkJWYs.js">
|
|
115
|
-
<link rel="modulepreload" crossorigin href="/assets/capgoAdapter-DO1rEVQf.js">
|
|
116
|
-
<link rel="modulepreload" crossorigin href="/assets/native-config-BOaqa45X.js">
|
|
117
|
-
<link rel="modulepreload" crossorigin href="/assets/runtimeConfig-7Umh9QWi.js">
|
|
118
|
-
<link rel="stylesheet" crossorigin href="/assets/src-HgtAe3Q4.css">
|
|
121
|
+
<link rel="modulepreload" crossorigin href="/assets/bootstrap-eLlfzqAI.js">
|
|
122
|
+
<link rel="modulepreload" crossorigin href="/assets/runtimeConfig-tHm7o_0I.js">
|
|
123
|
+
<link rel="stylesheet" crossorigin href="/assets/src-BZCFf9_1.css">
|
|
119
124
|
</head>
|
|
120
125
|
<body class="h-full bg-background text-foreground">
|
|
121
126
|
<div id="root" class="h-full">
|
package/dist/mobile.html
CHANGED
|
@@ -64,11 +64,11 @@
|
|
|
64
64
|
</script>
|
|
65
65
|
|
|
66
66
|
<style>.dark #mobile-startup-logo img { filter: invert(1); }</style>
|
|
67
|
-
<script type="module" crossorigin src="/assets/mobile-
|
|
67
|
+
<script type="module" crossorigin src="/assets/mobile-_zUth69Z.js"></script>
|
|
68
68
|
<link rel="modulepreload" crossorigin href="/assets/modulepreload-polyfill-P2Xu9kJm.js">
|
|
69
69
|
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-hePW80VL.js">
|
|
70
70
|
<link rel="modulepreload" crossorigin href="/assets/vendor-aparajita-capacitor-secure-storage-xol_6BsB.js">
|
|
71
|
-
<link rel="stylesheet" crossorigin href="/assets/src-
|
|
71
|
+
<link rel="stylesheet" crossorigin href="/assets/src-BZCFf9_1.css">
|
|
72
72
|
</head>
|
|
73
73
|
<body class="h-full bg-background text-foreground">
|
|
74
74
|
<div id="root" class="h-full">
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yuriai/web",
|
|
3
|
-
"version": "0.2.40-beta.
|
|
3
|
+
"version": "0.2.40-beta.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./server/index.js",
|
|
@@ -16,7 +16,8 @@
|
|
|
16
16
|
"dev:server": "bun run build:llm-bridge && node ../../scripts/ensure-node-better-sqlite3.mjs && cross-env NODE_ENV=development node server/index.js --port ${YURI_PORT:-3001}",
|
|
17
17
|
"dev:server:watch": "bun run build:llm-bridge && nodemon --exitcrash --watch server --ext js --exec \"node ../../scripts/ensure-node-better-sqlite3.mjs && cross-env NODE_ENV=development node server/index.js --port ${YURI_PORT:-3001}\"",
|
|
18
18
|
"build": "bun run build:llm-bridge && vite build",
|
|
19
|
-
"build:llm-bridge": "bun scripts/build-llm-bridge.mjs",
|
|
19
|
+
"build:llm-bridge": "bun scripts/build-llm-bridge.mjs && bun run build:remote-host-relay",
|
|
20
|
+
"build:remote-host-relay": "bun scripts/build-remote-host-relay.mjs",
|
|
20
21
|
"prepack": "bun run build:llm-bridge",
|
|
21
22
|
"build:watch": "vite build --watch",
|
|
22
23
|
"type-check": "tsc --noEmit",
|
package/server/index.d.ts
CHANGED
|
@@ -20,6 +20,12 @@ export interface WebUiServerController {
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
export interface StartWebUiServerOptions {
|
|
23
|
+
/** Host-owned credentials stay process-local. Never forward this adapter through IPC. */
|
|
24
|
+
remoteHostsAdapter?: {
|
|
25
|
+
listHosts: () => Promise<RemoteHostDescriptor[]> | RemoteHostDescriptor[];
|
|
26
|
+
prepareHost?: (hostId: string) => Promise<RemoteHostDescriptor>;
|
|
27
|
+
subscribe?: (listener: () => void) => () => void;
|
|
28
|
+
};
|
|
23
29
|
port?: number;
|
|
24
30
|
host?: string;
|
|
25
31
|
attachSignals?: boolean;
|
|
@@ -63,6 +69,19 @@ export interface StartWebUiServerOptions {
|
|
|
63
69
|
settingsPersistLock?: <T>(work: () => Promise<T> | T) => Promise<T>;
|
|
64
70
|
}
|
|
65
71
|
|
|
72
|
+
export interface RemoteHostDescriptor {
|
|
73
|
+
id: string;
|
|
74
|
+
name?: string;
|
|
75
|
+
label?: string;
|
|
76
|
+
source: 'ssh' | 'relay' | 'direct';
|
|
77
|
+
apiUrl?: string;
|
|
78
|
+
url?: string;
|
|
79
|
+
clientToken?: string;
|
|
80
|
+
requestHeaders?: Record<string, string>;
|
|
81
|
+
pairingSource?: string;
|
|
82
|
+
relay?: { relayUrl: string; serverId: string; hostEncPubJwk: JsonWebKey };
|
|
83
|
+
}
|
|
84
|
+
|
|
66
85
|
export declare function startWebUiServer(
|
|
67
86
|
options?: StartWebUiServerOptions
|
|
68
87
|
): Promise<WebUiServerController>;
|
package/server/index.js
CHANGED
|
@@ -50,6 +50,7 @@ import { createThemeRuntime } from './lib/opencode/theme-runtime.js';
|
|
|
50
50
|
import { createFeatureRoutesRuntime } from './lib/opencode/feature-routes-runtime.js';
|
|
51
51
|
import { parseServeCliOptions } from './lib/opencode/cli-options.js';
|
|
52
52
|
import {
|
|
53
|
+
redactRequestPathForLog,
|
|
53
54
|
registerAuthAndAccessRoutes,
|
|
54
55
|
registerCommonRequestMiddleware,
|
|
55
56
|
registerServerStatusRoutes,
|
|
@@ -127,6 +128,10 @@ import { createPreviewProxyRuntime } from './lib/preview/proxy-runtime.js';
|
|
|
127
128
|
import { attachRealtimeProxy } from './lib/realtime-proxy.js';
|
|
128
129
|
import { createRelayService, isRelayHostRuntime, resolveEffectiveRelayUrl } from './lib/relay/service.js';
|
|
129
130
|
import { createRelayHostLock } from './lib/relay/host-lock.js';
|
|
131
|
+
import { createRemoteHostStore } from './lib/remote-hosts/store.js';
|
|
132
|
+
import { createRemoteHostGateway } from './lib/remote-hosts/gateway.js';
|
|
133
|
+
import { registerRemoteHostRoutes } from './lib/remote-hosts/routes.js';
|
|
134
|
+
import { classifyRuntimeVersionBand, RUNTIME_CONTRACT_MIN_VERIFIED } from './lib/opencode/runtime-contract.js';
|
|
130
135
|
import { createProxyMiddleware, responseInterceptor } from 'http-proxy-middleware';
|
|
131
136
|
import webPush from 'web-push';
|
|
132
137
|
|
|
@@ -138,6 +143,7 @@ const DESKTOP_NOTIFY_PREFIX = '[YuriDesktopNotify] ';
|
|
|
138
143
|
const uiNotificationClients = new Set();
|
|
139
144
|
const uiNotificationWsClients = new Set();
|
|
140
145
|
const uiYuriEventClients = new Set();
|
|
146
|
+
let remoteHostInstanceId = null;
|
|
141
147
|
const HEALTH_CHECK_INTERVAL = 15000;
|
|
142
148
|
const SHUTDOWN_TIMEOUT = 10000;
|
|
143
149
|
const CLIENT_RELOAD_DELAY_MS = 800;
|
|
@@ -345,10 +351,11 @@ const settingsRuntime = createSettingsRuntime({
|
|
|
345
351
|
normalizeStringArray,
|
|
346
352
|
formatSettingsResponse,
|
|
347
353
|
resolveDirectoryCandidate,
|
|
348
|
-
onProjectOrderChanged: () =>
|
|
349
|
-
|
|
350
|
-
writeSseEvent
|
|
351
|
-
|
|
354
|
+
onProjectOrderChanged: () => {
|
|
355
|
+
const event = { type: 'yuri:project-order-changed', properties: { occurredAt: Date.now() } };
|
|
356
|
+
createYuriEventBroadcaster({ getYuriEventClients: () => uiYuriEventClients, writeSseEvent })(event);
|
|
357
|
+
broadcastGlobalUiEvent(event);
|
|
358
|
+
},
|
|
352
359
|
});
|
|
353
360
|
|
|
354
361
|
const readSettingsFromDiskMigrated = (...args) => settingsRuntime.readSettingsFromDiskMigrated(...args);
|
|
@@ -425,6 +432,7 @@ const notificationEmitterRuntime = createNotificationEmitterRuntime({
|
|
|
425
432
|
desktopNotifyPrefix: DESKTOP_NOTIFY_PREFIX,
|
|
426
433
|
getUiNotificationClients: () => uiNotificationClients,
|
|
427
434
|
getBroadcastGlobalUiEvent: () => broadcastGlobalUiEvent,
|
|
435
|
+
getInstanceId: () => remoteHostInstanceId,
|
|
428
436
|
});
|
|
429
437
|
|
|
430
438
|
const writeSseEvent = (...args) => notificationEmitterRuntime.writeSseEvent(...args);
|
|
@@ -1609,7 +1617,7 @@ async function main(options = {}) {
|
|
|
1609
1617
|
});
|
|
1610
1618
|
if (req.method === 'OPTIONS') {
|
|
1611
1619
|
if (YURI_VERBOSE_REQUEST_LOGS) {
|
|
1612
|
-
console.log(`${new Date().toISOString()} - ${req.method} ${req.path}`);
|
|
1620
|
+
console.log(`${new Date().toISOString()} - ${req.method} ${redactRequestPathForLog(req.path)}`);
|
|
1613
1621
|
}
|
|
1614
1622
|
res.status(204).end();
|
|
1615
1623
|
return;
|
|
@@ -1793,6 +1801,26 @@ async function main(options = {}) {
|
|
|
1793
1801
|
}, 0);
|
|
1794
1802
|
}
|
|
1795
1803
|
uiAuthController = bootstrapResult.uiAuthController;
|
|
1804
|
+
const remoteHostStore = createRemoteHostStore(path.join(YURI_DATA_DIR, 'remote-hosts.sqlite'));
|
|
1805
|
+
remoteHostInstanceId = remoteHostStore.hubId;
|
|
1806
|
+
let remoteHostRuntime;
|
|
1807
|
+
const remoteHostGateway = createRemoteHostGateway({
|
|
1808
|
+
store: remoteHostStore,
|
|
1809
|
+
indexDbPath: resolveSessionIndexDbPath({ sessionIndexDbPath: options.sessionIndexDbPath }, YURI_DATA_DIR),
|
|
1810
|
+
adapter: options.remoteHostsAdapter || null,
|
|
1811
|
+
broadcast: (payload, eventOptions) => broadcastGlobalUiEvent(payload, { ...eventOptions,
|
|
1812
|
+
targetFilter: (resource) => remoteHostRuntime?.canReceiveHostEvents(resource) === true }),
|
|
1813
|
+
onNotification: typeof options.onDesktopNotification === 'function' ? options.onDesktopNotification : null,
|
|
1814
|
+
});
|
|
1815
|
+
remoteHostRuntime = registerRemoteHostRoutes(app, {
|
|
1816
|
+
gateway: remoteHostGateway, getAuth: () => uiAuthController, server, isRequestOriginAllowed,
|
|
1817
|
+
remoteClientAuthRuntime, readSettings: readSettingsFromDiskMigrated,
|
|
1818
|
+
persistSettings, validateDirectoryPath, globalEventHub: globalMessageStreamHub,
|
|
1819
|
+
broadcaster: broadcastGlobalUiEvent, supportedRemote: isRelayHostRuntime(), version: YURI_VERSION,
|
|
1820
|
+
getOpenCodeCompatibility: () => ({ version: openCodeServeVersion, ready: isOpenCodeReady,
|
|
1821
|
+
minimumVersion: RUNTIME_CONTRACT_MIN_VERIFIED,
|
|
1822
|
+
compatible: openCodeServeVersion ? classifyRuntimeVersionBand(openCodeServeVersion) === 'verified' : null }),
|
|
1823
|
+
});
|
|
1796
1824
|
const guiNetworkRuntime = attachGuiNetwork({
|
|
1797
1825
|
server, uiAuthController, isRequestOriginAllowed,
|
|
1798
1826
|
isClientActive: async (id) => {
|
|
@@ -1872,6 +1900,7 @@ async function main(options = {}) {
|
|
|
1872
1900
|
relayService.registerRoutes(app);
|
|
1873
1901
|
|
|
1874
1902
|
await featureRoutesRuntime.registerRoutes(app, {
|
|
1903
|
+
getRemoteProjectState: () => ({ hubId: remoteHostStore.hubId, hasRemoteProjects: remoteHostStore.hasProjects() }),
|
|
1875
1904
|
remoteConnectionsAdapter: options.remoteConnectionsAdapter,
|
|
1876
1905
|
express,
|
|
1877
1906
|
uiAuthController,
|
|
@@ -2083,6 +2112,7 @@ async function main(options = {}) {
|
|
|
2083
2112
|
};
|
|
2084
2113
|
},
|
|
2085
2114
|
stop: async (shutdownOptions = {}) => {
|
|
2115
|
+
remoteHostRuntime.stop();
|
|
2086
2116
|
sessionTitleRuntime.stop();
|
|
2087
2117
|
try {
|
|
2088
2118
|
unsubscribeSessionIndexEvents();
|
|
@@ -10,7 +10,7 @@ export function formatAssistantBuiltinSkillsPrompt(tools) {
|
|
|
10
10
|
skills.push('- opencode: For OpenCode itself: configuration, agents, skills, tools, permissions, MCP, providers, plugins, CLI, SDK/API and troubleshooting. Load load_tools({"domain":"opencode.catalog"}), then read_opencode_skill({"id":"opencode"}); continue with nextOffset when partial. Use the current connected catalog, not a copied skill body or a virtual built-in file path.');
|
|
11
11
|
}
|
|
12
12
|
if (names.has('read')) {
|
|
13
|
-
skills.push(`- yuri-customization: For Yuri appearance, themes/CSS/layout, logos/Dock, GUI plugins, pages/tabs, widgets, file previews/exports, panels and settings, or SSH/config-sync/Relay capability boundaries. Load with read({"path":${JSON.stringify(customizationSkillPath)}}), then read only the matching references relative to ${JSON.stringify(path.dirname(customizationSkillPath))}. This contact has no bound local desktop helper for SSH, configuration sync or Relay pairing; those operations are unavailable here. Reading the skill does not create that authorization.`);
|
|
13
|
+
skills.push(`- yuri-customization: For adding a directory as a project in Yuri, appearance, themes/CSS/layout, logos/Dock, GUI plugins, pages/tabs, widgets, file previews/exports, panels and settings, or SSH/config-sync/Relay capability boundaries. Load with read({"path":${JSON.stringify(customizationSkillPath)}}), then read only the matching references relative to ${JSON.stringify(path.dirname(customizationSkillPath))}. Project registration uses granted yuri.projects tools, not a session-bound helper. This contact has no bound local desktop helper for SSH, configuration sync or Relay pairing; those operations are unavailable here. Reading the skill does not create that authorization.`);
|
|
14
14
|
}
|
|
15
15
|
return skills.length > 0 ? [
|
|
16
16
|
'Built-in skills (progressive instructions): load the matching skill before following its workflow. Reading instructions does not mount tools or grant permissions; use the actual contact tools, or assign substantive implementation to a worker with the relevant context.',
|
|
@@ -11,6 +11,8 @@ describe('assistant built-in skill pointers', () => {
|
|
|
11
11
|
expect(prompt).toContain('load_tools({"domain":"opencode.catalog"})');
|
|
12
12
|
expect(prompt).toContain('read_opencode_skill({"id":"opencode"})');
|
|
13
13
|
expect(prompt).toContain('nextOffset');
|
|
14
|
+
expect(prompt).toContain('adding a directory as a project in Yuri');
|
|
15
|
+
expect(prompt).toContain('granted yuri.projects tools');
|
|
14
16
|
expect(prompt).toContain('no bound local desktop helper');
|
|
15
17
|
expect(prompt).toContain('does not create that authorization');
|
|
16
18
|
expect(prompt).not.toContain('.opencode/skills');
|
|
@@ -170,6 +170,7 @@ export const createRemoteClientAuthRuntime = ({ fsPromises, path, crypto, storeP
|
|
|
170
170
|
return withStoreMutation(async () => {
|
|
171
171
|
const store = await readStore();
|
|
172
172
|
const normalizedDedupeKey = normalizeOptionalString(dedupeKey);
|
|
173
|
+
const previousIds = normalizedDedupeKey ? store.clients.map((entry) => entry.id) : [];
|
|
173
174
|
const token = generateToken();
|
|
174
175
|
const client = {
|
|
175
176
|
id: generateId(),
|
|
@@ -204,6 +205,11 @@ export const createRemoteClientAuthRuntime = ({ fsPromises, path, crypto, storeP
|
|
|
204
205
|
}
|
|
205
206
|
store.clients.push(client);
|
|
206
207
|
await writeStore(store);
|
|
208
|
+
for (const id of previousIds) if (!store.clients.some((entry) => entry.id === id)) {
|
|
209
|
+
for (const listener of revocationListeners) {
|
|
210
|
+
try { listener(id); } catch { /* Replacement credentials revoke old active resources independently. */ }
|
|
211
|
+
}
|
|
212
|
+
}
|
|
207
213
|
return { client: publicClient(client), token };
|
|
208
214
|
});
|
|
209
215
|
};
|
|
@@ -222,6 +228,7 @@ export const createRemoteClientAuthRuntime = ({ fsPromises, path, crypto, storeP
|
|
|
222
228
|
});
|
|
223
229
|
};
|
|
224
230
|
|
|
231
|
+
const revocationListeners = new Set();
|
|
225
232
|
const revokeClient = async (id) => {
|
|
226
233
|
if (typeof id !== 'string' || id.trim().length === 0) {
|
|
227
234
|
return { revoked: false };
|
|
@@ -232,6 +239,9 @@ export const createRemoteClientAuthRuntime = ({ fsPromises, path, crypto, storeP
|
|
|
232
239
|
if (!client) return { revoked: false };
|
|
233
240
|
if (!client.revokedAt) client.revokedAt = nowIso();
|
|
234
241
|
await writeStore(store);
|
|
242
|
+
for (const listener of revocationListeners) {
|
|
243
|
+
try { listener(id); } catch { /* Revocation must remain durable even if a consumer has already stopped. */ }
|
|
244
|
+
}
|
|
235
245
|
return { revoked: true, client: publicClient(client) };
|
|
236
246
|
});
|
|
237
247
|
};
|
|
@@ -278,6 +288,7 @@ export const createRemoteClientAuthRuntime = ({ fsPromises, path, crypto, storeP
|
|
|
278
288
|
};
|
|
279
289
|
|
|
280
290
|
return {
|
|
291
|
+
subscribeRevocation(listener) { revocationListeners.add(listener); return () => revocationListeners.delete(listener); },
|
|
281
292
|
authenticateBearerToken,
|
|
282
293
|
createClient,
|
|
283
294
|
listClients,
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# Global conversation content search
|
|
2
2
|
|
|
3
|
+
Remote Project searches execute on their target Host via the Gateway's read-only
|
|
4
|
+
content-search capability. Local search rejects explicit remote Host/Location
|
|
5
|
+
scopes without touching this index. Remote event fanout bypasses local ingestion;
|
|
6
|
+
the Hub never indexes remote conversation bodies.
|
|
7
|
+
|
|
3
8
|
`POST /api/yuri/content-search/resume` authenticates Host UI/client access without
|
|
4
9
|
URL/preview tokens, rejects cross-origin cookie requests, and returns 202 with the
|
|
5
10
|
current index status. It invokes the existing `sync({ resume: true })` in the
|
|
@@ -20,6 +20,10 @@ export function registerContentSearchRoutes(app, { contentSearch, uiAuthControll
|
|
|
20
20
|
});
|
|
21
21
|
app.get('/api/yuri/content-search', (req, res) => {
|
|
22
22
|
if (hasPreviewProxyCredential(req)) return res.status(403).json({ error: 'Forbidden' });
|
|
23
|
+
if (req.query.hostId || req.headers['x-yuri-remote-host']
|
|
24
|
+
|| (typeof req.query.directory === 'string' && req.query.directory.startsWith('yuri-remote-location:'))) {
|
|
25
|
+
return res.status(403).json({ code: 'remote_scope_forbidden', error: 'Use the Host-scoped content search API' });
|
|
26
|
+
}
|
|
23
27
|
if (!contentSearch) return res.status(503).json({ error: 'Global content index unavailable' });
|
|
24
28
|
const query = req.query.q ?? '';
|
|
25
29
|
const limit = req.query.limit === undefined ? 30 : Number(req.query.limit);
|
|
@@ -5,6 +5,16 @@ import { registerContentSearchRoutes } from './routes.js';
|
|
|
5
5
|
import { createContentSearchService } from './service.js';
|
|
6
6
|
import { createContentSearchRuntime } from './runtime.js';
|
|
7
7
|
|
|
8
|
+
test('rejects remote scopes without querying the local content index', async () => {
|
|
9
|
+
const app = express(); const search = vi.fn();
|
|
10
|
+
registerContentSearchRoutes(app, { contentSearch: { service: { search }, getRuntimeKey: () => 'local' } });
|
|
11
|
+
for (const query of [{ hostId: 'remote' }, { directory: 'yuri-remote-location:["hub","host","/repo"]' }]) {
|
|
12
|
+
expect((await request(app).get('/api/yuri/content-search').query(query)).status).toBe(403);
|
|
13
|
+
}
|
|
14
|
+
expect((await request(app).get('/api/yuri/content-search').set('x-yuri-remote-host', 'remote')).status).toBe(403);
|
|
15
|
+
expect(search).not.toHaveBeenCalled();
|
|
16
|
+
});
|
|
17
|
+
|
|
8
18
|
test('exposes durable initialization times through the existing status route', async () => {
|
|
9
19
|
const app = express();
|
|
10
20
|
const service = createContentSearchService({ dbPath: ':memory:' });
|
|
@@ -72,6 +72,11 @@ Native v2 `session.reasoning.*` events are filtered at the same outbound boundar
|
|
|
72
72
|
- Health checks are reserved for initial upstream connect failures and explicit upstream-unavailable responses, not for ordinary stall recovery on an already-established stream.
|
|
73
73
|
- Global synthetic events such as `yuri:session-status`, `yuri:session-activity`, `yuri:notification`, and `yuri:heartbeat` are preserved on the WS path, but heartbeat frames are emitted only while an upstream SSE stream is actively attached.
|
|
74
74
|
- Global UI broadcasts are fan-out capable across both SSE and WS clients.
|
|
75
|
+
- Remote Host envelopes (`yuri:host-*`) fail closed unless the broadcaster receives
|
|
76
|
+
a live `targetFilter`. SSE/WS sends and synthetic-event proxy subscribers apply
|
|
77
|
+
that same filter before serialization. Gateway pairing revocation/expiry clears
|
|
78
|
+
the resource grant; merely opening an unpaired local global stream never grants
|
|
79
|
+
access to remote content.
|
|
75
80
|
- The broadcaster's `subscribe` seam also feeds `/api/event` and `/api/global/event` through the authenticated proxy. Host title/metadata/notification events retain their directory envelope, use the same outbound filter and serialized writer, and can only be interleaved between complete upstream SSE blocks. Pending writes are capped at 2 MiB; overflow disconnects the slow stream. Close/error removes the subscription. Relay uses this same path.
|
|
76
81
|
- Queue event confirmation accepts native `session.inbox.enqueued` user items and `session.inbox.delivered` with exact inbox/session/runtime identity; periodic query reconciliation remains the fallback.
|
|
77
82
|
- Each global upstream connection captures a sanitized runtime fence containing the normalized runtime key plus connection generation and derived token. Queue confirmation uses that generation only to validate the connection runtime identity and read current authority by runtime key. Active and paused authorities confirm exact directory, session, and message matches through the queue service; shadow authority skips confirmation while session-index ingestion continues.
|
|
@@ -27,6 +27,7 @@ export function createGlobalUiEventBroadcaster({
|
|
|
27
27
|
}) {
|
|
28
28
|
const subscribers = new Set();
|
|
29
29
|
const broadcast = (payload, options = {}) => {
|
|
30
|
+
if (/^yuri:host-/.test(payload?.type || '') && typeof options.targetFilter !== 'function') return;
|
|
30
31
|
for (const emit of subscribers) {
|
|
31
32
|
try { emit(payload, options); } catch { /* Other streams remain independent. */ }
|
|
32
33
|
}
|
|
@@ -38,6 +39,7 @@ export function createGlobalUiEventBroadcaster({
|
|
|
38
39
|
|
|
39
40
|
if (hasSseClients) {
|
|
40
41
|
for (const res of sseClients) {
|
|
42
|
+
if (options.targetFilter && !options.targetFilter(res)) continue;
|
|
41
43
|
try {
|
|
42
44
|
writeSseEvent(res, payload);
|
|
43
45
|
} catch {
|
|
@@ -47,6 +49,7 @@ export function createGlobalUiEventBroadcaster({
|
|
|
47
49
|
|
|
48
50
|
if (hasWsClients) {
|
|
49
51
|
for (const socket of Array.from(wsClients)) {
|
|
52
|
+
if (options.targetFilter && !options.targetFilter(socket)) continue;
|
|
50
53
|
const sent = sendMessageStreamWsEvent(socket, payload, {
|
|
51
54
|
directory: typeof options.directory === 'string' && options.directory.length > 0 ? options.directory : 'global',
|
|
52
55
|
eventId: typeof options.eventId === 'string' && options.eventId.length > 0 ? options.eventId : undefined,
|
|
@@ -23,7 +23,7 @@ function waitForReconnectDelay(ms, signal) {
|
|
|
23
23
|
signal?.removeEventListener('abort', onAbort);
|
|
24
24
|
resolve();
|
|
25
25
|
};
|
|
26
|
-
const timeout = setTimeout(finish, Math.max(0, ms));
|
|
26
|
+
const timeout = setTimeout(finish, Math.max(0, typeof ms === 'function' ? ms() : ms));
|
|
27
27
|
const onAbort = () => {
|
|
28
28
|
clearTimeout(timeout);
|
|
29
29
|
finish();
|
|
@@ -13,12 +13,33 @@ run on the Host, so the pointer names the package-local resource directly rather
|
|
|
13
13
|
than staging a Session instruction. It advertises no bound desktop helper and
|
|
14
14
|
grants no SSH/config-sync/Relay capability. Read-only background reviews omit it.
|
|
15
15
|
|
|
16
|
-
References are organized by capability: window APIs, appearance, UI surfaces, plugin styles, global pages, work-status widgets, icons,
|
|
16
|
+
References are organized by capability: project registration, window APIs, appearance, UI surfaces, plugin styles, global pages, work-status widgets, icons,
|
|
17
17
|
file parsing/previews, preview actions/exports, and package workflow. Host contracts
|
|
18
18
|
and verification criteria are separate from illustrative templates and case
|
|
19
19
|
studies. Runmark and Eficy remain integration references; their service protocols,
|
|
20
20
|
renderers and compatibility choices are not requirements for unrelated plugins.
|
|
21
21
|
|
|
22
|
+
`references/projects.md` routes project registration through the bound projects
|
|
23
|
+
API helper, before plugin authoring. Shared-service admission supplies its binding
|
|
24
|
+
independently of Electron's remote-connections adapter. `projects-client.mjs` is
|
|
25
|
+
staged as `projects.mjs`; it and the remote helper share the staged
|
|
26
|
+
`session-skill-command.mjs` command formatter. Only bound helpers are staged, and
|
|
27
|
+
each resource combination has its own content fingerprint. Existing sessions keep
|
|
28
|
+
their immutable staged references until a new session is admitted. Contacts use
|
|
29
|
+
their own granted `yuri.projects` tools, not this session binding.
|
|
30
|
+
|
|
31
|
+
`projects.js` owns `POST /api/yuri/session-skills/projects` (`describe`, `list`,
|
|
32
|
+
`add`). The global gate and route require the existing loopback service credential,
|
|
33
|
+
no browser Origin, shared-service ownership and the session's admitted Host origin.
|
|
34
|
+
The bridge reuses `projects/registry.js`, just like the UI directory API and contact
|
|
35
|
+
tools: strict reads, canonical path deduplication, serialized persistence and
|
|
36
|
+
existing project-order SSE notifications remain with their owners. Registration
|
|
37
|
+
preserves an existing active selection and returns only `{project, created}` after
|
|
38
|
+
persistence, never settings/credentials. List errors remain errors. There is no
|
|
39
|
+
cloning, directory creation, conversation creation or desktop window navigation.
|
|
40
|
+
Web/Electron/connected-mobile shared-service sessions operate on their bound Host;
|
|
41
|
+
private/external OpenCode and standalone VS Code have no session helper admission.
|
|
42
|
+
|
|
22
43
|
`references/plugin-styles.md` inventories existing host CSS variables for plugin-owned
|
|
23
44
|
Solid/DOM content, including colors, typography, geometry, controls and optional
|
|
24
45
|
theme config. The workflow routes every plugin view through this reference. Visual
|
|
@@ -111,6 +132,9 @@ sessions across backend upgrades.
|
|
|
111
132
|
|
|
112
133
|
## Validation
|
|
113
134
|
|
|
135
|
+
`projects.test.js` exercises project bridge validation, authentication, binding,
|
|
136
|
+
persisted idempotent registration and failure receipts. Shared-service admission
|
|
137
|
+
tests execute the exact staged project helper through the real global auth gate.
|
|
114
138
|
`session-skill.test.js` exercises staging, complete resource availability, short
|
|
115
139
|
per-session pointers, managed admission/rollback/adopted sessions and external
|
|
116
140
|
ownership. Shared-service admission is covered by
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { readFile } from 'node:fs/promises';
|
|
2
|
+
import { realpathSync } from 'node:fs';
|
|
3
|
+
import { pathToFileURL } from 'node:url';
|
|
4
|
+
import { sessionSkillCommand } from './session-skill-command.mjs';
|
|
5
|
+
|
|
6
|
+
async function main() {
|
|
7
|
+
let bound = false;
|
|
8
|
+
try {
|
|
9
|
+
const [encoded, operation] = process.argv.slice(2);
|
|
10
|
+
const binding = JSON.parse(Buffer.from(encoded, 'base64url').toString());
|
|
11
|
+
if (!['describe', 'list', 'add'].includes(operation)) throw new Error();
|
|
12
|
+
const origin = new URL(binding.hostOrigin);
|
|
13
|
+
if (origin.protocol !== 'http:' || !['127.0.0.1', '[::1]'].includes(origin.hostname) || origin.username || origin.password) throw new Error();
|
|
14
|
+
const registration = JSON.parse(await readFile(binding.registrationFile, 'utf8'));
|
|
15
|
+
if (new URL(registration.url).origin !== binding.upstreamOrigin || typeof registration.password !== 'string' || !registration.password) throw new Error();
|
|
16
|
+
bound = true;
|
|
17
|
+
let input = {};
|
|
18
|
+
if (operation === 'add') {
|
|
19
|
+
let text = '';
|
|
20
|
+
for await (const chunk of process.stdin) {
|
|
21
|
+
text += chunk;
|
|
22
|
+
if (Buffer.byteLength(text) > 16 * 1024) throw new Error();
|
|
23
|
+
}
|
|
24
|
+
input = JSON.parse(text);
|
|
25
|
+
}
|
|
26
|
+
const response = await fetch(new URL('/api/yuri/session-skills/projects', origin), {
|
|
27
|
+
method: 'POST', redirect: 'error', signal: AbortSignal.timeout(30_000),
|
|
28
|
+
headers: { 'content-type': 'application/json', authorization: `Basic ${Buffer.from(`opencode:${registration.password}`).toString('base64')}` },
|
|
29
|
+
body: JSON.stringify({ sessionID: binding.sessionID, operation, input }),
|
|
30
|
+
});
|
|
31
|
+
const result = await response.json();
|
|
32
|
+
if (!response.ok) {
|
|
33
|
+
const terminal = [401, 403, 501].includes(response.status);
|
|
34
|
+
console.error(JSON.stringify({ error: 'Project API operation failed', status: response.status, terminal,
|
|
35
|
+
...(['invalid_input', 'validation_error', 'project_unavailable', 'project_operation_failed'].includes(result?.code) ? { code: result.code } : {}),
|
|
36
|
+
recovery: terminal ? 'Stop this workflow; resume only with a new supported session and its bound project describe command.'
|
|
37
|
+
: 'Result not confirmed. Check the path; use list or retry add with the same path after recovery. Never claim success from a failed request.',
|
|
38
|
+
}));
|
|
39
|
+
process.exitCode = 1;
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
if (operation === 'add' && (typeof result.project?.id !== 'string' || typeof result.project?.path !== 'string' || typeof result.created !== 'boolean')) throw new Error();
|
|
43
|
+
if (operation === 'list' && !Array.isArray(result.projects)) throw new Error();
|
|
44
|
+
if (operation === 'describe' && result.supported !== true) throw new Error();
|
|
45
|
+
console.log(JSON.stringify(operation === 'describe' ? { ...result,
|
|
46
|
+
commands: Object.fromEntries(['list', 'add'].map((op) => [op, sessionSkillCommand(process.execPath, process.argv[1], encoded, op)])),
|
|
47
|
+
} : result));
|
|
48
|
+
} catch {
|
|
49
|
+
console.error(JSON.stringify({ error: 'Bound project helper failed; the result is unconfirmed', terminal: !bound,
|
|
50
|
+
recovery: !bound ? 'Stop this workflow; resume only with a new supported session and its bound project describe command.'
|
|
51
|
+
: 'Check the input or connection. Resume with the bound describe command; retry add with the same path only after recovery.' }));
|
|
52
|
+
process.exitCode = 1;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
let directEntry = false;
|
|
57
|
+
try { directEntry = Boolean(process.argv[1] && pathToFileURL(realpathSync(process.argv[1])).href === import.meta.url); }
|
|
58
|
+
catch { /* Imports and Electron flags need not name a script. */ }
|
|
59
|
+
if (directEntry) await main();
|