bito-code-review[bot] commented on code in PR #41962:
URL: https://github.com/apache/superset/pull/41962#discussion_r3566234206
##########
superset-frontend/plugins/plugin-chart-echarts/src/Radar/utils.ts:
##########
@@ -73,7 +73,14 @@ export const renderNormalizedTooltip = (
return {
metric,
- value: formatter ? formatter(originalValue) : originalValue,
+ // A missing metric stays null; show it plainly rather than running it
+ // through the formatter, which would render a misleading "NaN".
+ value:
+ originalValue == null
+ ? 'N/A'
Review Comment:
<!-- Bito Reply -->
The suggestion to wrap the 'N/A' string in t() is appropriate for
maintaining consistency with the project's internationalization standards.
Applying this change ensures that the placeholder text is correctly handled by
the translation system.
**superset-frontend/plugins/plugin-chart-echarts/src/Radar/utils.ts**
```
value:
originalValue == null
? t('N/A')
: formatter
? formatter(originalValue)
: originalValue,
```
--
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]