Add Other component and refactor markup
This commit is contained in:
18
src/components/Album.tsx
Normal file
18
src/components/Album.tsx
Normal file
@@ -0,0 +1,18 @@
|
||||
import React from 'react';
|
||||
import { Box, Heading, Image } from 'grommet';
|
||||
|
||||
export const Album = ({ image, name }: { image: string; name: string }) => {
|
||||
return (
|
||||
<Box round='xxsmall' elevation='small' overflow='hidden'>
|
||||
<Box height='300px'>
|
||||
<Image src={image} fit='cover' />
|
||||
</Box>
|
||||
<Heading
|
||||
level='4'
|
||||
margin={{ bottom: 'small', top: 'small', left: 'small' }}
|
||||
>
|
||||
{name}
|
||||
</Heading>
|
||||
</Box>
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user