Set min width on forms and tables to prevent content from becoming unreadable

This commit is contained in:
James Nuanez
2020-04-22 14:44:46 -07:00
parent 12998ac6c0
commit bd8337bebb
3 changed files with 11 additions and 0 deletions
+1
View File
@@ -5,6 +5,7 @@ const Table = styled.table`
border-collapse: collapse;
white-space: nowrap;
width: 100%;
min-width: 38rem;
& > thead {
background: #F7F7F7;
@@ -89,6 +89,10 @@ const ContentContainer = styled.div`
${props => props.type === 'form' &&
'max-width: 61rem;'
}
min-width: ${props => props.type === 'form'
? '58rem'
: '38rem'
};
@media (max-width: 34rem) {
width: 100%;
}
@@ -34,6 +34,12 @@ const ContentContainer = styled.div`
border-radius: 0.5rem;
box-shadow: 0 0.25rem 0.25rem rgba(0, 0, 0, 0.1),
0px 0px 0.25rem rgba(0, 0, 0, 0.1);
${props => props.wide && `
min-width: 58rem;
`}
@media (max-width: 58rem) {
align-self: flex-start;
}
@media (max-width: 34rem) {
width: 100%;
}