-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The "page" classes should come in useful for other static pages that we want a nice chunky header and centred content on, like About and the Home page.
- Loading branch information
Showing
8 changed files
with
245 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
<title>Gender Balance</title> | ||
|
||
<meta property="og:title" content="What’s the Gender Balance of world politics? Help us find out."> | ||
<meta property="og:url" content="http://www.gender-balance.org"> | ||
<meta property="og:site_name" content="Gender Balance"> | ||
<meta property="og:type" content="website"> | ||
<meta property="og:description" content="By playing this simple game, you can help uncover the true gender balance across individual parliaments, and the world. Swipe left, right, up, or down, and work your way to the top of our leaderboard!"> | ||
<meta property="og:image" content="<%= request.base_url %>/banner.jpg"> | ||
<meta property="og:image:width" content="1200"> | ||
<meta property="og:image:height" content="630"> | ||
|
||
<meta name="twitter:card" content="summary"> | ||
<meta name="twitter:site" content="@mysociety"> | ||
<meta name="twitter:title" content="Play Gender Balance online"> | ||
<meta name="twitter:description" content="By playing this simple game, you can help uncover the true gender balance across individual parliaments, and the world. Swipe left, right, up, or down, and work your way to the top of our leaderboard!"> | ||
<meta name="twitter:image" content="<%= request.base_url %>/banner.jpg"> | ||
<meta name="twitter:image:width" content="1200"> | ||
<meta name="twitter:image:height" content="630"> | ||
|
||
<link href="https://fonts.googleapis.com/css?family=Roboto:400,900,700,500,300,400italic" rel="stylesheet" type="text/css"> | ||
<link href="<%= url '/main.css' %>" rel="stylesheet"> | ||
<!--[if lt IE 9]> | ||
<script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> | ||
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> | ||
<![endif]--> | ||
<script src="/js/jquery-1.11.3.min.js"></script> | ||
<script src="/js/jquery.transform2d.js"></script> | ||
<script src="/js/jquery.cardswipe.js"></script> | ||
<script src="/js/main.js"></script> | ||
<script> | ||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | ||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | ||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | ||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); | ||
ga('create', 'UA-660910-35', 'auto'); | ||
ga('send', 'pageview'); | ||
</script> | ||
</head> | ||
<body class="page <%= yield_content :body_class %>"> | ||
<div class="app-messages"> | ||
<%= erb :flash %> | ||
</div> | ||
<div class="page-header"> | ||
<div class="container"> | ||
<%= yield_content :back_button %> | ||
<h1>Gender Balance</h1> | ||
<%= yield_content :undo_button %> | ||
</div> | ||
</div> | ||
<div class="page-content"> | ||
<%= yield %> | ||
</div> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
$grid-max-width: 960px !default; | ||
$grid-gutter: 2em !default; | ||
$grid-breakpoint-sm: 768px !default; | ||
|
||
.container { | ||
margin-right: auto; | ||
margin-left: auto; | ||
padding-left: $grid-gutter / 2; | ||
padding-right: $grid-gutter / 2; | ||
max-width: $grid-max-width; | ||
} | ||
|
||
.row { | ||
@include clearfix(); | ||
margin-left: $grid-gutter / -2; | ||
margin-right: $grid-gutter / -2; | ||
} | ||
|
||
%col { | ||
padding-left: $grid-gutter / 2; | ||
padding-right: $grid-gutter / 2; | ||
min-height: 1px; | ||
} | ||
|
||
@for $i from 1 through 12 { | ||
.col-sm-#{$i} { | ||
@extend %col; | ||
} | ||
} | ||
|
||
@media(min-width: $grid-breakpoint-sm) { | ||
%col-float { | ||
float: left; | ||
} | ||
|
||
@for $i from 1 through 12 { | ||
.col-sm-#{$i} { | ||
@extend %col-float; | ||
width: 100% / 12 * $i; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
// Most of gender-balance is focussed around "app-like" screens with a | ||
// minimal header and tight gutters. But the rest of the site is made | ||
// from mostly static "page" type pages. These styles are for them. | ||
|
||
body.page { | ||
padding-top: 0; | ||
} | ||
|
||
.page-header { | ||
text-align: center; | ||
padding: 0.5em 0; | ||
background-color: $color_white; | ||
position: relative; | ||
|
||
@media (min-width: $screen_medium_min) { | ||
padding: 1em 0; | ||
} | ||
|
||
.container { | ||
position: relative; | ||
} | ||
|
||
a, h1 { | ||
line-height: 1.1em; | ||
font-size: 1em; | ||
margin: 0; | ||
} | ||
} | ||
|
||
.page-header__back { | ||
position: absolute; | ||
text-decoration: none; | ||
font-size: 0.9em; | ||
padding: 0.5em; | ||
|
||
left: 0; | ||
top: -0.5em; // vertically centre in header | ||
|
||
@media (min-width: $screen_medium_min) { | ||
font-size: 1em; | ||
left: 0.5em; | ||
} | ||
|
||
.fa { | ||
vertical-align: middle; | ||
} | ||
} | ||
|
||
.page-section { | ||
padding: 1em 0; | ||
|
||
@media (min-width: $screen_medium_min) and (min-height: 700px) { | ||
padding: 2em 0; | ||
} | ||
|
||
.container { | ||
@include remove-margin-from-children(); | ||
} | ||
} | ||
|
||
.page-section--white { | ||
background-color: $color_white; | ||
|
||
& + & { | ||
border-top: 1px solid $color_off_white; | ||
} | ||
} | ||
|
||
.page-section--blue { | ||
background-color: $color_off_white; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters