From 52275c782af84f85ac55866aa8d14d64ab10b380 Mon Sep 17 00:00:00 2001 From: Anthony Ronning <101225832+AnthonyRonning@users.noreply.github.com> Date: Sun, 25 Oct 2026 07:24:43 +0000 Subject: [PATCH] Show Maple Work migration notice on new Agent tasks --- .../frontend/src/components/AgentMode.tsx | 10 ++ .../agent/AgentWorkAnnouncement.tsx | 166 ++++++++++++++++++ 2 files changed, 176 insertions(+) create mode 100644 apps/maple-research/frontend/src/components/agent/AgentWorkAnnouncement.tsx diff --git a/apps/maple-research/frontend/src/components/AgentMode.tsx b/apps/maple-research/frontend/src/components/AgentMode.tsx index 120ef09dc..de71e7b46 100644 --- a/apps/maple-research/frontend/src/components/AgentMode.tsx +++ b/apps/maple-research/frontend/src/components/AgentMode.tsx @@ -90,6 +90,7 @@ import { ModelSelector } from "@/components/ModelSelector"; import { ToolActivityCard } from "@/components/ToolActivityCard"; import { AgentMcpMenu, AgentMcpServersDialog } from "@/components/agent/AgentMcpControls"; import { AgentSidebarInfoCard } from "@/components/agent/AgentSidebarInfoCard"; +import { AgentWorkAnnouncement } from "@/components/agent/AgentWorkAnnouncement"; import { latestAgentSidebarUpdatedMs } from "@/components/agent/agentSidebarInfoCardDate"; import { isDeliberateAgentComposerFocusTarget, @@ -3657,6 +3658,15 @@ export function AgentMode({ userId }: { userId: string }) { /> ) : null} + {timelineItems.length === 0 && + !hasStartedAgentSession && + !isInitializing && + !isTaskTransitionPending && + !isSubmitting && + !activeRunId ? ( + + ) : null} + {error && (
diff --git a/apps/maple-research/frontend/src/components/agent/AgentWorkAnnouncement.tsx b/apps/maple-research/frontend/src/components/agent/AgentWorkAnnouncement.tsx new file mode 100644 index 000000000..a53687e23 --- /dev/null +++ b/apps/maple-research/frontend/src/components/agent/AgentWorkAnnouncement.tsx @@ -0,0 +1,166 @@ +import { useEffect, useState } from "react"; +import { arch, type } from "@tauri-apps/plugin-os"; +import { ArrowRight, Download, ExternalLink, Gift, Sparkles } from "lucide-react"; + +import { Button } from "@/components/ui/button"; +import { + Dialog, + DialogContent, + DialogDescription, + DialogFooter, + DialogHeader, + DialogTitle, + DialogTrigger +} from "@/components/ui/dialog"; +import { marketingUrl } from "@/config/domains"; +import { FEATURE_FLAGS, flagsClient } from "@/services/flags"; +import { openExternalUrl } from "@/utils/openUrl"; + +function workDownload() { + // These are the architectures currently published by Maple Work. Read the + // native OS plugin rather than guessing from the webview's user agent. + try { + const os = type(); + const architecture = arch(); + if (os === "macos" && architecture === "aarch64") { + return { + label: "Download for macOS", + detail: "For Apple silicon Macs", + url: "https://updates.maple.ai/download/agent/stable/macos" + }; + } + if (os === "linux" && architecture === "x86_64") { + return { + label: "Download for Linux", + detail: "For x86-64 Linux · Extract the archive and run install.sh", + url: "https://updates.maple.ai/download/agent/stable/linux" + }; + } + } catch { + // Unknown devices can still learn about Work without a mismatched installer. + } + return null; +} + +export function AgentWorkAnnouncement({ userId }: { userId: string }) { + const [flag, setFlag] = useState<{ userId: string; enabled: boolean } | null>(null); + const enabled = + flag?.userId === userId + ? flag.enabled + : flagsClient.peekIsEnabled(userId, FEATURE_FLAGS.AGENT_MODE); + + useEffect(() => { + let disposed = false; + void flagsClient.isEnabled(userId, FEATURE_FLAGS.AGENT_MODE).then( + (enabled) => { + if (!disposed) setFlag({ userId, enabled }); + }, + () => { + if (!disposed) setFlag({ userId, enabled: false }); + } + ); + return () => { + disposed = true; + }; + }, [userId]); + + if (enabled !== true) return null; + + const download = workDownload(); + + return ( +
+ + + + + + + +
+
+
+ Meet Maple Work +
+ + Agent Mode is moving to its own desktop app. + +
+ +
+
+

Thanks for being an early beta tester!

+

+ Maple Work brings private AI to your desktop to work in your projects, run commands, + and get tasks done for you. +

+
+ +
+

+

+

+ For a limited time, enjoy special pricing on DeepSeek usage in Maple Work. Your + early-tester pricing is already active on your account. +

+
+ +
+

What happens to your Agent Mode chats?

+

+ Agent Mode in Maple Research will be retired soon. You won’t be able to continue + your chats here after that, and they won’t transfer to Maple Work. Save anything you + want to keep. +

+
+
+ + + {download ? ( + <> + +

{download.detail}

+ + ) : ( +

+ Maple Work is available for Apple silicon Macs and x86-64 Linux. A download for this + device isn’t available yet. +

+ )} + +
+
+
+
+ ); +}