@@ -8,6 +8,7 @@ import type { AgentResponse, UpdateAgentBody } from '@/api/agents';
88import { getAgentDetailQueryKey , updateAgent } from '@/api/agents' ;
99import { NovuApiError } from '@/api/api.client' ;
1010import { AnimatedBadgeDot , Badge } from '@/components/primitives/badge' ;
11+ import { HelpTooltipIndicator } from '@/components/primitives/help-tooltip-indicator' ;
1112import { Input } from '@/components/primitives/input' ;
1213import { showErrorToast , showSuccessToast } from '@/components/primitives/sonner-helpers' ;
1314import { Switch } from '@/components/primitives/switch' ;
@@ -36,10 +37,18 @@ function formatLongDate(dateStr: string): string {
3637 return formatted ;
3738}
3839
39- function SidebarRow ( { label, children, className } : { label : string ; children : React . ReactNode ; className ?: string } ) {
40+ function SidebarRow ( {
41+ label,
42+ children,
43+ className,
44+ } : {
45+ label : React . ReactNode ;
46+ children : React . ReactNode ;
47+ className ?: string ;
48+ } ) {
4049 return (
4150 < div className = { cn ( 'flex h-8 items-center justify-between px-1.5' , className ) } >
42- < span className = "text-text-soft text-label-xs font-medium" > { label } </ span >
51+ < span className = "text-text-soft text-label-xs flex items-center gap-1 font-medium" > { label } </ span >
4352 < div className = "flex items-center gap-1.5" > { children } </ div >
4453 </ div >
4554 ) ;
@@ -72,17 +81,17 @@ type BridgeUrlSectionProps = {
7281} ;
7382
7483function BridgeUrlSection ( { agent, canWrite, isUpdatePending, onUpdate } : BridgeUrlSectionProps ) {
75- const isDevOverrideActive = Boolean ( agent . devBridgeActive && agent . devBridgeUrl ) ;
76- const activeBridgeUrl = isDevOverrideActive ? agent . devBridgeUrl : agent . bridgeUrl ;
84+ const isLocalTunnelActive = Boolean ( agent . devBridgeActive && agent . devBridgeUrl ) ;
85+ const activeBridgeUrl = isLocalTunnelActive ? agent . devBridgeUrl : agent . bridgeUrl ;
7786
7887 return (
7988 < >
8089 < SidebarRow label = "Bridge URL" >
8190 { activeBridgeUrl ? (
8291 < div className = "flex items-center gap-1" >
83- { isDevOverrideActive ? (
92+ { isLocalTunnelActive ? (
8493 < Badge variant = "lighter" color = "orange" size = "sm" >
85- DEV
94+ LOCAL
8695 </ Badge >
8796 ) : null }
8897 < TruncatedUrl url = { activeBridgeUrl } />
@@ -92,7 +101,17 @@ function BridgeUrlSection({ agent, canWrite, isUpdatePending, onUpdate }: Bridge
92101 ) }
93102 </ SidebarRow >
94103 { agent . devBridgeUrl ? (
95- < SidebarRow label = "Dev override" >
104+ < SidebarRow
105+ label = {
106+ < >
107+ Local tunnel connection
108+ < HelpTooltipIndicator
109+ size = "3"
110+ text = "When enabled, the agent forwards traffic to your local tunnel URL instead of the deployed agent endpoint. Use this to test changes locally without redeploying."
111+ />
112+ </ >
113+ }
114+ >
96115 < Switch
97116 checked = { agent . devBridgeActive ?? false }
98117 disabled = { ! canWrite || isUpdatePending }
0 commit comments