π OpenHands: AI-Driven Development
chore(lint): remove context color spec bookkeeping (#18499)
Engel Nystd9ecec24181a
diff --git a/__tests__/themes/color-themes.test.tsx b/__tests__/themes/color-themes.test.tsxindex 9f0b19e4ad..f8cb194602 100644--- a/__tests__/themes/color-themes.test.tsx+++ b/__tests__/themes/color-themes.test.tsx@@ -100,7 +100,7 @@ describe("color themes", () => {"--oh-contrast against the Home mode toggle pill",).toBeGreaterThanOrEqual(4.5);- // @spec WN-001 β Context meter text and fills preserve contrast in each palette.+ // Context meter text and fills preserve contrast in each palette.const contextMeterSurface = luminance(resolve("--oh-surface-raised"));const contextMeterTrack = luminance(resolve("--oh-color-tertiary"));for (const role of ["--oh-feedback-error", "--oh-feedback-warning"]) {diff --git a/specs/warning-feedback.md b/specs/warning-feedback.mdindex f64660747e..41d4c3c483 100644--- a/specs/warning-feedback.md+++ b/specs/warning-feedback.md@@ -3,7 +3,7 @@**Spec ID:** WN-001**Status:** Implemented-Small warning text and warning icons use the `feedback-warning` text role, backed by `--oh-feedback-warning`. The built-in role meets 4.5:1 on the theme surfaces used by the Home no-LLM banner, Canvas Apps trust notice, ACP conflict messages, and required-secret onboarding warning. The Usage panel's context meter warning and danger text meets 4.5:1 against its raised card; its warning and danger fills also retain 3:1 contrast against the track. Light+ and Solarized Light use darker text shades while retaining the existing brand warning color for controls and tint.+Small warning text and warning icons use the `feedback-warning` text role, backed by `--oh-feedback-warning`. The built-in role meets 4.5:1 on the theme surfaces used by the Home no-LLM banner, Canvas Apps trust notice, ACP conflict messages, and required-secret onboarding warning. Light+ and Solarized Light use darker text shades while retaining the existing brand warning color for controls and tint.Embedding roots may override the role. The UI follows the nearest `[data-agent-server-ui]` scope. Changing the role does not change warning copy, validation, routing, credential state, or trust controls.diff --git a/src/components/features/conversation/usage-panel/compact-context-button.tsx b/src/components/features/conversation/usage-panel/compact-context-button.tsxindex 97899e1e4a..c39d73eb07 100644--- a/src/components/features/conversation/usage-panel/compact-context-button.tsx+++ b/src/components/features/conversation/usage-panel/compact-context-button.tsx@@ -21,7 +21,6 @@ interface CompactContextButtonProps {* call-to-action once the context fill passes* {@link CONTEXT_FILL_WARNING_PERCENT}.*/-// @spec WN-001 β Compact context warnings use the readable warning role.export function CompactContextButton({fillPercent,perTurnToken = 0,diff --git a/src/components/features/conversation/usage-panel/context-meter.test.tsx b/src/components/features/conversation/usage-panel/context-meter.test.tsxindex 30ffd99b7b..bfa0857e54 100644--- a/src/components/features/conversation/usage-panel/context-meter.test.tsx+++ b/src/components/features/conversation/usage-panel/context-meter.test.tsx@@ -36,7 +36,6 @@ describe("ContextMeter", () => {expect(bar.style.width).toBe("50%");});- // @spec WN-001 β Warning meter text and fill use readable theme roles.it("warns above 70% fill", () => {render(<ContextMeter perTurnToken={75} contextWindow={100} />);@@ -75,7 +74,6 @@ describe("ContextMeter", () => {});});-// @spec WN-001 β The compact action warning uses the same readable text role.describe("CompactContextButton", () => {it("uses warning feedback color when context is above the threshold", () => {render(<CompactContextButton fillPercent={75} />);diff --git a/src/components/features/conversation/usage-panel/context-meter.tsx b/src/components/features/conversation/usage-panel/context-meter.tsxindex 66ad3bc26d..47f137a01e 100644--- a/src/components/features/conversation/usage-panel/context-meter.tsx+++ b/src/components/features/conversation/usage-panel/context-meter.tsx@@ -31,7 +31,6 @@ interface ContextMeterProps {* Context-fill progress bar with theme-aware warning and danger states. Shows* the raw token numbers underneath.*/-// @spec WN-001 β Context usage indicators use readable warning and error roles.export function ContextMeter({perTurnToken,contextWindow,diff --git a/src/themes/color-theme/definitions/openhands-deepsea.ts b/src/themes/color-theme/definitions/openhands-deepsea.tsindex c6dcb523b3..98f65a2f77 100644--- a/src/themes/color-theme/definitions/openhands-deepsea.ts+++ b/src/themes/color-theme/definitions/openhands-deepsea.ts@@ -21,7 +21,7 @@ export const openhandsDeepsea: ColorThemeDefinition = {"--cool-grey-975": "#05070A",},tokens: {- // @spec WN-001 β Small danger text clears 4.5:1 on raised Usage cards.+ // Small danger text clears 4.5:1 on raised Usage cards."--oh-feedback-error": "#EF766A",},// Values generated by heroui() from hero.ts β restore them explicitly when