refactor(web): use ghost-muted where ghost buttons restyled to muted (#13020)

Co-authored-by: Claude Fable 5 <[email protected]>
This commit is contained in:
Julius MarmingeandClaude Fable 5 authored and GitHub committed 2026-09-22 12:22:10 -07:00
1 parent 17e34773b1
commit c0490e9d0e
12 files changed
+22 -33

No files matched your search

@@ -24,8 +24,7 @@ export function DiffFilePathCopyButton({ filePath }: { filePath: string }) {
<Button
ref={ref}
size="icon-micro"
variant="ghost"
className="text-muted-foreground [:hover,[data-pressed]]:bg-transparent"
variant="ghost-muted"
aria-label="Copy file path"
onClick={() => copyToClipboard(filePath, undefined)}
/>
+2 -2
View File
@@ -1260,9 +1260,9 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
render={
<Button
aria-label="Add panel surface"
className="size-6 shrink-0 text-muted-foreground hover:text-foreground"
className="size-6 shrink-0"
size="icon-xs"
variant="ghost"
variant="ghost-muted"
/>
}
>
@@ -117,10 +117,10 @@ export const ProviderStatusBanner = memo(function ProviderStatusBanner({
</div>
<Button
aria-label={`Dismiss ${providerName} provider ${status.status}`}
className="absolute top-2 right-2 size-6 text-muted-foreground hover:text-foreground"
className="absolute top-2 right-2 size-6"
onClick={onDismiss}
size="icon-xs"
variant="ghost"
variant="ghost-muted"
>
<XIcon aria-hidden className="size-3.5" />
</Button>
@@ -68,8 +68,8 @@ export function DiffCommentAnnotation({
<p className="min-w-0 flex-1 whitespace-pre-wrap text-[13px] leading-5">{displayedText}</p>
{onDelete ? (
<Button
className="-my-1 -mr-1 shrink-0 text-muted-foreground opacity-0 transition-opacity group-hover/comment:opacity-100 focus-visible:opacity-100 max-sm:opacity-100"
variant="ghost"
className="-my-1 -mr-1 shrink-0 opacity-0 transition-opacity group-hover/comment:opacity-100 focus-visible:opacity-100 max-sm:opacity-100"
variant="ghost-muted"
size="icon-xs"
aria-label="Delete comment"
onClick={onDelete}
@@ -115,12 +115,7 @@ export function DiffCommentAnnotation({
/>
<div className="mt-1.5 flex items-center gap-1">
<span className="mr-auto text-[10px] text-muted-foreground/70">⌘/Ctrl Enter to send</span>
<Button
className="text-muted-foreground hover:text-foreground"
variant="ghost"
size="xs"
onClick={onCancel}
>
<Button variant="ghost-muted" size="xs" onClick={onCancel}>
Cancel
</Button>
{secondaryAction ? (
@@ -44,8 +44,8 @@ export function PullRequestCommentBody({
{overflowing ? (
<Button
size="xs"
variant="ghost"
className="mt-2 text-muted-foreground"
variant="ghost-muted"
className="mt-2"
aria-expanded={expanded}
aria-controls={id}
onClick={() => {
@@ -166,8 +166,8 @@ function OpenOnHostButton({ url, onOpen }: { url: string | null; onOpen: (url: s
return url === null ? null : (
<Button
size="icon-xs"
variant="ghost"
className="-mr-1 -mt-1 shrink-0 text-muted-foreground"
variant="ghost-muted"
className="-mr-1 -mt-1 shrink-0"
aria-label="Open activity on host"
onClick={() => onOpen(url)}
>
@@ -369,8 +369,7 @@ export function AddProviderInstanceDialog({
<Button
type="button"
size="xs"
variant="ghost"
className="text-muted-foreground"
variant="ghost-muted"
onClick={() => setAccentColor("")}
>
Clear
@@ -1626,9 +1626,8 @@ function SavedBackendListRow({
render={
<Button
type="button"
variant="ghost"
variant="ghost-muted"
size="icon-xs"
className="text-muted-foreground hover:text-foreground"
disabled={isRemoving}
aria-label={`More actions for ${environment.label}`}
/>
@@ -3292,9 +3291,8 @@ export function ConnectionsSettings() {
render={
<Button
type="button"
variant="ghost"
variant="ghost-muted"
size="icon-xs"
className="text-muted-foreground hover:text-foreground"
aria-label="More actions for this machine"
/>
}
@@ -952,9 +952,8 @@ function KeybindingRowMenu({
render={
<Button
type="button"
variant="ghost"
variant="ghost-muted"
size="icon-sm"
className="text-muted-foreground hover:text-foreground"
disabled={isSaving}
aria-label={`Actions for ${commandLabel(row.command)}`}
/>
@@ -1232,9 +1231,8 @@ function NewKeybindingCancelIcon({
render={
<Button
type="button"
variant="ghost"
variant="ghost-muted"
size="icon-sm"
className="text-muted-foreground hover:text-foreground"
disabled={isSaving}
aria-label="Cancel new keybinding"
onClick={onCancel}
@@ -53,8 +53,8 @@ export function ProjectActionsList({
) : null}
<Button
size="icon-xs"
variant="ghost"
className="shrink-0 text-muted-foreground opacity-0 group-focus-within:opacity-100 group-hover:opacity-100"
variant="ghost-muted"
className="shrink-0 opacity-0 group-focus-within:opacity-100 group-hover:opacity-100"
aria-label={`Edit ${script.name}`}
disabled={disabled}
onClick={() => onEdit(script)}
@@ -767,8 +767,8 @@ export function ProviderInstanceCard({
<Button
type="button"
size="icon-xs"
variant="ghost"
className="shrink-0 text-muted-foreground hover:text-foreground"
variant="ghost-muted"
className="shrink-0"
onClick={() =>
copyToClipboard(updateCommand, { providerName: displayName })
}
+1 -1
View File
@@ -8,7 +8,7 @@ import * as NodeURL from "node:url";
// components/ui exports are migrated to variants (see vite.config.ts). This gate keeps the
// count from growing: CI fails when findings exceed the ceiling. Lower the ceiling when you
// migrate a file, and delete this script when the rule becomes an error.
export const RESTYLE_CEILING = 1207;
export const RESTYLE_CEILING = 1184;
const RULE = "shadcn(no-restyle)";