@@ -22,6 +22,7 @@ import { Label } from "@/components/ui/label";
2222import { Separator } from "@/components/ui/separator" ;
2323import { Skeleton } from "@/components/ui/skeleton" ;
2424import { Textarea } from "@/components/ui/textarea" ;
25+ import { Tooltip , TooltipContent , TooltipTrigger } from "@/components/ui/tooltip" ;
2526import { checkMcpServerDynamicClientRegistration , createMcpServer , createStaticOAuthMcpServer , deleteMcpServer , updateMcpServerOAuthScopes } from "@/ee/features/chat/mcp/actions" ;
2627import { ConnectMcpButton } from "@/ee/features/chat/mcp/components/connectMcpButton" ;
2728import { ConnectorCard } from "@/ee/features/chat/mcp/components/connectorCard" ;
@@ -31,7 +32,7 @@ import { buildMcpOAuthScopeEntries, getMcpRequestedOAuthScopes, normalizeMcpRequ
3132import { pluralize } from "@/features/chat/mcp/utils" ;
3233import { cn , isServiceError } from "@/lib/utils" ;
3334import { useQuery , useQueryClient } from "@tanstack/react-query" ;
34- import { AlertTriangleIcon , CableIcon , CopyIcon , KeyRoundIcon , Loader2 , MoreHorizontalIcon , PlusIcon , Trash2Icon , WrenchIcon } from "lucide-react" ;
35+ import { AlertTriangleIcon , CableIcon , CopyIcon , InfoIcon , KeyRoundIcon , Loader2 , MoreHorizontalIcon , PlusIcon , Trash2Icon , WrenchIcon } from "lucide-react" ;
3536import { PrefabConnectorPopover } from "@/ee/features/chat/mcp/components/prefabConnectorPopover" ;
3637import Markdown from "react-markdown" ;
3738import { getStaticOAuthDescription , type PrefabMcpServer } from "@/ee/features/chat/mcp/prefabMcpServers" ;
@@ -154,6 +155,18 @@ function OAuthScopesInput({
154155 aria-label = { `Request ${ scope } ` }
155156 />
156157 < span className = "break-all font-mono text-xs" > { scope } </ span >
158+ { scope === OFFLINE_ACCESS_SCOPE && (
159+ < Tooltip >
160+ < TooltipTrigger asChild >
161+ < span className = "shrink-0 text-muted-foreground" onClick = { ( event ) => event . preventDefault ( ) } >
162+ < InfoIcon className = "h-3.5 w-3.5" />
163+ </ span >
164+ </ TooltipTrigger >
165+ < TooltipContent className = "max-w-64" >
166+ Required for refresh tokens. Without this scope, users must re-authenticate whenever their access token expires, and some connectors reject authorization entirely.
167+ </ TooltipContent >
168+ </ Tooltip >
169+ ) }
157170 </ label >
158171 { onRemoveOAuthScope && (
159172 < Button
0 commit comments