@agent-native/core 0.16.2 → 0.16.3

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.
Files changed (120) hide show
  1. package/README.md +21 -5
  2. package/dist/cli/code-agent-executor.js +1 -1
  3. package/dist/cli/code-agent-executor.js.map +1 -1
  4. package/dist/cli/code.d.ts.map +1 -1
  5. package/dist/cli/code.js +29 -4
  6. package/dist/cli/code.js.map +1 -1
  7. package/dist/client/AgentPanel.d.ts.map +1 -1
  8. package/dist/client/AgentPanel.js +9 -1
  9. package/dist/client/AgentPanel.js.map +1 -1
  10. package/dist/client/AssistantChat.js +2 -2
  11. package/dist/client/AssistantChat.js.map +1 -1
  12. package/dist/client/ConnectBuilderCard.js +1 -1
  13. package/dist/client/ConnectBuilderCard.js.map +1 -1
  14. package/dist/client/components/CodeRequiredDialog.d.ts.map +1 -1
  15. package/dist/client/components/CodeRequiredDialog.js +3 -1
  16. package/dist/client/components/CodeRequiredDialog.js.map +1 -1
  17. package/dist/client/composer/AgentComposerFrame.d.ts +3 -1
  18. package/dist/client/composer/AgentComposerFrame.d.ts.map +1 -1
  19. package/dist/client/composer/AgentComposerFrame.js +3 -3
  20. package/dist/client/composer/AgentComposerFrame.js.map +1 -1
  21. package/dist/client/composer/ComposerPlusMenu.d.ts.map +1 -1
  22. package/dist/client/composer/ComposerPlusMenu.js +2 -7
  23. package/dist/client/composer/ComposerPlusMenu.js.map +1 -1
  24. package/dist/client/composer/PromptComposer.d.ts +4 -1
  25. package/dist/client/composer/PromptComposer.d.ts.map +1 -1
  26. package/dist/client/composer/PromptComposer.js +3 -3
  27. package/dist/client/composer/PromptComposer.js.map +1 -1
  28. package/dist/client/composer/TiptapComposer.d.ts.map +1 -1
  29. package/dist/client/composer/TiptapComposer.js +13 -3
  30. package/dist/client/composer/TiptapComposer.js.map +1 -1
  31. package/dist/client/onboarding/OnboardingPanel.js +1 -1
  32. package/dist/client/onboarding/OnboardingPanel.js.map +1 -1
  33. package/dist/client/settings/BackgroundAgentSection.d.ts.map +1 -1
  34. package/dist/client/settings/BackgroundAgentSection.js +9 -2
  35. package/dist/client/settings/BackgroundAgentSection.js.map +1 -1
  36. package/dist/client/settings/BrowserSection.d.ts.map +1 -1
  37. package/dist/client/settings/BrowserSection.js +17 -3
  38. package/dist/client/settings/BrowserSection.js.map +1 -1
  39. package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
  40. package/dist/client/settings/SettingsPanel.js +5 -5
  41. package/dist/client/settings/SettingsPanel.js.map +1 -1
  42. package/dist/client/settings/useBuilderStatus.d.ts +15 -2
  43. package/dist/client/settings/useBuilderStatus.d.ts.map +1 -1
  44. package/dist/client/settings/useBuilderStatus.js +99 -11
  45. package/dist/client/settings/useBuilderStatus.js.map +1 -1
  46. package/dist/client/settings/useBuilderStatus.spec.js +12 -6
  47. package/dist/client/settings/useBuilderStatus.spec.js.map +1 -1
  48. package/dist/code-agents/background-controller.d.ts +39 -0
  49. package/dist/code-agents/background-controller.d.ts.map +1 -0
  50. package/dist/code-agents/background-controller.js +249 -0
  51. package/dist/code-agents/background-controller.js.map +1 -0
  52. package/dist/code-agents/background-run.d.ts +58 -0
  53. package/dist/code-agents/background-run.d.ts.map +1 -0
  54. package/dist/code-agents/background-run.js +58 -0
  55. package/dist/code-agents/background-run.js.map +1 -0
  56. package/dist/code-agents/index.d.ts +2 -0
  57. package/dist/code-agents/index.d.ts.map +1 -1
  58. package/dist/code-agents/index.js +2 -0
  59. package/dist/code-agents/index.js.map +1 -1
  60. package/dist/connections/index.d.ts +1 -0
  61. package/dist/connections/index.d.ts.map +1 -1
  62. package/dist/connections/index.js +1 -0
  63. package/dist/connections/index.js.map +1 -1
  64. package/dist/connections/reader.d.ts +248 -0
  65. package/dist/connections/reader.d.ts.map +1 -0
  66. package/dist/connections/reader.js +461 -0
  67. package/dist/connections/reader.js.map +1 -0
  68. package/dist/credentials/index.d.ts +11 -0
  69. package/dist/credentials/index.d.ts.map +1 -1
  70. package/dist/credentials/index.js +40 -15
  71. package/dist/credentials/index.js.map +1 -1
  72. package/dist/index.d.ts +2 -2
  73. package/dist/index.d.ts.map +1 -1
  74. package/dist/index.js +2 -2
  75. package/dist/index.js.map +1 -1
  76. package/dist/server/agent-chat-plugin.d.ts +18 -0
  77. package/dist/server/agent-chat-plugin.d.ts.map +1 -1
  78. package/dist/server/agent-chat-plugin.js +57 -9
  79. package/dist/server/agent-chat-plugin.js.map +1 -1
  80. package/dist/server/agent-teams.d.ts +66 -1
  81. package/dist/server/agent-teams.d.ts.map +1 -1
  82. package/dist/server/agent-teams.js +433 -16
  83. package/dist/server/agent-teams.js.map +1 -1
  84. package/dist/server/builder-browser.d.ts +11 -0
  85. package/dist/server/builder-browser.d.ts.map +1 -1
  86. package/dist/server/builder-browser.js +45 -0
  87. package/dist/server/builder-browser.js.map +1 -1
  88. package/dist/server/core-routes-plugin.d.ts.map +1 -1
  89. package/dist/server/core-routes-plugin.js +25 -2
  90. package/dist/server/core-routes-plugin.js.map +1 -1
  91. package/dist/templates/workspace-root/AGENTS.md +5 -5
  92. package/dist/templates/workspace-root/README.md +1 -1
  93. package/dist/workspace-connections/credentials.d.ts +64 -0
  94. package/dist/workspace-connections/credentials.d.ts.map +1 -0
  95. package/dist/workspace-connections/credentials.js +378 -0
  96. package/dist/workspace-connections/credentials.js.map +1 -0
  97. package/dist/workspace-connections/index.d.ts +2 -1
  98. package/dist/workspace-connections/index.d.ts.map +1 -1
  99. package/dist/workspace-connections/index.js +2 -1
  100. package/dist/workspace-connections/index.js.map +1 -1
  101. package/dist/workspace-connections/store.d.ts +16 -0
  102. package/dist/workspace-connections/store.d.ts.map +1 -1
  103. package/dist/workspace-connections/store.js +57 -1
  104. package/dist/workspace-connections/store.js.map +1 -1
  105. package/docs/content/agent-teams.md +22 -5
  106. package/docs/content/cloneable-saas.md +2 -2
  107. package/docs/content/code-agents-ui.md +103 -3
  108. package/docs/content/creating-templates.md +16 -0
  109. package/docs/content/getting-started.md +40 -14
  110. package/docs/content/migration-workbench.md +25 -2
  111. package/docs/content/multi-app-workspace.md +1 -1
  112. package/docs/content/template-analytics.md +17 -1
  113. package/docs/content/template-brain.md +57 -28
  114. package/docs/content/template-dispatch.md +9 -2
  115. package/docs/content/workspace-connections.md +63 -14
  116. package/docs/content/workspace-management.md +9 -2
  117. package/docs/content/workspace.md +12 -5
  118. package/package.json +1 -1
  119. package/src/templates/workspace-root/AGENTS.md +5 -5
  120. package/src/templates/workspace-root/README.md +1 -1
