- 내부 설정 공통 탭에서 등록 모델 상단 중복 선택 칩 UI 제거 - 등록 모델 관리 영역을 리스트 중심 구조로 정리 - 선택 편집 삭제 액션을 팝업 친화적인 클릭 row 방식으로 변경 - 오버레이 동기화 경로에서 제거된 모델 칩 렌더 호출 삭제 - README 및 DEVELOPMENT 문서에 2026-04-06 00:08 (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:
@@ -14548,7 +14548,6 @@ public partial class ChatWindow : Window
|
||||
RefreshOverlayTokenPresetCards();
|
||||
RefreshOverlayServiceFieldLabels(service);
|
||||
RefreshOverlayServiceFieldVisibility(service);
|
||||
BuildOverlayModelChips(service);
|
||||
BuildOverlayRegisteredModelsPanel(service);
|
||||
RefreshOverlayAdvancedChoiceButtons();
|
||||
}
|
||||
@@ -16470,71 +16469,6 @@ public partial class ChatWindow : Window
|
||||
};
|
||||
}
|
||||
|
||||
private void BuildOverlayModelChips(string service)
|
||||
{
|
||||
if (OverlayModelChipPanel == null)
|
||||
return;
|
||||
|
||||
OverlayModelChipPanel.Children.Clear();
|
||||
foreach (var model in GetModelCandidates(service))
|
||||
{
|
||||
var captured = model.Id;
|
||||
var isActive = string.Equals(model.Id, _settings.Settings.Llm.Model, StringComparison.OrdinalIgnoreCase);
|
||||
var border = new Border
|
||||
{
|
||||
Cursor = Cursors.Hand,
|
||||
CornerRadius = new CornerRadius(8),
|
||||
BorderThickness = new Thickness(1),
|
||||
BorderBrush = isActive
|
||||
? BrushFromHex("#C7D2FE")
|
||||
: (TryFindResource("BorderColor") as Brush ?? Brushes.Gray),
|
||||
Background = isActive
|
||||
? BrushFromHex("#EEF2FF")
|
||||
: Brushes.Transparent,
|
||||
Padding = new Thickness(10, 7, 10, 7),
|
||||
Margin = new Thickness(0, 0, 8, 8),
|
||||
Child = new StackPanel
|
||||
{
|
||||
Children =
|
||||
{
|
||||
new TextBlock
|
||||
{
|
||||
Text = model.Label,
|
||||
FontSize = 11.5,
|
||||
FontWeight = isActive ? FontWeights.SemiBold : FontWeights.Normal,
|
||||
Foreground = isActive
|
||||
? BrushFromHex("#1D4ED8")
|
||||
: (TryFindResource("PrimaryText") as Brush ?? Brushes.Black),
|
||||
},
|
||||
new TextBlock
|
||||
{
|
||||
Text = model.Id,
|
||||
Margin = new Thickness(0, 2, 0, 0),
|
||||
FontSize = 10,
|
||||
Foreground = TryFindResource("SecondaryText") as Brush ?? Brushes.Gray,
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
border.MouseEnter += (_, _) =>
|
||||
{
|
||||
if (!isActive)
|
||||
border.Background = TryFindResource("ItemHoverBackground") as Brush ?? Brushes.LightGray;
|
||||
};
|
||||
border.MouseLeave += (_, _) =>
|
||||
{
|
||||
if (!isActive)
|
||||
border.Background = Brushes.Transparent;
|
||||
};
|
||||
border.MouseLeftButtonUp += (_, _) =>
|
||||
{
|
||||
CommitOverlayModelSelection(captured);
|
||||
PersistOverlaySettingsState(refreshOverlayDeferredInputs: false);
|
||||
};
|
||||
OverlayModelChipPanel.Children.Add(border);
|
||||
}
|
||||
}
|
||||
|
||||
private void BuildOverlayRegisteredModelsPanel(string service)
|
||||
{
|
||||
if (OverlayRegisteredModelsPanel == null || OverlayRegisteredModelsHeader == null || BtnOverlayAddModel == null)
|
||||
@@ -16638,29 +16572,53 @@ public partial class ChatWindow : Window
|
||||
VerticalAlignment = VerticalAlignment.Top,
|
||||
};
|
||||
|
||||
Button CreateAction(string text, RoutedEventHandler onClick, Brush foreground)
|
||||
Border CreateAction(string text, Action onClick, Brush foreground)
|
||||
{
|
||||
var button = new Button
|
||||
var label = new TextBlock
|
||||
{
|
||||
Content = text,
|
||||
Style = TryFindResource("GhostBtn") as Style,
|
||||
Text = text,
|
||||
FontSize = 11.5,
|
||||
FontWeight = FontWeights.SemiBold,
|
||||
Foreground = foreground,
|
||||
VerticalAlignment = VerticalAlignment.Center,
|
||||
};
|
||||
|
||||
var action = new Border
|
||||
{
|
||||
Cursor = Cursors.Hand,
|
||||
CornerRadius = new CornerRadius(8),
|
||||
Padding = new Thickness(8, 4, 8, 4),
|
||||
Margin = new Thickness(6, 0, 0, 0),
|
||||
Foreground = foreground,
|
||||
Cursor = Cursors.Hand,
|
||||
Background = Brushes.Transparent,
|
||||
Child = label,
|
||||
};
|
||||
button.Click += onClick;
|
||||
return button;
|
||||
action.MouseEnter += (_, _) =>
|
||||
{
|
||||
action.Background = hoverBg;
|
||||
};
|
||||
action.MouseLeave += (_, _) =>
|
||||
{
|
||||
action.Background = Brushes.Transparent;
|
||||
};
|
||||
action.MouseLeftButtonUp += (_, _) => onClick();
|
||||
return action;
|
||||
}
|
||||
|
||||
actions.Children.Add(CreateAction("선택", (_, _) =>
|
||||
actions.Children.Add(CreateAction("선택", () =>
|
||||
{
|
||||
CommitOverlayModelSelection(model.EncryptedModelName);
|
||||
PersistOverlaySettingsState(refreshOverlayDeferredInputs: false);
|
||||
}, accentBrush));
|
||||
|
||||
actions.Children.Add(CreateAction("편집", (_, _) => EditOverlayRegisteredModel(model), primaryText));
|
||||
actions.Children.Add(CreateAction("삭제", (_, _) => DeleteOverlayRegisteredModel(model), BrushFromHex("#DC2626")));
|
||||
actions.Children.Add(CreateAction("편집", () =>
|
||||
{
|
||||
EditOverlayRegisteredModel(model);
|
||||
BuildOverlayRegisteredModelsPanel(service);
|
||||
}, primaryText));
|
||||
actions.Children.Add(CreateAction("삭제", () =>
|
||||
{
|
||||
DeleteOverlayRegisteredModel(model);
|
||||
}, BrushFromHex("#DC2626")));
|
||||
|
||||
Grid.SetColumn(actions, 1);
|
||||
grid.Children.Add(actions);
|
||||
|
||||
Reference in New Issue
Block a user