ProfileHoverCard: convert to tsx
This commit is contained in:
parent
829a61c3a5
commit
2e5cc2619d
3 changed files with 2 additions and 3 deletions
|
@ -20,7 +20,7 @@ interface IHoverRefWrapper {
|
|||
/** Makes a profile hover card appear when the wrapped element is hovered. */
|
||||
export const HoverRefWrapper: React.FC<IHoverRefWrapper> = ({ accountId, children, inline = false }) => {
|
||||
const dispatch = useDispatch();
|
||||
const ref = useRef<HTMLElement>();
|
||||
const ref = useRef<HTMLDivElement>(null);
|
||||
const Elem: keyof JSX.IntrinsicElements = inline ? 'span' : 'div';
|
||||
|
||||
const handleMouseEnter = () => {
|
||||
|
@ -41,7 +41,6 @@ export const HoverRefWrapper: React.FC<IHoverRefWrapper> = ({ accountId, childre
|
|||
|
||||
return (
|
||||
<Elem
|
||||
// @ts-ignore: not sure how to fix :\
|
||||
ref={ref}
|
||||
className='hover-ref-wrapper'
|
||||
onMouseEnter={handleMouseEnter}
|
||||
|
|
Binary file not shown.
|
@ -61,7 +61,7 @@ export const AccountRecord = ImmutableRecord({
|
|||
note_emojified: '',
|
||||
note_plain: '',
|
||||
patron: null as PatronAccount | null,
|
||||
relationship: ImmutableList<ImmutableMap<string, any>>(),
|
||||
relationship: ImmutableMap<string, any>(),
|
||||
should_refetch: false,
|
||||
staff: false,
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue