Skip to content

πŸ™Œ OpenHands: AI-Driven Development

fix(lint): use semantic colors for Git Sync feedback (#18346)

Engel Nyst2415a2358ab7
diff --git a/src/components/features/automations/git-sync/git-sync-activity-row.tsx b/src/components/features/automations/git-sync/git-sync-activity-row.tsx
index 1849933ad4..d77a83344d 100644
--- a/src/components/features/automations/git-sync/git-sync-activity-row.tsx
+++ b/src/components/features/automations/git-sync/git-sync-activity-row.tsx
@@ -58,8 +58,8 @@ export function GitSyncActivityRow({
className={cn(
"mt-4 flex flex-wrap items-center gap-x-2 gap-y-1 rounded-md px-3 py-2 text-sm",
isRunning && "bg-tertiary text-content",
- state === "succeeded" && "bg-green-500/10 text-green-300",
- isFailed && "bg-red-500/10 text-red-300",
+ state === "succeeded" && "bg-status-success/10 text-feedback-success",
+ isFailed && "bg-status-error/10 text-feedback-error",
)}
>
{isRunning && <RefreshCw className="size-4 animate-spin" aria-hidden />}
diff --git a/src/components/features/automations/git-sync/git-sync-config-form.tsx b/src/components/features/automations/git-sync/git-sync-config-form.tsx
index ca8c0612d0..df23467dbc 100644
--- a/src/components/features/automations/git-sync/git-sync-config-form.tsx
+++ b/src/components/features/automations/git-sync/git-sync-config-form.tsx
@@ -418,13 +418,13 @@ export function GitSyncConfigForm({
<div
role="alert"
data-testid="git-sync-check-failure"
- className="rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words"
+ className="rounded-md border border-danger/40 bg-danger/5 p-3 text-sm text-feedback-error whitespace-pre-wrap break-words"
>
<p className="font-medium">
{t(I18nKey.AUTOMATIONS$GIT_SYNC$CHECK_FAILED_TITLE)}
</p>
<p className="mt-1">{failedCheck.detail}</p>
- <p className="mt-1 text-xs text-red-300/70">
+ <p className="mt-1 text-xs">
{t(I18nKey.AUTOMATIONS$GIT_SYNC$CHECK_FAILED_HINT)}
</p>
</div>
diff --git a/src/components/features/automations/git-sync/git-sync-error-banner.tsx b/src/components/features/automations/git-sync/git-sync-error-banner.tsx
index a9627ef8c5..0b109ba38f 100644
--- a/src/components/features/automations/git-sync/git-sync-error-banner.tsx
+++ b/src/components/features/automations/git-sync/git-sync-error-banner.tsx
@@ -17,14 +17,14 @@ export function GitSyncErrorBanner({
<div
role="alert"
data-testid="git-sync-error-banner"
- className="rounded-md border border-red-500/40 bg-red-500/10 p-3 text-sm text-red-300 whitespace-pre-wrap break-words"
+ className="rounded-md border border-danger/40 bg-danger/5 p-3 text-sm text-feedback-error whitespace-pre-wrap break-words"
>
<p className="font-medium">
{t(I18nKey.AUTOMATIONS$GIT_SYNC$LAST_ERROR_TITLE)}
</p>
<p className="mt-1">{error}</p>
{errorAt && (
- <p className="mt-1 text-xs text-red-300/70">
+ <p className="mt-1 text-xs">
{`${formatTimeDelta(errorAt)} ${t(I18nKey.CONVERSATION$AGO)}`}
</p>
)}