bito-code-review[bot] commented on code in PR #36760:
URL: https://github.com/apache/superset/pull/36760#discussion_r2641587200


##########
superset-frontend/src/explore/components/controls/FilterControl/AdhocFilterOption/index.tsx:
##########
@@ -59,14 +60,16 @@ export default function AdhocFilterOption({
       operators={operators}
       adhocFilter={adhocFilter}
       options={options}
-      datasource={datasource}
+      datasource={datasource as Record<string, unknown> || {}}
       onFilterEdit={onFilterEdit}
-      partitionColumn={partitionColumn}
+      partitionColumn={partitionColumn ?? undefined}
     >
       <OptionControlLabel
         label={actualTimeRange ?? adhocFilter.getDefaultLabel()}
         tooltipTitle={title ?? adhocFilter.getTooltipTitle()}
-        onRemove={onRemoveFilter}
+        onRemove={() =>
+          onRemoveFilter({} as React.MouseEvent<Element, MouseEvent>)
+        }

Review Comment:
   <!-- Bito Reply -->
   Yes, the suggestion to add `stopPropagation: () => {}` to the fake 
MouseEvent object is valid — it provides the minimal mock needed to prevent the 
runtime TypeError when the handler calls `stopPropagation()`, matching the 
original behavior without unnecessary complexity.



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