Skip to content

Commit

Permalink
Merge pull request #60 from astroash/fixes
Browse files Browse the repository at this point in the history
Fix some styling on summary and amend ask endpoint
  • Loading branch information
maxgerber committed Oct 12, 2017
2 parents 1cc5837 + 2f202af commit 55cc783
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/components/Menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ const Menu = ({ changeTopic, toggleMenu, cssImg }) => {
</li>
</Link>
<Link
to="/askanon"
to="/ask"
style={{ textDecoration: 'none' }}
onClick={() => {
toggleMenu();
Expand Down
19 changes: 11 additions & 8 deletions src/components/Summary.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,27 @@ const getSnippetTitle = (json, voteId) => {
}

const Summary= ({snippetUpvotes, snippetDownvotes}) => {
const upVotesList = snippetUpvotes.map(voteId => <li className="ma2">{getSnippetTitle(policies, voteId)}</li>)
const downVotesList = snippetDownvotes.map(voteId => <li>{getSnippetTitle(policies, voteId)}</li>)
const upVotesList = snippetUpvotes.map(voteId => <li className="ma3">{getSnippetTitle(policies, voteId)}</li>)
const downVotesList = snippetDownvotes.map(voteId => <li className="ma3">{getSnippetTitle(policies, voteId)}</li>)
return (
<div className="">
<h1 className="tc ma0 mb3">Summary</h1>
<section className="w-50 dib v-top">
<IconSnippet cssImg="megaphone" />
<ul className="list pa0 tc summary__ul ma0 summary--margin"> {upVotesList} </ul>
<ul className="list pa0 tc summary__ul summary--margin"> {upVotesList} </ul>
</section>
<section className="w-50 dib v-top">
<IconSnippet cssImg="bin" />
<ul className="list pa0 tc summary__ul"> {downVotesList} </ul>
<ul className="list pa0 tc summary__ul summary--margin"> {downVotesList} </ul>
</section>
<section className="ba bw1 b--gold br2 bg-white dib pa2 w-100 summary--margin">
<h3 className="ma2">What's next</h3>
<a href="#" className="db ma2">Link to cool meetup</a>
<a href="#" className="db ma2">Link to awesome grassroots movement</a>
<a href="#" className="db ma2">Link to volunteering opportunities</a>
<h3 className="ml3">What's next?</h3>
<ul className="pointer">
<li><a href="#" className="db ma2 black">Link to cool meetup</a></li>
<li><a href="#" className="db ma2 black">Link to awesome grassroots movement</a></li>
<li><a href="#" className="db ma2 black">Link to volunteering opportunities</a></li>
<li><a href="/ask" className="db ma2 black">Ask an MP</a></li>
</ul>
</section>
</div>
);
Expand Down
2 changes: 1 addition & 1 deletion src/css/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ body {

/*summary*/
.summary__ul {
font-size: calc(0.6rem + 0.7vw);
font-size: calc(0.8rem + 0.4vw);
}
.summary--margin {
margin-top: 2vw;
Expand Down

0 comments on commit 55cc783

Please sign in to comment.