Skip to content

Commit d2e94ba

Browse files
ltchurch88tbbmoz
authored andcommitted
Feature/#155492458 - User sees filters (#184)
* Pivotal Story #155492458 Filter section grid layout * Pivotal Story #155492458-Filter Grid Filter grid layout. Moved to left of screen with style added for visual appeal
1 parent b7c491b commit d2e94ba

File tree

3 files changed

+84
-12
lines changed

3 files changed

+84
-12
lines changed

client/components/Home/Home.js

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React, { Component, Fragment } from 'react'
1+
import React, { Component } from 'react'
22
import PropTypes from 'prop-types'
33
import { connect } from 'react-redux'
44
import Checkbox from 'material-ui/Checkbox'
@@ -33,31 +33,33 @@ class Home extends Component {
3333
<FormControlLabel key={index}
3434
control={ <Checkbox name={type} value={item} onChange={this.handleCheckbox} /> }
3535
label={item}
36+
className={styles.checkBoxes}
3637
/>
3738
)
3839
})
3940
}
4041

4142
render () {
4243
return (
43-
<Fragment>
44+
<div className={styles.homeGrid}>
4445
<section className={styles.filterSection}>
45-
<h1>{'Filters'}</h1>
46-
<FormLabel>Causes</FormLabel>
47-
<FormGroup row>
46+
<span className={styles.filterTitle}><h1>{'Filters'}</h1></span>
47+
<FormLabel className={styles.causeTitle}>Causes</FormLabel>
48+
<FormGroup column className={styles.causesList}>
4849
{ this.renderList(causes, 'causes') }
4950
</FormGroup>
50-
51-
<FormLabel>Technologies</FormLabel>
52-
<FormGroup row>
51+
<FormLabel className={styles.techTitle}>Tech</FormLabel>
52+
<FormGroup column className={styles.techList}>
5353
{ this.renderList(technologies, 'technologies') }
5454
</FormGroup>
5555
</section>
5656

5757
<ListOfProjects
5858
title={'Click To Apply'}
59-
projects={this.props.projects} />
60-
</Fragment>
59+
projects={this.props.projects}
60+
className={styles.projectList}
61+
/>
62+
</div>
6163
)
6264
}
6365
}

client/components/Home/Home.scss

Lines changed: 71 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,73 @@
1+
$titleBarColor: #f5f5f5;
2+
$titleBarRadius: 200px;
3+
$fontColor: #4b4c4d;
4+
5+
.homeGrid {
6+
display: grid;
7+
margin-left: -150px;
8+
grid-template-columns: auto 85%;//
9+
grid-template-areas:
10+
"filterSection projectList";
11+
}
12+
13+
.projectList {
14+
grid-area: projectList;
15+
padding: 0 30px;
16+
}
17+
118
.filterSection {
2-
padding: 0 60px;
3-
display: grid;
19+
padding: 0 30px 10px;
20+
grid-area: filterSection;
21+
box-shadow: 0 4px 80px 0 rgba(0, 0, 0, 0.1);
22+
display: grid;
23+
grid-template-rows: 60px 30px auto 30px auto;
24+
grid-template-columns: 300px;
25+
grid-template-areas:
26+
"filterTitle"
27+
"causeTitle"
28+
"causes"
29+
"techTitle"
30+
"technologies";
31+
grid-row-gap: 10px;
32+
height: 70%;
33+
}
34+
35+
.filterTitle {
36+
grid-area: filterTitle;
37+
}
38+
39+
.causeTitle {
40+
grid-area: causeTitle;
41+
border-radius: $titleBarRadius;
42+
color: $fontColor;
43+
font-weight: bold;
44+
height: 30px;
45+
display: flex;
46+
align-items: center;
47+
justify-content: center;
48+
background-color: $titleBarColor;
49+
}
50+
51+
.techTitle {
52+
grid-area: techTitle;
53+
border-radius: $titleBarRadius;
54+
color: $fontColor;
55+
font-weight: bold;
56+
height: 30px;
57+
display: flex;
58+
align-items: center;
59+
justify-content: center;
60+
background-color: $titleBarColor;
61+
}
62+
63+
.causesList {
64+
grid-area: causes;
65+
}
66+
67+
.techList {
68+
grid-area: technologies;
69+
}
70+
71+
.checkBoxes {
72+
margin-top: -2px;
473
}

docs/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#### Description of Changes:
2424
<!-- Put a description of your changes here -->
2525

26+
2627
#### TODO:
2728
<!-- Put any TODO's here -->
2829

0 commit comments

Comments
 (0)