Add onClick event to Other results cards
This commit is contained in:
@@ -1,9 +1,23 @@
|
||||
import React from 'react';
|
||||
import { Box, Heading, Image } from 'grommet';
|
||||
import { Box, Heading } from 'grommet';
|
||||
|
||||
export const Other = ({ image, name }: { image: string; name: string }) => {
|
||||
export const Other = ({
|
||||
image,
|
||||
name,
|
||||
handleClick,
|
||||
}: {
|
||||
image: string;
|
||||
name: string;
|
||||
handleClick: ((...args: any[]) => any) & ((event: MouseEvent) => void);
|
||||
}) => {
|
||||
return (
|
||||
<Box round='xxsmall' overflow='hidden' align='center' pad='small'>
|
||||
<Box
|
||||
round='xxsmall'
|
||||
overflow='hidden'
|
||||
align='center'
|
||||
pad='small'
|
||||
onClick={handleClick}
|
||||
>
|
||||
<Heading
|
||||
level='4'
|
||||
margin={{ bottom: 'small', top: 'small', left: 'small' }}
|
||||
|
||||
Reference in New Issue
Block a user