Skip to content

Commit 12de58d

Browse files
authored
Merge pull request #93 from usingbrain/bubblegum
instruction styling
2 parents ce63541 + f035d1a commit 12de58d

9 files changed

Lines changed: 52 additions & 10 deletions

File tree

client/src/Assets/classdata.png

4.4 KB
Loading

client/src/Assets/openclass.png

15.8 KB
Loading
25.9 KB
Loading

client/src/Assets/startsession.png

5 KB
Loading

client/src/Assets/studentdata.png

50.6 KB
Loading

client/src/Components/ClassView/DeleteBtn.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ const btnStyle = {
1313
};
1414

1515
const alertStyle =
16-
'text-white text-center flex flex-col items-center justify-evenly h-56 w-96 fixed top-2/3 inset-x-1/2 bg-black p-12';
16+
'text-white text-center flex flex-col items-center justify-evenly h-1/3 w-1/3 fixed top-1/3 inset-x-1/2 bg-black p-12';
1717

18-
const alertBtnStyle = 'hover:bg-white hover:text-black border-white p-4';
18+
const alertBtnStyle = 'text-white bg-black border-2 border-black hover:border-white p-4 w-1/2 m-1';
1919

2020
const DeleteBtn: React.FC<{ courseId: number }> = ({ courseId }) => {
2121
const navigate = useNavigate();

client/src/Components/TeacherDashboard/Course.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { setHistory, setSelected } from '../../store/actions';
66
import CourseType from '../../Types/course';
77

88
let courseStyle =
9-
'flex py-2 font-light text-left text-white w-full border-2 border-green hover:border-white justify-center';
9+
'flex flex-col py-2 font-light text-left text-white w-full border-2 border-green hover:border-white justify-center items-center';
1010

1111
const Course: React.FC<{ course: CourseType }> = ({ course }) => {
1212
const dispatch = useDispatch();
@@ -19,7 +19,8 @@ const Course: React.FC<{ course: CourseType }> = ({ course }) => {
1919

2020
return (
2121
<div className={courseStyle} onClick={handleClick}>
22-
<p className='flex justify-center border-b-2 w-1/4 pb-4'>{course.name}</p>
22+
<p className='flex justify-center pb-4'>{course.name}</p>
23+
<hr className="border-b-2 border-white w-1/4" />
2324
</div>
2425
);
2526
};

client/src/Components/TeacherHomepage/Instruction.tsx

Lines changed: 40 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,46 @@
1-
import React from 'react';
1+
import openOrCreate from '../../Assets/openclass.png';
2+
import registerImg from '../../Assets/registerstudents.png';
3+
import startImg from '../../Assets/startsession.png';
4+
import attendanceImg from '../../Assets/classdata.png';
5+
import studentData from '../../Assets/studentdata.png';
6+
7+
const imgStyle = "bg-white rounded-full h-16 w-16 flex justify-center items-center"
8+
const info = "w-2/3 text-2xl h-20 flex md:pl-8 pl-1 pr-2 items-center rounded-full justify-between"
29

310
const Instruction = () => {
411
return (
5-
<div className="text-center text-lg flex flex-col justify-evenly h-48">
6-
<h2 className="p-8">
7-
&lt;-- Click here to add a new course to your list
8-
</h2>
9-
<h2 className="p-8">&lt;-- or choose one that already exists</h2>
12+
<div className="h-screen flex flex-col items-center">
13+
<h1 className="text-5xl my-8">Quick start</h1>
14+
<p className={`${info} mb-4 bg-shades-one`}>
15+
Create or open a class
16+
<div className={imgStyle}>
17+
<img src={openOrCreate} alt="Open or create class" className="h-10 w-10" />
18+
</div>
19+
</p>
20+
<p className={`${info} my-4 bg-shades-two`}>
21+
Register students
22+
<div className={imgStyle}>
23+
<img src={registerImg} alt="Open or create class" className="h-10 w-10" />
24+
</div>
25+
</p>
26+
<p className={`${info} my-4 bg-shades-three`}>
27+
Start a session
28+
<div className={imgStyle}>
29+
<img src={startImg} alt="Open or create class" className="h-10 w-10" />
30+
</div>
31+
</p>
32+
<p className={`${info} my-4 bg-shades-four`}>
33+
Access attendance data
34+
<div className={imgStyle}>
35+
<img src={attendanceImg} alt="Open or create class" className="h-10 w-10" />
36+
</div>
37+
</p>
38+
<p className={`${info} my-4 bg-shades-five`}>
39+
Check individual student data
40+
<div className={imgStyle}>
41+
<img src={studentData} alt="Open or create class" className="h-10 w-10" />
42+
</div>
43+
</p>
1044
</div>
1145
);
1246
};

client/tailwind.config.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,13 @@ module.exports = {
2727
black: {
2828
DEFAULT: '#000000',
2929
},
30+
shades: {
31+
one: '#C7F4F0',
32+
two: '#AFEBE5',
33+
three: '#79D4CC',
34+
four: '#43BFB3',
35+
five: '#00A393'
36+
}
3037
},
3138
boxShadow: {
3239
bottom: '0 3px 2px -1px rgba(0, 0, 0, 0.2)'

0 commit comments

Comments
 (0)