Path: blob/main/components/dashboard/src/OnaRightPanel.tsx
2498 views
/**1* Copyright (c) 2025 Gitpod GmbH. All rights reserved.2* Licensed under the GNU Affero General Public License (AGPL).3* See License.AGPL.txt in the project root for license information.4*/56import React, { useState, useEffect } from "react";7import { trackEvent } from "./Analytics";8import { useCurrentUser } from "./user-context";9import { getPrimaryEmail } from "@gitpod/public-api-common/lib/user-utils";10import { useToast } from "./components/toasts/Toasts";11import onaWordmark from "./images/ona-wordmark.svg";12import onaApplication from "./images/ona-application.webp";1314export const OnaRightPanel = () => {15const [email, setEmail] = useState("");16const [isSubmitted, setIsSubmitted] = useState(false);17const user = useCurrentUser();18const { toast } = useToast();1920useEffect(() => {21const storedOnaData = localStorage.getItem("ona-waitlist-data");22if (storedOnaData) {23const { submitted } = JSON.parse(storedOnaData);24setIsSubmitted(submitted || false);25}26}, []);2728const handleEmailSubmit = (e: React.FormEvent) => {29e.preventDefault();30if (!email.trim()) return;3132const userEmail = user ? getPrimaryEmail(user) || email : email;33trackEvent("waitlist_joined", { email: userEmail, feature: "Ona" });3435setIsSubmitted(true);36localStorage.setItem("ona-waitlist-data", JSON.stringify({ submitted: true }));3738toast(39<div>40<div className="font-medium">You're on the waitlist</div>41<div className="text-sm opacity-80">We'll reach out to you soon.</div>42</div>,43);44};4546return (47<div className="w-full lg:w-1/3 flex flex-col justify-center p-4 lg:p-6 md:min-h-screen">48<div49className="rounded-lg flex flex-col gap-6 text-white p-6 h-full max-w-md mx-auto w-full"50style={{51background:52"linear-gradient(340deg, #1F1329 0%, #333A75 20%, #556CA8 40%, #90A898 60%, #E2B15C 80%, #BEA462 100%)",53}}54>55<div className="flex justify-center pt-4">56<img src={onaWordmark} alt="ONA" className="w-32" draggable="false" />57</div>5859<div className="relative bg-white/10 backdrop-blur-sm rounded-lg p-4 -mt-2">60<img61src={onaApplication}62alt="Ona application preview"63className="w-full h-auto rounded-lg shadow-lg"64draggable="false"65/>66</div>6768<div className="flex flex-col gap-4 flex-1">69<h2 className="text-white text-xl font-bold leading-tight text-center">70Ona - parallel SWE agents in the cloud, sandboxed for high-autonomy.{" "}71<a72href="https://app.ona.com"73target="_blank"74rel="noreferrer"75className="underline hover:no-underline"76>77Start for free78</a>{" "}79and get $100 credits. Gitpod Classic sunsets Oct 15 |{" "}80<a81href="https://ona.com/stories/gitpod-classic-payg-sunset"82target="_blank"83rel="noreferrer"84className="underline hover:no-underline"85>86Learn more87</a>88</h2>8990<div className="space-y-3 text-sm text-white/90 leading-relaxed">91<p>92Delegate software tasks to Ona. It writes code, runs tests, and opens a pull request. Or93jump in to inspect output or pair program in your IDE.94</p>95<p>96Ona runs inside your infrastructure (VPC), with full audit trails, zero data exposure, and97support for any LLM.98</p>99</div>100101<div className="mt-auto pt-4">102{!isSubmitted ? (103<form onSubmit={handleEmailSubmit} className="space-y-3">104<input105type="email"106value={email}107onChange={(e) => setEmail(e.target.value)}108placeholder="Enter your work email"109className="w-full px-4 py-2.5 rounded-lg bg-white/10 backdrop-blur-sm border border-white/20 text-white placeholder-white/60 focus:outline-none focus:ring-2 focus:ring-white/30 text-sm"110required111/>112<button113type="submit"114className="w-full bg-white text-gray-900 font-medium py-2.5 px-4 rounded-lg hover:bg-gray-100 transition-colors text-sm inline-flex items-center justify-center gap-2"115>116Request access117<span className="font-bold">→</span>118</button>119</form>120) : (121<button122onClick={() =>123window.open("https://www.gitpod.io/solutions/ai", "_blank", "noopener,noreferrer")124}125className="w-full bg-white/20 backdrop-blur-sm text-white font-medium py-2.5 px-4 rounded-lg hover:bg-white/30 transition-colors border border-white/20 inline-flex items-center justify-center gap-2 text-sm"126>127Learn more128<span className="font-bold">→</span>129</button>130)}131</div>132</div>133</div>134</div>135);136};137138139