Skip to content

fix(ui): global dark-mode — app bg, legacy-var bridge, core-ui component gaps - #33597

Merged
shah-harshit merged 2 commits into
mainfrom
6459-core-ui-dark-global
Sep 18, 2026
Merged

shah-harshit merged 2 commits into
mainfrom
6459-core-ui-dark-global

Conversation

@shah-harshit

@shah-harshit shah-harshit commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

Describe your changes:

Refs open-metadata/openmetadata-collate#6548 (theme tokens/global CSS), open-metadata/openmetadata-collate#6549 (UI core components)
Gate contract: open-metadata/openmetadata-collate#6564

Global/core dark-mode fixes, split out of the DQ PR (#33586). All light values unchanged (frozen).

Global (app-side)

  • App background: dark now --om-color-bg-primary (#0c0e12) to match the design recording; light keeps the frozen gray-blue-50 (#f8f9fc). The gray-blue scale's dark step (#0d0f1c) was too blue.
  • Legacy-var bridge (variables.less + app.less): each legacy @palette var resolves through an --om-* custom property — light = exact original hex (via var(--om-x, #hex) fallback, no drift), dark = semantic/utility token under .dark-mode. Themes every legacy-var consumer app-wide (including the DQ .less surfaces) with no per-file edits. Categorical ramps excluded.

Core-ui components (audited all 53; these were the only real gaps)

  • page-header: drop dark:bg-primary so the gradient header falls back to the Card's bg-surface in dark instead of melting into the page.
  • autocomplete / select: caret-alpha-black/90 → caret-primary (visible caret on dark input).
  • avatar-add-button: disabled gray-200 → border-disabled/text-fg-disabled.
  • tree: guide line gains a dark override (gray-blue-800).

Everything else in core-ui already uses semantic tokens or is intentional fixed-color (brand/social logos, tooltip/toast solid surfaces).

Type of change:

  • Improvement

Checklist:

  • References tickets + Gate Zero contract.
  • Light mode frozen; dark-only changes.
  • Prettier + token-audit clean (bridge uses the sanctioned var(--om-*, #hex) form).

RetriggerConfidence Score: 5/5

The PR appears safe to merge; the previous review findings are resolved and no new actionable issue remains.

Summary

This PR expands global dark-mode coverage while preserving existing light-mode styling.

  • Bridges selected legacy LESS palette variables to semantic dark-mode tokens.
  • Uses the semantic page-background token in dark mode.
  • Corrects dark-mode caret, disabled-avatar, tree-guide, and gradient-header styling.
  • The changes since the previous review address all three prior findings.

Reviews (2) · Last reviewed commit: "fix(ui-core): address review on global d..."

…e-ui gaps

- app.less: dark app background -> --om-color-bg-primary (#0c0e12), matching the
  design recording; light keeps the frozen gray-blue-50 (#f8f9fc). The gray-blue
  scale's dark step (#0d0f1c) was too blue.
- variables.less + app.less: legacy LESS palette vars now resolve through an
  --om-* bridge (light = exact original hex via fallback, dark = semantic/utility
  token under .dark-mode), theming every legacy-var consumer app-wide with no
  per-file edits. Renamed from the earlier --legacy-* to the sanctioned --om-*.
- page-header: drop dark:bg-primary so the gradient header falls back to the
  Card's bg-surface in dark instead of melting into the page.
- autocomplete/select: caret-alpha-black/90 -> caret-primary (visible caret on
  dark input).
- avatar-add-button: disabled gray-200 -> border-disabled/text-fg-disabled.
- tree: guide line gains a dark override (gray-blue-800).
All light values unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

This PR cannot be merged until the following are addressed on its linked issue:

  • No GitHub issue is linked. Link an issue in the Development section of the PR (or add Fixes #12345 to the description). For a same-org cross-repo issue, add Fixes open-metadata/<repo>#123 to the description.

The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically.

Maintainers can bypass this check by adding the skip-pr-checks label.

@shah-harshit shah-harshit added the UI UI specific issues label Sep 18, 2026
@shah-harshit shah-harshit self-assigned this Sep 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Hi there 👋 Thanks for your contribution!

The OpenMetadata team will review the PR shortly! Once it has been labeled as safe to test, the CI workflows
will start executing and we'll be able to make sure everything is working as expected.

Let us know if you need any help!

shah-harshit added a commit that referenced this pull request Sep 18, 2026
The variables.less/app.less global bridge and the dark app-background fix now
live in #33597 (core/global scope). This DQ PR keeps only its component (.tsx)
changes and depends on #33597 for the .less-surface dark theming.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@github-actions

github-actions Bot commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

✅ Playwright Results — workflow succeeded

Validated commit fae576c1eeb67be09ff07bbca37294dcdaccb7cb in Playwright run 35370913098, attempt 1.

✅ 4489 passed · ❌ 0 failed · 🟡 7 flaky · ⏭️ 1 skipped · 🧰 0 lifecycle flaky

Performance

Blocking targets: ✅ met · Optimization targets: 🟡 in progress

Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting.

🕒 Full workflow signal wall (to summary) 1h 6m 57s

⏱️ Max setup 4m 46s · max shard execution 19m 52s · max shard-job elapsed before upload 23m 13s · reporting 17s

🌐 221.47 requests/attempt · 2.23 app boots/UI scenario · 35.40% common-shard skew

Optimization targets still in progress:

  • Common shard skew was 35.4% (convergence target: at most 15%).
  • Browser traffic was 221.47 requests per attempt (convergence target: fewer than 200).
  • Application boot ratio was 2.23 per UI scenario (10673 boots / 4781 scenarios; convergence target: at most 1).
Shard Passed Failed Flaky Skipped Lifecycle failed Lifecycle flaky
✅ Shard advanced-search-01 68 0 0 0 0 0
✅ Shard advanced-search-02 62 0 0 0 0 0
✅ Shard chromium-01 126 0 0 1 0 0
✅ Shard chromium-02 128 0 0 0 0 0
✅ Shard chromium-03 172 0 0 0 0 0
🟡 Shard chromium-04 156 0 2 0 0 0
✅ Shard chromium-05 154 0 0 0 0 0
✅ Shard chromium-06 126 0 0 0 0 0
✅ Shard chromium-07 166 0 0 0 0 0
🟡 Shard chromium-08 196 0 1 0 0 0
✅ Shard chromium-09 145 0 0 0 0 0
🟡 Shard chromium-10 182 0 1 0 0 0
✅ Shard chromium-11 165 0 0 0 0 0
✅ Shard chromium-12 177 0 0 0 0 0
✅ Shard chromium-13 151 0 0 0 0 0
✅ Shard chromium-14 152 0 0 0 0 0
✅ Shard chromium-15 180 0 0 0 0 0
✅ Shard chromium-16 174 0 0 0 0 0
🟡 Shard chromium-17 167 0 1 0 0 0
✅ Shard chromium-18 177 0 0 0 0 0
🟡 Shard chromium-19 135 0 1 0 0 0
✅ Shard chromium-20 160 0 0 0 0 0
✅ Shard chromium-21 147 0 0 0 0 0
🟡 Shard chromium-22 179 0 1 0 0 0
✅ Shard chromium-23 146 0 0 0 0 0
✅ Shard chromium-24 137 0 0 0 0 0
✅ Shard chromium-25 129 0 0 0 0 0
✅ Shard data-asset-rules-01 65 0 0 0 0 0
✅ Shard domain-isolation-01 16 0 0 0 0 0
✅ Shard global-state-01 34 0 0 0 0 0
✅ Shard import-export-01 29 0 0 0 0 0
✅ Shard import-export-02 94 0 0 0 0 0
✅ Shard import-export-03 27 0 0 0 0 0
✅ Shard ingestion-01 39 0 0 0 0 0
✅ Shard ingestion-02 59 0 0 0 0 0
✅ Shard reindex-01 28 0 0 0 0 0
✅ Shard search-01 12 0 0 0 0 0
✅ Shard search-rbac-01 29 0 0 0 0 0
🟡 7 flaky test(s) (passed on retry)
  • Features/UserProfileOnlineStatus.spec.ts › Should show online status badge on user profile for active users (shard chromium-04, 1 retry)
  • Features/UserProfileOnlineStatus.spec.ts › Should show "Active recently" for users active within last hour (shard chromium-04, 1 retry)
  • Features/Pagination.spec.ts › should test Table columns complete flow with search (shard chromium-08, 1 retry)
  • Pages/UserDetails.spec.ts › Admin user can edit teams from the user profile (shard chromium-10, 1 retry)
  • Pages/Entity.spec.ts › Tier Add, Update and Remove (shard chromium-17, 1 retry)
  • Features/Dashboards.spec.ts › should be able to toggle between deleted and non-deleted charts (shard chromium-19, 1 retry)
  • Pages/ExplorePageRightPanel_KnowledgeCenter.spec.ts › Should remove user owner for knowledgeCenter (shard chromium-22, 1 retry)

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

- caret-primary is not a resolvable Tailwind token (caret-* draws from the
  --color-* namespace, which has no bare --color-primary). It emitted no CSS,
  and on combobox's text-transparent overlay input that left caret-color:auto
  = invisible in both themes. Use caret-text-primary (valid, inverts in dark)
  in combobox, autocomplete and multi-select.
- avatar-add-button: border-disabled/text-fg-disabled changed the LIGHT
  disabled colors vs the original gray-200. Restore gray-200 for light and
  apply the semantic disabled tokens only under .dark-mode, keeping the
  light-mode freeze.
- page-header: correct the stale comment — dark mode now falls back to the
  Card's bg-surface, not bg-primary.

Refs open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@shah-harshit

Copy link
Copy Markdown
Contributor Author

Addressed the review (fae576c):

  • caret-primary invalid → invisible caret (P1, both bots): correct — caret-* resolves from the --color-* namespace and there's no bare --color-primary, so it emitted nothing; on combobox's text-transparent overlay that meant caret-color:auto = invisible. Switched to caret-text-primary (valid, inverts in dark) in combobox, autocomplete, and multi-select.
  • avatar-add-button light disabled drift (P1): restored disabled:border-gray-200/disabled:text-gray-200 for light and moved the semantic disabled tokens to dark:disabled:*, keeping the light-mode freeze.
  • page-header stale comment (P2): updated to say dark falls back to the Card's bg-surface.

Prettier clean; --color-text-primary confirmed present so caret-text-primary resolves.

@github-actions

Copy link
Copy Markdown
Contributor

Hi there 👋 Thanks for your contribution!

The OpenMetadata team will review the PR shortly! Once it has been labeled as safe to test, the CI workflows
will start executing and we'll be able to make sure everything is working as expected.

Let us know if you need any help!

@gitar-bot

gitar-bot Bot commented Sep 18, 2026

Copy link
Copy Markdown
Code Review ✅ Approved 1 closed / 1 findings

🟡 Medium risk

Extends dark-mode coverage across the application and core component library by bridging legacy Less colors to semantic tokens, updating the global page background, and correcting component styling. All changes are approved with no open issues.

✅ 1 closed
✅ Bug: caret-primary is not a valid Tailwind token; caret fix no-ops

📄 openmetadata-ui-core-components/src/main/resources/ui/src/components/base/select/combobox.tsx:166 📄 openmetadata-ui-core-components/src/main/resources/ui/src/components/base/autocomplete/autocomplete.tsx:284 📄 openmetadata-ui-core-components/src/main/resources/ui/src/components/base/select/multi-select.tsx:202
caret-primary is not a resolvable Tailwind v4 utility here. The caret-* utility draws color names from the --color-* theme namespace (that is why caret-alpha-black and caret-transparent work), but there is no --color-primary token in globals.css — text-primary/bg-primary resolve through the separate --text-color-*/--background-color-* namespaces, which do not feed caret-*. As a result caret-primary emits no CSS and the intended "visible caret on dark input" fix does not apply. In autocomplete.tsx and multi-select.tsx the input also has text-primary, so the caret falls back to currentColor and stays visible by accident. But in combobox.tsx the overlay input is tw:text-transparent, so removing the old explicit caret-alpha-black/90 leaves caret-color: auto = transparent, making the text cursor invisible in the Select search input in BOTH light and dark — a regression. Use a token that exists in the --color-* namespace, e.g. caret-text-primary (or caret-fg-primary), which is defined and inverts under .dark-mode.

Review coverage

Rules No rules evaluated

Functional validation Not enabled · Set up

Auto-approval Not enabled · Set up

Options

Display: compact → Counting what did not apply, without listing it.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@shah-harshit shah-harshit added safe to test Add this label to run secure Github workflows on PRs skip-pr-checks Bypass PR metadata validation check labels Sep 18, 2026
Merged via the queue into main with commit b0209d9 Sep 18, 2026
282 of 295 checks passed
@shah-harshit
shah-harshit deleted the 6459-core-ui-dark-global branch September 18, 2026 22:02
timothybrush pushed a commit to timothybrush/OpenMetadata that referenced this pull request Sep 20, 2026
…tadata#6459) (open-metadata#33586)

* fix(ui): theme DQ authoring, incidents, profiler & alerts for dark mode

Combined dark-mode pass over the remaining Data Quality & Observability
AI-mode routes (workstream open-metadata/openmetadata-collate#6459). Swaps
compile-time fixed-hex LESS palette vars and raw Tailwind palette classes
for adaptive semantic / auto-inverting utility tokens; light-mode values
are preserved (exact for status colors) and only the resolved dark values
change.

Covers:
- open-metadata#6533 Add/Edit Test Case: TestCaseFormV1.less, add-test-suite-pipeline
  (@grey-*/@Blue-22 surfaces), AddTestCaseList bg-white -> tw:bg-primary.
- open-metadata#6531 Incident Manager: dimensionality heatmap legend + tooltip, failed
  sample-data diff rows, incident/result tab surfaces (@grey-*/status hex
  -> semantic + utility-{success,error,warning}).
- open-metadata#6532 Table DQ + Profiler: ProfilerLatestValue, TestSummaryGraph,
  no-profiler-banner, table-profiler (neutral greys -> semantic roles).
- open-metadata#6538 Pipeline Observability: data-observability-tab border.
- open-metadata#6530 Alerts: AlertAiNotificationSection bg-white + text-gray-500.

Status hexes map to exact-match auto-inverting utility tokens
(@red-22=error-500, @warning-400=warning-400, @Green-9=success-50,
@Blue-22=blue-light-50, @alert-error-icon-bg-1=error-100). Neutral greys
map to --color-bg/border/text semantic roles.

Deferred (categorical, tracked for the token foundation): the 5-level
incident severity ramp and the heatmap data-viz white-fade gradients in
incident-manager.style.less / DimensionalityHeatmap.less need shared dark
palette values rather than per-page overrides.

Verify-only (no offenders found; AI routes already on semantic tokens):
open-metadata#6540 Test Suites list, open-metadata#6535 Test Case details/versions, open-metadata#6537 Test
Library, open-metadata#6536 Suite details/ingestion.

Refs open-metadata/openmetadata-collate#6533 open-metadata/openmetadata-collate#6531 open-metadata/openmetadata-collate#6532 open-metadata/openmetadata-collate#6538 open-metadata/openmetadata-collate#6530 open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(ui): theme Data Quality summary widgets for dark mode

The AI-mode Data Quality summary shells already use adaptive semantic
tokens, but the shared widgets they embed (chart backgrounds, status
cards, statistic widgets, test-case status chart) baked compile-time
fixed-hex LESS palette vars (@grey-26/@grey-9/@grey-2/@grey-50, @Blue-13,
@GREEN-*, @RED-*, @yellow-10, @alert-*) that cannot follow the theme, so
those surfaces stayed light in dark mode.

Swap the fixed palette vars for adaptive tokens:
- neutral surfaces/borders -> semantic --color-bg-secondary_subtle /
  --color-bg-secondary / --color-border-secondary
- status colors -> --tw-color-utility-{error,success,warning,blue}-*,
  which auto-invert in dark (mirrors the merged StatusCardWidget
  precedent). Every status mapping is an exact light-value match, so
  light mode does not regress.
- AI dashboard section tint tw:bg-gray-blue-25 (fixed light) ->
  tw:bg-utility-gray-blue-50 (auto-inverting).

Already-adaptive utility-gray vars are left as-is. Categorical chart/
status data colors are intentionally unchanged.

Refs open-metadata/openmetadata-collate#6539 open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(ui): use blue-light token + update stale dashboard test

Address review on the DQ summary dark-mode PR:

- The coverage/all-tests chart icon mapped @blue-500 (#0ba5ec, cyan) to
  utility-blue-500 (#2e90fa), a perceptible cyan->blue hue shift in light
  mode. #0ba5ec is exactly the blue-light-500 ramp, so switch the icon fg
  to utility-blue-light-500 and its background (@Blue-13 #e0f2fe) to
  utility-blue-light-100 (#e0f2fe) — both now exact light-value matches.
- DataQualityDashboard.test.tsx still asserted the removed bg-gray-blue-25
  classes; update both expectations to bg-utility-gray-blue-50 so the
  focused test matches the component. Suite passes (8/8).

Refs open-metadata/openmetadata-collate#6539 open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(ui): theme Test Cases list dimension chip for dark mode

The dimension-count chip in the AI-mode Test Cases list used the raw
palette class tw:bg-blue-50, which does not invert in dark mode, so its
light-blue background stayed fixed while tw:text-primary flipped to a
light foreground — light-on-light, unreadable in dark.

Swap to tw:bg-utility-blue-50, which auto-inverts (light blue tint in
light, dark blue in dark) per colors.md §2.7, keeping text-primary
readable in both themes. Light mode is unchanged.

The rest of the Test Cases list (table header, filters, table shell) was
already on adaptive semantic tokens.

Refs open-metadata/openmetadata-collate#6534 open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(ui): avoid light-mode drift on DQ dashboard section cards

Address greptile P2: bg-utility-gray-blue-50 resolved to #f8f9fc in light,
shifting the section-card surface from the original bg-gray-blue-25
(#fcfcfd). Use tw:bg-secondary_subtle instead — light #fdfdfd (effectively
unchanged) and a proper dark surface, matching the LESS card surfaces in
this PR. Focused test updated; suite passes 8/8.

Refs open-metadata/openmetadata-collate#6539 open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* refactor(ui): theme legacy palette vars globally; revert per-file swaps

Replace the per-file dark-mode token swaps with a single global bridge so
the fixed-hex legacy LESS palette vars adapt to dark mode everywhere they
are used, with zero light-mode drift and no per-component edits.

- variables.less: the 27 fixed-hex vars this workstream touched
  (@grey-1/2/5/7/9/15/25/26/50, @green-9/10/12/100/500, @red-9/10/22,
  @yellow-10, @blue-13/22/500, @warning-100/400, @alert-*) become
  `@x: var(--legacy-x, #originalHex)`. Light resolves to the exact
  original hex (no drift — fixes the greptile light-shift comments); dark
  picks up the override.
- app.less: one `.dark-mode` block maps each `--legacy-*` to the semantic
  / auto-inverting utility token (neutrals -> --color-bg/border/text
  roles, status -> utility-{success,error,warning,blue-light}-*).
- Revert the individual DQ/Profiler/IncidentManager/Alerts LESS files back
  to origin/main — they now adapt automatically through the bridge.

Verified: variables.less and a consumer (.less) compile via lessc, emitting
`var(--legacy-*, #hex)`; no legacy var is used in a LESS color function or
operation (checked app-wide), so the var() substitution is safe. @black
left literal (mostly non-DQ, app-wide). Categorical severity/heatmap ramps
still deferred to the token foundation.

Raw Tailwind palette classes in TSX (bg-white, bg-gray-50, text-gray-500,
border-gray-300, bg-gray-blue-25) keep their per-file semantic swaps — they
are not LESS vars and have no global bridge.

Refs open-metadata/openmetadata-collate#6459

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* chore(ui): move legacy-var bridge + app-bg to core PR open-metadata#33597

The variables.less/app.less global bridge and the dark app-background fix now
live in open-metadata#33597 (core/global scope). This DQ PR keeps only its component (.tsx)
changes and depends on open-metadata#33597 for the .less-surface dark theming.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(ui): DQ page header/tab/table borders to subtle white-alpha in dark

The DQ page header card, tab-nav container, and table container draw their
border from @global-border (@Grey-15) — a solid gray that stands out in dark.
Scope a dark-only override to border-subtle (rgba(255,255,255,0.08)) to match
the subtle white-alpha border used across dark surfaces. Light unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* chore(playwright): auto-refresh impact-map.generated.json

---------

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

This branch was previously deployed

1 inactive deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

safe to test Add this label to run secure Github workflows on PRs skip-pr-checks Bypass PR metadata validation check UI UI specific issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants