aboutsummaryrefslogblamecommitdiffstats
path: root/packages/website/ts/components/image.tsx
blob: 65b2a970595d27920f60732169465009de60aeaa (plain) (tree)
1
2
3
4
5
6
7
8




                                       


                         


                                                                      
                              

  



                        
                                                     
  
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`};
`;