@@ -1399,7 +1399,7 @@ function BuilderConnectCta({ variant = "primary", onConnected, }) {
1399
1399
  if (configured) {
1400
1400
  return (_jsxs("div", { className: containerClass, children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "text-xs font-medium text-foreground", children: "Builder.io" }), _jsx("p", { className: "text-[11px] text-muted-foreground mt-0.5", children: orgName ? `Connected — ${orgName}` : "Connected" })] }), _jsxs("span", { className: "ml-auto inline-flex items-center gap-1 shrink-0 rounded-md bg-emerald-500/10 px-2 py-0.5 text-[10px] font-medium text-emerald-500", children: [_jsx(IconCheck, { size: 10 }), "Connected"] })] }));
1401
1401
  }
1402
- return (_jsxs("div", { className: containerClass, children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "text-xs font-medium text-foreground", children: "Connect Builder.io" }), _jsx("p", { className: "text-[11px] text-muted-foreground mt-0.5 max-w-[220px]", children: "Free credits for LLM, hosting, and more \u2014 no API key needed" }), error && _jsx("p", { className: "mt-1 text-[10px] text-destructive", children: error })] }), _jsx("button", { type: "button", onClick: start, disabled: connecting, className: "ml-auto inline-flex items-center gap-1 shrink-0 rounded-md bg-foreground px-3 py-1.5 text-[11px] font-medium no-underline text-background hover:opacity-90 disabled:opacity-60 disabled:cursor-wait", "aria-busy": connecting, children: connecting ? (_jsxs(_Fragment, { children: [_jsx(IconLoader2, { size: 10, className: "animate-spin" }), "Waiting\u2026"] })) : (_jsxs(_Fragment, { children: ["Connect", _jsx(IconExternalLink, { size: 10 })] })) })] }));
1402
+ return (_jsxs("div", { className: containerClass, children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "text-xs font-medium text-foreground", children: "Connect Builder.io" }), _jsx("p", { className: "text-[11px] text-muted-foreground mt-0.5 max-w-[220px]", children: "Free credits for LLM, hosting, and more \u2014 no API key needed" }), error && _jsx("p", { className: "mt-1 text-[10px] text-destructive", children: error })] }), _jsx("button", { type: "button", onClick: () => start(), disabled: connecting, className: "ml-auto inline-flex items-center gap-1 shrink-0 rounded-md bg-foreground px-3 py-1.5 text-[11px] font-medium no-underline text-background hover:opacity-90 disabled:opacity-60 disabled:cursor-wait", "aria-busy": connecting, children: connecting ? (_jsxs(_Fragment, { children: [_jsx(IconLoader2, { size: 10, className: "animate-spin" }), "Waiting\u2026"] })) : (_jsxs(_Fragment, { children: ["Connect", _jsx(IconExternalLink, { size: 10 })] })) })] }));
1403
1403
  }
