Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Mar 9, 2021. It is now read-only.

Commit 5b04a75

Browse files
author
z
committed
font size same as event card
1 parent 4e1e378 commit 5b04a75

File tree

2 files changed

+13
-10
lines changed

2 files changed

+13
-10
lines changed

components/learn/subject-card.js

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from 'react';
22
import styled from 'react-emotion';
33
import { Flex, Box } from 'grid-emotion';
4-
import { space } from 'styled-system';
4+
import { space, fontSize } from 'styled-system';
55
import Link from 'next/link';
66
import LearningIcon from 'react-icons/lib/fa/book';
77
import EstimateIcon from 'react-icons/lib/md/access-time';
@@ -42,18 +42,19 @@ const SubjectCard = styled.div`
4242
}
4343
}
4444
& .subtitle {
45-
font-size: 0.8rem;
45+
${fontSize};
4646
color: #8393a7;
4747
margin-top: 0px;
4848
margin-bottom: 10px;
4949
}
5050
& .stats {
51+
${fontSize};
5152
color: #8393a7;
52-
font-size: 0.8rem;
5353
}
5454
& .icons {
55-
font-size: 1.1rem;
55+
font-size: 1.2rem;
5656
margin-right: 0.25rem;
57+
margin-bottom: 0.25rem;
5758
color: #8393a7;
5859
}
5960
& .view {
@@ -81,15 +82,17 @@ export default ({ subject }) => (
8182
</div>
8283
<div className="content">
8384
<h3 className="title">{subject.title}</h3>
84-
<p className="subtitle">{subject.domain}</p>
85+
<p className="subtitle" fontSize={[12, 14, 16]}>
86+
{subject.domain}
87+
</p>
8588
<Flex className="stats" wrap>
86-
<Box pr={[1]} pb={[1]}>
89+
<Box pr={[1]} pb={[1]} fontSize={[12, 14, 16]}>
8790
<LearningIcon className="icons" />
88-
20 learning
91+
<span>20 learning</span>
8992
</Box>
90-
<Box>
93+
<Box fontSize={[12, 14, 16]}>
9194
<EstimateIcon className="icons" />
92-
20 hours
95+
<span>20 hours</span>
9396
</Box>
9497
</Flex>
9598
<Link href={`/learn/subject?id=${subject.subjectId}`} as={subject.url}>

pages/learn/subject.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export default class Subject extends React.Component {
7676
/>
7777
<CurriculumSection my={[2, 4]}>
7878
<Flex column={false}>
79-
<Box width={[0, 0.2]} className="box_toc">
79+
<Box width={[0.2]} className="box_toc">
8080
<div className="toc_title">Table of content</div>
8181
<SyllabusTree data={laravelSyllabus} changeChapter={this.changeChapter} />
8282
</Box>

0 commit comments

Comments
 (0)