@@ -11,6 +11,7 @@ import { GitPullRequest } from "lucide-react";
1111import { Popover , PopoverContent , PopoverTrigger } from "@/shared/ui/popover" ;
1212import { TopBarIconButton } from "@/shared/ui/top-bar-icon-button" ;
1313import { PullRequestsPanel } from "./PullRequestsPanel" ;
14+ import { WorkStatusBridge } from "./WorkStatusBridge" ;
1415import { useWorkStatusStore } from "./workStatusStore" ;
1516
1617const DEFAULT_POPOVER_HEIGHT = 480 ;
@@ -114,48 +115,53 @@ export function PullRequestsPopover() {
114115 } ;
115116
116117 return (
117- < Popover open = { open } onOpenChange = { handleOpenChange } >
118- < PopoverTrigger asChild >
119- < TopBarIconButton
120- type = "button"
121- size = "icon-top-bar"
122- className = "relative"
123- aria-label = { t ( "workStatus.topBarLabel" , { count : pullRequestCount } ) }
124- tooltip = { t ( "workStatus.title" ) }
118+ < >
119+ < WorkStatusBridge active = { open } />
120+ < Popover open = { open } onOpenChange = { handleOpenChange } >
121+ < PopoverTrigger asChild >
122+ < TopBarIconButton
123+ type = "button"
124+ size = "icon-top-bar"
125+ className = "relative"
126+ aria-label = { t ( "workStatus.topBarLabel" , {
127+ count : pullRequestCount ,
128+ } ) }
129+ tooltip = { t ( "workStatus.title" ) }
130+ >
131+ < GitPullRequest aria-hidden />
132+ { pullRequestCount > 0 ? (
133+ < span
134+ aria-hidden = "true"
135+ className = "pointer-events-none absolute -right-1 -top-1 flex h-4 min-w-4 items-center justify-center rounded-full bg-foreground px-1 font-medium text-[9px] leading-none text-background tabular-nums"
136+ >
137+ { formatCount ( pullRequestCount ) }
138+ </ span >
139+ ) : null }
140+ </ TopBarIconButton >
141+ </ PopoverTrigger >
142+ < PopoverContent
143+ align = "end"
144+ sideOffset = { 8 }
145+ style = { { height } }
146+ className = "relative w-[min(460px,calc(100vw-2rem))] max-w-[calc(100vw-2rem)] overflow-visible border-0 bg-transparent p-0 shadow-none"
125147 >
126- < GitPullRequest aria-hidden />
127- { pullRequestCount > 0 ? (
128- < span
129- aria-hidden = "true"
130- className = "pointer-events-none absolute -right-1 -top-1 flex h-4 min-w-4 items-center justify-center rounded-full bg-foreground px-1 font-medium text-[9px] leading-none text-background tabular-nums"
131- >
132- { formatCount ( pullRequestCount ) }
133- </ span >
134- ) : null }
135- </ TopBarIconButton >
136- </ PopoverTrigger >
137- < PopoverContent
138- align = "end"
139- sideOffset = { 8 }
140- style = { { height } }
141- className = "relative w-[min(460px,calc(100vw-2rem))] max-w-[calc(100vw-2rem)] overflow-visible border-0 bg-transparent p-0 shadow-none"
142- >
143- < PullRequestsPanel />
144- < hr
145- tabIndex = { 0 }
146- aria-label = { t ( "workStatus.resize" ) }
147- aria-orientation = "horizontal"
148- aria-valuemin = { minAvailableHeight ( ) }
149- aria-valuemax = { maxAvailableHeight ( ) }
150- aria-valuenow = { Math . round ( height ) }
151- onKeyDown = { handleResizeKeyDown }
152- onPointerDown = { handleResizePointerDown }
153- onPointerMove = { handleResizePointerMove }
154- onPointerUp = { handleResizePointerUp }
155- onPointerCancel = { handleResizePointerUp }
156- className = "absolute right-3 bottom-0 left-3 z-10 h-3 translate-y-1/2 cursor-ns-resize touch-none rounded-sm border-0 bg-transparent outline-none focus-visible:ring-2 focus-visible:ring-ring"
157- />
158- </ PopoverContent >
159- </ Popover >
148+ < PullRequestsPanel />
149+ < hr
150+ tabIndex = { 0 }
151+ aria-label = { t ( "workStatus.resize" ) }
152+ aria-orientation = "horizontal"
153+ aria-valuemin = { minAvailableHeight ( ) }
154+ aria-valuemax = { maxAvailableHeight ( ) }
155+ aria-valuenow = { Math . round ( height ) }
156+ onKeyDown = { handleResizeKeyDown }
157+ onPointerDown = { handleResizePointerDown }
158+ onPointerMove = { handleResizePointerMove }
159+ onPointerUp = { handleResizePointerUp }
160+ onPointerCancel = { handleResizePointerUp }
161+ className = "absolute right-3 bottom-0 left-3 z-10 h-3 translate-y-1/2 cursor-ns-resize touch-none rounded-sm border-0 bg-transparent outline-none focus-visible:ring-2 focus-visible:ring-ring"
162+ />
163+ </ PopoverContent >
164+ </ Popover >
165+ </ >
160166 ) ;
161167}
0 commit comments