Disabling Legend entries by default is not working
- Dominant language
- TypeScript
- Stars
- 206
- Forks
- 59
- Avg merge
- 4d 12h
- Merged PRs (30d)
- 19
Description
Hi all!
I think this is the same as #792.
We are not able to disable legend entries by default. We want only to disable if the user opens the page but whenever he clicks on it, it should work for them.
I am doing the following:
```js
builder.setOverrides((timerSeriesTable) => {
timerSeriesTable
.match(
{
id: "byNames",
options: {
mode: "exclude",
names: [
"someLegendLabel
],
prefix: "All except:",
readOnly: true
}
})
.overrideColor({
fixedColor: "blue",
mode: FieldColorModeId.Fixed,
})
.overrideCustomFieldConfig("hideFrom", {
viz: true,
legend: false,
tooltip: false
})
})
```
This code disables the other legend entries by default but you can't click on it again to enable it if you want to see it. When you click on it, it looks something like this:

Before it looks like this:

I can see that in the Grafana dashboards, something like a __systemRef is used which i don't know how i can set in scenes.
I would appreciate some help!
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the issue with the provided builder.setOverrides snippet, focusing on overrideCustomFieldConfig("hideFrom") and the legend interaction. Then inspect how Grafana Scenes handles hidden legend entries and the systemRef behavior; done means entries are hidden initially but can be clicked to become visible again.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100