@nomix-ai/nomix-harness 0.2.5 → 0.2.6
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/README.md +2 -9
- package/dist/assets/web/assets/index-BnapMmQ_.css +1 -0
- package/dist/assets/web/assets/index-Dx7Ws_OC.js +96 -0
- package/dist/assets/web/assets/langs/{php-D-uCvoST.js → php-DDkx9sim.js} +2 -2
- package/dist/{kernel/web-frontend/dist/assets/langs/ruby-DEItuUFs.js → assets/web/assets/langs/ruby-DCxyoPen.js} +2 -2
- package/dist/assets/web/assets/{vendor-Cjbwl5VI.js → vendor-D22_Mp1f.js} +2 -2
- package/dist/assets/web/favicon.svg +8 -0
- package/dist/assets/web/index.html +5 -5
- package/dist/bundles/base/cordis.patch.yml +31 -6
- package/dist/bundles/web-app/cordis.patch.yml +27 -6
- package/dist/cli/bin.js +4 -5
- package/dist/cli/builtin-registry.js +34 -4
- package/dist/cli/{dump-config-d3ECray2.js → dump-config-BEj2GlJo.js} +1 -1
- package/dist/cli/{plugin-Bw9wgrmj.js → plugin-D_gLgCYL.js} +1 -1
- package/dist/cli/profile-boot-BSrYtiQI.js +2 -0
- package/dist/cli/{profile-boot-DFHdh9Xq.js → profile-boot-CByqUxLM.js} +0 -2
- package/dist/cli/runtime.js +0 -2
- package/dist/config/agent-presets/code/agent.cordis.yml +4 -3
- package/dist/config/agent-presets/cordis/agent.cordis.yml +4 -3
- package/dist/config/agent-presets/cordis/skills/editing-cordis-compositions/SKILL.md +13 -2
- package/dist/config/agent-presets/minimal/agent.cordis.yml +27 -1
- package/dist/config/agent-presets/standard/agent.cordis.yml +4 -3
- package/dist/kernel/acp/package.json +1 -1
- package/dist/kernel/agent/package.json +1 -1
- package/dist/kernel/agent-default-model/package.json +1 -1
- package/dist/kernel/agent-instructions/package.json +1 -1
- package/dist/kernel/agent-loop/lib/index.js +33 -10
- package/dist/kernel/agent-loop/lib/types/agent.js +26 -6
- package/dist/kernel/agent-loop/package.json +1 -1
- package/dist/kernel/agent-presets/package.json +1 -1
- package/dist/kernel/agent-tool-presentation/package.json +1 -1
- package/dist/kernel/anonymous-user-id/package.json +1 -1
- package/dist/kernel/api-gateway/lib/client.js +84 -55
- package/dist/kernel/api-gateway/lib/types/client/index.js +93 -61
- package/dist/kernel/api-gateway/package.json +1 -1
- package/dist/kernel/api-remotes/lib/client.js +166 -27
- package/dist/kernel/api-remotes/lib/index.js +1 -1
- package/dist/kernel/api-remotes/lib/types/client/index.d.ts +4 -0
- package/dist/kernel/api-remotes/lib/types/client/index.js +4 -1
- package/dist/kernel/api-remotes/lib/types/remote-events.d.ts +1 -1
- package/dist/kernel/api-remotes/lib/types/remote-events.js +1 -1
- package/dist/kernel/api-remotes/package.json +11 -7
- package/dist/kernel/app-boot/lib/index.js +19 -41
- package/dist/kernel/app-boot/lib/types/index.d.ts +0 -1
- package/dist/kernel/app-boot/lib/types/index.js +2 -3
- package/dist/kernel/app-boot/lib/types/profile.d.ts +15 -12
- package/dist/kernel/app-boot/lib/types/profile.js +15 -25
- package/dist/kernel/app-boot/package.json +1 -1
- package/dist/kernel/atomic-write/lib/index.js +36 -16
- package/dist/kernel/atomic-write/lib/types/index.d.ts +21 -5
- package/dist/kernel/atomic-write/lib/types/index.js +40 -16
- package/dist/kernel/atomic-write/package.json +1 -1
- package/dist/kernel/attachment/lib/index.js +62 -3
- package/dist/kernel/attachment/lib/types/admission.d.ts +15 -0
- package/dist/kernel/attachment/lib/types/admission.js +33 -0
- package/dist/kernel/attachment/lib/types/brand.d.ts +8 -0
- package/dist/kernel/attachment/lib/types/brand.js +8 -0
- package/dist/kernel/attachment/lib/types/error.d.ts +2 -2
- package/dist/kernel/attachment/lib/types/error.js +1 -0
- package/dist/kernel/attachment/lib/types/index.d.ts +23 -5
- package/dist/kernel/attachment/lib/types/index.js +24 -2
- package/dist/kernel/attachment/lib/types/types.d.ts +47 -2
- package/dist/kernel/attachment/package.json +3 -2
- package/dist/kernel/attachment-local/lib/index.js +640 -48
- package/dist/kernel/attachment-local/lib/types/compression-limiter.d.ts +18 -0
- package/dist/kernel/attachment-local/lib/types/compression-limiter.js +43 -0
- package/dist/kernel/attachment-local/lib/types/encoding.d.ts +23 -0
- package/dist/kernel/attachment-local/lib/types/encoding.js +33 -0
- package/dist/kernel/attachment-local/lib/types/image.d.ts +31 -2
- package/dist/kernel/attachment-local/lib/types/image.js +43 -4
- package/dist/kernel/attachment-local/lib/types/index.d.ts +45 -10
- package/dist/kernel/attachment-local/lib/types/index.js +140 -10
- package/dist/kernel/attachment-local/lib/types/normalization.d.ts +44 -0
- package/dist/kernel/attachment-local/lib/types/normalization.js +148 -0
- package/dist/kernel/attachment-local/lib/types/request-image.d.ts +35 -0
- package/dist/kernel/attachment-local/lib/types/request-image.js +208 -0
- package/dist/kernel/attachment-local/lib/types/store.d.ts +36 -9
- package/dist/kernel/attachment-local/lib/types/store.js +60 -24
- package/dist/kernel/attachment-local/package.json +1 -1
- package/dist/kernel/authorization/lib/index.js +248 -0
- package/dist/kernel/authorization/lib/invariant.js +36 -0
- package/dist/kernel/authorization/lib/types/index.d.ts +223 -0
- package/dist/kernel/authorization/lib/types/index.js +299 -0
- package/dist/kernel/authorization/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/authorization/lib/types/invariant.js +38 -0
- package/dist/kernel/authorization/lib/types/types.d.ts +83 -0
- package/dist/kernel/authorization/lib/types/types.js +8 -0
- package/dist/kernel/{client-web-react → authorization}/package.json +19 -16
- package/dist/kernel/base/cordis.patch.yml +31 -6
- package/dist/kernel/base/package.json +3 -1
- package/dist/kernel/bash-local/package.json +1 -1
- package/dist/kernel/bash-sandbox/package.json +1 -1
- package/dist/kernel/brand/package.json +1 -1
- package/dist/kernel/client-connection/lib/client.js +148 -28
- package/dist/kernel/client-connection/lib/index.js +4 -4
- package/dist/kernel/client-connection/lib/types/client/fixture.js +112 -20
- package/dist/kernel/client-connection/lib/types/client/index.d.ts +21 -1
- package/dist/kernel/client-connection/lib/types/client/index.js +3 -2
- package/dist/kernel/client-connection/lib/types/client/rpc.d.ts +4 -1
- package/dist/kernel/client-connection/lib/types/client/rpc.js +4 -2
- package/dist/kernel/client-connection/lib/types/http-bridge.d.ts +2 -2
- package/dist/kernel/client-connection/lib/types/http-bridge.js +3 -3
- package/dist/kernel/client-connection/lib/types/index.d.ts +1 -1
- package/dist/kernel/client-connection/package.json +15 -9
- package/dist/kernel/client-hmr/package.json +1 -1
- package/dist/kernel/client-locale/lib/client.js +48 -9
- package/dist/kernel/client-locale/lib/types/client/index.d.ts +19 -3
- package/dist/kernel/client-locale/lib/types/client/index.js +48 -7
- package/dist/kernel/client-locale/package.json +6 -6
- package/dist/kernel/client-modules/lib/client.js +188 -123
- package/dist/kernel/client-modules/lib/index.js +177 -31
- package/dist/kernel/client-modules/lib/types/client/index.d.ts +19 -8
- package/dist/kernel/client-modules/lib/types/client/index.js +25 -8
- package/dist/kernel/client-modules/lib/types/client/manifest.d.ts +90 -41
- package/dist/kernel/client-modules/lib/types/client/manifest.js +45 -12
- package/dist/kernel/client-modules/lib/types/client/system.d.ts +15 -17
- package/dist/kernel/client-modules/lib/types/client/system.js +85 -56
- package/dist/kernel/client-modules/lib/types/index.d.ts +28 -12
- package/dist/kernel/client-modules/lib/types/index.js +128 -34
- package/dist/kernel/client-modules/package.json +4 -2
- package/dist/kernel/client-runtime/lib/client.js +43 -8
- package/dist/kernel/client-runtime/lib/types/client/contract/session.d.ts +1 -1
- package/dist/kernel/client-runtime/lib/types/client/contract/store.d.ts +1 -1
- package/dist/kernel/client-runtime/lib/types/client/contract/store.js +2 -2
- package/dist/kernel/client-runtime/lib/types/client/index.d.ts +2 -2
- package/dist/kernel/client-runtime/lib/types/client/index.js +3 -3
- package/dist/kernel/client-runtime/lib/types/client/sessions/context-provenance.d.ts +8 -0
- package/dist/kernel/client-runtime/lib/types/client/sessions/context-provenance.js +13 -0
- package/dist/kernel/client-runtime/lib/types/client/sessions/conversation.d.ts +11 -7
- package/dist/kernel/client-runtime/lib/types/client/sessions/projection-store.d.ts +1 -1
- package/dist/kernel/client-runtime/lib/types/client/sessions/session.d.ts +1 -1
- package/dist/kernel/client-runtime/lib/types/client/sessions/session.js +4 -4
- package/dist/kernel/client-runtime/lib/types/client/slots.d.ts +1 -1
- package/dist/kernel/client-runtime/lib/types/client/slots.js +1 -1
- package/dist/kernel/client-runtime/lib/types/client/workspaces/path.d.ts +9 -0
- package/dist/kernel/client-runtime/lib/types/client/workspaces/path.js +27 -1
- package/dist/kernel/client-runtime/package.json +25 -14
- package/dist/kernel/client-ui-agent-preset/lib/client.js +55 -55
- package/dist/kernel/client-ui-agent-preset/lib/types/client/index.js +2 -2
- package/dist/kernel/client-ui-agent-preset/lib/types/client/settings-store.d.ts +7 -1
- package/dist/kernel/client-ui-agent-preset/lib/types/client/settings-store.js +21 -20
- package/dist/kernel/client-ui-agent-preset/package.json +2 -7
- package/dist/kernel/client-ui-attachment/lib/client.js +782 -0
- package/dist/kernel/client-ui-attachment/lib/index.js +5 -505
- package/dist/kernel/client-ui-attachment/lib/invariant.js +2 -3
- package/dist/kernel/client-ui-attachment/lib/types/client/ComposerAttachments.d.ts +4 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/ComposerAttachments.js +85 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/MessageImages.d.ts +4 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/MessageImages.js +8 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/index.d.ts +7 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/index.js +16 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/labels.d.ts +35 -0
- package/dist/kernel/client-ui-attachment/lib/types/client/labels.js +52 -0
- package/dist/kernel/client-ui-attachment/lib/types/index.d.ts +3 -15
- package/dist/kernel/client-ui-attachment/lib/types/index.js +3 -11
- package/dist/kernel/client-ui-attachment/lib/types/invariant.js +2 -3
- package/dist/kernel/client-ui-attachment/package.json +32 -9
- package/dist/kernel/client-ui-brand-official/lib/client.js +50 -0
- package/dist/kernel/client-ui-brand-official/lib/index.js +9 -0
- package/dist/kernel/{client-web-react → client-ui-brand-official}/lib/invariant.js +6 -8
- package/dist/kernel/client-ui-brand-official/lib/types/client/Brand.d.ts +16 -0
- package/dist/kernel/client-ui-brand-official/lib/types/client/Brand.js +18 -0
- package/dist/kernel/client-ui-brand-official/lib/types/client/index.d.ts +10 -0
- package/dist/kernel/client-ui-brand-official/lib/types/client/index.js +17 -0
- package/dist/kernel/client-ui-brand-official/lib/types/index.d.ts +7 -0
- package/dist/kernel/client-ui-brand-official/lib/types/index.js +7 -0
- package/dist/kernel/client-ui-brand-official/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/{client-web-react → client-ui-brand-official}/lib/types/invariant.js +6 -8
- package/dist/kernel/client-ui-brand-official/package.json +72 -0
- package/dist/kernel/client-ui-commands/lib/client.js +44 -15
- package/dist/kernel/client-ui-commands/lib/types/client/locales.d.ts +2 -0
- package/dist/kernel/client-ui-commands/lib/types/client/locales.js +2 -0
- package/dist/kernel/client-ui-commands/lib/types/client/service.d.ts +11 -1
- package/dist/kernel/client-ui-commands/lib/types/client/service.js +39 -7
- package/dist/kernel/client-ui-commands/package.json +2 -5
- package/dist/kernel/client-ui-conversation/lib/client.js +949 -531
- package/dist/kernel/client-ui-conversation/lib/types/client/apply.js +6 -4
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/AssistantMarkdown.d.ts +4 -5
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/AssistantMarkdown.js +6 -6
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/AssistantNodeView.d.ts +1 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/AssistantNodeView.js +2 -2
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/ChatNodeSeat.d.ts +1 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/ChatNodeSeat.js +5 -3
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/ChatView.js +53 -10
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/ContextInjectionRow.js +4 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/MessageItem.d.ts +4 -5
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/MessageItem.js +46 -16
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/StatsLine.d.ts +5 -3
- package/dist/kernel/client-ui-conversation/lib/types/client/chat/StatsLine.js +54 -5
- package/dist/kernel/client-ui-conversation/lib/types/client/contract/slots.d.ts +90 -8
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/assistant.js +1 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/chat-snapshot-builder.d.ts +1 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/chat-snapshot-builder.js +95 -6
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/message.d.ts +11 -3
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/turn-error.d.ts +6 -3
- package/dist/kernel/client-ui-conversation/lib/types/client/conversation-nodes/turn-error.js +10 -26
- package/dist/kernel/client-ui-conversation/lib/types/client/image-labels.d.ts +1 -33
- package/dist/kernel/client-ui-conversation/lib/types/client/image-labels.js +5 -54
- package/dist/kernel/client-ui-conversation/lib/types/client/index.d.ts +1 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/input/contract.d.ts +17 -14
- package/dist/kernel/client-ui-conversation/lib/types/client/input/decorations.d.ts +13 -5
- package/dist/kernel/client-ui-conversation/lib/types/client/input/decorations.js +26 -10
- package/dist/kernel/client-ui-conversation/lib/types/client/input/facade.d.ts +34 -14
- package/dist/kernel/client-ui-conversation/lib/types/client/input/facade.js +116 -34
- package/dist/kernel/client-ui-conversation/lib/types/client/input/hub.d.ts +1 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/input/hub.js +21 -19
- package/dist/kernel/client-ui-conversation/lib/types/client/input/machine.d.ts +35 -14
- package/dist/kernel/client-ui-conversation/lib/types/client/input/machine.js +71 -34
- package/dist/kernel/client-ui-conversation/lib/types/client/locales.d.ts +16 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/locales.js +16 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/reference/ReferenceIcon.d.ts +16 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/reference/ReferenceIcon.js +16 -0
- package/dist/kernel/client-ui-conversation/lib/types/client/service.d.ts +14 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/service.js +26 -6
- package/dist/kernel/client-ui-conversation/lib/types/client/skeleton/ConversationRoot.js +1 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/skeleton/ConversationSession.js +18 -3
- package/dist/kernel/client-ui-conversation/lib/types/client/skeleton/EmptyHero.d.ts +3 -1
- package/dist/kernel/client-ui-conversation/lib/types/client/skeleton/EmptyHero.js +4 -2
- package/dist/kernel/client-ui-conversation/lib/types/client/skeleton/InputBar.js +141 -126
- package/dist/kernel/client-ui-conversation/package.json +9 -8
- package/dist/kernel/client-ui-cordis/lib/client.js +48 -48
- package/dist/kernel/client-ui-cordis/package.json +2 -5
- package/dist/kernel/client-ui-deliverables/lib/client.js +5 -5
- package/dist/kernel/client-ui-deliverables/package.json +4 -6
- package/dist/kernel/client-ui-directory-picker-browse/lib/client.js +26 -26
- package/dist/kernel/client-ui-directory-picker-browse/package.json +2 -5
- package/dist/kernel/client-ui-directory-picker-native/package.json +2 -5
- package/dist/kernel/client-ui-goal/lib/client.js +8 -8
- package/dist/kernel/client-ui-goal/package.json +6 -5
- package/dist/kernel/client-ui-input-trigger/lib/client.js +82 -26
- package/dist/kernel/client-ui-input-trigger/lib/types/client/MenuView.js +13 -9
- package/dist/kernel/client-ui-input-trigger/lib/types/client/controller.d.ts +5 -3
- package/dist/kernel/client-ui-input-trigger/lib/types/client/controller.js +19 -7
- package/dist/kernel/client-ui-input-trigger/lib/types/client/index.d.ts +1 -1
- package/dist/kernel/client-ui-input-trigger/lib/types/core/contract.d.ts +7 -2
- package/dist/kernel/client-ui-input-trigger/lib/types/core/detect.d.ts +4 -4
- package/dist/kernel/client-ui-input-trigger/lib/types/core/detect.js +24 -6
- package/dist/kernel/client-ui-input-trigger/lib/types/core/menu.d.ts +15 -2
- package/dist/kernel/client-ui-input-trigger/lib/types/core/menu.js +13 -4
- package/dist/kernel/client-ui-input-trigger/lib/types/types.d.ts +52 -8
- package/dist/kernel/client-ui-input-trigger/package.json +4 -5
- package/dist/kernel/client-ui-jobs/lib/client.js +10 -10
- package/dist/kernel/client-ui-jobs/package.json +3 -7
- package/dist/kernel/client-ui-layout/lib/client.js +3 -3
- package/dist/kernel/client-ui-layout/package.json +2 -4
- package/dist/kernel/client-ui-message-feedback/lib/client.js +174 -58
- package/dist/kernel/client-ui-message-feedback/lib/types/client/MessageFeedbackActions.d.ts +9 -3
- package/dist/kernel/client-ui-message-feedback/lib/types/client/MessageFeedbackActions.js +164 -25
- package/dist/kernel/client-ui-message-feedback/lib/types/client/locales.d.ts +2 -0
- package/dist/kernel/client-ui-message-feedback/lib/types/client/locales.js +2 -0
- package/dist/kernel/client-ui-message-feedback/package.json +3 -5
- package/dist/kernel/client-ui-model-selection/lib/client.js +18 -18
- package/dist/kernel/client-ui-model-selection/package.json +7 -9
- package/dist/kernel/client-ui-permission-presets/lib/client.js +97 -83
- package/dist/kernel/client-ui-permission-presets/lib/types/client/index.js +6 -19
- package/dist/kernel/client-ui-permission-presets/lib/types/client/settings-store.d.ts +27 -18
- package/dist/kernel/client-ui-permission-presets/lib/types/client/settings-store.js +95 -68
- package/dist/kernel/client-ui-permission-presets/package.json +2 -8
- package/dist/kernel/client-ui-plan/lib/client.js +1 -1
- package/dist/kernel/client-ui-plan/lib/types/client/index.js +1 -1
- package/dist/kernel/client-ui-plan/package.json +2 -6
- package/dist/kernel/client-ui-primitives/lib/Button.module.css +79 -0
- package/dist/kernel/client-ui-primitives/lib/ConnectionBanner.module.css +13 -0
- package/dist/kernel/client-ui-primitives/lib/DiffBlock.module.css +107 -0
- package/dist/kernel/client-ui-primitives/lib/DisclosureRow.module.css +69 -0
- package/dist/kernel/client-ui-primitives/lib/HoverCard.module.css +54 -0
- package/dist/kernel/client-ui-primitives/lib/Input.module.css +38 -0
- package/dist/kernel/client-ui-primitives/lib/JsonTree.module.css +222 -0
- package/dist/kernel/client-ui-primitives/lib/Menu.module.css +242 -0
- package/dist/kernel/client-ui-primitives/lib/Modal.module.css +103 -0
- package/dist/kernel/client-ui-primitives/lib/OnboardingSurface.module.css +29 -0
- package/dist/kernel/client-ui-primitives/lib/Pill.module.css +27 -0
- package/dist/kernel/client-ui-primitives/lib/ReadBlock.module.css +117 -0
- package/dist/kernel/client-ui-primitives/lib/RiskConfirmation.module.css +73 -0
- package/dist/kernel/client-ui-primitives/lib/SearchBlock.module.css +120 -0
- package/dist/kernel/client-ui-primitives/lib/StateDot.module.css +65 -0
- package/dist/kernel/client-ui-primitives/lib/TerminalBlock.module.css +211 -0
- package/dist/kernel/client-ui-primitives/lib/Toast.module.css +70 -0
- package/dist/kernel/client-ui-primitives/lib/Tooltip.module.css +49 -0
- package/dist/kernel/client-ui-primitives/lib/WebBlock.module.css +130 -0
- package/dist/kernel/client-ui-primitives/lib/index.js +291 -261
- package/dist/kernel/client-ui-primitives/lib/invariant.js +2 -0
- package/dist/kernel/client-ui-primitives/lib/markdown/CodeBlock.module.css +96 -0
- package/dist/kernel/client-ui-primitives/lib/markdown/JsonBlock.module.css +32 -0
- package/dist/kernel/client-ui-primitives/lib/markdown/MarkdownText.module.css +304 -0
- package/dist/kernel/client-ui-primitives/lib/markdown/MessageText.module.css +9 -0
- package/dist/kernel/client-ui-primitives/lib/types/BrandWordmark.d.ts +7 -1
- package/dist/kernel/client-ui-primitives/lib/types/BrandWordmark.js +4 -2
- package/dist/kernel/client-ui-primitives/lib/types/index.d.ts +4 -1
- package/dist/kernel/client-ui-primitives/lib/types/index.js +2 -1
- package/dist/kernel/client-ui-primitives/lib/types/markdown/render.d.ts +2 -0
- package/dist/kernel/client-ui-primitives/lib/types/markdown/render.js +10 -2
- package/dist/kernel/client-ui-primitives/lib/types/useAnchoredPosition.d.ts +32 -0
- package/dist/kernel/client-ui-primitives/lib/types/useAnchoredPosition.js +69 -0
- package/dist/kernel/client-ui-primitives/package.json +2 -1
- package/dist/kernel/client-ui-reference/lib/client.js +149 -0
- package/dist/kernel/client-ui-reference/lib/index.js +11 -0
- package/dist/kernel/{client-schema-form → client-ui-reference}/lib/invariant.js +7 -8
- package/dist/kernel/client-ui-reference/lib/types/client/index.d.ts +9 -0
- package/dist/kernel/client-ui-reference/lib/types/client/index.js +106 -0
- package/dist/kernel/client-ui-reference/lib/types/client/locales.d.ts +30 -0
- package/dist/kernel/client-ui-reference/lib/types/client/locales.js +22 -0
- package/dist/kernel/client-ui-reference/lib/types/index.d.ts +9 -0
- package/dist/kernel/client-ui-reference/lib/types/index.js +9 -0
- package/dist/kernel/{client-schema-form → client-ui-reference}/lib/types/invariant.d.ts +3 -3
- package/dist/kernel/{client-schema-form → client-ui-reference}/lib/types/invariant.js +7 -8
- package/dist/kernel/client-ui-reference/package.json +77 -0
- package/dist/kernel/client-ui-renderer/lib/client.js +989 -0
- package/dist/kernel/client-ui-renderer/lib/index.js +6 -0
- package/dist/kernel/client-ui-renderer/lib/invariant.js +23 -0
- package/dist/kernel/{client-web/lib/types → client-ui-renderer/lib/types/client}/DocumentTitle.d.ts +4 -4
- package/dist/kernel/client-ui-renderer/lib/types/client/DocumentTitle.js +17 -0
- package/dist/kernel/client-ui-renderer/lib/types/client/app.d.ts +18 -0
- package/dist/kernel/{client-web/lib/types → client-ui-renderer/lib/types/client}/app.js +5 -5
- package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/bind.d.ts +1 -1
- package/dist/kernel/client-ui-renderer/lib/types/client/index.d.ts +29 -0
- package/dist/kernel/client-ui-renderer/lib/types/client/index.js +51 -0
- package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/scoped-slots.d.ts +1 -1
- package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/scoped-slots.js +1 -1
- package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/session-provider.d.ts +1 -1
- package/dist/kernel/client-ui-renderer/lib/types/index.d.ts +4 -0
- package/dist/kernel/client-ui-renderer/lib/types/index.js +4 -0
- package/dist/kernel/{client-web-react → client-ui-renderer}/lib/types/invariant.d.ts +3 -3
- package/dist/kernel/client-ui-renderer/lib/types/invariant.js +22 -0
- package/dist/kernel/client-ui-renderer/package.json +71 -0
- package/dist/kernel/client-ui-settings/lib/client.js +1177 -67
- package/dist/kernel/client-ui-settings/lib/types/client/index.d.ts +20 -12
- package/dist/kernel/client-ui-settings/lib/types/client/index.js +25 -6
- package/dist/kernel/client-ui-settings/lib/types/client/schema.d.ts +72 -0
- package/dist/kernel/client-ui-settings/lib/types/client/schema.js +152 -0
- package/dist/kernel/client-ui-settings/lib/types/client/settings-mirror.d.ts +118 -0
- package/dist/kernel/client-ui-settings/lib/types/client/settings-mirror.js +160 -0
- package/dist/kernel/client-ui-settings/lib/types/client/settings-scope.d.ts +51 -24
- package/dist/kernel/client-ui-settings/lib/types/client/settings-scope.js +88 -71
- package/dist/kernel/client-ui-settings/package.json +7 -7
- package/dist/kernel/client-ui-settings-general/lib/client.js +60 -64
- package/dist/kernel/client-ui-settings-general/lib/types/client/SettingsDocumentAction.d.ts +7 -6
- package/dist/kernel/client-ui-settings-general/lib/types/client/index.js +10 -11
- package/dist/kernel/client-ui-settings-general/lib/types/client/settings-document-store.d.ts +13 -11
- package/dist/kernel/client-ui-settings-general/lib/types/client/settings-document-store.js +37 -40
- package/dist/kernel/client-ui-settings-general/package.json +4 -8
- package/dist/kernel/client-ui-settings-models/lib/client.js +280 -210
- package/dist/kernel/client-ui-settings-models/lib/types/client/DeepSeekOnboardingDialog.d.ts +3 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/DeepSeekOnboardingDialog.js +2 -2
- package/dist/kernel/client-ui-settings-models/lib/types/client/ModelListEditor.js +11 -1
- package/dist/kernel/client-ui-settings-models/lib/types/client/ModelsSection.d.ts +10 -5
- package/dist/kernel/client-ui-settings-models/lib/types/client/ModelsSection.js +9 -6
- package/dist/kernel/client-ui-settings-models/lib/types/client/ProviderEditor.d.ts +3 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/ProviderEditor.js +30 -29
- package/dist/kernel/client-ui-settings-models/lib/types/client/index.js +27 -22
- package/dist/kernel/client-ui-settings-models/lib/types/client/locales.d.ts +2 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/locales.js +4 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/schema-operations.d.ts +10 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/schema-operations.js +17 -0
- package/dist/kernel/client-ui-settings-models/lib/types/client/store.d.ts +15 -7
- package/dist/kernel/client-ui-settings-models/lib/types/client/store.js +30 -21
- package/dist/kernel/client-ui-settings-models/lib/types/client/welcome-store.d.ts +35 -18
- package/dist/kernel/client-ui-settings-models/lib/types/client/welcome-store.js +89 -82
- package/dist/kernel/client-ui-settings-models/package.json +3 -8
- package/dist/kernel/client-ui-settings-plugin-inventory/lib/client.js +11 -11
- package/dist/kernel/client-ui-settings-plugin-inventory/package.json +2 -5
- package/dist/kernel/client-ui-settings-plugins/lib/client.js +42 -65
- package/dist/kernel/client-ui-settings-plugins/lib/types/client/index.js +5 -8
- package/dist/kernel/client-ui-settings-plugins/lib/types/client/tab-store.d.ts +8 -17
- package/dist/kernel/client-ui-settings-plugins/lib/types/client/tab-store.js +22 -44
- package/dist/kernel/client-ui-settings-plugins/package.json +2 -7
- package/dist/kernel/client-ui-sidebar/lib/client.js +50 -20
- package/dist/kernel/client-ui-sidebar/lib/types/client/SidebarRoot.js +7 -3
- package/dist/kernel/client-ui-sidebar/lib/types/client/contract/slots.d.ts +30 -1
- package/dist/kernel/client-ui-sidebar/lib/types/client/index.d.ts +1 -1
- package/dist/kernel/client-ui-sidebar/lib/types/client/index.js +2 -0
- package/dist/kernel/client-ui-sidebar/package.json +2 -4
- package/dist/kernel/client-ui-skill/lib/client.js +12 -12
- package/dist/kernel/client-ui-skill/package.json +2 -5
- package/dist/kernel/client-ui-slots/lib/index.js +2 -0
- package/dist/kernel/client-ui-slots/lib/invariant.js +2 -0
- package/dist/kernel/client-ui-slots/lib/types/renderer.d.ts +1 -1
- package/dist/kernel/client-ui-slots/lib/types/store.d.ts +1 -1
- package/dist/kernel/client-ui-slots/package.json +1 -1
- package/dist/kernel/client-ui-subagent/lib/client.js +289 -157
- package/dist/kernel/client-ui-subagent/lib/types/client/SubagentHeaderLineage.d.ts +18 -0
- package/dist/kernel/client-ui-subagent/lib/types/client/{SubagentCatalogAction.js → SubagentHeaderLineage.js} +153 -25
- package/dist/kernel/client-ui-subagent/lib/types/client/index.d.ts +4 -16
- package/dist/kernel/client-ui-subagent/lib/types/client/index.js +7 -45
- package/dist/kernel/client-ui-subagent/lib/types/client/locales.d.ts +1 -0
- package/dist/kernel/client-ui-subagent/lib/types/client/locales.js +2 -0
- package/dist/kernel/client-ui-subagent/package.json +6 -8
- package/dist/kernel/client-ui-theme/lib/client.js +46 -3
- package/dist/kernel/client-ui-theme/lib/index.js +22 -23
- package/dist/kernel/client-ui-theme/lib/types/boot-theme.d.ts +9 -10
- package/dist/kernel/client-ui-theme/lib/types/boot-theme.js +12 -19
- package/dist/kernel/client-ui-theme/lib/types/client/index.d.ts +1 -1
- package/dist/kernel/client-ui-theme/lib/types/client/index.js +3 -1
- package/dist/kernel/client-ui-theme/lib/types/client/styles.d.ts +7 -0
- package/dist/kernel/client-ui-theme/lib/types/client/styles.js +32 -0
- package/dist/kernel/client-ui-theme/lib/types/index.d.ts +4 -3
- package/dist/kernel/client-ui-theme/lib/types/index.js +7 -6
- package/dist/kernel/client-ui-theme/package.json +4 -6
- package/dist/kernel/client-ui-tool/lib/client.js +105 -65
- package/dist/kernel/client-ui-tool/lib/types/client/apply.d.ts +1 -2
- package/dist/kernel/client-ui-tool/lib/types/client/apply.js +6 -2
- package/dist/kernel/client-ui-tool/lib/types/client/contract/slots.d.ts +13 -3
- package/dist/kernel/client-ui-tool/lib/types/client/index.d.ts +1 -1
- package/dist/kernel/client-ui-tool/lib/types/client/tool/ToolCallTree.d.ts +1 -1
- package/dist/kernel/client-ui-tool/lib/types/client/tool/ToolCallTree.js +8 -6
- package/dist/kernel/client-ui-tool/lib/types/client/tool/ToolDetails.d.ts +2 -9
- package/dist/kernel/client-ui-tool/lib/types/client/tool/ToolDetails.js +4 -3
- package/dist/kernel/client-ui-tool/lib/types/client/tool/models/read-card-model.d.ts +4 -18
- package/dist/kernel/client-ui-tool/lib/types/client/tool/models/read-card-model.js +21 -4
- package/dist/kernel/client-ui-tool/lib/types/client/tool/models/tool-call-model.d.ts +2 -9
- package/dist/kernel/client-ui-tool/lib/types/client/tool/models/tool-call-model.js +22 -2
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/GenericToolCard.d.ts +1 -1
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/GenericToolCard.js +3 -3
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/file-mutation-row.d.ts +1 -1
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/file-mutation-row.js +2 -2
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/read-row.d.ts +1 -1
- package/dist/kernel/client-ui-tool/lib/types/client/tool/toolviews/read-row.js +3 -3
- package/dist/kernel/client-ui-tool/package.json +4 -6
- package/dist/kernel/client-ui-trajectory/lib/client.js +144 -143
- package/dist/kernel/client-ui-trajectory/lib/types/client/trajectory-assistant-definition.js +2 -1
- package/dist/kernel/client-ui-trajectory/package.json +2 -4
- package/dist/kernel/client-ui-user-questions/lib/client.js +73 -36
- package/dist/kernel/client-ui-user-questions/lib/types/client/QuestionComposer.js +24 -6
- package/dist/kernel/client-ui-user-questions/package.json +12 -10
- package/dist/kernel/client-ui-workflow-run/lib/client.js +262 -87
- package/dist/kernel/client-ui-workflow-run/lib/types/client/WorkflowRunPanel.js +162 -23
- package/dist/kernel/client-ui-workflow-run/package.json +3 -7
- package/dist/kernel/client-ui-workspace/lib/client.js +96 -60
- package/dist/kernel/client-ui-workspace/lib/types/client/WorkspaceBrowser.d.ts +1 -1
- package/dist/kernel/client-ui-workspace/lib/types/client/WorkspaceBrowser.js +38 -6
- package/dist/kernel/client-ui-workspace/lib/types/client/contract/slots.d.ts +9 -7
- package/dist/kernel/client-ui-workspace/lib/types/client/index.js +4 -2
- package/dist/kernel/client-ui-workspace/lib/types/client/rows/Rows.d.ts +4 -1
- package/dist/kernel/client-ui-workspace/lib/types/client/rows/Rows.js +5 -3
- package/dist/kernel/client-ui-workspace/package.json +6 -4
- package/dist/kernel/client-web/lib/base.css +41 -0
- package/dist/kernel/client-web/lib/boot-page.module.css +104 -0
- package/dist/kernel/client-web/lib/index.js +154 -308
- package/dist/kernel/client-web/lib/invariant.js +2 -0
- package/dist/kernel/client-web/lib/types/boot-page.d.ts +46 -0
- package/dist/kernel/client-web/lib/types/boot-page.js +93 -0
- package/dist/kernel/client-web/lib/types/boot.d.ts +20 -33
- package/dist/kernel/client-web/lib/types/boot.js +76 -149
- package/dist/kernel/client-web/lib/types/index.d.ts +5 -11
- package/dist/kernel/client-web/lib/types/index.js +4 -10
- package/dist/kernel/client-web/lib/types/loader-status.d.ts +3 -51
- package/dist/kernel/client-web/lib/types/loader-status.js +0 -35
- package/dist/kernel/client-web/lib/types/platform.d.ts +3 -1
- package/dist/kernel/client-web/lib/types/platform.js +4 -3
- package/dist/kernel/client-web/lib/types/seed.js +0 -6
- package/dist/kernel/client-web/package.json +8 -15
- package/dist/kernel/cmdline/package.json +1 -1
- package/dist/kernel/code-runtime/package.json +1 -1
- package/dist/kernel/code-runtime-python/lib/index.js +413 -0
- package/dist/kernel/code-runtime-python/lib/invariant.js +24 -0
- package/dist/kernel/code-runtime-python/lib/types/index.d.ts +12 -0
- package/dist/kernel/code-runtime-python/lib/types/index.js +11 -0
- package/dist/kernel/code-runtime-python/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/code-runtime-python/lib/types/invariant.js +23 -0
- package/dist/kernel/code-runtime-python/lib/types/protocol.d.ts +329 -0
- package/dist/kernel/code-runtime-python/lib/types/protocol.js +496 -0
- package/dist/kernel/{client-schema-form → code-runtime-python}/package.json +11 -14
- package/dist/kernel/code-runtime-python/py/protocol.py +138 -0
- package/dist/kernel/code-runtime-worker-thread/package.json +1 -1
- package/dist/kernel/command-compact/package.json +1 -1
- package/dist/kernel/command-feedback/package.json +1 -1
- package/dist/kernel/command-goal/lib/index.js +40 -6
- package/dist/kernel/command-goal/lib/types/index.js +35 -6
- package/dist/kernel/command-goal/package.json +2 -1
- package/dist/kernel/commands/lib/index.js +78 -21
- package/dist/kernel/commands/lib/typert.host.js +53 -9
- package/dist/kernel/commands/lib/typert.remote-client.d.ts +4 -3
- package/dist/kernel/commands/lib/typert.remote-client.js +18 -2
- package/dist/kernel/commands/lib/types/index.d.ts +20 -1
- package/dist/kernel/commands/lib/types/index.js +77 -20
- package/dist/kernel/commands/lib/types/types.d.ts +8 -0
- package/dist/kernel/commands/package.json +5 -1
- package/dist/kernel/compaction/package.json +1 -1
- package/dist/kernel/compaction-basic/package.json +1 -1
- package/dist/kernel/compaction-tool-result-pruner/package.json +1 -1
- package/dist/kernel/cordis/package.json +3 -1
- package/dist/kernel/cordis-client-runner/lib/client.js +171 -37
- package/dist/kernel/cordis-client-runner/lib/types/client/api-catalog.js +3 -3
- package/dist/kernel/cordis-client-runner/lib/types/client/slot-catalog.js +208 -30
- package/dist/kernel/cordis-client-runner/package.json +2 -5
- package/dist/kernel/cordis-host-runner/lib/index.js +28 -5
- package/dist/kernel/cordis-host-runner/lib/typert.host.js +54 -6
- package/dist/kernel/cordis-host-runner/lib/types/sandbox.d.ts +9 -3
- package/dist/kernel/cordis-host-runner/lib/types/sandbox.js +34 -6
- package/dist/kernel/cordis-host-runner/package.json +1 -1
- package/dist/kernel/cordis-plugin-group/package.json +3 -1
- package/dist/kernel/cordis-plugin-hmr/lib/types/index.js +1 -1
- package/dist/kernel/cordis-plugin-hmr/package.json +3 -1
- package/dist/kernel/cordis-plugin-include/lib/index.js +2 -2
- package/dist/kernel/cordis-plugin-include/lib/types/index.d.ts +2 -2
- package/dist/kernel/cordis-plugin-include/lib/types/index.js +2 -2
- package/dist/kernel/cordis-plugin-include/package.json +3 -1
- package/dist/kernel/cordis-plugin-loader/package.json +3 -1
- package/dist/kernel/cordis-plugin-logger-console/package.json +3 -1
- package/dist/kernel/cordis-plugin-timer/package.json +3 -1
- package/dist/kernel/cosmokit/package.json +3 -1
- package/dist/kernel/credentials/lib/index.js +104 -13
- package/dist/kernel/credentials/lib/invariant.js +3 -3
- package/dist/kernel/credentials/lib/types/index.d.ts +136 -7
- package/dist/kernel/credentials/lib/types/index.js +114 -15
- package/dist/kernel/credentials/lib/types/invariant.js +3 -3
- package/dist/kernel/credentials/lib/types/types.d.ts +58 -5
- package/dist/kernel/credentials/lib/types/types.js +4 -4
- package/dist/kernel/credentials/package.json +1 -1
- package/dist/kernel/credentials-local/lib/index.js +387 -29
- package/dist/kernel/credentials-local/lib/invariant.js +1 -1
- package/dist/kernel/credentials-local/lib/types/index.d.ts +57 -12
- package/dist/kernel/credentials-local/lib/types/index.js +445 -30
- package/dist/kernel/credentials-local/lib/types/invariant.js +1 -1
- package/dist/kernel/credentials-local/package.json +1 -1
- package/dist/kernel/e2b/package.json +1 -1
- package/dist/kernel/experimental-agent-team/lib/index.js +1728 -0
- package/dist/kernel/experimental-agent-team/lib/invariant.js +354 -0
- package/dist/kernel/experimental-agent-team/lib/types/activity.d.ts +23 -0
- package/dist/kernel/experimental-agent-team/lib/types/activity.js +85 -0
- package/dist/kernel/experimental-agent-team/lib/types/error.d.ts +13 -0
- package/dist/kernel/experimental-agent-team/lib/types/error.js +23 -0
- package/dist/kernel/experimental-agent-team/lib/types/fold.d.ts +44 -0
- package/dist/kernel/experimental-agent-team/lib/types/fold.js +243 -0
- package/dist/kernel/experimental-agent-team/lib/types/index.d.ts +115 -0
- package/dist/kernel/experimental-agent-team/lib/types/index.js +205 -0
- package/dist/kernel/experimental-agent-team/lib/types/invariant.d.ts +9 -0
- package/dist/kernel/experimental-agent-team/lib/types/invariant.js +29 -0
- package/dist/kernel/experimental-agent-team/lib/types/journal.d.ts +39 -0
- package/dist/kernel/experimental-agent-team/lib/types/journal.js +59 -0
- package/dist/kernel/experimental-agent-team/lib/types/lifecycle.d.ts +33 -0
- package/dist/kernel/experimental-agent-team/lib/types/lifecycle.js +85 -0
- package/dist/kernel/experimental-agent-team/lib/types/mailbox.d.ts +79 -0
- package/dist/kernel/experimental-agent-team/lib/types/mailbox.js +303 -0
- package/dist/kernel/experimental-agent-team/lib/types/roster.d.ts +113 -0
- package/dist/kernel/experimental-agent-team/lib/types/roster.js +445 -0
- package/dist/kernel/experimental-agent-team/lib/types/session-message.d.ts +11 -0
- package/dist/kernel/experimental-agent-team/lib/types/session-message.js +23 -0
- package/dist/kernel/experimental-agent-team/lib/types/task-board.d.ts +62 -0
- package/dist/kernel/experimental-agent-team/lib/types/task-board.js +275 -0
- package/dist/kernel/experimental-agent-team/lib/types/task-graph.d.ts +21 -0
- package/dist/kernel/experimental-agent-team/lib/types/task-graph.js +62 -0
- package/dist/kernel/experimental-agent-team/lib/types/types.d.ts +192 -0
- package/dist/kernel/experimental-agent-team/lib/types/types.js +26 -0
- package/dist/kernel/experimental-agent-team/lib/types/validation.d.ts +16 -0
- package/dist/kernel/experimental-agent-team/lib/types/validation.js +33 -0
- package/dist/kernel/experimental-agent-team/package.json +62 -0
- package/dist/kernel/experimental-tool-agent-team/lib/index.js +555 -0
- package/dist/kernel/experimental-tool-agent-team/lib/invariant.js +13 -0
- package/dist/kernel/experimental-tool-agent-team/lib/types/index.d.ts +19 -0
- package/dist/kernel/experimental-tool-agent-team/lib/types/index.js +379 -0
- package/dist/kernel/experimental-tool-agent-team/lib/types/invariant.d.ts +9 -0
- package/dist/kernel/experimental-tool-agent-team/lib/types/invariant.js +11 -0
- package/dist/kernel/experimental-tool-agent-team/package.json +61 -0
- package/dist/kernel/file-reference/lib/index.js +138 -0
- package/dist/kernel/file-reference/lib/invariant.js +23 -0
- package/dist/kernel/file-reference/lib/typert.host.d.ts +3 -0
- package/dist/kernel/file-reference/lib/typert.host.js +436 -0
- package/dist/kernel/file-reference/lib/typert.remote-client.d.ts +26 -0
- package/dist/kernel/file-reference/lib/typert.remote-client.js +59 -0
- package/dist/kernel/file-reference/lib/types/grammar.d.ts +33 -0
- package/dist/kernel/file-reference/lib/types/grammar.js +43 -0
- package/dist/kernel/file-reference/lib/types/index.d.ts +42 -0
- package/dist/kernel/file-reference/lib/types/index.js +75 -0
- package/dist/kernel/file-reference/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/file-reference/lib/types/invariant.js +22 -0
- package/dist/kernel/file-reference/lib/types/types.d.ts +13 -0
- package/dist/kernel/file-reference/lib/types/types.js +7 -0
- package/dist/kernel/file-reference/package.json +70 -0
- package/dist/kernel/file-reference-local/lib/index.js +327 -0
- package/dist/kernel/file-reference-local/lib/invariant.js +23 -0
- package/dist/kernel/file-reference-local/lib/types/index.d.ts +35 -0
- package/dist/kernel/file-reference-local/lib/types/index.js +105 -0
- package/dist/kernel/file-reference-local/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/file-reference-local/lib/types/invariant.js +22 -0
- package/dist/kernel/file-reference-local/lib/types/search.d.ts +52 -0
- package/dist/kernel/file-reference-local/lib/types/search.js +258 -0
- package/dist/kernel/file-reference-local/package.json +58 -0
- package/dist/kernel/fs/package.json +1 -1
- package/dist/kernel/fs-e2b/package.json +1 -1
- package/dist/kernel/fs-local/package.json +1 -1
- package/dist/kernel/fs-observation-policy/package.json +1 -1
- package/dist/kernel/fs-sandbox/package.json +1 -1
- package/dist/kernel/goal/lib/index.js +5 -2
- package/dist/kernel/goal/lib/typert.host.js +27 -3
- package/dist/kernel/goal/lib/types/index.js +2 -2
- package/dist/kernel/goal/lib/types/types.d.ts +3 -0
- package/dist/kernel/goal/package.json +1 -1
- package/dist/kernel/goal-round-driver/package.json +1 -1
- package/dist/kernel/headless/package.json +1 -1
- package/dist/kernel/home-paths/package.json +1 -1
- package/dist/kernel/hook-protocol/package.json +1 -1
- package/dist/kernel/hooks-claude-code/package.json +1 -1
- package/dist/kernel/hooks-codex/package.json +1 -1
- package/dist/kernel/host-apiproxy/lib/index.js +25 -57
- package/dist/kernel/host-apiproxy/lib/types/api/host.d.ts +2 -0
- package/dist/kernel/host-apiproxy/lib/types/api/host.schema.d.ts +1 -0
- package/dist/kernel/host-apiproxy/lib/types/api/host.schema.js +1 -0
- package/dist/kernel/host-apiproxy/lib/types/api/sessions.d.ts +4 -0
- package/dist/kernel/host-apiproxy/lib/types/api/sessions.schema.js +1 -0
- package/dist/kernel/host-apiproxy/lib/types/api-proxy.js +15 -53
- package/dist/kernel/host-apiproxy/package.json +1 -1
- package/dist/kernel/host-directory-picker/package.json +1 -1
- package/dist/kernel/host-directory-picker-auto/package.json +1 -1
- package/dist/kernel/host-directory-picker-browse/package.json +1 -1
- package/dist/kernel/host-directory-picker-native/package.json +1 -1
- package/dist/kernel/host-frontend-static/lib/index.js +34 -26
- package/dist/kernel/host-frontend-static/lib/types/index.d.ts +10 -10
- package/dist/kernel/host-frontend-static/lib/types/index.js +38 -27
- package/dist/kernel/host-frontend-static/package.json +2 -2
- package/dist/kernel/host-plugin-inventory/package.json +1 -1
- package/dist/kernel/host-webserver/lib/index.js +102 -6
- package/dist/kernel/host-webserver/lib/types/index.d.ts +33 -5
- package/dist/kernel/host-webserver/lib/types/index.js +28 -5
- package/dist/kernel/host-webserver/lib/types/injections.d.ts +56 -0
- package/dist/kernel/host-webserver/lib/types/injections.js +82 -0
- package/dist/kernel/host-webserver/package.json +1 -1
- package/dist/kernel/invariants/package.json +1 -1
- package/dist/kernel/jobs/package.json +1 -1
- package/dist/kernel/jobs-local/package.json +1 -1
- package/dist/kernel/launch-environment/package.json +1 -1
- package/dist/kernel/llm/lib/index.js +247 -25
- package/dist/kernel/llm/lib/types/assembler.d.ts +10 -1
- package/dist/kernel/llm/lib/types/assembler.js +20 -1
- package/dist/kernel/llm/lib/types/content.d.ts +59 -0
- package/dist/kernel/llm/lib/types/content.js +149 -0
- package/dist/kernel/llm/lib/types/index.d.ts +24 -1
- package/dist/kernel/llm/lib/types/index.js +61 -8
- package/dist/kernel/llm/lib/types/retry-policy.d.ts +1 -1
- package/dist/kernel/llm/lib/types/retry-policy.js +6 -2
- package/dist/kernel/llm/package.json +1 -1
- package/dist/kernel/llm-deepseek/lib/index.js +1100 -70
- package/dist/kernel/llm-deepseek/lib/types/adapter.d.ts +69 -1
- package/dist/kernel/llm-deepseek/lib/types/adapter.js +296 -60
- package/dist/kernel/llm-deepseek/lib/types/file-id.d.ts +19 -0
- package/dist/kernel/llm-deepseek/lib/types/file-id.js +18 -0
- package/dist/kernel/llm-deepseek/lib/types/file-store.d.ts +83 -0
- package/dist/kernel/llm-deepseek/lib/types/file-store.js +261 -0
- package/dist/kernel/llm-deepseek/lib/types/files-api.d.ts +103 -0
- package/dist/kernel/llm-deepseek/lib/types/files-api.js +206 -0
- package/dist/kernel/llm-deepseek/lib/types/index.d.ts +31 -3
- package/dist/kernel/llm-deepseek/lib/types/index.js +139 -3
- package/dist/kernel/llm-deepseek/lib/types/serialize.d.ts +55 -6
- package/dist/kernel/llm-deepseek/lib/types/serialize.js +179 -23
- package/dist/kernel/llm-deepseek/lib/types/types.d.ts +28 -5
- package/dist/kernel/llm-deepseek/lib/types/upload-index.d.ts +68 -0
- package/dist/kernel/llm-deepseek/lib/types/upload-index.js +171 -0
- package/dist/kernel/llm-deepseek/package.json +9 -1
- package/dist/kernel/llm-pi-ai/lib/index.js +1758 -1171
- package/dist/kernel/llm-pi-ai/lib/types/adapter.d.ts +30 -5
- package/dist/kernel/llm-pi-ai/lib/types/adapter.js +43 -23
- package/dist/kernel/llm-pi-ai/lib/types/auth.d.ts +60 -0
- package/dist/kernel/llm-pi-ai/lib/types/auth.js +196 -0
- package/dist/kernel/llm-pi-ai/lib/types/catalog.d.ts +176 -38
- package/dist/kernel/llm-pi-ai/lib/types/catalog.js +245 -50
- package/dist/kernel/llm-pi-ai/lib/types/config.d.ts +37 -5
- package/dist/kernel/llm-pi-ai/lib/types/config.js +67 -2
- package/dist/kernel/llm-pi-ai/lib/types/context.d.ts +8 -3
- package/dist/kernel/llm-pi-ai/lib/types/context.js +60 -16
- package/dist/kernel/llm-pi-ai/lib/types/index.d.ts +1 -0
- package/dist/kernel/llm-pi-ai/lib/types/index.js +21 -19
- package/dist/kernel/llm-pi-ai/lib/types/login.d.ts +21 -0
- package/dist/kernel/llm-pi-ai/lib/types/login.js +154 -0
- package/dist/kernel/llm-pi-ai/lib/types/stream.js +4 -0
- package/dist/kernel/llm-pi-ai/package.json +3 -1
- package/dist/kernel/llm-retry/package.json +1 -1
- package/dist/kernel/lsp/package.json +1 -1
- package/dist/kernel/lsp-stdio/package.json +1 -1
- package/dist/kernel/manifest.json +10 -2
- package/dist/kernel/mcp-client/package.json +1 -1
- package/dist/kernel/message-feedback/package.json +1 -1
- package/dist/kernel/native-command/package.json +1 -1
- package/dist/kernel/node-addon-landlock-run/lib/index.js +1 -1
- package/dist/kernel/node-addon-landlock-run/package.json +4 -2
- package/dist/kernel/output-retention/package.json +1 -1
- package/dist/kernel/permission-presets/lib/index.js +14 -2
- package/dist/kernel/permission-presets/lib/types/index.d.ts +5 -0
- package/dist/kernel/permission-presets/lib/types/index.js +11 -2
- package/dist/kernel/permission-presets/package.json +1 -1
- package/dist/kernel/persona/package.json +1 -1
- package/dist/kernel/plan-mode/lib/index.js +49 -15
- package/dist/kernel/plan-mode/lib/types/index.d.ts +22 -0
- package/dist/kernel/plan-mode/lib/types/index.js +45 -19
- package/dist/kernel/plan-mode/lib/types/types.d.ts +5 -4
- package/dist/kernel/plan-mode/package.json +1 -1
- package/dist/kernel/pwsh-local/package.json +1 -1
- package/dist/kernel/pwsh-sandbox/package.json +1 -1
- package/dist/kernel/repeat-tool-reminder/lib/index.js +1 -1
- package/dist/kernel/repeat-tool-reminder/package.json +1 -1
- package/dist/kernel/sandbox/package.json +1 -1
- package/dist/kernel/sandbox-local/lib/index.js +8 -13
- package/dist/kernel/sandbox-local/lib/types/index.d.ts +1 -3
- package/dist/kernel/sandbox-local/lib/types/index.js +4 -7
- package/dist/kernel/sandbox-local/lib/types/profiles.js +1 -1
- package/dist/kernel/sandbox-local/package.json +1 -1
- package/dist/kernel/sandbox-policy/package.json +1 -1
- package/dist/kernel/sandbox-windows-acl/package.json +1 -1
- package/dist/kernel/schedule/package.json +1 -1
- package/dist/kernel/schemastery/package.json +3 -1
- package/dist/kernel/scope/package.json +1 -1
- package/dist/kernel/sdk-client/lib/index.js +2 -2
- package/dist/kernel/sdk-client/lib/types/api.js +2 -2
- package/dist/kernel/sdk-client/lib/types/types.d.ts +4 -4
- package/dist/kernel/sdk-client/package.json +1 -1
- package/dist/kernel/sdk-jsonrpc-server/lib/index.js +12 -5
- package/dist/kernel/sdk-jsonrpc-server/lib/types/index.js +7 -0
- package/dist/kernel/sdk-jsonrpc-server/lib/types/server.d.ts +2 -1
- package/dist/kernel/sdk-jsonrpc-server/lib/types/server.js +15 -6
- package/dist/kernel/sdk-jsonrpc-server/package.json +2 -1
- package/dist/kernel/sdk-protocol/package.json +1 -1
- package/dist/kernel/session/lib/index.js +4 -0
- package/dist/kernel/session/lib/types/known-event-types.js +4 -0
- package/dist/kernel/session/lib/types/types.d.ts +6 -1
- package/dist/kernel/session/package.json +1 -1
- package/dist/kernel/session-checkpoint-policy/package.json +1 -1
- package/dist/kernel/session-log-export/package.json +2 -5
- package/dist/kernel/session-persistence/lib/index.js +1 -1
- package/dist/kernel/session-persistence/lib/types/coordinator.js +2 -1
- package/dist/kernel/session-persistence/package.json +1 -1
- package/dist/kernel/session-persistence-jsonl/package.json +1 -1
- package/dist/kernel/session-persistence-sqlite/lib/index.js +1105 -375
- package/dist/kernel/session-persistence-sqlite/lib/invariant.js +2 -2
- package/dist/kernel/session-persistence-sqlite/lib/types/codec.d.ts +72 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/codec.js +304 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/compression.d.ts +46 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/compression.js +234 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/index.d.ts +22 -80
- package/dist/kernel/session-persistence-sqlite/lib/types/index.js +27 -278
- package/dist/kernel/session-persistence-sqlite/lib/types/invariant.js +2 -2
- package/dist/kernel/session-persistence-sqlite/lib/types/schema.d.ts +63 -85
- package/dist/kernel/session-persistence-sqlite/lib/types/schema.js +293 -159
- package/dist/kernel/session-persistence-sqlite/lib/types/sql.d.ts +15 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/sql.js +57 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/store.d.ts +66 -0
- package/dist/kernel/session-persistence-sqlite/lib/types/store.js +394 -0
- package/dist/kernel/session-persistence-sqlite/package.json +9 -3
- package/dist/kernel/session-persistence-sqlite/resources/sql/begin-immediate.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/begin.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/commit.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/delete-events-from.sql +2 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/foreign-keys-on.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/insert-event.sql +3 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/insert-persistence-state.sql +2 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/journal-mode-delete.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/journal-mode-persist.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/journal-mode-truncate.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/journal-mode-wal.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/mmap-off.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/rollback.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/schema.sql +30 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-application-id.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-events-from.sql +4 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-events.sql +4 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-mmap-size.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-packed-predecessors.sql +6 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-schema-objects.sql +4 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-session.sql +4 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-sessions.sql +3 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-store-id.sql +3 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-synchronous.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-tail-events.sql +5 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-trusted-schema.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-user-object-count.sql +3 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/select-user-version.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/set-application-id.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/set-user-version-17.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/synchronous-full.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/trusted-schema-off.sql +1 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/update-session-revision.sql +3 -0
- package/dist/kernel/session-persistence-sqlite/resources/sql/upsert-session.sql +13 -0
- package/dist/kernel/session-projection/lib/index.js +55 -30
- package/dist/kernel/session-projection/lib/types/index.d.ts +57 -34
- package/dist/kernel/session-projection/lib/types/index.js +61 -36
- package/dist/kernel/session-projection/lib/types/types.d.ts +11 -4
- package/dist/kernel/session-projection/package.json +1 -1
- package/dist/kernel/session-projection-cache/lib/index.js +1 -1
- package/dist/kernel/session-projection-cache/lib/types/index.d.ts +1 -1
- package/dist/kernel/session-projection-cache/lib/types/index.js +4 -5
- package/dist/kernel/session-projection-cache/package.json +1 -1
- package/dist/kernel/session-query/package.json +1 -1
- package/dist/kernel/session-query-sqlite/package.json +1 -1
- package/dist/kernel/session-reference/lib/index.js +232 -110
- package/dist/kernel/session-reference/lib/typert.host.d.ts +3 -0
- package/dist/kernel/session-reference/lib/typert.host.js +458 -0
- package/dist/kernel/session-reference/lib/typert.remote-client.d.ts +26 -0
- package/dist/kernel/session-reference/lib/typert.remote-client.js +62 -0
- package/dist/kernel/session-reference/lib/types/index.d.ts +25 -5
- package/dist/kernel/session-reference/lib/types/index.js +230 -126
- package/dist/kernel/session-reference/lib/types/types.d.ts +14 -3
- package/dist/kernel/session-reference/lib/types/types.js +6 -1
- package/dist/kernel/session-reference/package.json +23 -3
- package/dist/kernel/session-stats/lib/index.js +31 -12
- package/dist/kernel/session-stats/lib/types/projection.d.ts +64 -2
- package/dist/kernel/session-stats/lib/types/projection.js +31 -12
- package/dist/kernel/session-stats/package.json +1 -1
- package/dist/kernel/session-telemetry/package.json +1 -1
- package/dist/kernel/session-telemetry-otel/package.json +1 -1
- package/dist/kernel/session-title/lib/index.js +6 -2
- package/dist/kernel/session-title/lib/types/index.js +3 -2
- package/dist/kernel/session-title/lib/types/types.d.ts +3 -0
- package/dist/kernel/session-title/package.json +1 -1
- package/dist/kernel/session-title-all-prompts-llm/package.json +1 -1
- package/dist/kernel/session-title-first-prompt-llm/package.json +1 -1
- package/dist/kernel/session-title-llm/package.json +1 -1
- package/dist/kernel/settings/package.json +1 -1
- package/dist/kernel/settings-file/package.json +1 -1
- package/dist/kernel/shell/package.json +1 -1
- package/dist/kernel/shell-env/package.json +1 -1
- package/dist/kernel/skill/package.json +1 -1
- package/dist/kernel/skill-badge/assets/nomix-badge.md +6 -6
- package/dist/kernel/skill-badge/assets/nomix-badge.png +0 -0
- package/dist/kernel/skill-badge/lib/index.js +1 -1
- package/dist/kernel/skill-badge/lib/types/index.js +1 -1
- package/dist/kernel/skill-badge/package.json +1 -1
- package/dist/kernel/skill-filesystem/package.json +1 -1
- package/dist/kernel/spill/package.json +1 -1
- package/dist/kernel/spill-local/package.json +1 -1
- package/dist/kernel/spill-policy/package.json +1 -1
- package/dist/kernel/storage/package.json +1 -1
- package/dist/kernel/storage-domain/package.json +1 -1
- package/dist/kernel/storage-json/package.json +1 -1
- package/dist/kernel/storage-sqlite/package.json +1 -1
- package/dist/kernel/subagent/lib/index.js +123 -20
- package/dist/kernel/subagent/lib/types/continuation.d.ts +21 -2
- package/dist/kernel/subagent/lib/types/continuation.js +58 -7
- package/dist/kernel/subagent/lib/types/index.d.ts +11 -0
- package/dist/kernel/subagent/lib/types/index.js +16 -0
- package/dist/kernel/subagent/lib/types/out-of-process.d.ts +2 -0
- package/dist/kernel/subagent/lib/types/out-of-process.js +31 -1
- package/dist/kernel/subagent/lib/types/projection.d.ts +55 -8
- package/dist/kernel/subagent/lib/types/projection.js +30 -15
- package/dist/kernel/subagent/lib/types/run-settlement.js +10 -3
- package/dist/kernel/subagent/lib/types/types.d.ts +7 -0
- package/dist/kernel/subagent/package.json +1 -1
- package/dist/kernel/subagent-acp/package.json +1 -1
- package/dist/kernel/subagent-claude-code/cordis.patch.yml +6 -0
- package/dist/kernel/subagent-claude-code/lib/index.js +267 -73
- package/dist/kernel/subagent-claude-code/lib/types/index.d.ts +16 -6
- package/dist/kernel/subagent-claude-code/lib/types/index.js +35 -14
- package/dist/kernel/subagent-claude-code/lib/types/process.d.ts +5 -7
- package/dist/kernel/subagent-claude-code/lib/types/process.js +12 -24
- package/dist/kernel/subagent-claude-code/lib/types/run.d.ts +24 -7
- package/dist/kernel/subagent-claude-code/lib/types/run.js +266 -40
- package/dist/kernel/subagent-claude-code/package.json +10 -2
- package/dist/kernel/subagent-codex/cordis.patch.yml +5 -0
- package/dist/kernel/subagent-codex/lib/index.js +482 -91
- package/dist/kernel/subagent-codex/lib/types/index.d.ts +11 -6
- package/dist/kernel/subagent-codex/lib/types/index.js +33 -12
- package/dist/kernel/subagent-codex/lib/types/run.d.ts +17 -8
- package/dist/kernel/subagent-codex/lib/types/run.js +235 -42
- package/dist/kernel/subagent-codex/lib/types/wire.d.ts +49 -1
- package/dist/kernel/subagent-codex/lib/types/wire.js +280 -33
- package/dist/kernel/subagent-codex/package.json +10 -5
- package/dist/kernel/subagent-fork-in-process/package.json +1 -1
- package/dist/kernel/subagent-in-process-driver/package.json +1 -1
- package/dist/kernel/subagent-nomix-sdk/package.json +1 -1
- package/dist/kernel/subagent-spawn-in-process/package.json +1 -1
- package/dist/kernel/subprocess/package.json +1 -1
- package/dist/kernel/subprocess-e2b/package.json +1 -1
- package/dist/kernel/subprocess-local/lib/index.js +303 -1
- package/dist/kernel/subprocess-local/lib/types/process-inspector.js +3 -0
- package/dist/kernel/subprocess-local/lib/types/terminal.d.ts +6 -1
- package/dist/kernel/subprocess-local/lib/types/terminal.js +78 -1
- package/dist/kernel/subprocess-local/lib/types/windows-inspector.d.ts +80 -0
- package/dist/kernel/subprocess-local/lib/types/windows-inspector.js +259 -0
- package/dist/kernel/subprocess-local/package.json +2 -1
- package/dist/kernel/system-prompt/package.json +1 -1
- package/dist/kernel/terminal/package.json +1 -1
- package/dist/kernel/terminal-bash/lib/index.js +85 -20
- package/dist/kernel/terminal-bash/lib/types/config.d.ts +29 -5
- package/dist/kernel/terminal-bash/lib/types/config.js +33 -3
- package/dist/kernel/terminal-bash/lib/types/index.d.ts +7 -0
- package/dist/kernel/terminal-bash/lib/types/index.js +65 -13
- package/dist/kernel/terminal-bash/package.json +2 -1
- package/dist/kernel/time-context/lib/index.js +1 -1
- package/dist/kernel/time-context/lib/invariant.js +1 -1
- package/dist/kernel/time-context/package.json +1 -1
- package/dist/kernel/timeout/package.json +1 -1
- package/dist/kernel/tmux-context/lib/index.js +1 -1
- package/dist/kernel/tmux-context/package.json +1 -1
- package/dist/kernel/token-meter/lib/index.js +77 -21
- package/dist/kernel/token-meter/lib/types/breakdown-projection.d.ts +76 -9
- package/dist/kernel/token-meter/lib/types/breakdown-projection.js +22 -6
- package/dist/kernel/token-meter/lib/types/usage-projection.d.ts +186 -25
- package/dist/kernel/token-meter/lib/types/usage-projection.js +44 -15
- package/dist/kernel/token-meter/package.json +1 -1
- package/dist/kernel/tool-ask-user/package.json +1 -1
- package/dist/kernel/tool-bash/package.json +1 -1
- package/dist/kernel/tool-bash-persistent/lib/index.js +15 -5
- package/dist/kernel/tool-bash-persistent/lib/types/index.js +23 -6
- package/dist/kernel/tool-bash-persistent/package.json +1 -1
- package/dist/kernel/tool-call-timeout-policy/package.json +1 -1
- package/dist/kernel/tool-cordis/lib/index.js +655 -83
- package/dist/kernel/tool-cordis/lib/types/api-catalog.js +439 -41
- package/dist/kernel/tool-cordis/package.json +1 -1
- package/dist/kernel/tool-fs/lib/index.js +80 -52
- package/dist/kernel/tool-fs/lib/types/read-image.d.ts +16 -12
- package/dist/kernel/tool-fs/lib/types/read-image.js +73 -29
- package/dist/kernel/tool-fs/package.json +1 -1
- package/dist/kernel/tool-fs-search/lib/index.js +11 -7
- package/dist/kernel/tool-fs-search/lib/types/search-core.d.ts +5 -6
- package/dist/kernel/tool-fs-search/lib/types/search-core.js +12 -7
- package/dist/kernel/tool-fs-search/package.json +1 -1
- package/dist/kernel/tool-goal/package.json +1 -1
- package/dist/kernel/tool-jobs/package.json +1 -1
- package/dist/kernel/tool-lsp/package.json +1 -1
- package/dist/kernel/tool-pwsh/package.json +1 -1
- package/dist/kernel/tool-pwsh-persistent/lib/index.js +407 -0
- package/dist/kernel/tool-pwsh-persistent/lib/invariant.js +24 -0
- package/dist/kernel/tool-pwsh-persistent/lib/types/index.d.ts +24 -0
- package/dist/kernel/tool-pwsh-persistent/lib/types/index.js +465 -0
- package/dist/kernel/tool-pwsh-persistent/lib/types/invariant.d.ts +16 -0
- package/dist/kernel/tool-pwsh-persistent/lib/types/invariant.js +23 -0
- package/dist/kernel/tool-pwsh-persistent/package.json +62 -0
- package/dist/kernel/tool-ralph/package.json +1 -1
- package/dist/kernel/tool-session-query/package.json +1 -1
- package/dist/kernel/tool-skill/package.json +1 -1
- package/dist/kernel/tool-str-replace-editor/package.json +1 -1
- package/dist/kernel/tool-subagent/lib/index.js +10 -8
- package/dist/kernel/tool-subagent/lib/types/index.js +15 -8
- package/dist/kernel/tool-subagent/package.json +1 -1
- package/dist/kernel/tool-subagent-control/package.json +1 -1
- package/dist/kernel/tool-subagent-report/lib/index.js +1 -1
- package/dist/kernel/tool-subagent-report/lib/types/index.d.ts +3 -3
- package/dist/kernel/tool-subagent-report/lib/types/index.js +1 -1
- package/dist/kernel/tool-subagent-report/package.json +1 -1
- package/dist/kernel/tool-terminal/package.json +1 -1
- package/dist/kernel/tool-todo/lib/index.js +5 -2
- package/dist/kernel/tool-todo/lib/types/index.js +2 -2
- package/dist/kernel/tool-todo/lib/types/types.d.ts +3 -0
- package/dist/kernel/tool-todo/package.json +1 -1
- package/dist/kernel/tool-web/lib/index.js +101 -26
- package/dist/kernel/tool-web/lib/types/index.d.ts +4 -2
- package/dist/kernel/tool-web/lib/types/index.js +5 -3
- package/dist/kernel/tool-web/lib/types/search.d.ts +23 -20
- package/dist/kernel/tool-web/lib/types/search.js +109 -20
- package/dist/kernel/tool-web/package.json +1 -1
- package/dist/kernel/tool-workflow/package.json +1 -1
- package/dist/kernel/tools/package.json +1 -1
- package/dist/kernel/typert-generator/lib/index.js +8 -3
- package/dist/kernel/typert-generator/lib/types/cordis-catalog.js +8 -3
- package/dist/kernel/typert-generator/package.json +1 -1
- package/dist/kernel/typert-loader/package.json +1 -1
- package/dist/kernel/typert-protocol/package.json +1 -1
- package/dist/kernel/typert-registry/package.json +1 -1
- package/dist/kernel/user-approval/package.json +1 -1
- package/dist/kernel/user-questions/package.json +1 -1
- package/dist/kernel/web/lib/types/types.d.ts +4 -3
- package/dist/kernel/web/package.json +1 -1
- package/dist/kernel/web-app/cordis.patch.yml +27 -6
- package/dist/kernel/web-app/lib/index.js +111 -15
- package/dist/kernel/web-app/lib/startup.js +4 -2
- package/dist/kernel/web-app/lib/types/index.d.ts +8 -4
- package/dist/kernel/web-app/lib/types/index.js +116 -23
- package/dist/kernel/web-app/lib/types/startup.d.ts +3 -1
- package/dist/kernel/web-app/lib/types/startup.js +4 -1
- package/dist/kernel/web-app/package.json +12 -2
- package/dist/kernel/web-fetch-http/lib/index.js +1 -1
- package/dist/kernel/web-fetch-http/lib/types/index.d.ts +1 -1
- package/dist/kernel/web-fetch-http/lib/types/index.js +1 -1
- package/dist/kernel/web-fetch-http/package.json +1 -1
- package/dist/kernel/web-frontend/dist/assets/index-BnapMmQ_.css +1 -0
- package/dist/kernel/web-frontend/dist/assets/index-Dx7Ws_OC.js +96 -0
- package/dist/kernel/web-frontend/dist/assets/langs/{php-D-uCvoST.js → php-DDkx9sim.js} +2 -2
- package/dist/{assets/web/assets/langs/ruby-DEItuUFs.js → kernel/web-frontend/dist/assets/langs/ruby-DCxyoPen.js} +2 -2
- package/dist/kernel/web-frontend/dist/assets/{vendor-Cjbwl5VI.js → vendor-D22_Mp1f.js} +2 -2
- package/dist/kernel/web-frontend/dist/favicon.svg +8 -0
- package/dist/kernel/web-frontend/dist/index.html +5 -5
- package/dist/kernel/web-frontend/package.json +5 -8
- package/dist/kernel/web-search-deepseek/lib/index.js +1 -1
- package/dist/kernel/web-search-deepseek/lib/types/provider.js +1 -1
- package/dist/kernel/web-search-deepseek/package.json +1 -1
- package/dist/kernel/web-search-exa/lib/index.js +1 -1
- package/dist/kernel/web-search-exa/lib/types/provider.js +1 -1
- package/dist/kernel/web-search-exa/package.json +1 -1
- package/dist/kernel/web-search-perplexity/lib/index.js +1 -1
- package/dist/kernel/web-search-perplexity/lib/types/provider.js +1 -1
- package/dist/kernel/web-search-perplexity/package.json +1 -1
- package/dist/kernel/workflow/package.json +1 -1
- package/dist/kernel/workflow-worker-thread/package.json +1 -1
- package/dist/kernel/workspace/package.json +1 -1
- package/dist/plugins/manifest.json +50 -10
- package/dist/runtime/index.js +0 -2
- package/package.json +8 -6
- package/dist/assets/web/assets/index-B_fSXASy.css +0 -1
- package/dist/assets/web/assets/index-B_sZ-Gsu.js +0 -112
- package/dist/cli/builtin-registry.d.ts +0 -5
- package/dist/cli/profile-boot-CeU09iFc.js +0 -2
- package/dist/kernel/app-boot/lib/types/legacy-branding.d.ts +0 -6
- package/dist/kernel/app-boot/lib/types/legacy-branding.js +0 -18
- package/dist/kernel/client-schema-form/lib/index.js +0 -137
- package/dist/kernel/client-schema-form/lib/types/index.d.ts +0 -10
- package/dist/kernel/client-schema-form/lib/types/index.js +0 -9
- package/dist/kernel/client-schema-form/lib/types/model.d.ts +0 -66
- package/dist/kernel/client-schema-form/lib/types/model.js +0 -153
- package/dist/kernel/client-ui-subagent/lib/types/client/SubagentCatalogAction.d.ts +0 -18
- package/dist/kernel/client-ui-theme/lib/styles/base.css +0 -15
- package/dist/kernel/client-ui-theme/lib/styles/design-platform.css +0 -338
- package/dist/kernel/client-ui-theme/lib/styles/gradient-shadow-text.css +0 -232
- package/dist/kernel/client-ui-theme/lib/styles/scrollbar.css +0 -90
- package/dist/kernel/client-ui-theme/lib/styles/shiki.css +0 -31
- package/dist/kernel/client-web/lib/types/AppRoot.d.ts +0 -16
- package/dist/kernel/client-web/lib/types/AppRoot.js +0 -27
- package/dist/kernel/client-web/lib/types/DocumentTitle.js +0 -16
- package/dist/kernel/client-web/lib/types/app-shell.d.ts +0 -28
- package/dist/kernel/client-web/lib/types/app-shell.js +0 -27
- package/dist/kernel/client-web/lib/types/app.d.ts +0 -21
- package/dist/kernel/client-web-react/lib/index.js +0 -810
- package/dist/kernel/client-web-react/lib/types/index.d.ts +0 -16
- package/dist/kernel/client-web-react/lib/types/index.js +0 -6
- package/dist/kernel/client-web-react/lib/types/use-invoke.d.ts +0 -9
- package/dist/kernel/client-web-react/lib/types/use-invoke.js +0 -52
- package/dist/kernel/skill-badge/assets/nomix-badge.svg +0 -8
- package/dist/kernel/web-frontend/dist/assets/index-B_fSXASy.css +0 -1
- package/dist/kernel/web-frontend/dist/assets/index-B_sZ-Gsu.js +0 -112
- /package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/bind.js +0 -0
- /package/dist/kernel/{client-web-react/lib/types → client-ui-renderer/lib/types/client}/session-provider.js +0 -0
|
@@ -0,0 +1,989 @@
|
|
|
1
|
+
window.__ModuleLoader__.load({
|
|
2
|
+
id: "@nomix-ai/nomix-client-ui-renderer",
|
|
3
|
+
factory: (require) => {
|
|
4
|
+
var module = { exports: {} };
|
|
5
|
+
var exports = module.exports;
|
|
6
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
7
|
+
//#region \0rolldown/runtime.js
|
|
8
|
+
var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
|
|
9
|
+
//#endregion
|
|
10
|
+
let react = require("react");
|
|
11
|
+
let react_dom = require("react-dom");
|
|
12
|
+
let react_dom_client = require("react-dom/client");
|
|
13
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
14
|
+
let _nomix_ai_nomix_client_ui_slots = require("@nomix-ai/nomix-client-ui-slots");
|
|
15
|
+
//#region ../../../node_modules/.pnpm/use-sync-external-store@1.2.0_react@18.3.1/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js
|
|
16
|
+
/**
|
|
17
|
+
* @license React
|
|
18
|
+
* use-sync-external-store-shim.production.min.js
|
|
19
|
+
*
|
|
20
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
21
|
+
*
|
|
22
|
+
* This source code is licensed under the MIT license found in the
|
|
23
|
+
* LICENSE file in the root directory of this source tree.
|
|
24
|
+
*/
|
|
25
|
+
var require_use_sync_external_store_shim_production_min = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
26
|
+
var e = require("react");
|
|
27
|
+
function h(a, b) {
|
|
28
|
+
return a === b && (0 !== a || 1 / a === 1 / b) || a !== a && b !== b;
|
|
29
|
+
}
|
|
30
|
+
var k = "function" === typeof Object.is ? Object.is : h, l = e.useState, m = e.useEffect, n = e.useLayoutEffect, p = e.useDebugValue;
|
|
31
|
+
function q(a, b) {
|
|
32
|
+
var d = b(), f = l({ inst: {
|
|
33
|
+
value: d,
|
|
34
|
+
getSnapshot: b
|
|
35
|
+
} }), c = f[0].inst, g = f[1];
|
|
36
|
+
n(function() {
|
|
37
|
+
c.value = d;
|
|
38
|
+
c.getSnapshot = b;
|
|
39
|
+
r(c) && g({ inst: c });
|
|
40
|
+
}, [
|
|
41
|
+
a,
|
|
42
|
+
d,
|
|
43
|
+
b
|
|
44
|
+
]);
|
|
45
|
+
m(function() {
|
|
46
|
+
r(c) && g({ inst: c });
|
|
47
|
+
return a(function() {
|
|
48
|
+
r(c) && g({ inst: c });
|
|
49
|
+
});
|
|
50
|
+
}, [a]);
|
|
51
|
+
p(d);
|
|
52
|
+
return d;
|
|
53
|
+
}
|
|
54
|
+
function r(a) {
|
|
55
|
+
var b = a.getSnapshot;
|
|
56
|
+
a = a.value;
|
|
57
|
+
try {
|
|
58
|
+
var d = b();
|
|
59
|
+
return !k(a, d);
|
|
60
|
+
} catch (f) {
|
|
61
|
+
return !0;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
function t(a, b) {
|
|
65
|
+
return b();
|
|
66
|
+
}
|
|
67
|
+
var u = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? t : q;
|
|
68
|
+
exports.useSyncExternalStore = void 0 !== e.useSyncExternalStore ? e.useSyncExternalStore : u;
|
|
69
|
+
}));
|
|
70
|
+
//#endregion
|
|
71
|
+
//#region ../../../node_modules/.pnpm/use-sync-external-store@1.2.0_react@18.3.1/node_modules/use-sync-external-store/shim/index.js
|
|
72
|
+
var require_shim = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
73
|
+
module.exports = require_use_sync_external_store_shim_production_min();
|
|
74
|
+
}));
|
|
75
|
+
//#endregion
|
|
76
|
+
//#region ../../../node_modules/.pnpm/use-sync-external-store@1.2.0_react@18.3.1/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.min.js
|
|
77
|
+
/**
|
|
78
|
+
* @license React
|
|
79
|
+
* use-sync-external-store-shim/with-selector.production.min.js
|
|
80
|
+
*
|
|
81
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
82
|
+
*
|
|
83
|
+
* This source code is licensed under the MIT license found in the
|
|
84
|
+
* LICENSE file in the root directory of this source tree.
|
|
85
|
+
*/
|
|
86
|
+
var require_with_selector_production_min = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
87
|
+
var h = require("react"), n = require_shim();
|
|
88
|
+
function p(a, b) {
|
|
89
|
+
return a === b && (0 !== a || 1 / a === 1 / b) || a !== a && b !== b;
|
|
90
|
+
}
|
|
91
|
+
var q = "function" === typeof Object.is ? Object.is : p, r = n.useSyncExternalStore, t = h.useRef, u = h.useEffect, v = h.useMemo, w = h.useDebugValue;
|
|
92
|
+
exports.useSyncExternalStoreWithSelector = function(a, b, e, l, g) {
|
|
93
|
+
var c = t(null);
|
|
94
|
+
if (null === c.current) {
|
|
95
|
+
var f = {
|
|
96
|
+
hasValue: !1,
|
|
97
|
+
value: null
|
|
98
|
+
};
|
|
99
|
+
c.current = f;
|
|
100
|
+
} else f = c.current;
|
|
101
|
+
c = v(function() {
|
|
102
|
+
function a(a) {
|
|
103
|
+
if (!c) {
|
|
104
|
+
c = !0;
|
|
105
|
+
d = a;
|
|
106
|
+
a = l(a);
|
|
107
|
+
if (void 0 !== g && f.hasValue) {
|
|
108
|
+
var b = f.value;
|
|
109
|
+
if (g(b, a)) return k = b;
|
|
110
|
+
}
|
|
111
|
+
return k = a;
|
|
112
|
+
}
|
|
113
|
+
b = k;
|
|
114
|
+
if (q(d, a)) return b;
|
|
115
|
+
var e = l(a);
|
|
116
|
+
if (void 0 !== g && g(b, e)) return b;
|
|
117
|
+
d = a;
|
|
118
|
+
return k = e;
|
|
119
|
+
}
|
|
120
|
+
var c = !1, d, k, m = void 0 === e ? null : e;
|
|
121
|
+
return [function() {
|
|
122
|
+
return a(b());
|
|
123
|
+
}, null === m ? void 0 : function() {
|
|
124
|
+
return a(m());
|
|
125
|
+
}];
|
|
126
|
+
}, [
|
|
127
|
+
b,
|
|
128
|
+
e,
|
|
129
|
+
l,
|
|
130
|
+
g
|
|
131
|
+
]);
|
|
132
|
+
var d = r(a, c[0], c[1]);
|
|
133
|
+
u(function() {
|
|
134
|
+
f.hasValue = !0;
|
|
135
|
+
f.value = d;
|
|
136
|
+
}, [d]);
|
|
137
|
+
w(d);
|
|
138
|
+
return d;
|
|
139
|
+
};
|
|
140
|
+
}));
|
|
141
|
+
//#endregion
|
|
142
|
+
//#region lib/types/client/bind.js
|
|
143
|
+
var import_with_selector = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
144
|
+
module.exports = require_with_selector_production_min();
|
|
145
|
+
})))();
|
|
146
|
+
/**
|
|
147
|
+
* Bind a bare observable source to a typed uSES selector hook.
|
|
148
|
+
* subscribe/getSnapshot are captured once per source into stable closures
|
|
149
|
+
* (also re-binds `this` for method-based sources), so components never
|
|
150
|
+
* resubscribe across renders. Equality defaults to Object.is.
|
|
151
|
+
* @param w - snapshot source (engine store, Session object, store instance).
|
|
152
|
+
* @returns the selector hook.
|
|
153
|
+
*/
|
|
154
|
+
function bindSnapshotSelector(w) {
|
|
155
|
+
const subscribe = (fn) => w.subscribe(fn);
|
|
156
|
+
const getSnapshot = () => w.getSnapshot();
|
|
157
|
+
return function useSelector(sel, eq) {
|
|
158
|
+
return (0, import_with_selector.useSyncExternalStoreWithSelector)(subscribe, getSnapshot, void 0, sel, eq);
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
//#endregion
|
|
162
|
+
//#region lib/types/client/session-provider.js
|
|
163
|
+
/** Internal React bindings for the renderer host and active session provide bundle. */
|
|
164
|
+
/**
|
|
165
|
+
* A missing-provider assembly error: the shell wired the tree wrong. The slot
|
|
166
|
+
* error boundary rethrows this class so misassembly stays fail-loud while
|
|
167
|
+
* registrant errors (inject factories, entry components) are contained
|
|
168
|
+
* per entry.
|
|
169
|
+
*/
|
|
170
|
+
var SlotAssemblyError = class extends Error {};
|
|
171
|
+
/** In-package renderer host context. */
|
|
172
|
+
const HostContext = (0, react.createContext)(null);
|
|
173
|
+
/**
|
|
174
|
+
* Read the installed renderer host; throws outside the rendered root tree
|
|
175
|
+
* (framework components must not render detached from the renderer).
|
|
176
|
+
* @returns the host API.
|
|
177
|
+
*/
|
|
178
|
+
function useHost() {
|
|
179
|
+
const host = (0, react.useContext)(HostContext);
|
|
180
|
+
if (!host) throw new SlotAssemblyError("slot machinery rendered outside the installed renderer tree");
|
|
181
|
+
return host;
|
|
182
|
+
}
|
|
183
|
+
const BindingContext = (0, react.createContext)(null);
|
|
184
|
+
/** Read the current-session-optional bundle supplied at the root. */
|
|
185
|
+
function useSessionMaybeProvideInfo() {
|
|
186
|
+
const info = (0, react.useContext)(BindingContext);
|
|
187
|
+
if (!info) throw new SlotAssemblyError("session-aware slot rendered outside the root binding provider");
|
|
188
|
+
return info;
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* Identity-stable selector hook per host observable. uSES resubscribes when
|
|
192
|
+
* the subscribe reference changes, so the bound hook must be created once per
|
|
193
|
+
* source — cached here by source identity (sources are host-owned singletons).
|
|
194
|
+
* @param source - host-provided observable.
|
|
195
|
+
* @returns the cached selector hook.
|
|
196
|
+
*/
|
|
197
|
+
function observableHook(source) {
|
|
198
|
+
let hook = hookCache.get(source);
|
|
199
|
+
if (hook === void 0) {
|
|
200
|
+
hook = bindSnapshotSelector(source);
|
|
201
|
+
hookCache.set(source, hook);
|
|
202
|
+
}
|
|
203
|
+
return hook;
|
|
204
|
+
}
|
|
205
|
+
const hookCache = /* @__PURE__ */ new WeakMap();
|
|
206
|
+
const absentSource = {
|
|
207
|
+
getSnapshot: () => void 0,
|
|
208
|
+
subscribe: () => () => {}
|
|
209
|
+
};
|
|
210
|
+
/** Bind a source that disappears with the current session to an optional selector hook. */
|
|
211
|
+
function maybeObservableHook(source) {
|
|
212
|
+
if (source !== void 0) return observableHook(source);
|
|
213
|
+
return useAbsentSnapshot;
|
|
214
|
+
}
|
|
215
|
+
function useAbsentSnapshot(_selector, _equal) {
|
|
216
|
+
observableHook(absentSource)(() => void 0);
|
|
217
|
+
}
|
|
218
|
+
/**
|
|
219
|
+
* The useProjection framework seat (docs/subsystems/session-projection.md), one bound
|
|
220
|
+
* function per provide bundle (cached by info identity — components may hold
|
|
221
|
+
* it across renders). Key-addressed: the key resolves a per-session value
|
|
222
|
+
* face off the projection store; the bound selector hook comes from the same
|
|
223
|
+
* per-source cache as every other kit hook, so exactly one uSES subscription
|
|
224
|
+
* runs per call and the subscribe reference stays stable per key. A key no
|
|
225
|
+
* baseline or frame has carried (or a no-session bundle) reads `undefined` —
|
|
226
|
+
* capability absence — keeping the hook order constant.
|
|
227
|
+
*/
|
|
228
|
+
function projectionHook(info) {
|
|
229
|
+
let hook = projectionHookCache.get(info);
|
|
230
|
+
if (hook === void 0) {
|
|
231
|
+
hook = (key, selector, eq) => {
|
|
232
|
+
return observableHook(info.projections?.faceOf(key) ?? absentSource)(selector ?? ((value) => value), eq);
|
|
233
|
+
};
|
|
234
|
+
projectionHookCache.set(info, hook);
|
|
235
|
+
}
|
|
236
|
+
return hook;
|
|
237
|
+
}
|
|
238
|
+
const projectionHookCache = /* @__PURE__ */ new WeakMap();
|
|
239
|
+
/**
|
|
240
|
+
* Root-level binding provider. It follows current selection without a key;
|
|
241
|
+
* per-entry identity is the outlet's adoption bookkeeping (SessionMaybeEntry):
|
|
242
|
+
* a blank-born incarnation adopts the first session without remounting, and
|
|
243
|
+
* every later transition (switch or loss) remounts like a strict entry.
|
|
244
|
+
*/
|
|
245
|
+
function SessionMaybeProvider({ children }) {
|
|
246
|
+
const info = observableHook(useHost().sessions.provideInfo)((s) => s);
|
|
247
|
+
return (0, react_jsx_runtime.jsx)(BindingContext.Provider, {
|
|
248
|
+
value: info,
|
|
249
|
+
children
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
/**
|
|
253
|
+
* Framework-wired session area: subscribes to the host's current provide
|
|
254
|
+
* source and remounts the body under `key={sessionId}` so a session switch
|
|
255
|
+
* rebuilds the session subtree. This dependency-inverted layer uses plain
|
|
256
|
+
* string ids; `PropsRuntime` applies the branded type at the component
|
|
257
|
+
* boundary.
|
|
258
|
+
*/
|
|
259
|
+
function SessionProvider({ empty, children }) {
|
|
260
|
+
const info = observableHook(useHost().sessions.provideInfo)((s) => s);
|
|
261
|
+
const id = info.sessionId;
|
|
262
|
+
if (id === void 0) return (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: empty?.() ?? null });
|
|
263
|
+
return (0, react_jsx_runtime.jsx)(BindingContext.Provider, {
|
|
264
|
+
value: info,
|
|
265
|
+
children: children(id)
|
|
266
|
+
}, id);
|
|
267
|
+
}
|
|
268
|
+
//#endregion
|
|
269
|
+
//#region lib/types/client/scoped-slots.js
|
|
270
|
+
/**
|
|
271
|
+
* React renderer for declarative slots. Per-entry bindings enforce child
|
|
272
|
+
* authorization, and entry boundaries contain registrant failures.
|
|
273
|
+
*/
|
|
274
|
+
/**
|
|
275
|
+
* Per-entry renderSlot bindings. The binding is identity-stable per entry
|
|
276
|
+
* (memoized components must not resubscribe on unrelated re-renders) and dies
|
|
277
|
+
* with the entry: a retained closure calling after the entry's disposal hits
|
|
278
|
+
* the in-ledger check and throws.
|
|
279
|
+
*/
|
|
280
|
+
const renderSlotCache = /* @__PURE__ */ new WeakMap();
|
|
281
|
+
function boundRenderSlot(host, entry) {
|
|
282
|
+
let binding = renderSlotCache.get(entry);
|
|
283
|
+
if (!binding) {
|
|
284
|
+
binding = (key, owner, opts) => {
|
|
285
|
+
if (!host.isLive(entry)) throw new _nomix_ai_nomix_client_ui_slots.StaleAuthorizationError(`renderSlot('${key}') from a disposed registration`);
|
|
286
|
+
const declared = entry.children?.[key];
|
|
287
|
+
if (declared === void 0) throw new _nomix_ai_nomix_client_ui_slots.SlotOwnershipError(`slot '${key}' is not declared by this entry's children`);
|
|
288
|
+
if (declared.kind === "chain") throw new _nomix_ai_nomix_client_ui_slots.SlotOwnershipError(`slot '${key}' is declared 'chain' — use renderSlotChain`);
|
|
289
|
+
return (0, react_jsx_runtime.jsx)(SlotOutlet, {
|
|
290
|
+
slotKey: key,
|
|
291
|
+
ownerProps: owner,
|
|
292
|
+
opts
|
|
293
|
+
});
|
|
294
|
+
};
|
|
295
|
+
renderSlotCache.set(entry, binding);
|
|
296
|
+
}
|
|
297
|
+
return binding;
|
|
298
|
+
}
|
|
299
|
+
/**
|
|
300
|
+
* Per-entry renderSlotChain bindings: identity-stable per entry (same cache
|
|
301
|
+
* axis as renderSlot — a per-frame dispatch must not rebuild the binding) and
|
|
302
|
+
* dead with the entry. The chain-kind check is the plain-JS backstop twin of
|
|
303
|
+
* the declaration check; typed callers are narrowed to chain keys.
|
|
304
|
+
*/
|
|
305
|
+
const renderSlotChainCache = /* @__PURE__ */ new WeakMap();
|
|
306
|
+
function boundRenderSlotChain(host, entry) {
|
|
307
|
+
let binding = renderSlotChainCache.get(entry);
|
|
308
|
+
if (!binding) {
|
|
309
|
+
binding = (key, owner, opts) => {
|
|
310
|
+
if (!host.isLive(entry)) throw new _nomix_ai_nomix_client_ui_slots.StaleAuthorizationError(`renderSlotChain('${key}') from a disposed registration`);
|
|
311
|
+
const declared = entry.children?.[key];
|
|
312
|
+
if (declared === void 0) throw new _nomix_ai_nomix_client_ui_slots.SlotOwnershipError(`slot '${key}' is not declared by this entry's children`);
|
|
313
|
+
if (declared.kind !== "chain") throw new _nomix_ai_nomix_client_ui_slots.SlotOwnershipError(`slot '${key}' is declared '${declared.kind}', not 'chain' — use renderSlot`);
|
|
314
|
+
return (0, react_jsx_runtime.jsx)(SlotOutlet, {
|
|
315
|
+
slotKey: key,
|
|
316
|
+
ownerProps: owner,
|
|
317
|
+
opts
|
|
318
|
+
});
|
|
319
|
+
};
|
|
320
|
+
renderSlotChainCache.set(entry, binding);
|
|
321
|
+
}
|
|
322
|
+
return binding;
|
|
323
|
+
}
|
|
324
|
+
/**
|
|
325
|
+
* Inject results cache: root entries per entry, session entries per
|
|
326
|
+
* (entry x provide bundle). WeakMap keys are entry/info objects (both
|
|
327
|
+
* identity-stable per registration/session scope), so cache lifetime rides
|
|
328
|
+
* the same axes as the values it memoizes.
|
|
329
|
+
*/
|
|
330
|
+
const rootInjectCache = /* @__PURE__ */ new WeakMap();
|
|
331
|
+
const sessionInjectCache = /* @__PURE__ */ new WeakMap();
|
|
332
|
+
const sessionMaybeInjectCache = /* @__PURE__ */ new WeakMap();
|
|
333
|
+
const EMPTY_INJECTED_PROPS = {};
|
|
334
|
+
function runInject(entry, info, actions) {
|
|
335
|
+
const inject = entry.inject;
|
|
336
|
+
if (!inject) return EMPTY_INJECTED_PROPS;
|
|
337
|
+
const args = [];
|
|
338
|
+
if (info !== void 0) args.push(info.sessionId);
|
|
339
|
+
if (actions !== void 0) args.push(actions);
|
|
340
|
+
return bindInjectHooks(inject(...args));
|
|
341
|
+
}
|
|
342
|
+
/**
|
|
343
|
+
* Normalize one entry-owned inject face on its existing cache axis. Its hooks
|
|
344
|
+
* compartment remains the original Observable-only contract.
|
|
345
|
+
*/
|
|
346
|
+
function bindInjectHooks(face) {
|
|
347
|
+
const sources = face["hooks"];
|
|
348
|
+
if (sources === void 0) return face;
|
|
349
|
+
const { hooks: _hooks, ...rest } = face;
|
|
350
|
+
const bound = rest;
|
|
351
|
+
for (const [name, source] of Object.entries(sources)) {
|
|
352
|
+
const hookName = `use${name[0]?.toUpperCase() ?? ""}${name.slice(1)}`;
|
|
353
|
+
bound[hookName] = observableHook(source);
|
|
354
|
+
}
|
|
355
|
+
return bound;
|
|
356
|
+
}
|
|
357
|
+
const slotInjectCache = /* @__PURE__ */ new WeakMap();
|
|
358
|
+
const EMPTY_SLOT_INJECT = { props: EMPTY_INJECTED_PROPS };
|
|
359
|
+
/** Normalize one dispatcher-owned inject face by its stable object identity. */
|
|
360
|
+
function cachedSlotInject(face) {
|
|
361
|
+
if (face === void 0) return EMPTY_SLOT_INJECT;
|
|
362
|
+
let bound = slotInjectCache.get(face);
|
|
363
|
+
if (bound !== void 0) return bound;
|
|
364
|
+
const definitions = face["hooks"];
|
|
365
|
+
if (definitions === void 0) {
|
|
366
|
+
bound = { props: face };
|
|
367
|
+
slotInjectCache.set(face, bound);
|
|
368
|
+
return bound;
|
|
369
|
+
}
|
|
370
|
+
const { hooks: _hooks, ...rest } = face;
|
|
371
|
+
const props = rest;
|
|
372
|
+
let factories;
|
|
373
|
+
for (const [name, definition] of Object.entries(definitions)) {
|
|
374
|
+
const hookName = `use${name[0]?.toUpperCase() ?? ""}${name.slice(1)}`;
|
|
375
|
+
if (typeof definition === "function") {
|
|
376
|
+
factories ??= {};
|
|
377
|
+
factories[name] = definition;
|
|
378
|
+
} else props[hookName] = observableHook(definition);
|
|
379
|
+
}
|
|
380
|
+
bound = factories === void 0 ? { props } : {
|
|
381
|
+
props,
|
|
382
|
+
slotHookFactories: factories
|
|
383
|
+
};
|
|
384
|
+
slotInjectCache.set(face, bound);
|
|
385
|
+
return bound;
|
|
386
|
+
}
|
|
387
|
+
/** Bind deferred slot-level factories for one stable renderSlot occurrence. */
|
|
388
|
+
function bindSlotHookFactories(factories, standard, hookContext) {
|
|
389
|
+
const hooks = {};
|
|
390
|
+
for (const [name, factory] of Object.entries(factories)) {
|
|
391
|
+
const hookName = `use${name[0]?.toUpperCase() ?? ""}${name.slice(1)}`;
|
|
392
|
+
hooks[hookName] = factory(standard, hookContext);
|
|
393
|
+
}
|
|
394
|
+
return hooks;
|
|
395
|
+
}
|
|
396
|
+
function cachedRootInject(entry, actions) {
|
|
397
|
+
let props = rootInjectCache.get(entry);
|
|
398
|
+
if (!props) {
|
|
399
|
+
props = runInject(entry, void 0, actions);
|
|
400
|
+
rootInjectCache.set(entry, props);
|
|
401
|
+
}
|
|
402
|
+
return props;
|
|
403
|
+
}
|
|
404
|
+
function cachedSessionInject(entry, info, actions) {
|
|
405
|
+
let perInfo = sessionInjectCache.get(entry);
|
|
406
|
+
if (!perInfo) {
|
|
407
|
+
perInfo = /* @__PURE__ */ new WeakMap();
|
|
408
|
+
sessionInjectCache.set(entry, perInfo);
|
|
409
|
+
}
|
|
410
|
+
let props = perInfo.get(info);
|
|
411
|
+
if (!props) {
|
|
412
|
+
props = runInject(entry, info, actions);
|
|
413
|
+
perInfo.set(info, props);
|
|
414
|
+
}
|
|
415
|
+
return props;
|
|
416
|
+
}
|
|
417
|
+
function cachedSessionMaybeInject(entry, info, actions) {
|
|
418
|
+
let perInfo = sessionMaybeInjectCache.get(entry);
|
|
419
|
+
if (!perInfo) {
|
|
420
|
+
perInfo = /* @__PURE__ */ new WeakMap();
|
|
421
|
+
sessionMaybeInjectCache.set(entry, perInfo);
|
|
422
|
+
}
|
|
423
|
+
let props = perInfo.get(info);
|
|
424
|
+
if (!props) {
|
|
425
|
+
props = runInject(entry, info, actions);
|
|
426
|
+
perInfo.set(info, props);
|
|
427
|
+
}
|
|
428
|
+
return props;
|
|
429
|
+
}
|
|
430
|
+
/**
|
|
431
|
+
* Locale `t` seat bindings, cached per (face, namespace, revision). The
|
|
432
|
+
* revision is part of the cache key ON PURPOSE: a locale switch mints a NEW
|
|
433
|
+
* function reference per namespace, so `React.memo` components taking `t`
|
|
434
|
+
* re-render through ordinary shallow comparison — freshness rides identity,
|
|
435
|
+
* no extra invalidation channel. Within one revision the reference is stable
|
|
436
|
+
* (memoized children do not churn on unrelated re-renders).
|
|
437
|
+
*/
|
|
438
|
+
const localeSeatCache = /* @__PURE__ */ new WeakMap();
|
|
439
|
+
function localeSeat(face, ns) {
|
|
440
|
+
let perNs = localeSeatCache.get(face);
|
|
441
|
+
if (!perNs) {
|
|
442
|
+
perNs = /* @__PURE__ */ new Map();
|
|
443
|
+
localeSeatCache.set(face, perNs);
|
|
444
|
+
}
|
|
445
|
+
const revision = face.getSnapshot().revision;
|
|
446
|
+
const cached = perNs.get(ns);
|
|
447
|
+
if (cached && cached.revision === revision) return cached.t;
|
|
448
|
+
const bound = face.bind(ns);
|
|
449
|
+
const t = (key, params) => bound(key, params);
|
|
450
|
+
perNs.set(ns, {
|
|
451
|
+
revision,
|
|
452
|
+
t
|
|
453
|
+
});
|
|
454
|
+
return t;
|
|
455
|
+
}
|
|
456
|
+
const noopSubscribe = () => () => {};
|
|
457
|
+
const zeroRevision = () => 0;
|
|
458
|
+
/**
|
|
459
|
+
* Per-face subscribe/getSnapshot closure pair. Cached by face identity: the
|
|
460
|
+
* face is one global source shared by every outlet, and uSES resubscribes
|
|
461
|
+
* whenever the subscribe reference changes — fresh closures per render would
|
|
462
|
+
* churn one unsubscribe/resubscribe pair per outlet per render.
|
|
463
|
+
*/
|
|
464
|
+
const localeSubscriptionCache = /* @__PURE__ */ new WeakMap();
|
|
465
|
+
function localeSubscription(face) {
|
|
466
|
+
let cached = localeSubscriptionCache.get(face);
|
|
467
|
+
if (!cached) {
|
|
468
|
+
cached = {
|
|
469
|
+
subscribe: (fn) => face.subscribe(fn),
|
|
470
|
+
getRevision: () => face.getSnapshot().revision
|
|
471
|
+
};
|
|
472
|
+
localeSubscriptionCache.set(face, cached);
|
|
473
|
+
}
|
|
474
|
+
return cached;
|
|
475
|
+
}
|
|
476
|
+
/**
|
|
477
|
+
* Subscribe an outlet to the installed locale face's revision (0 while none
|
|
478
|
+
* is installed — exactly one uSES call either way, keeping hook order
|
|
479
|
+
* stable). Every outlet re-renders on a locale switch; entry bodies then
|
|
480
|
+
* re-derive their `t` seat at the new revision. The face must be installed
|
|
481
|
+
* before the first render that needs it — a face appearing later has no
|
|
482
|
+
* notification channel to already-mounted outlets.
|
|
483
|
+
*/
|
|
484
|
+
function useLocaleRevision(face) {
|
|
485
|
+
const subscription = face !== void 0 ? localeSubscription(face) : void 0;
|
|
486
|
+
return (0, react.useSyncExternalStore)(subscription?.subscribe ?? noopSubscribe, subscription?.getRevision ?? zeroRevision);
|
|
487
|
+
}
|
|
488
|
+
/**
|
|
489
|
+
* Entry-identity React keys for entry boundaries. An outlet renders one
|
|
490
|
+
* winner per position (single/keyed/list cell head, chain election) through
|
|
491
|
+
* an error boundary; without a key, a boundary that failed on entry A would
|
|
492
|
+
* survive a winner change (re-election, shadowing fallback after an
|
|
493
|
+
* abdication, HMR re-registration) and keep a healthy entry B blacked out.
|
|
494
|
+
* Keying by entry identity remounts the boundary fresh whenever the winner
|
|
495
|
+
* changes (entries are identity-stable per registration, so the key is
|
|
496
|
+
* stable while the same entry stays the winner).
|
|
497
|
+
*/
|
|
498
|
+
let nextEntryKey = 0;
|
|
499
|
+
const entryKeys = /* @__PURE__ */ new WeakMap();
|
|
500
|
+
function entryKeyOf(entry) {
|
|
501
|
+
let key = entryKeys.get(entry);
|
|
502
|
+
if (key === void 0) {
|
|
503
|
+
key = nextEntryKey++;
|
|
504
|
+
entryKeys.set(entry, key);
|
|
505
|
+
}
|
|
506
|
+
return key;
|
|
507
|
+
}
|
|
508
|
+
/**
|
|
509
|
+
* Per-entry isolation: one registrant crashing (component render or inject
|
|
510
|
+
* factory) must not take down siblings. Assembly errors (missing providers)
|
|
511
|
+
* rethrow — a miswired shell must fail loud, not degrade into fallbacks.
|
|
512
|
+
* Every catch reports through `onEntryError` (the ledger's supervision
|
|
513
|
+
* seam); for shadowing kinds the report abdicates the entry, the outlet
|
|
514
|
+
* re-renders onto the cell's next survivor, and this boundary's crash face
|
|
515
|
+
* only shows until that re-render lands (permanently once the cell is dry —
|
|
516
|
+
* the outlet then owns the crash face).
|
|
517
|
+
*/
|
|
518
|
+
var SlotErrorBoundary = class extends react.Component {
|
|
519
|
+
state = { failed: false };
|
|
520
|
+
static getDerivedStateFromError(error) {
|
|
521
|
+
if (error instanceof SlotAssemblyError) throw error;
|
|
522
|
+
return { failed: true };
|
|
523
|
+
}
|
|
524
|
+
componentDidCatch(error) {
|
|
525
|
+
console.error(`slot entry crashed in '${this.props.slotKey}':`, error);
|
|
526
|
+
this.props.onEntryError(error);
|
|
527
|
+
}
|
|
528
|
+
render() {
|
|
529
|
+
if (this.state.failed) return (0, react_jsx_runtime.jsx)("div", { "data-slot-error": this.props.slotKey });
|
|
530
|
+
return this.props.children;
|
|
531
|
+
}
|
|
532
|
+
};
|
|
533
|
+
const standardPropsCache = /* @__PURE__ */ new WeakMap();
|
|
534
|
+
/** Stable official-props object used by contextual Hook factories. */
|
|
535
|
+
function standardProps(host, scope, info) {
|
|
536
|
+
let cache = standardPropsCache.get(host);
|
|
537
|
+
if (cache === void 0) {
|
|
538
|
+
cache = {
|
|
539
|
+
root: {
|
|
540
|
+
useSessions: observableHook(host.sessions.list),
|
|
541
|
+
useWorkspaces: observableHook(host.workspaces.list)
|
|
542
|
+
},
|
|
543
|
+
session: /* @__PURE__ */ new WeakMap(),
|
|
544
|
+
sessionMaybe: /* @__PURE__ */ new WeakMap()
|
|
545
|
+
};
|
|
546
|
+
standardPropsCache.set(host, cache);
|
|
547
|
+
}
|
|
548
|
+
if (scope === "root") return cache.root;
|
|
549
|
+
if (info === void 0) throw new SlotAssemblyError(`scope '${scope}' rendered without session provide info`);
|
|
550
|
+
const byInfo = scope === "session" ? cache.session : cache.sessionMaybe;
|
|
551
|
+
let standard = byInfo.get(info);
|
|
552
|
+
if (standard !== void 0) return standard;
|
|
553
|
+
standard = { ...cache.root };
|
|
554
|
+
for (const [name, source] of Object.entries(info.hooks)) {
|
|
555
|
+
const hookName = `use${name[0]?.toUpperCase() ?? ""}${name.slice(1)}`;
|
|
556
|
+
if (scope === "session-maybe") standard[hookName] = maybeObservableHook(source);
|
|
557
|
+
else {
|
|
558
|
+
if (source === void 0) throw new SlotAssemblyError(`strict session hook '${name}' has no source`);
|
|
559
|
+
standard[hookName] = observableHook(source);
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
Object.assign(standard, info.props);
|
|
563
|
+
standard["sessionId"] = info.sessionId;
|
|
564
|
+
standard["useProjection"] = projectionHook(info);
|
|
565
|
+
byInfo.set(info, standard);
|
|
566
|
+
return standard;
|
|
567
|
+
}
|
|
568
|
+
/**
|
|
569
|
+
* Standard-kit synthesis shared by both scope branches: the global
|
|
570
|
+
* useSessions/useWorkspaces hooks, the per-session provide bundle (every
|
|
571
|
+
* `hooks` source becomes a `use<Name>` selector hook — useSession is the
|
|
572
|
+
* runtime's own 'session' contribution, no special case — and `props` spread
|
|
573
|
+
* verbatim), the store pair when declared, the renderSlot binding when
|
|
574
|
+
* children are declared, and the SessionProvider seat when the children
|
|
575
|
+
* declare a session-scope slot. Hosts hand out BARE observable sources
|
|
576
|
+
* (hooks never cross the host contract); every hook is bound HERE, cached
|
|
577
|
+
* per source (observableHook), so spreading a fresh kit object per render
|
|
578
|
+
* never churns child subscriptions.
|
|
579
|
+
*/
|
|
580
|
+
function standardKit(host, entry, scope, info) {
|
|
581
|
+
const standard = standardProps(host, scope, info);
|
|
582
|
+
const kit = { ...standard };
|
|
583
|
+
if (entry.locale !== void 0) {
|
|
584
|
+
const face = host.locale;
|
|
585
|
+
if (face === void 0) throw new SlotAssemblyError(`entry declares locale namespace '${entry.locale}' but no locale face is installed (locale plugin missing from the composition?)`);
|
|
586
|
+
kit["t"] = localeSeat(face, entry.locale);
|
|
587
|
+
}
|
|
588
|
+
const store = scope === "session-maybe" && info?.sessionId === void 0 ? void 0 : host.storeOf(entry, info?.sessionId);
|
|
589
|
+
if (store !== void 0) {
|
|
590
|
+
kit["useStore"] = observableHook(store);
|
|
591
|
+
kit["actions"] = store.actions;
|
|
592
|
+
}
|
|
593
|
+
if (entry.children !== void 0) {
|
|
594
|
+
kit["renderSlot"] = boundRenderSlot(host, entry);
|
|
595
|
+
if (Object.values(entry.children).some((spec) => spec.kind === "chain")) kit["renderSlotChain"] = boundRenderSlotChain(host, entry);
|
|
596
|
+
if (Object.values(entry.children).some((spec) => spec.scope === "session")) kit["SessionProvider"] = SessionProvider;
|
|
597
|
+
}
|
|
598
|
+
return {
|
|
599
|
+
kit,
|
|
600
|
+
standard,
|
|
601
|
+
actions: store?.actions
|
|
602
|
+
};
|
|
603
|
+
}
|
|
604
|
+
/**
|
|
605
|
+
* One rendered entry: standard kit + cached entry inject + common slot inject
|
|
606
|
+
* + owner props (owner wins). The shares are erased at this render boundary;
|
|
607
|
+
* the registration and renderSlot seams already proved their contracts.
|
|
608
|
+
*/
|
|
609
|
+
function ContextualEntry({ slotKey, Comp, kit, standard, injected, slotInjected, ownerProps, hookContext, hasHookContext }) {
|
|
610
|
+
const contextual = (0, react.useMemo)(() => {
|
|
611
|
+
if (!hasHookContext) throw new SlotAssemblyError(`slot '${slotKey}' has contextual injected Hooks but no hookContext`);
|
|
612
|
+
return bindSlotHookFactories(slotInjected.slotHookFactories, standard, hookContext);
|
|
613
|
+
}, [
|
|
614
|
+
hasHookContext,
|
|
615
|
+
hookContext,
|
|
616
|
+
slotInjected.slotHookFactories,
|
|
617
|
+
slotKey,
|
|
618
|
+
standard
|
|
619
|
+
]);
|
|
620
|
+
return (0, react_jsx_runtime.jsx)(Comp, {
|
|
621
|
+
...kit,
|
|
622
|
+
...injected,
|
|
623
|
+
...slotInjected.props,
|
|
624
|
+
...contextual,
|
|
625
|
+
...ownerProps
|
|
626
|
+
});
|
|
627
|
+
}
|
|
628
|
+
function renderEntry(slotKey, Comp, kit, standard, injected, slotInjected, ownerProps, hookContext, hasHookContext) {
|
|
629
|
+
if (slotInjected.slotHookFactories === void 0) return (0, react_jsx_runtime.jsx)(Comp, {
|
|
630
|
+
...kit,
|
|
631
|
+
...injected,
|
|
632
|
+
...slotInjected.props,
|
|
633
|
+
...ownerProps
|
|
634
|
+
});
|
|
635
|
+
return (0, react_jsx_runtime.jsx)(ContextualEntry, {
|
|
636
|
+
slotKey,
|
|
637
|
+
Comp,
|
|
638
|
+
kit,
|
|
639
|
+
standard,
|
|
640
|
+
injected,
|
|
641
|
+
slotInjected,
|
|
642
|
+
ownerProps,
|
|
643
|
+
hookContext,
|
|
644
|
+
hasHookContext
|
|
645
|
+
});
|
|
646
|
+
}
|
|
647
|
+
function SessionEntry({ entry, ownerProps, info, slotKey, slotInjected, hookContext, hasHookContext }) {
|
|
648
|
+
const host = useHost();
|
|
649
|
+
const Comp = entry.component;
|
|
650
|
+
const { kit, standard, actions } = standardKit(host, entry, "session", info);
|
|
651
|
+
return renderEntry(slotKey, Comp, kit, standard, cachedSessionInject(entry, info, actions), slotInjected, ownerProps, hookContext, hasHookContext);
|
|
652
|
+
}
|
|
653
|
+
function SessionMaybeEntryBody({ entry, ownerProps, info, slotKey, slotInjected, hookContext, hasHookContext }) {
|
|
654
|
+
const host = useHost();
|
|
655
|
+
const Comp = entry.component;
|
|
656
|
+
const { kit, standard, actions } = standardKit(host, entry, "session-maybe", info);
|
|
657
|
+
return renderEntry(slotKey, Comp, kit, standard, cachedSessionMaybeInject(entry, info, actions), slotInjected, ownerProps, hookContext, hasHookContext);
|
|
658
|
+
}
|
|
659
|
+
/**
|
|
660
|
+
* Session-maybe identity: adoption — the ONLY behavior (there is no
|
|
661
|
+
* hold-identity-forever mode). An incarnation born session-less ADOPTS the
|
|
662
|
+
* first session that arrives: identity holds across that one transition
|
|
663
|
+
* (undefined → first id), so a blank shell's DOM survives the moment a
|
|
664
|
+
* session appears. From then on the entry behaves exactly like a strict
|
|
665
|
+
* session entry: switching to a DIFFERENT session remounts (component-local
|
|
666
|
+
* state must not leak between sessions), and dropping back to no-session
|
|
667
|
+
* remounts into a fresh blank incarnation, which will adopt again.
|
|
668
|
+
* Component-local per-session state therefore clears by construction; state
|
|
669
|
+
* that must SURVIVE a switch belongs in session-bound sources (machine,
|
|
670
|
+
* store, hooks) — the existing layering rule, now load-bearing.
|
|
671
|
+
*/
|
|
672
|
+
function SessionMaybeEntry({ entry, ownerProps, slotKey, slotInjected, hookContext, hasHookContext }) {
|
|
673
|
+
const info = useSessionMaybeProvideInfo();
|
|
674
|
+
const [state, setState] = (0, react.useState)(FIRST_INCARNATION);
|
|
675
|
+
let { adopted, epoch } = state;
|
|
676
|
+
if (info.sessionId !== void 0 && adopted === void 0) {
|
|
677
|
+
adopted = info.sessionId;
|
|
678
|
+
setState({
|
|
679
|
+
adopted,
|
|
680
|
+
epoch
|
|
681
|
+
});
|
|
682
|
+
} else if (adopted !== void 0 && info.sessionId !== void 0 && info.sessionId !== adopted) {
|
|
683
|
+
adopted = info.sessionId;
|
|
684
|
+
epoch += 1;
|
|
685
|
+
setState({
|
|
686
|
+
adopted,
|
|
687
|
+
epoch
|
|
688
|
+
});
|
|
689
|
+
} else if (adopted !== void 0 && info.sessionId === void 0) {
|
|
690
|
+
adopted = void 0;
|
|
691
|
+
epoch += 1;
|
|
692
|
+
setState({
|
|
693
|
+
adopted,
|
|
694
|
+
epoch
|
|
695
|
+
});
|
|
696
|
+
}
|
|
697
|
+
return (0, react_jsx_runtime.jsx)(SessionMaybeEntryBody, {
|
|
698
|
+
entry,
|
|
699
|
+
ownerProps,
|
|
700
|
+
info,
|
|
701
|
+
slotKey,
|
|
702
|
+
slotInjected,
|
|
703
|
+
hookContext,
|
|
704
|
+
hasHookContext
|
|
705
|
+
}, epoch);
|
|
706
|
+
}
|
|
707
|
+
const FIRST_INCARNATION = {
|
|
708
|
+
adopted: void 0,
|
|
709
|
+
epoch: 0
|
|
710
|
+
};
|
|
711
|
+
function RootEntry({ entry, ownerProps, slotKey, slotInjected, hookContext, hasHookContext }) {
|
|
712
|
+
const host = useHost();
|
|
713
|
+
const Comp = entry.component;
|
|
714
|
+
const { kit, standard, actions } = standardKit(host, entry, "root", void 0);
|
|
715
|
+
return renderEntry(slotKey, Comp, kit, standard, cachedRootInject(entry, actions), slotInjected, ownerProps, hookContext, hasHookContext);
|
|
716
|
+
}
|
|
717
|
+
function StrictSessionEntry({ slotKey, entry, ownerProps, slotInjected, hookContext, hasHookContext, onEntryError }) {
|
|
718
|
+
const info = useSessionMaybeProvideInfo();
|
|
719
|
+
if (info.sessionId === void 0) return null;
|
|
720
|
+
return (0, react_jsx_runtime.jsx)(SlotErrorBoundary, {
|
|
721
|
+
slotKey,
|
|
722
|
+
onEntryError,
|
|
723
|
+
children: (0, react_jsx_runtime.jsx)(SessionEntry, {
|
|
724
|
+
entry,
|
|
725
|
+
ownerProps,
|
|
726
|
+
info,
|
|
727
|
+
slotKey,
|
|
728
|
+
slotInjected,
|
|
729
|
+
hookContext,
|
|
730
|
+
hasHookContext
|
|
731
|
+
})
|
|
732
|
+
}, info.sessionId);
|
|
733
|
+
}
|
|
734
|
+
/**
|
|
735
|
+
* Anchor style shared by every outlet wrapper: `display:contents` keeps the
|
|
736
|
+
* wrapper out of layout (grid/flex parents see the slot's own children), so
|
|
737
|
+
* the anchor is purely addressable surface. Module-level constant — a stable
|
|
738
|
+
* reference so the wrapper never diffs its style prop.
|
|
739
|
+
*/
|
|
740
|
+
const ANCHOR_STYLE = { display: "contents" };
|
|
741
|
+
function SlotOutlet({ slotKey, ownerProps, opts }) {
|
|
742
|
+
const host = useHost();
|
|
743
|
+
(0, react.useSyncExternalStore)((fn) => host.subscribe(slotKey, fn), () => host.getVersion(slotKey));
|
|
744
|
+
useLocaleRevision(host.locale);
|
|
745
|
+
return (0, react_jsx_runtime.jsx)("div", {
|
|
746
|
+
"data-slot": slotKey,
|
|
747
|
+
style: ANCHOR_STYLE,
|
|
748
|
+
children: renderOutletContent(host, slotKey, ownerProps, opts, useSessionMaybeProvideInfo())
|
|
749
|
+
});
|
|
750
|
+
}
|
|
751
|
+
/** Kind dispatch behind the outlet anchor (single/keyed/list/chain, fallbacks, crash faces). */
|
|
752
|
+
function renderOutletContent(host, slotKey, ownerProps, opts, sessionInfo) {
|
|
753
|
+
const spec = host.specOf(slotKey);
|
|
754
|
+
if (!spec) return null;
|
|
755
|
+
const strictSessionAbsent = spec.scope === "session" && sessionInfo.sessionId === void 0;
|
|
756
|
+
if (strictSessionAbsent && (spec.kind !== "chain" || !opts?.overlay)) return (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: opts?.fallback ?? null });
|
|
757
|
+
const entries = strictSessionAbsent ? [] : host.entriesOf(slotKey);
|
|
758
|
+
const slotInjected = cachedSlotInject(spec.inject);
|
|
759
|
+
const guarded = (entry, key, owner = ownerProps) => {
|
|
760
|
+
const hasHookContext = opts !== void 0 && Object.hasOwn(opts, "hookContext");
|
|
761
|
+
const hookContext = opts?.hookContext;
|
|
762
|
+
const onEntryError = (error) => {
|
|
763
|
+
host.reportEntryError(slotKey, entry, error, { abdicate: spec.kind !== "chain" });
|
|
764
|
+
};
|
|
765
|
+
return spec.scope === "session" ? (0, react_jsx_runtime.jsx)(StrictSessionEntry, {
|
|
766
|
+
slotKey,
|
|
767
|
+
entry,
|
|
768
|
+
ownerProps: owner,
|
|
769
|
+
slotInjected,
|
|
770
|
+
hookContext,
|
|
771
|
+
hasHookContext,
|
|
772
|
+
onEntryError
|
|
773
|
+
}, key) : (0, react_jsx_runtime.jsx)(SlotErrorBoundary, {
|
|
774
|
+
slotKey,
|
|
775
|
+
onEntryError,
|
|
776
|
+
children: spec.scope === "session-maybe" ? (0, react_jsx_runtime.jsx)(SessionMaybeEntry, {
|
|
777
|
+
entry,
|
|
778
|
+
ownerProps: owner,
|
|
779
|
+
slotKey,
|
|
780
|
+
slotInjected,
|
|
781
|
+
hookContext,
|
|
782
|
+
hasHookContext
|
|
783
|
+
}) : (0, react_jsx_runtime.jsx)(RootEntry, {
|
|
784
|
+
entry,
|
|
785
|
+
ownerProps: owner,
|
|
786
|
+
slotKey,
|
|
787
|
+
slotInjected,
|
|
788
|
+
hookContext,
|
|
789
|
+
hasHookContext
|
|
790
|
+
})
|
|
791
|
+
}, key);
|
|
792
|
+
};
|
|
793
|
+
const deadCell = () => (0, react_jsx_runtime.jsx)("div", { "data-slot-error": slotKey });
|
|
794
|
+
if (spec.kind === "single") {
|
|
795
|
+
const entry = host.entriesOfSlot(slotKey)[0];
|
|
796
|
+
if (!entry) return entries.length > 0 ? deadCell() : (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: opts?.fallback ?? null });
|
|
797
|
+
return guarded(entry, entryKeyOf(entry));
|
|
798
|
+
}
|
|
799
|
+
if (spec.kind === "keyed") {
|
|
800
|
+
const entry = host.entriesOfSlot(slotKey).find((e) => e.options.key === opts?.entryKey);
|
|
801
|
+
if (!entry) return entries.some((e) => e.options.key === opts?.entryKey) ? deadCell() : (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: opts?.fallback ?? null });
|
|
802
|
+
return guarded(entry, entryKeyOf(entry));
|
|
803
|
+
}
|
|
804
|
+
if (spec.kind === "chain") {
|
|
805
|
+
let elected = null;
|
|
806
|
+
for (const entry of entries) {
|
|
807
|
+
let matched;
|
|
808
|
+
try {
|
|
809
|
+
matched = entry.select(ownerProps);
|
|
810
|
+
} catch (error) {
|
|
811
|
+
console.error(`chain selector crashed in '${slotKey}' (${entry.registrant ?? "unknown registrant"}), treating as declined:`, error);
|
|
812
|
+
continue;
|
|
813
|
+
}
|
|
814
|
+
if (matched !== null) {
|
|
815
|
+
elected = guarded(entry, entryKeyOf(entry), {
|
|
816
|
+
...ownerProps,
|
|
817
|
+
matched
|
|
818
|
+
});
|
|
819
|
+
break;
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
if (opts?.overlay) return (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [(0, react_jsx_runtime.jsx)("div", {
|
|
823
|
+
"data-chain-overlay-fallback": slotKey,
|
|
824
|
+
style: { display: elected === null ? "contents" : "none" },
|
|
825
|
+
children: opts.fallback ?? null
|
|
826
|
+
}), elected] });
|
|
827
|
+
return elected ?? (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: opts?.fallback ?? null });
|
|
828
|
+
}
|
|
829
|
+
const rows = host.entriesOfSlot(slotKey).map((entry) => ({
|
|
830
|
+
entry,
|
|
831
|
+
id: entry.options.id,
|
|
832
|
+
order: entry.options.order ?? 0
|
|
833
|
+
}));
|
|
834
|
+
const rowIds = new Set(rows.map((row) => row.id));
|
|
835
|
+
for (const entry of entries) {
|
|
836
|
+
if (rowIds.has(entry.options.id)) continue;
|
|
837
|
+
rowIds.add(entry.options.id);
|
|
838
|
+
rows.push({
|
|
839
|
+
entry: void 0,
|
|
840
|
+
id: entry.options.id,
|
|
841
|
+
order: entry.options.order ?? 0
|
|
842
|
+
});
|
|
843
|
+
}
|
|
844
|
+
let list = [...rows].sort((a, b) => a.order - b.order);
|
|
845
|
+
if (opts?.only !== void 0) list = list.filter((item) => item.id === opts.only);
|
|
846
|
+
if (list.length === 0) return (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: opts?.fallback ?? null });
|
|
847
|
+
return (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: list.map((item, i) => item.entry !== void 0 ? guarded(item.entry, `e${entryKeyOf(item.entry)}`) : (0, react_jsx_runtime.jsx)("div", { "data-slot-error": slotKey }, `x${item.id ?? i}`)) });
|
|
848
|
+
}
|
|
849
|
+
/** Root outlet: the shell's single ctx-level render entry — an unregistered 'root' is a boot-order failure, never a silent blank. */
|
|
850
|
+
function RootOutlet({ ownerProps }) {
|
|
851
|
+
const host = useHost();
|
|
852
|
+
(0, react.useSyncExternalStore)((fn) => host.subscribe("root", fn), () => host.getVersion("root"));
|
|
853
|
+
useLocaleRevision(host.locale);
|
|
854
|
+
const entry = host.entriesOfSlot("root")[0];
|
|
855
|
+
if (!entry) {
|
|
856
|
+
if (host.entriesOf("root").length > 0) return (0, react_jsx_runtime.jsx)("div", { "data-slot-error": "root" });
|
|
857
|
+
throw new SlotAssemblyError("renderSlot('root') before any 'root' registration (boot order)");
|
|
858
|
+
}
|
|
859
|
+
return (0, react_jsx_runtime.jsx)("div", {
|
|
860
|
+
"data-slot": "root",
|
|
861
|
+
style: ANCHOR_STYLE,
|
|
862
|
+
children: (0, react_jsx_runtime.jsx)(SlotErrorBoundary, {
|
|
863
|
+
slotKey: "root",
|
|
864
|
+
onEntryError: (error) => {
|
|
865
|
+
host.reportEntryError("root", entry, error, { abdicate: true });
|
|
866
|
+
},
|
|
867
|
+
children: (0, react_jsx_runtime.jsx)(RootEntry, {
|
|
868
|
+
entry,
|
|
869
|
+
ownerProps,
|
|
870
|
+
slotKey: "root",
|
|
871
|
+
slotInjected: EMPTY_SLOT_INJECT,
|
|
872
|
+
hookContext: void 0,
|
|
873
|
+
hasHookContext: false
|
|
874
|
+
})
|
|
875
|
+
}, entryKeyOf(entry))
|
|
876
|
+
});
|
|
877
|
+
}
|
|
878
|
+
/**
|
|
879
|
+
* Build the renderer the shell installs into the runtime SlotRegistry
|
|
880
|
+
* (ctx.slots.install(createSlotRenderer()) at boot; the service owns the
|
|
881
|
+
* install/renderSlot contract and the double-install/not-installed throws).
|
|
882
|
+
* @returns the renderer.
|
|
883
|
+
*/
|
|
884
|
+
function createSlotRenderer() {
|
|
885
|
+
return { renderRoot(host, ownerProps) {
|
|
886
|
+
return (0, react_jsx_runtime.jsx)(HostContext.Provider, {
|
|
887
|
+
value: host,
|
|
888
|
+
children: (0, react_jsx_runtime.jsx)(SessionMaybeProvider, { children: (0, react_jsx_runtime.jsx)(RootOutlet, { ownerProps }) })
|
|
889
|
+
});
|
|
890
|
+
} };
|
|
891
|
+
}
|
|
892
|
+
//#endregion
|
|
893
|
+
//#region lib/types/client/DocumentTitle.js
|
|
894
|
+
/**
|
|
895
|
+
* Project the selected durable session title into the browser title and
|
|
896
|
+
* restore the build-selected product title when unmounted.
|
|
897
|
+
* @param props - Selected session title projection.
|
|
898
|
+
* @returns No rendered content.
|
|
899
|
+
*/
|
|
900
|
+
function DocumentTitle({ title }) {
|
|
901
|
+
const productTitle = "Nomix Harness";
|
|
902
|
+
(0, react.useEffect)(() => {
|
|
903
|
+
document.title = title === void 0 ? productTitle : `${title} — ${productTitle}`;
|
|
904
|
+
return () => {
|
|
905
|
+
document.title = productTitle;
|
|
906
|
+
};
|
|
907
|
+
}, [productTitle, title]);
|
|
908
|
+
return null;
|
|
909
|
+
}
|
|
910
|
+
//#endregion
|
|
911
|
+
//#region lib/types/client/app.js
|
|
912
|
+
/**
|
|
913
|
+
* Build the assembled application factory.
|
|
914
|
+
* @param deps - Active UI-renderer dependencies.
|
|
915
|
+
* @returns Factory producing the application React tree.
|
|
916
|
+
*/
|
|
917
|
+
function buildRenderApp(deps) {
|
|
918
|
+
const { ctx } = deps;
|
|
919
|
+
const sessions = ctx.get("sessions");
|
|
920
|
+
if (sessions === void 0) throw new Error("ui renderer: sessions service unavailable");
|
|
921
|
+
const useSessions = bindSnapshotSelector(sessions.list);
|
|
922
|
+
const SessionDocumentTitle = () => {
|
|
923
|
+
const title = useSessions((state) => {
|
|
924
|
+
const id = state.current;
|
|
925
|
+
return id === void 0 ? void 0 : state.byId[id]?.title;
|
|
926
|
+
});
|
|
927
|
+
return (0, react_jsx_runtime.jsx)(DocumentTitle, { ...title === void 0 ? {} : { title } });
|
|
928
|
+
};
|
|
929
|
+
return () => (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [(0, react_jsx_runtime.jsx)(SessionDocumentTitle, {}), ctx.slots.renderSlot("root", {})] });
|
|
930
|
+
}
|
|
931
|
+
//#endregion
|
|
932
|
+
//#region lib/types/client/index.js
|
|
933
|
+
/**
|
|
934
|
+
* Browser UI renderer. It installs the slot renderer after its Cordis
|
|
935
|
+
* dependencies activate and exposes the mount operation used by the web boot
|
|
936
|
+
* kernel after the complete client roster settles.
|
|
937
|
+
*/
|
|
938
|
+
/** Services required before application assembly. */
|
|
939
|
+
const inject = ["slots", "sessions"];
|
|
940
|
+
/** Hydrate the kernel-owned loading DOM before replacing it with the application. */
|
|
941
|
+
function BootHandoff(props) {
|
|
942
|
+
const [ready, setReady] = (0, react.useState)(false);
|
|
943
|
+
(0, react.useLayoutEffect)(() => {
|
|
944
|
+
setReady(true);
|
|
945
|
+
}, []);
|
|
946
|
+
if (ready) return props.app();
|
|
947
|
+
return (0, react.createElement)("div", {
|
|
948
|
+
className: props.boot.className,
|
|
949
|
+
"data-nomix-boot": "",
|
|
950
|
+
dangerouslySetInnerHTML: { __html: props.boot.html }
|
|
951
|
+
});
|
|
952
|
+
}
|
|
953
|
+
/** Mount React while preserving the framework-free boot DOM through hydration. */
|
|
954
|
+
function mountApp(container, app) {
|
|
955
|
+
const boot = container.querySelector(":scope > [data-nomix-boot]");
|
|
956
|
+
if (boot !== null) return (0, react_dom_client.hydrateRoot)(container, (0, react.createElement)(BootHandoff, {
|
|
957
|
+
app,
|
|
958
|
+
boot: {
|
|
959
|
+
className: boot.className,
|
|
960
|
+
html: boot.innerHTML
|
|
961
|
+
}
|
|
962
|
+
}));
|
|
963
|
+
const root = (0, react_dom_client.createRoot)(container);
|
|
964
|
+
(0, react_dom.flushSync)(() => {
|
|
965
|
+
root.render(app());
|
|
966
|
+
});
|
|
967
|
+
return root;
|
|
968
|
+
}
|
|
969
|
+
/**
|
|
970
|
+
* Install the slot renderer and provide the application mount face.
|
|
971
|
+
* @param ctx - Plugin context.
|
|
972
|
+
*/
|
|
973
|
+
function apply(ctx) {
|
|
974
|
+
ctx.slots.install(createSlotRenderer());
|
|
975
|
+
ctx.reflect.provide("uiRenderer", { mount: (container) => {
|
|
976
|
+
const root = mountApp(container, buildRenderApp({ ctx }));
|
|
977
|
+
return () => {
|
|
978
|
+
root.unmount();
|
|
979
|
+
};
|
|
980
|
+
} });
|
|
981
|
+
}
|
|
982
|
+
//#endregion
|
|
983
|
+
exports.apply = apply;
|
|
984
|
+
exports.inject = inject;
|
|
985
|
+
return module.exports;
|
|
986
|
+
}
|
|
987
|
+
});
|
|
988
|
+
|
|
989
|
+
//# sourceMappingURL=client.js.map
|