Commit e4d2d17
authored
fix: Add missing graph properties for single-value custom widgets (#327)
CustomWidgets with a Single Value type didn't have all properties correctly set, such as the `title`.
The createGraphWidget() method is safe to be called like this because although its `props: GraphWidgetProps` parameter is *not* directly compatible with type type `SingleValueWidgetProps`, the parameters are being filled in CustomMonitoring.createCustomMetricGroupWidgets(), which only contains fields from their common supertype (`MetricWidgetProps`), therefore making the fields compatible.
---
_By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license_1 parent f675375 commit e4d2d17
File tree
2 files changed
+2
-1
lines changed- lib/common/widget
- test/monitoring/custom/__snapshots__
2 files changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| 51 | + | |
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
| |||
Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments