-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ab87f7c
commit f52b268
Showing
3 changed files
with
56 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
'use client' | ||
|
||
import {FC} from 'react' | ||
|
||
import Box from '@/styled-components/Grid/Mobile/HFlexBox' | ||
|
||
import styled from 'styled-components' | ||
|
||
export interface Props { | ||
LeftBox: JSX.Element | ||
RightBox: JSX.Element | ||
} | ||
|
||
const BoxWrapper = styled.div` | ||
position: relative; | ||
width: 50%; | ||
@media (max-width: 1024px) { | ||
width: 100%; | ||
} | ||
` | ||
|
||
const GridTwoColumns: FC<Props> = ({LeftBox, RightBox}) => { | ||
return ( | ||
<Box> | ||
<BoxWrapper>{LeftBox}</BoxWrapper> | ||
<BoxWrapper>{RightBox}</BoxWrapper> | ||
</Box> | ||
) | ||
} | ||
|
||
export default GridTwoColumns |
10 changes: 10 additions & 0 deletions
10
apps/website/src/styled-components/Grid/Mobile/HFlexBox.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import styled from 'styled-components' | ||
import ParentComponent from '../HFlexBox' | ||
|
||
const Box = styled(ParentComponent)` | ||
@media (max-width: 1024px) { | ||
flex-direction: column; | ||
} | ||
` | ||
|
||
export default Box |