aminghadersohi commented on code in PR #40410:
URL: https://github.com/apache/superset/pull/40410#discussion_r3343403704


##########
superset-frontend/src/explore/components/controls/ControlPopover/ControlPopover.tsx:
##########
@@ -202,6 +202,7 @@ const ControlPopover: FC<PopoverProps> = ({
       getPopupContainer={handleGetPopupContainer}
       destroyOnHidden={destroyOnHidden}
       afterOpenChange={handleAfterOpenChange}
+      rootClassName="superset-explore-popover"
     />
   );
 };

Review Comment:
   NIT: hardcoded `rootClassName` comes after `{...props}` (line 197), so any 
`rootClassName` a caller passes is silently dropped. No current callers are 
affected, but it's a composability footgun.
   
   Safe fix — destructure and merge:
   ```tsx
   const ControlPopover: FC<PopoverProps> = ({
     ...
     rootClassName,
     ...props
   }) => {
     ...
     return (
       <Popover
         {...props}
         ...
         rootClassName={['superset-explore-popover', 
rootClassName].filter(Boolean).join(' ')}
       />
     );
   }
   ```



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