feat(sidebar): restore PR state color, swap badge order, brighten checks on hover
- PR icon color reflects merge state (open/merged/closed) via the existing getWorkspacePrIconColor helper. - PR badge is rendered before the failed-checks badge in the workspace row. - Hovering the PR badge swaps the GitPullRequest icon for ExternalLink in place (same size, no layout shift) and removes the trailing arrow. - Hovering the checks row in the workspace hover card brightens the icon and "Checks" label to foreground.
This commit is contained in:
@@ -306,14 +306,24 @@ function WorkspaceHoverCardContent({
|
||||
badgeLabel = `${checks.length} passed`;
|
||||
}
|
||||
|
||||
const iconColor = hovered
|
||||
? theme.colors.foreground
|
||||
: theme.colors.foregroundMuted;
|
||||
return (
|
||||
<>
|
||||
{hovered ? (
|
||||
<ExternalLink size={12} color={theme.colors.foregroundMuted} />
|
||||
<ExternalLink size={12} color={iconColor} />
|
||||
) : (
|
||||
<GitHubIcon size={12} color={theme.colors.foregroundMuted} />
|
||||
<GitHubIcon size={12} color={iconColor} />
|
||||
)}
|
||||
<Text style={styles.checksSummaryLabel}>Checks</Text>
|
||||
<Text
|
||||
style={[
|
||||
styles.checksSummaryLabel,
|
||||
hovered && styles.checksSummaryLabelHovered,
|
||||
]}
|
||||
>
|
||||
Checks
|
||||
</Text>
|
||||
<View style={styles.checksSummaryCounts}>
|
||||
<View style={[styles.checksDot, { backgroundColor: badgeColor }]} />
|
||||
<Text style={[styles.checksStatusText, { color: badgeColor }]}>
|
||||
@@ -395,6 +405,9 @@ const styles = StyleSheet.create((theme) => ({
|
||||
fontWeight: theme.fontWeight.normal,
|
||||
color: theme.colors.foregroundMuted,
|
||||
},
|
||||
checksSummaryLabelHovered: {
|
||||
color: theme.colors.foreground,
|
||||
},
|
||||
checksSummaryCounts: {
|
||||
flexDirection: "row",
|
||||
alignItems: "center",
|
||||
|
||||
Reference in New Issue
Block a user