Skip to content
This repository was archived by the owner on Jun 10, 2019. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"react-error-overlay": "^1.0.7",
"react-ga": "^2.2.0",
"react-icons": "^2.2.5",
"react-modal": "^1.7.7",
"react-modal": "^2.3.2",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this!

"react-router": "^4.1.1",
"react-router-dom": "^4.1.1",
"react-scroll": "^1.5.4",
Expand Down
62 changes: 45 additions & 17 deletions src/scenes/home/families/facts/facts.css
Original file line number Diff line number Diff line change
@@ -1,26 +1,54 @@

.facts {
display: 'flex';
background-color: '#E2E2E2';
align-items: 'center';
padding: '96px';
display: flex;
flex-direction: row;
justify-content: space-between;
padding: 50px 0;
}

@media screen and (max-width: 1024px) {
.facts {
display: block;
}
}
.factsHeading {
font-size: '50px';
text-align: 'center';

.factsHeading h2 {
width: 100%;
}

.factsList {
color: '#445366';
font-size: '24px';
padding: '0 32px';
flex: .48;
color: #445366;
font-size: 1.5rem;
}

.factsList ul {
width: 80%;
margin: 0 auto;
}

.factsList .footnote {
font-size: 80%;
font-style: italic;
margin: 0 auto;
text-align: left;
width: 75%;
}

.factsRight {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't want to give you more lame instructions on styles, so I made some final changes I'd like you to commit:

.factsRight {
  background-position: 70% 30%;
  border-radius: 40px;
  flex: 0.48;
  height: 50vh;
  margin-top: 65px;
  overflow: hidden;
}

.factItem {
  padding-bottom: 24px;
}

/* most mobile browsers have annoying behavior with vh on scroll */
@media screen and (max-width: 420px) {
  .factsRight {
    height: 300px;
  }
}

I changed background-position simply because it seems to work well on my iPhone, laptop, and desktop with that setting.

padding: '0 32px'
background-position: 90% 25%;
border-radius: 40px;
flex: .48;
height: 50vh;
margin-top: 65px;
overflow: hidden;
}
.factsImage {
width: '30vw';
border-radius: '40px';

@media screen and (max-width: 1150px) {
.factsRight {
background-position: 80% 25%;
}
}

.factItem {
padding-bottom: '24px';
}
padding-bottom: 24px;
}
10 changes: 6 additions & 4 deletions src/scenes/home/families/facts/facts.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React, { Component } from 'react';
import Heading from 'shared/components/heading/heading';
import styles from './facts.css';
import family3 from '../../../../images/Family-3.jpg';

Expand All @@ -8,7 +9,7 @@ class Facts extends Component {
<div className={styles.facts}>
<div className={styles.factsList}>
<div className={styles.factsHeading}>
<h5>The Facts</h5>
<Heading text="The Facts" />
</div>
<ul>
<li className={styles.factItem}>
Expand All @@ -28,10 +29,11 @@ class Facts extends Component {
Only 19% of military spouses have adequate full-time employment.
</li>
</ul>
<div className={styles.footnote}>
<span>*Source </span><strong>pointsofflight.org</strong>

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you align this to the left edge of the quotes above it?

</div>
</div>
<div className={styles.factsRight}>
<img className={styles.factsImage} src={family3} alt="" />
</div>
<div className={styles.factsRight} style={{ backgroundImage: `url(${family3})` }}>{null}</div>
</div>
);
}
Expand Down
10 changes: 10 additions & 0 deletions src/scenes/home/families/families.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
.quoteSection {
margin-top: 50vh;
position: relative;
}

@media screen and (max-width: 800px) {
.quoteSection {
margin-top: 200px;
}
}
40 changes: 40 additions & 0 deletions src/scenes/home/families/families.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
import React, { Component } from 'react';
import Join from 'shared/components/join/join';
import Donate from 'shared/components/donate/donate';
import Section from 'shared/components/section/section';
import HeaderClipMask from 'shared/components/headerClipMask/headerClipMask';
import QuoteBanner from 'shared/components/quoteBanner/quoteBanner';
import Facts from './facts/facts';
import Goals from './goals/goals';
import styles from './families.css';

class Families extends Component {
render() {
const quoteProps = {
author: 'Former First Lady Michelle Obama',
quote: 'It\'s hard to impress employers who often view a resume with multiple jobs as a red flag rather than as a reality of military life.'
};

return (
<div>
<Section className={styles.quoteSection} theme="white">
<HeaderClipMask />
<QuoteBanner {...quoteProps} />
</Section>

<Section className={styles.factsSection}>
<Facts />
</Section>

<Section className={styles.goalsSection} theme="white">
<Goals />
</Section>

<Donate />
<Join />
</div>
);
}
}

export default Families;
44 changes: 44 additions & 0 deletions src/scenes/home/families/goals/goals.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
.goals {
width: 100%;
}

.goalsHeading h2 {
width: 100%;
}

.goalsContent {
margin: 0 auto;
width: 80%;
}

@media screen and (max-width: 1024px) {
.goalsContent {
width: 95%;
}
}

.goalsContent p,
.goalsContent ul li {
font-size: 1.5rem;
}

.goalsContent ul li {
background-image: url('../../../../images/logos/small-blue-medal.png');
background-position: left center;
background-repeat: no-repeat;
background-size: 60px;
list-style: none;
margin: 0;
padding: 36px 0 36px 97px;
}

@media screen and (max-width: 1024px) {
.goalsContent ul {
padding: 0;
}

.goalsContent ul li {
background-size: 40px;
padding: 16px 0 16px 67px;
}
}
26 changes: 26 additions & 0 deletions src/scenes/home/families/goals/goals.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import React, { Component } from 'react';
import Heading from 'shared/components/heading/heading';
import styles from './goals.css';

class Goals extends Component {
render() {
return (
<div className={styles.goals}>
<div className={styles.goalsHeading}>
<Heading text="Our Goals" />
</div>
<div className={styles.goalsContent}>
<p>When a loved one deploys, we understand the hardships that family members who are left behind can endure. There can be a lot of responsibilities to juggle. Operation Code works to ease the burden on military families by opening our programs and services up to military spouses, children and grandchildren.</p>
<ul>
<li>We strive to make software development more accessible not only to our veteran and military members, but also to their spouses and extended family.</li>
<li>Our community works to increase the interaction and engagement between military families across all our social channels.</li>
<li>Operation Code programs, scholarships and services are open to military families to help cultivate the learning process, and our employer services can work with family members to get them placed in software development jobs.</li>
<li>In the future, Operation Code plans to do a curriculum and grow a community for military children who are interested in learning how to code.</li>
</ul>
</div>
</div>
);
}
}

export default Goals;
15 changes: 0 additions & 15 deletions src/scenes/home/families/jumboQuote/jumboQuote.css

This file was deleted.

39 changes: 0 additions & 39 deletions src/scenes/home/families/jumboQuote/jumboQuote.js

This file was deleted.

7 changes: 0 additions & 7 deletions src/scenes/home/families/jumboQuote/quotes.json

This file was deleted.

2 changes: 1 addition & 1 deletion src/scenes/home/home.css
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

@media screen and (max-width: 800px) {
.backgroundImage {
background-size: auto 8%;
background-size: contain;
}
}

Expand Down
7 changes: 6 additions & 1 deletion src/scenes/home/home.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import MentorRequest from './mentorRequest/mentorRequest';
import SquadsNew from './squads/squadsNew/squadsNew';
import CodeSchools from './codeSchools/codeSchools';
import About from './about/about';
import Families from './families/families';
import Press from './press/press';
import ResetPassword from './resetPassword/resetPassword';
import Challenge from './challenge/challenge';
Expand Down Expand Up @@ -59,7 +60,7 @@ class Home extends Component {
}

setBgImage(location) {
if (location.pathname === '/') {
if (location.pathname === '/' || location.pathname === '/families') {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be removed if we don't want the BgImage on the families page.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can leave it in here. I'll be fiddling with the Nav this weekend and this page isn't linked anywhere on the site.

While I'm in the Nav, I'll add a different image and try to set it up to dynamically choose a header image based upon route.

this.setState({ bgChanged: !(this.state.bgImage), bgImage: true, bgImageUrl: familyImage });
} else {
this.setState({ bgChanged: this.state.bgImage, bgImage: false, bgImageUrl: null });
Expand Down Expand Up @@ -161,6 +162,10 @@ class Home extends Component {
path="/about"
component={About}
/>
<Route
path="/families"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we make this /about/families?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it should be it's own separate route because people will usually click it from the home page once we enable a link on the "Military Families and Spouses" card on the landing page.

component={Families}
/>
<Route
path="/press"
component={Press}
Expand Down
11 changes: 7 additions & 4 deletions src/scenes/home/team/team.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,15 @@ class Team extends Component {
alt: 'Thomas Ciszec'
};

const quoteProps = {
author: 'Abraham Lincoln',
quote: 'To care for him who shall have borne the battle and for his widow, and his orphan.',
isHeadline: true
};

return (
<div>
<QuoteBanner
author="Abraham Lincoln"
quote="To care for him who shall have borne the battle and for his widow, and his orphan."
/>
<QuoteBanner {...quoteProps} />

<Section title="Our Staff" theme="white">
<p>
Expand Down
22 changes: 22 additions & 0 deletions src/shared/components/headerClipMask/headerClipMask.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
.maskLeft,
.maskRight {
bottom: 99.5%;
fill: #FFFFFF;
position: absolute;
width: 50%;
}

.maskLeft {
left: 0;
}

.maskRight {
right: 0;
}

@media screen and (max-width: 800px) {
.maskLeft,
.maskRight {
display: none;
}
}
19 changes: 19 additions & 0 deletions src/shared/components/headerClipMask/headerClipMask.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import React, { Component } from 'react';
import styles from './headerClipMask.css';

class HeaderClipMask extends Component {
render() {
return (
<div>
<svg className={styles.maskLeft} x="0px" y="0px" viewBox="0 0 612 97" style={{ enableBackground: 'new 0 0 612 97' }}>
<path d="M614.8,97H0V0C0,0,317.7,97,614.8,97z" />
</svg>
<svg className={styles.maskRight} x="0px" y="0px" viewBox="0 0 612 97" style={{ enableBackground: 'new 0 0 612 97' }}>
<path d="M0,97h615V0C615,0,297.1,97,0,97z" />
</svg>
</div>
);
}
}

export default HeaderClipMask;
Loading