aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/@next/components/image.tsx
blob: 34520b619be777a57795bdc70abb974ce39638de (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import * as React from 'react';
import styled from 'styled-components';

interface Props {
    alt?: string;
    src?: any;
    srcset?: any;
    isCentered?: boolean;
}

const ImageClass: React.FunctionComponent<Props> = (props: Props) => {
    return (
        <img {...props} />
    );
};

export const Image = styled(ImageClass)<Props>`
    margin: ${props => props.isCentered && `0 auto`};
`;