apteva 0.4.41 → 0.4.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ActivityPage.c48n83h2.js +3 -0
- package/dist/ApiDocsPage.yzcxx5ax.js +4 -0
- package/dist/App.09yb8t0b.js +1 -0
- package/dist/App.152mbs1r.js +4 -0
- package/dist/App.3a67nx9w.js +4 -0
- package/dist/App.9epx6785.js +4 -0
- package/dist/App.d8955awp.js +4 -0
- package/dist/App.drwb57jq.js +4 -0
- package/dist/App.gssbmajb.js +4 -0
- package/dist/App.qw70pc29.js +53 -0
- package/dist/{App.7fb3e7mp.js → App.qzbx5wtj.js} +1 -1
- package/dist/App.r5serxkt.js +8 -0
- package/dist/App.tpmp9020.js +20 -0
- package/dist/App.v2wb4d7d.js +61 -0
- package/dist/App.vxmaaj0m.js +13 -0
- package/dist/App.w4p2tda9.js +4 -0
- package/dist/App.wv2ng55q.js +221 -0
- package/dist/App.yncnrn0f.js +4 -0
- package/dist/ConnectionsPage.k6cspyqq.js +3 -0
- package/dist/McpPage.cdxm48xj.js +3 -0
- package/dist/SettingsPage.evpv7c2y.js +3 -0
- package/dist/SkillsPage.pvzp6c1a.js +3 -0
- package/dist/TasksPage.6jnvbpsy.js +3 -0
- package/dist/TelemetryPage.t7vk24zc.js +3 -0
- package/dist/TestsPage.5x6658aa.js +3 -0
- package/dist/ThreadsPage.3fvhtevh.js +3 -0
- package/dist/apteva-kit.css +1 -1
- package/dist/index.html +1 -1
- package/dist/styles.css +1 -1
- package/package.json +8 -8
- package/src/db.ts +19 -9
- package/src/integrations/agentdojo.ts +1 -0
- package/src/mcp-platform.ts +418 -63
- package/src/openapi.ts +96 -0
- package/src/providers.ts +50 -24
- package/src/routes/api/agent-utils.ts +0 -1
- package/src/routes/api/agents.ts +19 -1
- package/src/routes/api/meta-agent.ts +2 -0
- package/src/routes/api/system.ts +90 -1
- package/src/routes/api/telemetry.ts +19 -1
- package/src/routes/share.ts +85 -0
- package/src/server.ts +12 -0
- package/src/web/App.tsx +89 -11
- package/src/web/components/activity/ActivityPage.tsx +14 -14
- package/src/web/components/agents/AgentCard.tsx +14 -14
- package/src/web/components/agents/AgentPanel.tsx +358 -198
- package/src/web/components/agents/AgentsView.tsx +4 -4
- package/src/web/components/agents/CreateAgentModal.tsx +21 -79
- package/src/web/components/api/ApiDocsPage.tsx +66 -66
- package/src/web/components/auth/CreateAccountStep.tsx +16 -16
- package/src/web/components/auth/LoginPage.tsx +10 -10
- package/src/web/components/common/LoadingSpinner.tsx +2 -2
- package/src/web/components/common/Modal.tsx +8 -8
- package/src/web/components/common/Select.tsx +9 -9
- package/src/web/components/connections/ConnectionsPage.tsx +4 -4
- package/src/web/components/connections/IntegrationsTab.tsx +18 -18
- package/src/web/components/connections/OverviewTab.tsx +13 -13
- package/src/web/components/connections/TriggersTab.tsx +99 -99
- package/src/web/components/dashboard/Dashboard.tsx +32 -32
- package/src/web/components/layout/Header.tsx +50 -34
- package/src/web/components/layout/Sidebar.tsx +34 -15
- package/src/web/components/mcp/IntegrationsPanel.tsx +40 -40
- package/src/web/components/mcp/McpPage.tsx +208 -208
- package/src/web/components/meta-agent/MetaAgent.tsx +12 -10
- package/src/web/components/onboarding/OnboardingWizard.tsx +25 -25
- package/src/web/components/settings/SettingsPage.tsx +258 -175
- package/src/web/components/skills/SkillsPage.tsx +88 -88
- package/src/web/components/tasks/TasksPage.tsx +339 -54
- package/src/web/components/telemetry/TelemetryPage.tsx +135 -64
- package/src/web/components/tests/TestsPage.tsx +50 -50
- package/src/web/components/threads/ThreadsPage.tsx +23 -21
- package/src/web/context/ProjectContext.tsx +6 -1
- package/src/web/context/ThemeContext.tsx +69 -0
- package/src/web/context/index.ts +2 -0
- package/src/web/styles.css +5 -3
- package/src/web/themes.ts +99 -0
- package/src/web/types.ts +0 -4
- package/dist/ActivityPage.7907h64p.js +0 -3
- package/dist/ApiDocsPage.k3jjenpq.js +0 -4
- package/dist/App.01nq20st.js +0 -4
- package/dist/App.1maqvamf.js +0 -4
- package/dist/App.2yjrh32f.js +0 -4
- package/dist/App.3qw8nben.js +0 -20
- package/dist/App.7sy3wq8c.js +0 -4
- package/dist/App.apjrmctz.js +0 -57
- package/dist/App.av6t2yhe.js +0 -4
- package/dist/App.jqj5a094.js +0 -46
- package/dist/App.mc7xf85h.js +0 -4
- package/dist/App.myxqcj9x.js +0 -4
- package/dist/App.nm91r1mp.js +0 -13
- package/dist/App.p02f4ret.js +0 -1
- package/dist/App.qcknavjz.js +0 -221
- package/dist/App.vc7vfhg4.js +0 -4
- package/dist/App.z4s9zkw5.js +0 -4
- package/dist/ConnectionsPage.z1pw5xe2.js +0 -3
- package/dist/McpPage.8vc97z0b.js +0 -3
- package/dist/SettingsPage.p61bz8kd.js +0 -3
- package/dist/SkillsPage.r9x43g3g.js +0 -3
- package/dist/TasksPage.1e0zkye4.js +0 -3
- package/dist/TelemetryPage.p9vbe4gf.js +0 -3
- package/dist/TestsPage.d4xy504e.js +0 -3
- package/dist/ThreadsPage.m016am3x.js +0 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useState, useEffect, useMemo, useCallback, createContext, useContext, type ReactNode } from "react";
|
|
2
2
|
import { Chat } from "@apteva/apteva-kit";
|
|
3
|
-
import { useAuth, useProjects, useTriggerRefresh } from "../../context";
|
|
3
|
+
import { useAuth, useProjects, useTriggerRefresh, useTheme } from "../../context";
|
|
4
4
|
|
|
5
5
|
interface MetaAgentStatus {
|
|
6
6
|
enabled: boolean;
|
|
@@ -112,8 +112,8 @@ export function MetaAgentButton() {
|
|
|
112
112
|
onClick={ctx.toggle}
|
|
113
113
|
className={`hidden md:flex items-center gap-2 px-3 py-2 rounded transition ${
|
|
114
114
|
ctx.isOpen
|
|
115
|
-
? "bg-[
|
|
116
|
-
: "bg-[
|
|
115
|
+
? "bg-[var(--color-accent)] text-white"
|
|
116
|
+
: "bg-[var(--color-bg-secondary)] hover:bg-[var(--color-surface-raised)] text-[var(--color-text-secondary)] hover:text-white"
|
|
117
117
|
}`}
|
|
118
118
|
title="Apteva Assistant"
|
|
119
119
|
>
|
|
@@ -128,6 +128,7 @@ export function MetaAgentButton() {
|
|
|
128
128
|
|
|
129
129
|
// Chat panel component - renders as a right-side drawer
|
|
130
130
|
export function MetaAgentPanel() {
|
|
131
|
+
const { theme } = useTheme();
|
|
131
132
|
const ctx = useMetaAgent();
|
|
132
133
|
const { currentProjectId, currentProject } = useProjects();
|
|
133
134
|
const triggerRefresh = useTriggerRefresh();
|
|
@@ -157,16 +158,16 @@ export function MetaAgentPanel() {
|
|
|
157
158
|
/>
|
|
158
159
|
|
|
159
160
|
{/* Drawer Panel */}
|
|
160
|
-
<div className="hidden md:flex fixed top-0 right-0 h-full w-[480px] lg:w-[540px] bg-[
|
|
161
|
+
<div className="hidden md:flex fixed top-0 right-0 h-full w-[480px] lg:w-[540px] bg-[var(--color-bg)] border-l border-[var(--color-border)] shadow-2xl z-50 flex-col">
|
|
161
162
|
{/* Header */}
|
|
162
|
-
<div className="flex items-center justify-between px-4 py-3 border-b border-[
|
|
163
|
+
<div className="flex items-center justify-between px-4 py-3 border-b border-[var(--color-border)] bg-[var(--color-surface)]">
|
|
163
164
|
<div className="flex items-center gap-2">
|
|
164
|
-
<div className={`w-2 h-2 rounded-full ${isRunning ? "bg-green-400" : "bg-[
|
|
165
|
+
<div className={`w-2 h-2 rounded-full ${isRunning ? "bg-green-400" : "bg-[var(--color-scrollbar)]"}`} />
|
|
165
166
|
<span className="font-medium text-sm">Apteva Assistant</span>
|
|
166
167
|
</div>
|
|
167
168
|
<button
|
|
168
169
|
onClick={close}
|
|
169
|
-
className="text-[
|
|
170
|
+
className="text-[var(--color-text-muted)] hover:text-[var(--color-text-secondary)] transition"
|
|
170
171
|
>
|
|
171
172
|
<CloseIcon />
|
|
172
173
|
</button>
|
|
@@ -180,15 +181,16 @@ export function MetaAgentPanel() {
|
|
|
180
181
|
apiUrl={`/api/agents/${agent!.id}`}
|
|
181
182
|
placeholder="Ask me anything about Apteva..."
|
|
182
183
|
variant="terminal"
|
|
184
|
+
theme={theme.id as "light" | "dark"}
|
|
183
185
|
showHeader={false}
|
|
184
186
|
context={chatContext}
|
|
185
187
|
onToolResult={triggerRefresh}
|
|
186
188
|
/>
|
|
187
189
|
) : (
|
|
188
190
|
<div className="flex-1 flex flex-col items-center justify-center p-6 text-center">
|
|
189
|
-
<AssistantIcon className="w-12 h-12 text-[
|
|
191
|
+
<AssistantIcon className="w-12 h-12 text-[var(--color-border-light)] mb-4" />
|
|
190
192
|
<h3 className="font-medium mb-2">Apteva Assistant</h3>
|
|
191
|
-
<p className="text-sm text-[
|
|
193
|
+
<p className="text-sm text-[var(--color-text-muted)] mb-6">
|
|
192
194
|
I can help you navigate Apteva, create agents, set up MCP servers, and more.
|
|
193
195
|
</p>
|
|
194
196
|
{error && (
|
|
@@ -197,7 +199,7 @@ export function MetaAgentPanel() {
|
|
|
197
199
|
<button
|
|
198
200
|
onClick={startAgent}
|
|
199
201
|
disabled={isStarting}
|
|
200
|
-
className="bg-[
|
|
202
|
+
className="bg-[var(--color-accent)] hover:bg-[var(--color-accent-hover)] disabled:opacity-50 text-white px-6 py-2 rounded font-medium transition"
|
|
201
203
|
>
|
|
202
204
|
{isStarting ? "Starting..." : "Start Assistant"}
|
|
203
205
|
</button>
|
|
@@ -125,31 +125,31 @@ export function OnboardingWizard({ onComplete, needsAccount = false }: Onboardin
|
|
|
125
125
|
const currentStep = needsAccount ? step : step - 1;
|
|
126
126
|
|
|
127
127
|
return (
|
|
128
|
-
<div className="min-h-screen bg-[
|
|
128
|
+
<div className="min-h-screen bg-[var(--color-bg)] text-[var(--color-text)] font-mono flex items-center justify-center p-8">
|
|
129
129
|
<div className="w-full max-w-2xl">
|
|
130
130
|
{/* Logo */}
|
|
131
131
|
<div className="text-center mb-8">
|
|
132
132
|
<div className="flex items-center justify-center gap-2 mb-2">
|
|
133
|
-
<span className="text-[
|
|
133
|
+
<span className="text-[var(--color-accent)] text-3xl">>_</span>
|
|
134
134
|
<span className="text-3xl tracking-wider">apteva</span>
|
|
135
135
|
</div>
|
|
136
|
-
<p className="text-[
|
|
136
|
+
<p className="text-[var(--color-text-muted)]">Run AI agents locally</p>
|
|
137
137
|
</div>
|
|
138
138
|
|
|
139
139
|
{/* Progress */}
|
|
140
140
|
<div className="flex items-center justify-center gap-2 mb-8">
|
|
141
141
|
{needsAccount && (
|
|
142
142
|
<>
|
|
143
|
-
<div className={`w-3 h-3 rounded-full ${step >= 0 ? 'bg-[
|
|
144
|
-
<div className={`w-16 h-0.5 ${step >= 1 ? 'bg-[
|
|
143
|
+
<div className={`w-3 h-3 rounded-full ${step >= 0 ? 'bg-[var(--color-accent)]' : 'bg-[var(--color-surface-raised)]'}`} />
|
|
144
|
+
<div className={`w-16 h-0.5 ${step >= 1 ? 'bg-[var(--color-accent)]' : 'bg-[var(--color-surface-raised)]'}`} />
|
|
145
145
|
</>
|
|
146
146
|
)}
|
|
147
|
-
<div className={`w-3 h-3 rounded-full ${step >= 1 ? 'bg-[
|
|
148
|
-
<div className={`w-16 h-0.5 ${step >= 2 ? 'bg-[
|
|
149
|
-
<div className={`w-3 h-3 rounded-full ${step >= 2 ? 'bg-[
|
|
147
|
+
<div className={`w-3 h-3 rounded-full ${step >= 1 ? 'bg-[var(--color-accent)]' : 'bg-[var(--color-surface-raised)]'}`} />
|
|
148
|
+
<div className={`w-16 h-0.5 ${step >= 2 ? 'bg-[var(--color-accent)]' : 'bg-[var(--color-surface-raised)]'}`} />
|
|
149
|
+
<div className={`w-3 h-3 rounded-full ${step >= 2 ? 'bg-[var(--color-accent)]' : 'bg-[var(--color-surface-raised)]'}`} />
|
|
150
150
|
</div>
|
|
151
151
|
|
|
152
|
-
<div className="bg-[
|
|
152
|
+
<div className="bg-[var(--color-surface)] rounded-lg border border-[var(--color-border)] p-8">
|
|
153
153
|
{step === 0 && needsAccount && (
|
|
154
154
|
<CreateAccountStep onComplete={handleAccountCreated} />
|
|
155
155
|
)}
|
|
@@ -220,16 +220,16 @@ function Step1AddKeys({
|
|
|
220
220
|
return (
|
|
221
221
|
<>
|
|
222
222
|
<h2 className="text-2xl font-semibold mb-2">Add {selectedProviderData.name} Key</h2>
|
|
223
|
-
<p className="text-[
|
|
223
|
+
<p className="text-[var(--color-text-muted)] mb-6">
|
|
224
224
|
Enter your API key below. It will be encrypted and stored locally.
|
|
225
225
|
</p>
|
|
226
226
|
|
|
227
227
|
<div className="mb-6">
|
|
228
|
-
<div className="p-4 rounded border border-[
|
|
228
|
+
<div className="p-4 rounded border border-[var(--color-accent)] bg-[var(--color-accent-5)] mb-4">
|
|
229
229
|
<div className="flex items-center justify-between">
|
|
230
230
|
<div>
|
|
231
231
|
<p className="font-medium">{selectedProviderData.name}</p>
|
|
232
|
-
<p className="text-sm text-[
|
|
232
|
+
<p className="text-sm text-[var(--color-text-muted)]">
|
|
233
233
|
{selectedProviderData.models.length} models available
|
|
234
234
|
</p>
|
|
235
235
|
</div>
|
|
@@ -251,7 +251,7 @@ function Step1AddKeys({
|
|
|
251
251
|
onChange={e => onApiKeyChange(e.target.value)}
|
|
252
252
|
placeholder="Enter your API key..."
|
|
253
253
|
autoFocus
|
|
254
|
-
className="w-full bg-[
|
|
254
|
+
className="w-full bg-[var(--color-bg)] border border-[var(--color-border-light)] rounded px-4 py-3 focus:outline-none focus:border-[var(--color-accent)] text-lg"
|
|
255
255
|
/>
|
|
256
256
|
{error && <p className="text-red-400 text-sm">{error}</p>}
|
|
257
257
|
{success && <p className="text-green-400 text-sm">{success}</p>}
|
|
@@ -264,14 +264,14 @@ function Step1AddKeys({
|
|
|
264
264
|
onSelectProvider(null);
|
|
265
265
|
onApiKeyChange("");
|
|
266
266
|
}}
|
|
267
|
-
className="flex-1 border border-[
|
|
267
|
+
className="flex-1 border border-[var(--color-border-light)] hover:border-[var(--color-text-muted)] px-4 py-3 rounded font-medium transition"
|
|
268
268
|
>
|
|
269
269
|
Back
|
|
270
270
|
</button>
|
|
271
271
|
<button
|
|
272
272
|
onClick={onSaveKey}
|
|
273
273
|
disabled={!apiKey || saving}
|
|
274
|
-
className="flex-1 bg-[
|
|
274
|
+
className="flex-1 bg-[var(--color-accent)] hover:bg-[var(--color-accent-hover)] disabled:opacity-50 disabled:cursor-not-allowed text-black px-4 py-3 rounded font-medium transition"
|
|
275
275
|
>
|
|
276
276
|
{testing ? "Testing..." : saving ? "Saving..." : "Save API Key"}
|
|
277
277
|
</button>
|
|
@@ -284,7 +284,7 @@ function Step1AddKeys({
|
|
|
284
284
|
return (
|
|
285
285
|
<>
|
|
286
286
|
<h2 className="text-2xl font-semibold mb-2">Welcome to apteva</h2>
|
|
287
|
-
<p className="text-[
|
|
287
|
+
<p className="text-[var(--color-text-muted)] mb-6">
|
|
288
288
|
To get started, you'll need to add at least one AI provider API key.
|
|
289
289
|
Your keys are encrypted and stored locally.
|
|
290
290
|
</p>
|
|
@@ -303,7 +303,7 @@ function Step1AddKeys({
|
|
|
303
303
|
<button
|
|
304
304
|
onClick={onContinue}
|
|
305
305
|
disabled={configuredProviders.length === 0}
|
|
306
|
-
className="w-full bg-[
|
|
306
|
+
className="w-full bg-[var(--color-surface-raised)] hover:bg-[var(--color-surface-raised)] disabled:opacity-50 disabled:cursor-not-allowed px-4 py-3 rounded font-medium transition"
|
|
307
307
|
>
|
|
308
308
|
{configuredProviders.length === 0
|
|
309
309
|
? "Add at least one API key to continue"
|
|
@@ -328,14 +328,14 @@ function ProviderCard({ provider, selected, onSelect }: ProviderCardProps) {
|
|
|
328
328
|
provider.hasKey
|
|
329
329
|
? 'border-green-500/30 bg-green-500/5'
|
|
330
330
|
: selected
|
|
331
|
-
? 'border-[
|
|
332
|
-
: 'border-[
|
|
331
|
+
? 'border-[var(--color-accent)] bg-[var(--color-accent-5)]'
|
|
332
|
+
: 'border-[var(--color-border-light)] hover:border-[var(--color-border-light)]'
|
|
333
333
|
}`}
|
|
334
334
|
>
|
|
335
335
|
<div className="flex items-center justify-between">
|
|
336
336
|
<div>
|
|
337
337
|
<p className="font-medium">{provider.name}</p>
|
|
338
|
-
<p className="text-sm text-[
|
|
338
|
+
<p className="text-sm text-[var(--color-text-muted)]">
|
|
339
339
|
{provider.models.length} models available
|
|
340
340
|
</p>
|
|
341
341
|
</div>
|
|
@@ -370,17 +370,17 @@ function Step2Complete({ configuredProviders, onAddMore, onComplete }: Step2Prop
|
|
|
370
370
|
return (
|
|
371
371
|
<>
|
|
372
372
|
<h2 className="text-2xl font-semibold mb-2">You're all set!</h2>
|
|
373
|
-
<p className="text-[
|
|
373
|
+
<p className="text-[var(--color-text-muted)] mb-6">
|
|
374
374
|
You've configured {configuredProviders.length} provider{configuredProviders.length > 1 ? 's' : ''}.
|
|
375
375
|
You can add more providers later in Settings.
|
|
376
376
|
</p>
|
|
377
377
|
|
|
378
378
|
<div className="space-y-2 mb-6">
|
|
379
379
|
{configuredProviders.map(provider => (
|
|
380
|
-
<div key={provider.id} className="flex items-center gap-3 p-3 bg-[
|
|
380
|
+
<div key={provider.id} className="flex items-center gap-3 p-3 bg-[var(--color-bg)] rounded">
|
|
381
381
|
<CheckIcon className="w-5 h-5 text-green-400" />
|
|
382
382
|
<span>{provider.name}</span>
|
|
383
|
-
<span className="text-[
|
|
383
|
+
<span className="text-[var(--color-text-muted)] text-sm">({provider.keyHint})</span>
|
|
384
384
|
</div>
|
|
385
385
|
))}
|
|
386
386
|
</div>
|
|
@@ -388,13 +388,13 @@ function Step2Complete({ configuredProviders, onAddMore, onComplete }: Step2Prop
|
|
|
388
388
|
<div className="flex gap-3">
|
|
389
389
|
<button
|
|
390
390
|
onClick={onAddMore}
|
|
391
|
-
className="flex-1 border border-[
|
|
391
|
+
className="flex-1 border border-[var(--color-border-light)] hover:border-[var(--color-accent)] px-4 py-3 rounded font-medium transition"
|
|
392
392
|
>
|
|
393
393
|
Add More
|
|
394
394
|
</button>
|
|
395
395
|
<button
|
|
396
396
|
onClick={onComplete}
|
|
397
|
-
className="flex-1 bg-[
|
|
397
|
+
className="flex-1 bg-[var(--color-accent)] hover:bg-[var(--color-accent-hover)] text-black px-4 py-3 rounded font-medium transition"
|
|
398
398
|
>
|
|
399
399
|
Start Using apteva
|
|
400
400
|
</button>
|