AX Agent 토큰 사용 라벨 hover 종료와 스타일 정리
Some checks failed
Release Gate / gate (push) Has been cancelled

- 하단 컨텍스트 토큰 라벨이 hover 후 남아 있던 문제를 카드와 팝업의 실제 hover 상태 기준으로 닫히도록 수정
- 토큰 카드가 숨겨질 때 popup도 함께 닫히도록 보강
- 토큰 심볼과 popup 스타일을 얇은 테두리와 약한 그림자 중심으로 정리
- README와 DEVELOPMENT 문서에 2026-04-05 22:53 (KST) 기준 작업 이력 반영
- 검증: dotnet build src/AxCopilot/AxCopilot.csproj -c Release -v minimal -p:OutputPath=bin\verify\ -p:IntermediateOutputPath=obj\verify\ (경고 0 / 오류 0)
This commit is contained in:
2026-04-05 20:08:15 +09:00
parent 2975bb39a2
commit 78905d16c0
4 changed files with 25 additions and 9 deletions

View File

@@ -1734,9 +1734,9 @@
Width="28"
Height="28"
CornerRadius="999"
BorderBrush="Transparent"
BorderThickness="0"
Background="Transparent"
BorderBrush="{DynamicResource BorderColor}"
BorderThickness="1"
Background="{DynamicResource LauncherBackground}"
VerticalAlignment="Center"
Visibility="Collapsed"
Cursor="Hand"
@@ -1744,8 +1744,8 @@
MouseLeave="TokenUsageCard_MouseLeave">
<Grid>
<Grid Width="28" Height="28" VerticalAlignment="Center">
<Ellipse Stroke="{DynamicResource HintBackground}"
StrokeThickness="3"/>
<Ellipse Stroke="{DynamicResource BorderColor}"
StrokeThickness="2.5"/>
<Path x:Name="TokenUsageArc"
Stroke="{DynamicResource AccentColor}"
StrokeThickness="3"
@@ -1812,13 +1812,13 @@
<Border Background="{DynamicResource LauncherBackground}"
BorderBrush="{DynamicResource BorderColor}"
BorderThickness="1"
CornerRadius="14"
CornerRadius="12"
Padding="12,10"
MinWidth="186"
MouseEnter="TokenUsagePopup_MouseEnter"
MouseLeave="TokenUsagePopup_MouseLeave">
<Border.Effect>
<DropShadowEffect BlurRadius="18" ShadowDepth="0" Opacity="0.16"/>
<DropShadowEffect BlurRadius="10" ShadowDepth="0" Opacity="0.08"/>
</Border.Effect>
<StackPanel>
<TextBlock x:Name="TokenUsagePopupTitle"

View File

@@ -265,8 +265,7 @@ public partial class ChatWindow : Window
_tokenUsagePopupCloseTimer.Tick += (_, _) =>
{
_tokenUsagePopupCloseTimer.Stop();
if (TokenUsagePopup != null)
TokenUsagePopup.IsOpen = false;
CloseTokenUsagePopupIfIdle();
};
KeyDown += ChatWindow_KeyDown;
@@ -18866,6 +18865,8 @@ private static (string icon, string label, string bgHex, string fgHex) GetDecisi
TokenUsageCard.Visibility = showContextUsage ? Visibility.Visible : Visibility.Collapsed;
if (!showContextUsage)
{
if (TokenUsagePopup != null)
TokenUsagePopup.IsOpen = false;
return;
}
@@ -18989,6 +18990,17 @@ private static (string icon, string label, string bgHex, string fgHex) GetDecisi
_tokenUsagePopupCloseTimer.Start();
}
private void CloseTokenUsagePopupIfIdle()
{
if (TokenUsagePopup == null)
return;
var cardHovered = TokenUsageCard?.IsMouseOver ?? false;
var popupHovered = TokenUsagePopup.Child is FrameworkElement popupChild && popupChild.IsMouseOver;
if (!cardHovered && !popupHovered)
TokenUsagePopup.IsOpen = false;
}
private static string BuildUsageModelKey(string? service, string? model)
{
var normalizedService = (service ?? "").Trim().ToLowerInvariant();