rusackas commented on code in PR #37625:
URL: https://github.com/apache/superset/pull/37625#discussion_r2770112136


##########
superset-frontend/src/dashboard/components/gridComponents/Chart/Chart.tsx:
##########
@@ -660,11 +692,14 @@ const Chart = props => {
         addDangerToast={boundActionCreators.addDangerToast}
         handleToggleFullSize={props.handleToggleFullSize}
         isFullSize={props.isFullSize}
-        chartStatus={chartStatus}
-        formData={formData}
+        chartStatus={chartStatus || ''}
+        formData={
+          formData as unknown as import('@superset-ui/core').QueryFormData

Review Comment:
   Same situation — the inline import type is used for a one-off cast. Will be 
addressed in the RootState typing follow-up.



##########
superset-frontend/src/dashboard/components/gridComponents/Chart/Chart.tsx:
##########
@@ -700,37 +737,39 @@ const Chart = props => {
         <ChartContainer
           width={width}
           height={getChartHeight()}
-          addFilter={addFilter}
+          addFilter={addFilter as unknown as (type: string) => void}

Review Comment:
   You're right — the double cast (`as unknown as`) signals a genuine type 
mismatch between `addFilter`'s signature and what `ChartContainer` expects. 
Aligning these types would require updating either the `addFilter` action 
creator's signature or `ChartContainer`'s prop types, which touches multiple 
files and could affect runtime behavior. This is pre-existing from the JS code 
where the mismatch was invisible. Noted for the RootState/action typing 
follow-up.



-- 
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]

Reply via email to