Skip to content

Commit

Permalink
line-clamp on header
Browse files Browse the repository at this point in the history
  • Loading branch information
temmietope committed Jan 4, 2021
1 parent d764db0 commit 2af21c7
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/components/Post.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ const Post = ({
buttonFontColor,
buttonText
}) => {
const mediumScreen = useMediaQuery('(max-width: 950px)')
const smallScreen = useMediaQuery('(max-width: 768px)')
const smallerScreen = useMediaQuery('(max-width: 500px)')

Expand Down Expand Up @@ -47,9 +46,7 @@ const Post = ({

postHeader: {
fontSize: headerSize
? mediumScreen
? '1.2rem'
: smallScreen
? smallScreen
? '1.25rem'
: smallerScreen
? '1.05rem'
Expand All @@ -63,7 +60,8 @@ const Post = ({
padding: '0',
display: '-webkit-box',
WebkitBoxOrient: 'vertical',
WebkitLineClamp: '2'
WebkitLineClamp: '2',
overflow: 'hidden'
},

postExcerpt: {
Expand Down

0 comments on commit 2af21c7

Please sign in to comment.