From 16c349417f7b72984a5b1f97d2f5374d6f38faae Mon Sep 17 00:00:00 2001 From: Bohdan Triapitsyn Date: Tue, 5 May 2026 23:57:42 +0300 Subject: [PATCH] style: simplify git header controls Show sync counters only when needed Use an icon-only identity selector --- packages/ui/src/components/views/git/GitHeader.tsx | 2 +- packages/ui/src/components/views/git/SyncActions.tsx | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/ui/src/components/views/git/GitHeader.tsx b/packages/ui/src/components/views/git/GitHeader.tsx index 88a890a0..ec4cdac0 100644 --- a/packages/ui/src/components/views/git/GitHeader.tsx +++ b/packages/ui/src/components/views/git/GitHeader.tsx @@ -270,7 +270,7 @@ export const GitHeader: React.FC = ({ onSelect={onSelectIdentity} isApplying={isApplyingIdentity} - iconOnly={false} + iconOnly={true} /> ); diff --git a/packages/ui/src/components/views/git/SyncActions.tsx b/packages/ui/src/components/views/git/SyncActions.tsx index 790bef9d..5e287988 100644 --- a/packages/ui/src/components/views/git/SyncActions.tsx +++ b/packages/ui/src/components/views/git/SyncActions.tsx @@ -55,9 +55,11 @@ export const SyncActions: React.FC = ({ const isPrimaryDisabled = disabled || syncAction !== null || isRemovingRemote || !trackingRemote || blocksRebaseSync; const isDropdownDisabled = disabled || syncAction !== null || isRemovingRemote || remotes.length === 0; const hasKnownSyncWork = aheadCount > 0 || behindCount > 0; - const primaryLabel = hasKnownSyncWork - ? t('gitView.sync.syncCounts', { ahead: aheadCount, behind: behindCount }) - : t('gitView.sync.sync'); + const primaryLabel = [ + t('gitView.sync.sync'), + behindCount > 0 ? `↓${behindCount}` : null, + aheadCount > 0 ? `↑${aheadCount}` : null, + ].filter(Boolean).join(' '); const tooltipLabel = blocksRebaseSync ? t('gitView.sync.commitOrStashTooltip') : trackingRemote