Skip to content

Commit

Permalink
fix(hoverWorkaround): fix bug when PaperProps.style is passed
Browse files Browse the repository at this point in the history
fix #56
  • Loading branch information
jedwards1211 committed Apr 27, 2021
1 parent 30516a8 commit 358af40
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/hoverWorkaround.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ export default function hoverWorkaround(Comp) {
/* eslint-disable react/display-name */
return React.forwardRef(({ PaperProps, style, ...props }, ref) => (
<Comp
{...props}
ref={ref}
style={{ pointerEvents: 'none', ...style }}
PaperProps={{
style: { pointerEvents: 'auto', ...PaperProps?.style },
...PaperProps,
style: { pointerEvents: 'auto', ...PaperProps?.style },
}}
{...props}
/>
))
}

0 comments on commit 358af40

Please sign in to comment.