Skip to content

YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context

fix(workflows): preserve sharing choice, allow team accounts, and emphasize website (#7273)

Louis Beaumont25396f3c54cb
diff --git a/.github/pr-assets/workflow-consent-context/context-after.png b/.github/pr-assets/workflow-consent-context/context-after.png
new file mode 100644
index 000000000..91e012800
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-after.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-before.png b/.github/pr-assets/workflow-consent-context/context-before.png
new file mode 100644
index 000000000..03d26b8e0
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-before.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-filled-compact.png b/.github/pr-assets/workflow-consent-context/context-filled-compact.png
new file mode 100644
index 000000000..73ba73512
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-filled-compact.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-filled-desktop.png b/.github/pr-assets/workflow-consent-context/context-filled-desktop.png
new file mode 100644
index 000000000..fd43a0692
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-filled-desktop.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-filled-narrow.png b/.github/pr-assets/workflow-consent-context/context-filled-narrow.png
new file mode 100644
index 000000000..d1c66df3b
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-filled-narrow.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-narrow-after.png b/.github/pr-assets/workflow-consent-context/context-narrow-after.png
new file mode 100644
index 000000000..c2625003f
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-narrow-after.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-narrow-before.png b/.github/pr-assets/workflow-consent-context/context-narrow-before.png
new file mode 100644
index 000000000..51f5be41b
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-narrow-before.png differ
diff --git a/.github/pr-assets/workflow-consent-context/context-website-keyboard-focus.png b/.github/pr-assets/workflow-consent-context/context-website-keyboard-focus.png
new file mode 100644
index 000000000..cddae1a29
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/context-website-keyboard-focus.png differ
diff --git a/.github/pr-assets/workflow-consent-context/enable-confirmation-desktop.png b/.github/pr-assets/workflow-consent-context/enable-confirmation-desktop.png
new file mode 100644
index 000000000..ca9479cfc
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/enable-confirmation-desktop.png differ
diff --git a/.github/pr-assets/workflow-consent-context/enable-confirmation-narrow.png b/.github/pr-assets/workflow-consent-context/enable-confirmation-narrow.png
new file mode 100644
index 000000000..5c583ac62
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/enable-confirmation-narrow.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-after-outside-click.png b/.github/pr-assets/workflow-consent-context/sharing-after-outside-click.png
new file mode 100644
index 000000000..a37f6f7f1
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-after-outside-click.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-details-desktop.png b/.github/pr-assets/workflow-consent-context/sharing-details-desktop.png
new file mode 100644
index 000000000..0834718f0
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-details-desktop.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-details-narrow.png b/.github/pr-assets/workflow-consent-context/sharing-details-narrow.png
new file mode 100644
index 000000000..72da769ed
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-details-narrow.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-loading.png b/.github/pr-assets/workflow-consent-context/sharing-loading.png
new file mode 100644
index 000000000..4a08a64bf
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-loading.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-ready-desktop.png b/.github/pr-assets/workflow-consent-context/sharing-ready-desktop.png
new file mode 100644
index 000000000..a37f6f7f1
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-ready-desktop.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-ready-narrow.png b/.github/pr-assets/workflow-consent-context/sharing-ready-narrow.png
new file mode 100644
index 000000000..a936645ed
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-ready-narrow.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-save-error-before.png b/.github/pr-assets/workflow-consent-context/sharing-save-error-before.png
new file mode 100644
index 000000000..5ca69d934
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-save-error-before.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-save-error.png b/.github/pr-assets/workflow-consent-context/sharing-save-error.png
new file mode 100644
index 000000000..a92b2ad2c
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-save-error.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-saving.png b/.github/pr-assets/workflow-consent-context/sharing-saving.png
new file mode 100644
index 000000000..ec756a2bb
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-saving.png differ
diff --git a/.github/pr-assets/workflow-consent-context/sharing-unavailable-after.png b/.github/pr-assets/workflow-consent-context/sharing-unavailable-after.png
new file mode 100644
index 000000000..203955d36
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/sharing-unavailable-after.png differ
diff --git a/.github/pr-assets/workflow-consent-context/team-sharing-after.png b/.github/pr-assets/workflow-consent-context/team-sharing-after.png
new file mode 100644
index 000000000..588fff41d
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/team-sharing-after.png differ
diff --git a/.github/pr-assets/workflow-consent-context/team-sharing-before.png b/.github/pr-assets/workflow-consent-context/team-sharing-before.png
new file mode 100644
index 000000000..5f74b7ce5
Binary files /dev/null and b/.github/pr-assets/workflow-consent-context/team-sharing-before.png differ
diff --git a/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.test.tsx b/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.test.tsx
index 6497f8818..4d08c9603 100644
--- a/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.test.tsx
+++ b/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.test.tsx
@@ -66,16 +66,29 @@ describe("sharing consent UI", () => {
await waitFor(() => expect(requests.some(r => r.method === "DELETE")).toBe(true));
expect(f.settings.workflowSharing).toBeNull();
});
- it("hides the optional entry control when rollout is unavailable", async () => {
- remote.available = false;
- render(<WorkflowSharingControls compact />);
- await waitFor(() => expect(requests.length).toBe(1));
- expect(screen.queryByRole("switch")).toBeNull();
+ it.each(["unavailable", "notice mismatch"])("keeps %s sharing visible without saving a choice", async reason => {
+ if (reason === "unavailable") remote.available = false;
+ if (reason === "notice mismatch") remote.noticeVersion = "different-version";
+ const done = vi.fn();
+ render(<WorkflowSharingControls compact onDone={done} />);
+ expect(await screen.findByText("Sharing is not available for this account.")).toBeVisible();
+ expect(screen.getByRole("button", { name: "Allow sharing" })).toBeDisabled();
+ expect(screen.getByRole("button", { name: "Not now" })).toBeEnabled();
+ expect(done).not.toHaveBeenCalled();
+ expect(f.update).not.toHaveBeenCalled();
+ expect(requests.every(r => r.method === "GET")).toBe(true);
});
- it("does not enable sharing for managed deployments", async () => {
- f.managed = true; render(<WorkflowSharingControls />);
- await waitFor(() => expect(requests.length).toBe(1));
- expect(screen.getByRole("switch")).toBeDisabled();
+ it.each([false, true])("allows managed accounts to opt in explicitly (compact=%s)", async compact => {
+ f.managed = true;
+ f.settings.enterpriseManagedSettings = { serverUrl: "https://example.com" };
+ render(<WorkflowSharingControls compact={compact} />);
+ const control = compact ? screen.getByRole("button", { name: "Allow sharing" }) : screen.getByRole("switch");
+ await waitFor(() => expect(control).toBeEnabled());
+ expect(requests.every(r => r.method === "GET")).toBe(true);
+ expect(f.update).not.toHaveBeenCalled();
+ fireEvent.click(control);
+ await waitFor(() => expect(f.settings.workflowSharing).toMatchObject({ accountId: "user_one" }));
+ expect(requests.find(r => r.method === "PUT")!.body).toMatchObject({ sharing: true, training: true });
});
it("submits both permissions only after the explicit prompt action", async () => {
const done = vi.fn();
diff --git a/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.tsx b/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.tsx
index 3569e513b..804a240d4 100644
--- a/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.tsx
+++ b/apps/screenpipe-app-tauri/components/workflows/workflow-sharing-controls.tsx
@@ -4,21 +4,18 @@
import { PROD_WEB_BASE, screenpipeWebUrl } from "@/lib/web-url";
import { useEffect, useRef, useState } from "react";
import { useSettings } from "@/lib/hooks/use-settings";
-import { useManagedPolicy } from "@/lib/hooks/use-managed-policy";
import { commands } from "@/lib/utils/tauri";
import { Button } from "@/components/ui/button";
import { Loader2, MessageSquare, ShieldCheck } from "lucide-react";
import { Switch } from "@/components/ui/switch";
import { SHARING_NOTICE_VERSION, sharingRequest, trajectoryCollector, type SharingStatus } from "@/lib/trajectories/collector";
-export function WorkflowSharingControls({ compact = false, onDone, onUnavailable, onBusyChange }: {
+export function WorkflowSharingControls({ compact = false, onDone, onBusyChange }: {
compact?: boolean;
onDone?: () => void;
- onUnavailable?: () => void;
onBusyChange?: (busy: boolean) => void;
}) {
const { settings, updateSettings } = useSettings();
- const { isManagedDeployment } = useManagedPolicy();
const [status, setStatus] = useState<SharingStatus | null>(null);
const [busy, setBusy] = useState(false);
const [error, setError] = useState("");
@@ -39,11 +36,7 @@ export function WorkflowSharingControls({ compact = false, onDone, onUnavailable
}, [settings.user?.id, settings.workflowSharing?.epoch, reload, compact]);
const local = settings.workflowSharing;
const enabled = !!local && status?.acceptedNoticeVersion === SHARING_NOTICE_VERSION && status.training && status?.sharing === true && status.accountId === local.accountId && status.epoch === local.epoch;
- const available = !!status?.available && !isManagedDeployment && status.noticeVersion === SHARING_NOTICE_VERSION;
-
- useEffect(() => {
- if (compact && status && !available && !local) onUnavailable?.();
- }, [compact, status, available, local, onUnavailable]);
+ const available = !!status?.available && status.noticeVersion === SHARING_NOTICE_VERSION;
async function change(sharing: boolean, remove = false) {
if (busy || (sharing && !available)) return;
@@ -113,6 +106,7 @@ export function WorkflowSharingControls({ compact = false, onDone, onUnavailable
{confirmDelete && <p className="w-full text-xs text-muted-foreground">Deletes shared copies for this account and stops sharing on all devices. Your local chats stay on this device.</p>}
</div>}
{compact && <>
+ {status && !available && <p role="status" className="text-xs text-muted-foreground">Sharing is not available for this account.</p>}
{!status && !error && <p role="status" className="text-xs text-muted-foreground">Checking sharing availability…</p>}
<p className="text-xs text-muted-foreground">Stop sharing or delete shared chats in Privacy settings.</p>
<div className="grid grid-cols-2 gap-3">
diff --git a/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.test.tsx b/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.test.tsx
index eb1791edb..feb837a20 100644
--- a/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.test.tsx
+++ b/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.test.tsx
@@ -93,6 +93,36 @@ describe("workflow schedule control", () => {
await waitFor(() => expect(f.settings.workflowSharingPromptSeen["fixture-user"]).toBe("2026-09-23"));
expect(tasks.enable).not.toHaveBeenCalled(); expect(tasks.disable).not.toHaveBeenCalled();
});
+ it("keeps sharing open across recorder disconnect and reconnect until explicitly closed", async () => {
+ f.settings.workflowSharingPromptSeen = {};
+ const tasks = service();
+ const view = render(<WorkflowTasksPrompt active tasks={tasks} />);
+ await loaded(); await enable();
+ expect(await screen.findByRole("dialog", { name: "Help improve Screenpipe" })).toBeVisible();
+ view.rerender(<WorkflowTasksPrompt active backendReady={false} tasks={tasks} />);
+ expect(screen.getByRole("dialog", { name: "Help improve Screenpipe" })).toBeVisible();
+ view.rerender(<WorkflowTasksPrompt active backendReady tasks={tasks} />);
+ expect(screen.getByRole("dialog", { name: "Help improve Screenpipe" })).toBeVisible();
+ fireEvent.click(screen.getByRole("button", { name: "Close" }));
+ await waitFor(() => expect(screen.queryByRole("dialog")).not.toBeInTheDocument());
+ expect(f.settings.workflowSharingPromptSeen["fixture-user"]).toBe("2026-09-23");
+ });
+ it("ignores outside clicks on both consent steps without recording a choice", async () => {
+ f.settings.workflowSharingPromptSeen = {};
+ const tasks = service(); render(<WorkflowTasksPrompt active tasks={tasks} />); await loaded();
+ fireEvent.click(toggle());
+ // Radix registers outside-pointer handling after the opening event.
+ await act(async () => { await new Promise(resolve => setTimeout(resolve, 0)); });
+ fireEvent.pointerDown(document.querySelector("[data-modal-overlay]")!, { pointerType: "mouse", button: 0 });
+ expect(screen.getByRole("dialog", { name: "Keep your workflows up to date?" })).toBeVisible();
+ fireEvent.click(screen.getByRole("button", { name: "Enable automatic updates" }));
+ expect(await screen.findByText("Skip sharing")).toBeVisible();
+ fireEvent.pointerDown(document.querySelector("[data-modal-overlay]")!, { pointerType: "mouse", button: 0 });
+ expect(screen.getByRole("dialog", { name: "Help improve Screenpipe" })).toBeVisible();
+ expect(f.update).not.toHaveBeenCalled();
+ fireEvent.keyDown(screen.getByRole("dialog"), { key: "Escape" });
+ await waitFor(() => expect(screen.queryByRole("dialog")).not.toBeInTheDocument());
+ });
it("waits for backend readiness and recovers on reconnect without clicking retry", async () => {
const tasks = service([true,true,true,true]);
const view = render(<WorkflowTasksPrompt active backendReady={false} tasks={tasks} />);
diff --git a/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.tsx b/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.tsx
index 7ca1ca2ad..d1356fa5b 100644
--- a/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.tsx
+++ b/apps/screenpipe-app-tauri/components/workflows/workflow-tasks-prompt.tsx
@@ -42,7 +42,6 @@ export function WorkflowTasksPrompt({ active, tasks = desktopTasks, backendReady
const failedIntent = useRef<boolean | null>(null);
failedIntent.current = failedTarget;
- const close = useCallback(() => setOpen(false), []);
const finishSharing = useCallback(() => {
const account = current.current.user?.id;
if (account) void updateSettings({ workflowSharingPromptSeen: { ...current.current.workflowSharingPromptSeen, [account]: SHARING_NOTICE_VERSION } }).catch(() => {});
@@ -64,9 +63,9 @@ export function WorkflowTasksPrompt({ active, tasks = desktopTasks, backendReady
let timer: ReturnType<typeof setTimeout> | undefined;
let attempts = 0;
let offeredSharing = false;
- setOpen(false);
+ // Recorder reconnects refresh task status, not an open consent decision.
+ if (!active) { setOpen(false); setStep("tasks"); }
setSetup(null);
- setStep("tasks");
setError("");
async function load() {
if (loading || enabling.current || cancelled) return;
@@ -162,10 +161,11 @@ export function WorkflowTasksPrompt({ active, tasks = desktopTasks, backendReady
if (enabling.current || busy) return;
if (!value && step === "sharing") finishSharing(); else setOpen(value);
}}>
- <DialogContent onOpenAutoFocus={event => { event.preventDefault(); title.current?.focus(); }} style={{
+ <DialogContent onInteractOutside={event => event.preventDefault()} onOpenAutoFocus={event => { event.preventDefault(); title.current?.focus(); }} style={{
"--foreground": "0 0% 9%", "--background": "0 0% 100%", "--muted-foreground": "80 4% 42%",
"--border": "70 10% 85%", "--primary": "0 0% 9%", "--primary-foreground": "0 0% 100%",
"--accent": "70 10% 95%", "--accent-foreground": "0 0% 9%",
+ "--destructive": "0 0% 9%", "--destructive-foreground": "0 0% 100%",
colorScheme: "light", background: "#fff", color: "#171815", fontFamily: "Inter, -apple-system, BlinkMacSystemFont, sans-serif",
} as CSSProperties} className="max-w-md [&_button]:normal-case [&_button]:tracking-normal [&_button]:font-[inherit]" overlayClassName="bg-black/30" hideCloseButton={busy}>
<DialogHeader className="text-left">
@@ -176,7 +176,7 @@ export function WorkflowTasksPrompt({ active, tasks = desktopTasks, backendReady
{step === "tasks" ? "Discover workflows and keep them accurate with automatic updates." : "Share new Workflows chats to improve workflows and train Screenpipe’s own AI models. Never external providers’ models."}
</DialogDescription>
</DialogHeader>
- {step === "sharing" ? <WorkflowSharingControls compact onDone={finishSharing} onUnavailable={close} onBusyChange={setBusy} /> : <>
+ {step === "sharing" ? <WorkflowSharingControls compact onDone={finishSharing} onBusyChange={setBusy} /> : <>
{setup && <div className="flex items-center gap-3 rounded-lg border p-4">
<Clock3 className="h-4 w-4 shrink-0 text-muted-foreground" aria-hidden="true" />
<div className="min-w-0"><p className="text-sm font-medium">{setup.title}</p><p className="text-xs text-muted-foreground">{setup.schedule} · While Screenpipe is open</p></div>
diff --git a/apps/screenpipe-app-tauri/lib/trajectories/collector.test.ts b/apps/screenpipe-app-tauri/lib/trajectories/collector.test.ts
index 1bb8f428b..4f08899a0 100644
--- a/apps/screenpipe-app-tauri/lib/trajectories/collector.test.ts
+++ b/apps/screenpipe-app-tauri/lib/trajectories/collector.test.ts
@@ -1,7 +1,7 @@
// screenpipe — AI that knows everything you've seen, said, or heard
// https://screenpipe.com
import { describe, it, expect, vi } from "vitest";
-import { createTrajectoryCollector, type LocalSharing, type SharingStatus } from "./collector";
+import { createTrajectoryCollector, type LocalSharing, type SharingStatus, trajectoryCollector } from "./collector";
function fixture() {
let local: LocalSharing | null = { accountId: "user_one", epoch: "epoch-one", enabledAt: 0, priorBackend: "local" };
let token: string | null = "token-one";
@@ -71,3 +71,16 @@ describe("Trajectory collection boundary", () => {
await f.collector.complete(ticket, "question", " "); expect(f.request).not.toHaveBeenCalled();
});
});
+
+const managed = vi.hoisted(() => ({ settings: {} as any }));
+vi.mock("@/lib/hooks/use-settings", () => ({ getStore: async () => ({ get: async () => managed.settings }) }));
+vi.mock("@/lib/utils/tauri", () => ({ commands: { getCloudToken: async () => "token-one" } }));
+it("honors explicit managed-account consent while requiring cloud redaction", async () => {
+ managed.settings = { enterpriseManagedSettings: { serverUrl: "https://example.com" }, piiBackend: "tinfoil", workflowSharing: { accountId: "user_one", epoch: "epoch-one", enabledAt: 0, priorBackend: "local" } };
+ expect(await trajectoryCollector.begin()).toMatchObject({ local: { accountId: "user_one", epoch: "epoch-one" } });
+ managed.settings.piiBackend = "local";
+ expect(await trajectoryCollector.begin()).toBeNull();
+ managed.settings.piiBackend = "tinfoil";
+ managed.settings.workflowSharing = null;
+ expect(await trajectoryCollector.begin()).toBeNull();
+});
diff --git a/apps/screenpipe-app-tauri/lib/trajectories/collector.ts b/apps/screenpipe-app-tauri/lib/trajectories/collector.ts
index 9aac90616..452ab6e5a 100644
--- a/apps/screenpipe-app-tauri/lib/trajectories/collector.ts
+++ b/apps/screenpipe-app-tauri/lib/trajectories/collector.ts
@@ -93,8 +93,8 @@ export const trajectoryCollector = createTrajectoryCollector({
async local() {
const { getStore } = await import("@/lib/hooks/use-settings");
const settings = await (await getStore()).get<import("@/lib/hooks/use-settings").Settings>("settings");
- // Managed deployments never contribute, even if an old local preference exists.
- if (settings?.enterpriseManagedSettings || settings?.piiBackend !== "tinfoil") return null;
+ // Every account needs explicit opt-in and strict cloud redaction.
+ if (settings?.piiBackend !== "tinfoil") return null;
return settings?.workflowSharing ?? null;
},
token: () => commands.getCloudToken(),
diff --git a/packages/workflows-ui/src/context-composer.tsx b/packages/workflows-ui/src/context-composer.tsx
index ed194c92a..529e9aa6a 100644
--- a/packages/workflows-ui/src/context-composer.tsx
+++ b/packages/workflows-ui/src/context-composer.tsx
@@ -91,8 +91,8 @@ export function ContextComposer({ profile, update, fillContext, discoverContext
return <section className={styles.contextComposer} aria-label={ui("Add context")}
onDragOver={(event) => { event.preventDefault(); }}
onDrop={(event) => { event.preventDefault(); readFiles(Array.from(event.dataTransfer.files)); }}>
- <label className={styles.contextWebsite}><span>Company website</span><input aria-label={ui("Company website")} value={profile.website || ""} onChange={(event) => update({ ...profile, website: event.target.value })} placeholder="company.com" autoComplete="url" maxLength={253} disabled={busy} /></label>
- <textarea aria-label={ui("Paste context")} placeholder={discoverContext ? ui("Add notes or files, or let Screenpipe learn from your work history and connections…") : ui("Paste notes about your work, or drop documents here…")} value={text} onChange={(event) => setText(event.target.value)} maxLength={MAX_CONTEXT_SOURCE_TEXT} disabled={busy || reading} />
+ <label className={styles.contextWebsite}><span>Company website</span><input aria-label={ui("Company website")} value={profile.website || ""} onChange={(event) => update({ ...profile, website: event.target.value })} placeholder="company.com" inputMode="url" autoCapitalize="none" spellCheck={false} autoComplete="url" maxLength={253} disabled={busy} /></label>
+ <textarea rows={2} aria-label={ui("Paste context")} placeholder={discoverContext ? ui("Optional: add notes or files, or learn from your work history and connections…") : ui("Optional: paste notes about your work, or drop documents here…")} value={text} onChange={(event) => setText(event.target.value)} maxLength={MAX_CONTEXT_SOURCE_TEXT} disabled={busy || reading} />
{documents.length > 0 && <div className={styles.contextAttachments}>{documents.map((document, index) => <span key={`${index}:${document.name}`}>{document.name}<button aria-label={ui("Remove {value1}", { value1: document.name })} onClick={() => setDocuments(documents.filter((_, i) => i !== index))} disabled={busy || reading}><X size={12} /></button></span>)}</div>}
<div className={styles.contextToolbar}>
<input ref={input} type="file" multiple accept=".pdf,.txt,.md,.markdown,.csv,.json,.zip" hidden onChange={(event) => { readFiles(Array.from(event.target.files || [])); event.target.value = ""; }} />
diff --git a/packages/workflows-ui/src/workflows-app.module.css b/packages/workflows-ui/src/workflows-app.module.css
index 6f69933d7..b7884cabf 100644
--- a/packages/workflows-ui/src/workflows-app.module.css
+++ b/packages/workflows-ui/src/workflows-app.module.css
@@ -915,10 +915,11 @@
.contextHeader h1 { margin: 0; font-size: 26px; font-weight: 650; letter-spacing: -.03em; }
.contextHeader p { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.contextComposer { margin-bottom: 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); overflow: hidden; }
-.contextWebsite { display: flex; align-items: center; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
-.contextWebsite span { flex-shrink: 0; font-size: 12px; color: var(--muted); }
-.contextWebsite input { width: 100%; min-width: 0; border: 0; background: transparent; color: var(--ink); font: inherit; font-size: 13px; outline-offset: 4px; }
-.contextComposer > textarea { display: block; width: 100%; min-height: 100px; padding: 16px; border: 0; resize: vertical; color: var(--ink); background: transparent; font: inherit; font-size: 13px; line-height: 1.6; outline-offset: -3px; }
+.contextWebsite { display: flex; flex-direction: column; gap: 10px; padding: 20px; border-bottom: 1px solid var(--line); }
+.contextWebsite span { font-size: 15px; font-weight: 600; color: var(--ink); }
+.contextWebsite input { width: 100%; min-width: 0; min-height: 48px; padding: 12px 14px; border: 1px solid var(--muted); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; font-size: 16px; }
+.contextWebsite input:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
+.contextComposer > textarea { display: block; width: 100%; min-height: 64px; padding: 16px; border: 0; resize: vertical; color: var(--ink); background: transparent; font: inherit; font-size: 13px; line-height: 1.6; outline-offset: -3px; }
.contextToolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; }
.contextToolbar button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); color: var(--ink); font: inherit; font-size: 12px; cursor: pointer; }
.contextToolbar .contextFillButton { border-color: var(--ink); background: var(--ink); color: var(--panel); }