Explorar o código

create Image component

AykutSarac %!s(int64=3) %!d(string=hai) anos
pai
achega
85bae53459
Modificáronse 1 ficheiros con 14 adicións e 0 borrados
  1. 14 0
      src/components/Image/index.tsx

+ 14 - 0
src/components/Image/index.tsx

@@ -0,0 +1,14 @@
+import React from 'react';
+import styled from 'styled-components';
+
+const StyledImage = styled.img`
+  object-fit: contain;
+  
+  @media only screen and (max-width: 768px) {
+    width: 100%;
+  }
+`;
+
+export const Image = ({ ...props }) => {
+  return <StyledImage {...props} />
+};