StateTimeline: add spanNulls editor (#44811) (#44938)

(cherry picked from commit b07345e57e)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
This commit is contained in:
Grot (@grafanabot)
2022-02-05 00:16:23 +01:00
committed by GitHub
co-authored by Leon Sorokin
parent ce185ce6a3
commit bfd38ece7e
3 changed files with 33 additions and 11 deletions
@@ -17,13 +17,11 @@ function applySpanNullsThresholds(frame: DataFrame) {
continue;
}
if (field.type === FieldType.number) {
let spanNulls = field.config.custom?.spanNulls;
let spanNulls = field.config.custom?.spanNulls;
if (typeof spanNulls === 'number') {
if (spanNulls !== -1) {
field.values = new ArrayVector(nullToUndefThreshold(refValues, field.values.toArray(), spanNulls));
}
if (typeof spanNulls === 'number') {
if (spanNulls !== -1) {
field.values = new ArrayVector(nullToUndefThreshold(refValues, field.values.toArray(), spanNulls));
}
}
}