add ids to variables

Co-authored-by: Ashley Harrison <ashharrison90@gmail.com>
This commit is contained in:
joshhunt
2025-08-26 13:18:28 +01:00
co-authored by Ashley Harrison
parent 98beb1e848
commit 15923ca6b4
6 changed files with 6 additions and 0 deletions
@@ -69,6 +69,7 @@ export function getAdHocFilterOptions(variable: SceneVariable): OptionsPaneItemD
return [
new OptionsPaneItemDescriptor({
id: `variable-${variable.state.name}-value`,
render: () => <AdHocFiltersVariableEditor variable={variable} onRunQuery={noop} inline={true} />,
}),
];
@@ -67,6 +67,7 @@ export function getGroupByVariableOptions(variable: SceneVariable): OptionsPaneI
return [
new OptionsPaneItemDescriptor({
id: `variable-${variable.state.name}-value`,
render: () => <GroupByVariableEditor variable={variable} onRunQuery={noop} inline={true} />,
}),
];
@@ -71,6 +71,7 @@ export function getIntervalVariableOptions(variable: SceneVariable): OptionsPane
return [
new OptionsPaneItemDescriptor({
id: `variable-${variable.state.name}-value`,
render: () => <IntervalVariableEditor variable={variable} onRunQuery={noop} inline={true} />,
}),
];
@@ -127,6 +127,7 @@ export function getQueryVariableOptions(variable: SceneVariable): OptionsPaneIte
return [
new OptionsPaneItemDescriptor({
id: `variable-${variable.state.name}-value`,
render: () => <ModalEditor variable={variable} />,
}),
];
@@ -9,6 +9,7 @@ export function getSystemVariableOptions(variable: SceneVariable): OptionsPaneIt
return [
new OptionsPaneItemDescriptor({
id: `variable-${variable.state.name}-value`,
render: () => {
return (
<Stack direction="column">
@@ -32,6 +32,7 @@ export function getTextBoxVariableOptions(variable: SceneVariable): OptionsPaneI
return [
new OptionsPaneItemDescriptor({
title: t('dashboard-scene.textbox-variable-form.label-value', 'Value'),
id: `variable-${variable.state.name}-value`,
render: () => <TextBoxVariableEditor onChange={noop} variable={variable} inline={true} />,
}),
];