LevisNgigi commented on code in PR #33196:
URL: https://github.com/apache/superset/pull/33196#discussion_r2052975750
##########
superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx:
##########
@@ -188,6 +188,47 @@ class BigNumberVis extends
PureComponent<BigNumberVizProps> {
);
}
+ renderSubheader(maxHeight: number) {
+ const { bigNumber, subheader, width, bigNumberFallback } = this.props;
+ let fontSize = 0;
+
+ const NO_DATA_OR_HASNT_LANDED = t(
+ 'No data after filtering or data is NULL for the latest time record',
+ );
+ const NO_DATA = t(
+ 'Try applying different filters or ensuring your datasource has data',
+ );
+ let text = subheader;
+ if (bigNumber === null) {
+ text = bigNumberFallback ? NO_DATA : NO_DATA_OR_HASNT_LANDED;
Review Comment:
That sounds fine, it can be cleaner that way I think.Will this affect the
subheader used in the transform props for the big number with trendline as well?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]