diff --git a/src/renderer/src/components/settings/AntigravityChatSignInRow.test.tsx b/src/renderer/src/components/settings/AntigravityChatSignInRow.test.tsx index 88980f2aa3c6..09d870d5490f 100644 --- a/src/renderer/src/components/settings/AntigravityChatSignInRow.test.tsx +++ b/src/renderer/src/components/settings/AntigravityChatSignInRow.test.tsx @@ -163,28 +163,30 @@ it('sends the address pasted from a browser on another computer to the host', as it("names the account and why it's needed before the host knows its sign-in", async () => { const owner = { kind: 'environment', environmentId: 'provider-unanswered' } as const render( - + + }} + /> + ) await act(async () => undefined) expect(screen.getByText('Account')).toBeTruthy() diff --git a/src/renderer/src/components/settings/AntigravityChatSignInRow.tsx b/src/renderer/src/components/settings/AntigravityChatSignInRow.tsx index e81a65b76043..8b74bae209e4 100644 --- a/src/renderer/src/components/settings/AntigravityChatSignInRow.tsx +++ b/src/renderer/src/components/settings/AntigravityChatSignInRow.tsx @@ -1,5 +1,5 @@ import { useEffect, useId, useState, useSyncExternalStore } from 'react' -import { Check, Copy } from 'lucide-react' +import { Check, Copy, Info } from 'lucide-react' import { translate } from '@/i18n/i18n' import { useClipboardTextCopyFeedback } from '@/hooks/use-clipboard-text-copy-feedback' import { @@ -202,6 +202,26 @@ export function PastedAddressForm(props: { ) } +/** Beside the sign-in button: users expect their agy CLI login to carry over to chats. */ +export function AntigravityChatSignInInfo(): React.JSX.Element { + const label = translate('accounts.antigravity.chatSignInInfoLabel', 'About Antigravity sign-in') + return ( + + + + + + {translate( + 'accounts.antigravity.chatSignInInfo', + "Antigravity chats have their own sign-in. Signing in to the agy CLI doesn't sign you in here." + )} + + + ) +} + /** One host's chat sign-in as both Settings layouts show it. `signedOut` is the line for a host * that answered it is not signed in; `unanswered` stands in while it has nothing else to say, as a * host learns its sign-in only when a chat starts or asks to sign in. */ @@ -325,15 +345,18 @@ export function AntigravityChatSignInRow(props: { ) : ( - +
+ + +
)} {url && } diff --git a/src/renderer/src/components/settings/AntigravityProviderSignInArea.tsx b/src/renderer/src/components/settings/AntigravityProviderSignInArea.tsx index 25fba3d906f9..3cc2996f2049 100644 --- a/src/renderer/src/components/settings/AntigravityProviderSignInArea.tsx +++ b/src/renderer/src/components/settings/AntigravityProviderSignInArea.tsx @@ -5,6 +5,7 @@ import type { RuntimeClientTarget } from '../../../../shared/runtime-client-targ import { LoadingSpinner } from '../LoadingSpinner' import { Button } from '../ui/button' import { + AntigravityChatSignInInfo, PastedAddressForm, antigravityChatSignInBlocked, useAntigravityChatSignInControls @@ -85,15 +86,18 @@ export function AntigravityProviderSignInArea(props: { ) : ( - +
+ + +
)} {url && } diff --git a/src/renderer/src/i18n/locales/en.json b/src/renderer/src/i18n/locales/en.json index d735840f6df7..0afca3021bd8 100644 --- a/src/renderer/src/i18n/locales/en.json +++ b/src/renderer/src/i18n/locales/en.json @@ -20092,6 +20092,8 @@ "chatTitle": "Antigravity chats", "chatDescription": "Chats use their own Antigravity sign-in, separate from your agy account above. Sign in once on this device.", "chatSignIn": "Sign in", + "chatSignInInfoLabel": "About Antigravity sign-in", + "chatSignInInfo": "Antigravity chats have their own sign-in. Signing in to the agy CLI doesn't sign you in here.", "chatChangeAccount": "Change account", "chatRetry": "Retry sign-in", "chatCancel": "Cancel", diff --git a/src/renderer/src/i18n/locales/es.json b/src/renderer/src/i18n/locales/es.json index e57e14b9d160..72e3dc573ab3 100644 --- a/src/renderer/src/i18n/locales/es.json +++ b/src/renderer/src/i18n/locales/es.json @@ -19694,6 +19694,8 @@ "chatTitle": "Chats de Antigravity", "chatDescription": "Los chats usan su propio inicio de sesión de Antigravity, independiente de tu cuenta de agy de arriba. Inicia sesión una vez en este dispositivo.", "chatSignIn": "Iniciar sesión", + "chatSignInInfoLabel": "Acerca del inicio de sesión de Antigravity", + "chatSignInInfo": "Los chats de Antigravity tienen su propio inicio de sesión. Iniciar sesión en la CLI de agy no inicia sesión aquí.", "chatChangeAccount": "Cambiar de cuenta", "chatRetry": "Reintentar inicio de sesión", "chatCancel": "Cancelar", diff --git a/src/renderer/src/i18n/locales/fr.json b/src/renderer/src/i18n/locales/fr.json index 7571c2be53b7..e735104b3e56 100644 --- a/src/renderer/src/i18n/locales/fr.json +++ b/src/renderer/src/i18n/locales/fr.json @@ -19851,6 +19851,8 @@ "chatTitle": "Discussions Antigravity", "chatDescription": "Les discussions utilisent leur propre connexion Antigravity, distincte de votre compte agy ci-dessus. Connectez-vous une seule fois sur cet appareil.", "chatSignIn": "Se connecter", + "chatSignInInfoLabel": "À propos de la connexion Antigravity", + "chatSignInInfo": "Les chats Antigravity ont leur propre connexion. Se connecter à la CLI agy ne vous connecte pas ici.", "chatChangeAccount": "Changer de compte", "chatRetry": "Réessayer la connexion", "chatCancel": "Annuler", diff --git a/src/renderer/src/i18n/locales/ja.json b/src/renderer/src/i18n/locales/ja.json index 4c88d1d25949..8f7b5f4dea76 100644 --- a/src/renderer/src/i18n/locales/ja.json +++ b/src/renderer/src/i18n/locales/ja.json @@ -19851,6 +19851,8 @@ "chatTitle": "Antigravity チャット", "chatDescription": "チャットは上の agy アカウントとは別の、独自の Antigravity サインインを使用します。このデバイスで一度サインインしてください。", "chatSignIn": "サインイン", + "chatSignInInfoLabel": "Antigravity のサインインについて", + "chatSignInInfo": "Antigravity チャットには専用のサインインがあります。agy CLI にサインインしても、ここではサインインされません。", "chatChangeAccount": "アカウントを変更", "chatRetry": "サインインを再試行", "chatCancel": "キャンセル", diff --git a/src/renderer/src/i18n/locales/ko.json b/src/renderer/src/i18n/locales/ko.json index 6bcc6bddc12e..4aea15541189 100644 --- a/src/renderer/src/i18n/locales/ko.json +++ b/src/renderer/src/i18n/locales/ko.json @@ -19851,6 +19851,8 @@ "chatTitle": "Antigravity 채팅", "chatDescription": "채팅은 위의 agy 계정과 별개인 자체 Antigravity 로그인을 사용합니다. 이 기기에서 한 번 로그인하세요.", "chatSignIn": "로그인", + "chatSignInInfoLabel": "Antigravity 로그인 정보", + "chatSignInInfo": "Antigravity 채팅은 별도로 로그인합니다. agy CLI에 로그인해도 여기에는 로그인되지 않습니다.", "chatChangeAccount": "계정 변경", "chatRetry": "로그인 다시 시도", "chatCancel": "취소", diff --git a/src/renderer/src/i18n/locales/zh.json b/src/renderer/src/i18n/locales/zh.json index aa269aa3e3b5..d47bfd693968 100644 --- a/src/renderer/src/i18n/locales/zh.json +++ b/src/renderer/src/i18n/locales/zh.json @@ -19851,6 +19851,8 @@ "chatTitle": "Antigravity 聊天", "chatDescription": "聊天使用自己的 Antigravity 登录,与上方的 agy 帐户分开。在此设备上登录一次即可。", "chatSignIn": "登录", + "chatSignInInfoLabel": "关于 Antigravity 登录", + "chatSignInInfo": "Antigravity 聊天有单独的登录。登录 agy CLI 不会在这里登录。", "chatChangeAccount": "更换帐户", "chatRetry": "重试登录", "chatCancel": "取消",