rusackas commented on code in PR #37625:
URL: https://github.com/apache/superset/pull/37625#discussion_r2760238835
##########
superset-frontend/plugins/plugin-chart-echarts/src/BigNumber/BigNumberViz.tsx:
##########
@@ -192,7 +192,7 @@ function BigNumberVis({
const renderHeader = (maxHeight: number) => {
const { bigNumber, width, colorThresholdFormatters, onContextMenu } =
props;
- // @ts-ignore
+ // @ts-expect-error
const text = bigNumber === null ? t('No data') :
headerFormatter(bigNumber);
Review Comment:
Fixed in 896b19737d. Properly handles all DataRecordValue types now:
- null/undefined → 'No data'
- number → format directly
- string/boolean/Date → convert to number if possible, otherwise show as
string
This removes the @ts-expect-error while maintaining runtime safety.
--
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]