@ -115,7 +115,13 @@ export function ThresholdsEditor({ onChange, value, context }: StandardEditorPro
placeholder="value"
width={24}
value={threshold.value}
onChange={(evt) => onThresholdFieldChange(thresholdIdx, 'value', isNumber(evt.currentTarget.value) ? +evt.currentTarget.value : undefined)}
onChange={(evt) =>
onThresholdFieldChange(
thresholdIdx,
'value',
isNumber(evt.currentTarget.value) ? +evt.currentTarget.value : undefined
)
}
/>
)}
</InlineField>
@ -50,7 +50,9 @@ export function UseMetricEditor({ onChange, value, context }: StandardEditorProp
value={config?.value}
onChange={(evt) => onFieldChange('value', isNumber(evt.currentTarget.value) ? +evt.currentTarget.value : undefined)}
onFieldChange('value', isNumber(evt.currentTarget.value) ? +evt.currentTarget.value : undefined)
@ -26,7 +26,7 @@ export function getLastMetricValue(
metricName: string | undefined,
optionName: string
): number | null {
if(metricName === undefined) {
if (metricName === undefined) {
return null;
// optionName -> helper in Error, mb use option path instead