mirror of
https://github.com/Stremio/stremio-web.git
synced 2026-04-21 03:22:11 +00:00
Button forwarded ref fixed
This commit is contained in:
parent
ddd95be447
commit
de53cfbfa0
1 changed files with 6 additions and 2 deletions
|
|
@ -42,10 +42,14 @@ Button.defaultProps = {
|
||||||
stopPropagation: true
|
stopPropagation: true
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const ButtonWithFocusable = withFocusable(Button);
|
||||||
|
|
||||||
|
ButtonWithFocusable.displayName = 'ButtonWithFocusable';
|
||||||
|
|
||||||
const ButtonWithForwardedRef = React.forwardRef((props, ref) => (
|
const ButtonWithForwardedRef = React.forwardRef((props, ref) => (
|
||||||
<Button {...props} forwardedRef={ref} />
|
<ButtonWithFocusable {...props} forwardedRef={ref} />
|
||||||
));
|
));
|
||||||
|
|
||||||
ButtonWithForwardedRef.displayName = 'ButtonWithForwardedRef';
|
ButtonWithForwardedRef.displayName = 'ButtonWithForwardedRef';
|
||||||
|
|
||||||
export default withFocusable(ButtonWithForwardedRef);
|
export default ButtonWithForwardedRef;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue