Procházet zdrojové kódy

fix spacing between containers

AykutSarac před 3 roky
rodič
revize
6cd127b6b3
1 změnil soubory, kde provedl 8 přidání a 3 odebrání
  1. 8 3
      src/components/Container/index.tsx

+ 8 - 3
src/components/Container/index.tsx

@@ -11,16 +11,21 @@ const StyledContainer = styled.div<{ reverse: boolean }>`
   gap: 50px;
   align-items: center;
   width: 75%;
-  margin: 160px auto;
-  flex-direction: ${({ reverse }) => reverse && 'row-reverse'};
+  margin: 0 auto;
+  min-height: calc(100vh - 250px);
+  flex-direction: ${({ reverse }) => reverse && "row-reverse"};
   line-height: 1.2;
 
   @media only screen and (max-width: 768px) {
     width: 100%;
     flex-direction: column;
+    margin-top: 160px;
   }
 `;
 
-export const Container: React.FC<ContainerProps> = ({ children, reverse = false }) => {
+export const Container: React.FC<ContainerProps> = ({
+  children,
+  reverse = false,
+}) => {
   return <StyledContainer reverse={reverse}>{children}</StyledContainer>;
 };