1404
1404
  // ─── Builder Setup Card ─────────────────────────────────────────────────────
1405
1405
  function BuilderSetupCard({ onConnected, bouncePulse, }) {
@@ -1571,7 +1571,7 @@ function RunErrorRecoveryCard({ info, onContinue, onRetry, onFork, onDismiss, })
1571
1571
  }, [builderReconnectResolved, onDismiss]);
1572
1572
  return (_jsxs("div", { className: "rounded-lg border border-amber-500/25 bg-amber-500/[0.06] p-3 text-sm", children: [_jsxs("div", { className: "flex items-start gap-2", children: [_jsx("span", { className: "mt-0.5 flex h-6 w-6 shrink-0 items-center justify-center rounded-md bg-amber-500/10 text-amber-700 dark:text-amber-300", children: _jsx(IconAlertTriangle, { size: 14 }) }), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "font-medium text-foreground", children: canRecover
1573
1573
  ? "The agent stopped before finishing"
1574
- : "The agent hit an error" }), _jsx("p", { className: "mt-1 text-xs leading-relaxed text-muted-foreground", children: info.message }), shouldShowBuilderReconnect && !builderReconnectResolved && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-muted-foreground", children: "The current Builder.io or model-provider credential was rejected. Reconnect Builder.io, then retry this message." })), isConnectionRecoveryError && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-muted-foreground", children: "If retry lands on the same error, start a new chat session and continue from what already changed." })), (info.runId || info.errorCode || info.details) && (_jsxs("button", { type: "button", onClick: () => setDetailsOpen((v) => !v), className: "mt-2 inline-flex items-center gap-1 text-[11px] font-medium text-muted-foreground hover:text-foreground", children: [_jsx(IconChevronDown, { size: 12, className: cn("transition-transform", detailsOpen && "rotate-180") }), "Details"] })), detailsOpen && (_jsxs("div", { className: "mt-2 rounded-md border border-border/60 bg-background/70 p-2 font-mono text-[11px] leading-relaxed text-muted-foreground", children: [info.runId && _jsxs("div", { children: ["run: ", info.runId] }), info.errorCode && _jsxs("div", { children: ["code: ", info.errorCode] }), info.details && (_jsx("pre", { className: "mt-2 max-h-28 overflow-auto whitespace-pre-wrap break-words font-mono", children: info.details }))] }))] }), _jsx("button", { type: "button", onClick: onDismiss, "aria-label": "Dismiss", className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground hover:bg-background/80 hover:text-foreground", children: _jsx(IconX, { size: 14 }) })] }), _jsxs("div", { className: "mt-3 flex flex-wrap items-center gap-2", children: [shouldShowBuilderReconnect && !builderReconnectResolved && (_jsxs("button", { type: "button", onClick: builderReconnect.start, disabled: builderReconnect.connecting, className: "inline-flex h-8 items-center gap-1.5 rounded-md bg-foreground px-3 text-xs font-medium text-background hover:opacity-90 disabled:cursor-wait disabled:opacity-70", children: [builderReconnect.connecting ? (_jsx(IconLoader2, { size: 13, className: "animate-spin" })) : (_jsx(IconExternalLink, { size: 13 })), builderReconnect.connecting
1574
+ : "The agent hit an error" }), _jsx("p", { className: "mt-1 text-xs leading-relaxed text-muted-foreground", children: info.message }), shouldShowBuilderReconnect && !builderReconnectResolved && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-muted-foreground", children: "The current Builder.io or model-provider credential was rejected. Reconnect Builder.io, then retry this message." })), isConnectionRecoveryError && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-muted-foreground", children: "If retry lands on the same error, start a new chat session and continue from what already changed." })), (info.runId || info.errorCode || info.details) && (_jsxs("button", { type: "button", onClick: () => setDetailsOpen((v) => !v), className: "mt-2 inline-flex items-center gap-1 text-[11px] font-medium text-muted-foreground hover:text-foreground", children: [_jsx(IconChevronDown, { size: 12, className: cn("transition-transform", detailsOpen && "rotate-180") }), "Details"] })), detailsOpen && (_jsxs("div", { className: "mt-2 rounded-md border border-border/60 bg-background/70 p-2 font-mono text-[11px] leading-relaxed text-muted-foreground", children: [info.runId && _jsxs("div", { children: ["run: ", info.runId] }), info.errorCode && _jsxs("div", { children: ["code: ", info.errorCode] }), info.details && (_jsx("pre", { className: "mt-2 max-h-28 overflow-auto whitespace-pre-wrap break-words font-mono", children: info.details }))] }))] }), _jsx("button", { type: "button", onClick: onDismiss, "aria-label": "Dismiss", className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground hover:bg-background/80 hover:text-foreground", children: _jsx(IconX, { size: 14 }) })] }), _jsxs("div", { className: "mt-3 flex flex-wrap items-center gap-2", children: [shouldShowBuilderReconnect && !builderReconnectResolved && (_jsxs("button", { type: "button", onClick: () => builderReconnect.start(), disabled: builderReconnect.connecting, className: "inline-flex h-8 items-center gap-1.5 rounded-md bg-foreground px-3 text-xs font-medium text-background hover:opacity-90 disabled:cursor-wait disabled:opacity-70", children: [builderReconnect.connecting ? (_jsx(IconLoader2, { size: 13, className: "animate-spin" })) : (_jsx(IconExternalLink, { size: 13 })), builderReconnect.connecting
1575
1575
  ? "Connecting Builder.io"
1576
1576
  : "Reconnect Builder.io"] })), canRecover && (_jsxs(_Fragment, { children: [_jsxs("button", { type: "button", onClick: onContinue, className: "inline-flex h-8 items-center gap-1.5 rounded-md bg-foreground px-3 text-xs font-medium text-background hover:opacity-90", children: [_jsx(IconPlayerPlay, { size: 13 }), "Continue"] }), _jsxs("button", { type: "button", onClick: onRetry, className: "inline-flex h-8 items-center gap-1.5 rounded-md border border-border bg-background px-3 text-xs font-medium text-foreground hover:bg-accent", children: [_jsx(IconRefresh, { size: 13 }), isQueryError ? "Diagnose and retry" : "Retry"] })] })), canRecover && isConnectionRecoveryError && (_jsxs("button", { type: "button", onClick: startNewChat, className: "inline-flex h-8 items-center gap-1.5 rounded-md border border-border bg-background px-3 text-xs font-medium text-foreground hover:bg-accent", children: [_jsx(IconPlus, { size: 13 }), "New chat"] })), canRecover && onFork && !isConnectionRecoveryError && (_jsxs("button", { type: "button", onClick: handleFork, disabled: forking, title: "Fork this conversation into a separate chat thread.", "aria-label": "Fork this conversation into a separate chat thread", className: "inline-flex h-8 items-center gap-1.5 rounded-md border border-border bg-background px-3 text-xs font-medium text-foreground hover:bg-accent disabled:cursor-wait disabled:opacity-70", children: [forking ? (_jsx(IconLoader2, { size: 13, className: "animate-spin" })) : (_jsx(IconGitFork, { size: 13 })), forking ? "Forking..." : "Fork chat"] })), _jsxs("button", { type: "button", onClick: copyDetails, className: "ml-auto inline-flex h-8 items-center gap-1.5 rounded-md px-2.5 text-xs font-medium text-muted-foreground hover:bg-background/80 hover:text-foreground", children: [copied ? _jsx(IconCheck, { size: 13 }) : _jsx(IconCopy, { size: 13 }), copied ? "Copied" : copyLabel] })] }), shouldShowBuilderReconnect && builderReconnect.error && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-red-500", children: builderReconnect.error })), forkError && (_jsx("p", { className: "mt-2 text-xs leading-relaxed text-red-500", children: forkError }))] }));
1577
1577
  }