GraphNG: fix and optimize spanNulls (#29633)

* fix and optimize spanNulls

* AsZero implies spanNulls = true, to prevent null-scanning

* move spanNulls toggle below fillOpacity
This commit is contained in:
Leon Sorokin
2020-12-06 19:26:00 -06:00
committed by GitHub
parent b66bc4a7b1
commit 2d156a385b
6 changed files with 41 additions and 35 deletions

View File

@@ -63,6 +63,18 @@ export const plugin = new PanelPlugin<Options, GraphFieldConfig>(GraphPanel)
},
showIf: c => c.drawStyle !== DrawStyle.Points,
})
.addRadio({
path: 'spanNulls',
name: 'Null values',
defaultValue: false,
settings: {
options: [
{ label: 'Gaps', value: false },
{ label: 'Connected', value: true },
],
},
showIf: c => c.drawStyle === DrawStyle.Line,
})
.addRadio({
path: 'points',
name: 'Points',
@@ -82,17 +94,6 @@ export const plugin = new PanelPlugin<Options, GraphFieldConfig>(GraphPanel)
},
showIf: c => c.points !== PointMode.Never,
})
.addRadio({
path: 'spanNulls',
name: 'Null values',
defaultValue: false,
settings: {
options: [
{ label: 'Gaps', value: false },
{ label: 'Connected', value: true },
],
},
})
.addRadio({
path: 'axisPlacement',
name: 'Placement',