Skip to content

fix(plugin): render Normal/OK state-bar lane green - #6

Open
David6811 wants to merge 1 commit into
mainfrom
weixu_plugin_normal_lane
Open

fix(plugin): render Normal/OK state-bar lane green#6
David6811 wants to merge 1 commit into
mainfrom
weixu_plugin_normal_lane

Conversation

@David6811

Copy link
Copy Markdown
Owner

Problem

The plugin's Normal/OK state-bar lane was invisible — the green OK segments that the demo shows did not render inside Grafana.

Cause

--chart-state-normal was mapped to theme.colors.background.secondary (Grafana's dark secondary background), so the Normal lane blended into the page. Pending/Firing used warning.main/error.main and rendered fine, which is why only the green lane was missing.

Fix

Map --chart-state-normal to theme.colors.success.transparent — a theme-aware (dark/light) green that matches the demo's muted-green intent.

One line, packages/plugin/src/pages/styles.ts.

Map --chart-state-normal to theme.colors.success.transparent instead of
background.secondary. The Normal/OK lane was painted with Grafana's
secondary background, so it blended into the page and the green OK
segments were invisible — unlike the demo, which uses a muted green.
success.transparent is theme-aware (dark/light) and matches the demo's
intent.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant