1import { css } from '@emotion/react';
2import { spacing, theme } from '@expo/styleguide';
3
4type IconProps = {
5  title: string;
6  image?: string;
7  size?: number;
8};
9
10export const Icon = ({ title, image, size = 64 }: IconProps) => (
11  <img
12    css={[
13      iconStyle,
14      css({
15        width: size,
16        height: size,
17      }),
18    ]}
19    alt={title}
20    src={image}
21  />
22);
23
24const iconStyle = css({
25  background: theme.background.element,
26  borderRadius: '100%',
27  padding: spacing[1],
28});
29