Skip to content
This repository has been archived by the owner on Jan 15, 2021. It is now read-only.

Commit

Permalink
add autoWidth prop to self adjust (#1560)
Browse files Browse the repository at this point in the history
  • Loading branch information
W3stside authored Oct 30, 2020
1 parent a2bb4d8 commit b081e02
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 3 additions & 1 deletion src/components/layout/PageWrappers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,10 @@ export const StandaloneCardWrapper = styled.div`
}
}
`
export const PageWrapper = styled.section`
export const PageWrapper = styled.section<{ $autoWidth?: boolean }>`
height: 75rem;
width: ${({ $autoWidth = false }): string => ($autoWidth ? 'auto' : '100%')};
margin: auto;
max-width: 100%;
background: var(--color-background-pageWrapper);
Expand Down
2 changes: 0 additions & 2 deletions src/components/layout/SwapLayout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@ const Wrapper = styled.div`
}
> section {
width: 100%;
@media ${MEDIA.mobile} {
overflow: initial;
}
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Wallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { PageWrapper } from 'components/layout'
import DepositWidget from 'components/DepositWidget'

const Deposit: React.FC = () => (
<PageWrapper>
<PageWrapper $autoWidth>
<DepositWidget />
</PageWrapper>
)
Expand Down

0 comments on commit b081e02

Please sign in to comment.