diff --git a/ui/component/button/view.jsx b/ui/component/button/view.jsx index 4220c2ef7..e42b05750 100644 --- a/ui/component/button/view.jsx +++ b/ui/component/button/view.jsx @@ -1,12 +1,13 @@ // @flow import type { Node } from 'react'; -import React, { forwardRef } from 'react'; +import React, { forwardRef, useRef } from 'react'; import Icon from 'component/common/icon'; import classnames from 'classnames'; import { NavLink } from 'react-router-dom'; import { formatLbryUriForWeb } from 'util/uri'; import { OutboundLink } from 'react-ga'; import * as PAGES from 'constants/pages'; +import useCombinedRefs from 'effects/use-combined-refs'; type Props = { id: ?string, @@ -86,6 +87,9 @@ const Button = forwardRef((props: Props, ref: any) => { className ); + const innerRef = useRef(null); + const combinedRef = useCombinedRefs(ref, innerRef, myref); + const content = ( {icon && } @@ -117,7 +121,7 @@ const Button = forwardRef((props: Props, ref: any) => { if (requiresAuth && !emailVerified) { return ( { e.stopPropagation(); @@ -135,7 +139,7 @@ const Button = forwardRef((props: Props, ref: any) => { return path ? ( ((props: Props, ref: any) => { ) : (