aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--templates/web/bromley/footer.html37
-rw-r--r--templates/web/bromley/header.html51
-rwxr-xr-xtemplates/web/default/reports/council.html14
-rw-r--r--templates/web/fixmystreet/header.html2
-rw-r--r--web/cobrands/bromley/base.scss22
-rw-r--r--web/cobrands/bromley/bromley-logo.jpgbin0 -> 20898 bytes
-rw-r--r--web/cobrands/bromley/bromley-logo.s.jpgbin0 -> 5908 bytes
-rw-r--r--web/cobrands/bromley/bromley.scss81
-rw-r--r--web/cobrands/bromley/favicon.icobin0 -> 61798 bytes
-rw-r--r--web/cobrands/bromley/fixmystreet.js593
-rw-r--r--web/cobrands/bromley/layout.scss62
-rw-r--r--web/cobrands/bromley/tab-blue.pngbin0 -> 826 bytes
-rw-r--r--web/cobrands/fixmystreet/_base.scss20
-rw-r--r--web/cobrands/fixmystreet/_layout.scss10
-rw-r--r--web/js/map-OpenLayers.js11
-rw-r--r--web/js/modernizr.custom.76759.js4
-rw-r--r--web/js/modernizr.custom.js4
17 files changed, 856 insertions, 55 deletions
diff --git a/templates/web/bromley/footer.html b/templates/web/bromley/footer.html
index 9be0741bf..da77b1756 100644
--- a/templates/web/bromley/footer.html
+++ b/templates/web/bromley/footer.html
@@ -1,22 +1,3 @@
- [% IF pagefooter %]
- <footer role="content-info">
- <div class="tablewrapper bordered">
- <div id="footer-mobileapps">
- <h4>Mobile apps</h4>
-
- <ul>
- <li><a class="m-app-iphone" href="http://itunes.apple.com/gb/app/fixmystreet/id297456545">iPhone</a></li>
- <li><a class="m-app-droid" href="https://market.android.com/details?id=com.android.fixmystreet">Android</a></li>
- <li><a class="m-app-nokia" href="http://store.ovi.com/content/107557">Nokia</a></li>
- <li><a class="m-app-iphone-streetreport" href="http://itunes.apple.com/gb/app/streetreport/id371891859">iPhone Street Report</a></li>
- </ul>
- </div>
-
- <div id="footer-help">
- </div>
- </div>
- </footer>
- [% END %]
</div><!-- .content role=main -->
</div><!-- .container -->
</div><!-- .table-cell -->
@@ -25,7 +6,7 @@
<div class="nav-wrapper-2">
<div id="main-nav" role="navigation">
<ul id="mysoc-menu">
- <li><a href="http://www.fixmystreet.com/">Powered by FixMyStreet</a></li>
+ <li><a href="http://www.fixmystreet.com/">Powered by <img src="https://github.com/mysociety/fixmystreet/raw/9a9889db881e24c17f51804ba56c11bd264bbf9c/web/cobrands/fixmystreet/fms-logo.png" style="height:20px; vertical-align: bottom"></a></li>
</ul>
<ul id="main-menu">
@@ -44,7 +25,21 @@
</div>
</div>
-<!-- [% INCLUDE 'debug_footer.html' %] -->
</div> <!-- .wrapper -->
+
+<div id="bromley-footer" class="desk-only">
+ <p class="copy">&copy; 2012 London Borough of Bromley</p>
+
+ <a href="http://www.direct.gov.uk/"><img src="http://www.bromley.gov.uk/site/images/directgov.jpg" alt="Directgov website link - Public services all in one place" /></a>
+
+ <ul class="footer-nav">
+ <li><a href="#bromley-header">To the top</a></li>
+ <li><a href="http://www.bromley.gov.uk/terms">Disclaimer</a></li>
+ <li><a href="http://www.bromley.gov.uk/privacy" rel="nofollow">Privacy and cookies</a></li>
+ <li><a href="http://www.bromley.gov.uk/accesstoinfo">Access to information</a></li>
+ </ul>
+
+</div>
+
</body>
</html>
diff --git a/templates/web/bromley/header.html b/templates/web/bromley/header.html
index f7beabd8c..1b58bcccf 100644
--- a/templates/web/bromley/header.html
+++ b/templates/web/bromley/header.html
@@ -6,31 +6,62 @@
<!--[if gt IE 9]><!--><html class="no-js" lang="[% lang_code %]"><!--<![endif]-->
<head>
<meta name="viewport" content="initial-scale=1.0">
-
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
<meta name="HandHeldFriendly" content="true">
<meta name="mobileoptimized" content="0">
<link rel="stylesheet" href="[% version('/cobrands/bromley/base.css') %]">
- <!-- <link rel="stylesheet" href="[% version('/cobrands/fixmystreet/layout.css') %]" media="(min-width:48em)"> -->
+ <link rel="stylesheet" href="[% version('/cobrands/bromley/layout.css') %]" media="(min-width:48em)">
<link rel="stylesheet" href="[% version('/js/fancybox/jquery.fancybox-1.3.4.css') %]">
+ <link rel="stylesheet" href="[% version('/cobrands/bromley/bromley.css') %]">
<!--[if (lt IE 9) & (!IEMobile)]>
- <!-- <link rel="stylesheet" href="[% version('/cobrands/fixmystreet/layout.css') %]"> -->
+ <link rel="stylesheet" href="[% version('/cobrands/bromley/layout.css') %]">
<![endif]-->
- <script src="[% version('/js/modernizr.custom.76759.js') %]" charset="utf-8"></script>
- [% INCLUDE 'common_header_tags.html', js_override = '/cobrands/fixmystreet/fixmystreet.js' %]
+ <script src="[% version('/js/modernizr.custom.js') %]" charset="utf-8"></script>
+ [% INCLUDE 'common_header_tags.html', js_override = '/cobrands/bromley/fixmystreet.js' %]
<script src="[% version('/js/fancybox/jquery.fancybox-1.3.4.pack.js') %]" charset="utf-8"></script>
- [% IF c.req.uri.host == 'osm.fixmystreet.com' %]
- <link rel="canonical" href="http://www.fixmystreet.com[% c.req.uri.path_query %]">
- [% END %]
-
- [% INCLUDE 'tracking_code.html' %]
+ <link rel="Shortcut Icon" type="image/x-icon" href="/cobrands/bromley/favicon.ico">
</head>
<body class="[% bodyclass | html IF bodyclass %]">
+<div id="bromley-header" class="desk-only">
+ <ul class="header-nav">
+ <li><a href="http://www.bromley.gov.uk/accessibility">Accessibility</a></li>
+ <li><a class="skiplink" href="http://www.bromley.gov.uk/#user-meta" rel="nofollow">Skip to content</a></li>
+ <!-- <li><a rel="nofollow" href="http://www.bromley.gov.uk/a_to_z?previewstyle=generic/print.css">Printer friendly</a></li> -->
+ <!-- <li><a href="http://www.bromley.gov.uk/accessibility/settings">Text size: AAA</a></li> -->
+ <li><div id="google_translate_element"></div></li>
+ </ul>
+
+ <div class="logo">
+ <a href="http://www.bromley.gov.uk"><img src="http://www.bromley.gov.uk/site/images/bromley-logo.jpg" alt="London Borough of Bromley logo" width="159" height="114" /></a>
+ </div>
+
+ <!-- <div class="sign-in">
+ <p>
+ You are not signed in. <a href="https://www.bromley.gov.uk/sign_in?referer=%2fa_to_z">Sign in</a>
+ or <a href="https://www.bromley.gov.uk/register">register</a>?
+ </p>
+ </div> -->
+
+ <div class="main-menu">
+ <ul>
+ <li class="home"><a href="http://www.bromley.gov.uk">Home</a></li>
+ <li><a href="http://www.bromley.gov.uk/a_to_z">A to Z</a></li>
+ <li><a href="http://www.bromley.gov.uk/site_map">Site map</a></li>
+ </ul>
+ <form action="http://www.bromley.gov.uk/site/scripts/google_results.aspx" method="get" id="search">
+ <label for="SearchSite">Search by Keyword</label>
+ <input type="text" size="18" maxlength="40" class="field" name="q" id="SearchSite" value="Search by keyword" onclick="if (this.value == 'Search by keyword') { this.value = ''; }" onblur="if (this.value == '') { this.value = 'Search by keyword'; }" />
+ <input value="Search" id="SearchSubmit" type="submit" class="button" />
+ </form>
+ </div>
+
+</div>
+
<div class="wrapper">
<div class="table-cell">
<header id="site-header" role="banner">
diff --git a/templates/web/default/reports/council.html b/templates/web/default/reports/council.html
index 0d3d43d82..4eef35dec 100755
--- a/templates/web/default/reports/council.html
+++ b/templates/web/default/reports/council.html
@@ -1,3 +1,9 @@
+[% IF c.cobrand.moniker == 'fixmystreet' OR c.cobrand.moniker == 'bromley';
+ style = 'new';
+ ELSE;
+ style = 'old';
+ END;
+%]
[% IF ward %]
[% name = "$ward.name, $council.name"
thing = loc('ward')
@@ -19,7 +25,7 @@
[% map_html %]
-[% IF c.cobrand.moniker != 'fixmystreet' AND children.size %]
+[% IF style != 'new' AND children.size %]
<h2 style="clear:right">[% loc('Wards of this council') %]</h2>
<p>[% loc('Follow a ward link to view only reports within that ward.') %]</p>
<ul>
@@ -66,7 +72,7 @@ Its area is now covered by <a href="/reports/Bedford">Bedford Borough Council</a
<a href="/reports/Central+Bedfordshire">Central Bedfordshire Council</a>.
[% END %]
</p>
-[% ELSIF c.cobrand.moniker == 'fixmystreet' %]
+[% ELSIF style == 'new' %]
<div class="shadow-wrap">
<ul id="key-tools"[% IF NOT children.size %] class="singleton"[% END %]>
<li><a rel="nofollow" id="key-tool-updates-area" class="feed" href="[% rss_url %]">[% tprintf(loc('Get updates of problems in this %s'), thing) %]</a></li>
@@ -81,7 +87,7 @@ Its area is now covered by <a href="/reports/Bedford">Bedford Borough Council</a
[% TRY %][% INCLUDE 'reports/cobrand_stats.html' %][% CATCH file %][% END %]
-[% IF c.cobrand.moniker == 'fixmystreet' AND children.size %]
+[% IF style == 'new' AND children.size %]
<section id="council_wards" class="hidden-js">
<h2>[% loc('Wards of this council') %]</h2>
<p>[% loc('Follow a ward link to view only reports within that ward.') %]</p>
@@ -117,7 +123,7 @@ Its area is now covered by <a href="/reports/Bedford">Bedford Borough Council</a
[% IF problems %]
<ul class="issue-list-a">
-[% IF c.cobrand.moniker == 'fixmystreet' %]
+[% IF style == 'new' %]
[% FOREACH problem IN problems %]
<li>
diff --git a/templates/web/fixmystreet/header.html b/templates/web/fixmystreet/header.html
index 6be57891a..da5a0808f 100644
--- a/templates/web/fixmystreet/header.html
+++ b/templates/web/fixmystreet/header.html
@@ -18,7 +18,7 @@
<link rel="stylesheet" href="[% version('/cobrands/fixmystreet/layout.css') %]">
<![endif]-->
- <script src="[% version('/js/modernizr.custom.76759.js') %]" charset="utf-8"></script>
+ <script src="[% version('/js/modernizr.custom.js') %]" charset="utf-8"></script>
[% INCLUDE 'common_header_tags.html', js_override = '/cobrands/fixmystreet/fixmystreet.js' %]
<script src="[% version('/js/fancybox/jquery.fancybox-1.3.4.pack.js') %]" charset="utf-8"></script>
diff --git a/web/cobrands/bromley/base.scss b/web/cobrands/bromley/base.scss
index 4594f832f..710078118 100644
--- a/web/cobrands/bromley/base.scss
+++ b/web/cobrands/bromley/base.scss
@@ -5,3 +5,25 @@
@import "../fixmystreet/_base";
+// Want a white header, and logo is slightly bigger
+#site-header {
+ @include background(linear-gradient(#ddd, #fff 10%, #fff));
+ height: 4em;
+}
+
+// Colour tab to match colour scheme
+#nav-link {
+ width: 50px;
+ height: 48px;
+ background: url('/cobrands/bromley/tab-blue.png') 0 0 no-repeat;
+}
+
+// Change logo to logo of council
+#site-logo {
+ display: block;
+ width: 80px;
+ height: 44px;
+ top: 0.9em;
+ background: url('/cobrands/bromley/bromley-logo.s.jpg') 0 0 no-repeat;
+}
+
diff --git a/web/cobrands/bromley/bromley-logo.jpg b/web/cobrands/bromley/bromley-logo.jpg
new file mode 100644
index 000000000..28da8b7ea
--- /dev/null
+++ b/web/cobrands/bromley/bromley-logo.jpg
Binary files differ
diff --git a/web/cobrands/bromley/bromley-logo.s.jpg b/web/cobrands/bromley/bromley-logo.s.jpg
new file mode 100644
index 000000000..16f632848
--- /dev/null
+++ b/web/cobrands/bromley/bromley-logo.s.jpg
Binary files differ
diff --git a/web/cobrands/bromley/bromley.scss b/web/cobrands/bromley/bromley.scss
new file mode 100644
index 000000000..054315fbd
--- /dev/null
+++ b/web/cobrands/bromley/bromley.scss
@@ -0,0 +1,81 @@
+/* Parts of Bromley's main CSS needed for its header/footer and adjusted (see
+ * bottom) to not be affected by main FixMyStreet CSS. Not very sustainable;
+ * perhaps we should wrap all council CSS within a SCSS #council ID? Hmm.
+ */
+
+@import "compass";
+
+h1, h2, h3, h4, h5, h6, legend { font-family: 'Gill Sans', 'Trebuchet MS', Calibri, sans-serif; }
+body { color: #333; font-family: Arial, 'Helvetica Neue', Helvetica, sans-serif; line-height: 1.4; }
+
+// #header renamed to #bromley-header
+#bromley-header { padding: 0 18px 0 25px; }
+
+.header-nav {float:right; background:url('http://www.bromley.gov.uk/site/styles/css_img/header-nav.gif') no-repeat; overflow:hidden; width:651px; height:34px; line-height:34px; padding:0 20px;}
+.header-nav li {float:left; width:130px; text-align:center; background:url('http://www.bromley.gov.uk/site/styles/css_img/header-nav-divider.gif') top right no-repeat;}
+.header-nav li:last-child {background:none;}
+.header-nav a:link, .header-nav a:visited {color:#fff; text-decoration:none;}
+.header-nav a:hover, .header-nav a:active {text-decoration:underline;}
+
+/* -------- For Google translate select box only */
+.header-nav div#google_translate_element .goog-te-gadget { font-family: Arial, 'Helvetica Neue', Helvetica, sans-serif; }
+.header-nav div#google_translate_element .goog-te-gadget .goog-te-combo { margin:5px 0 0 5px; padding:0 0 0 2px; background: #9b9b9b; color: #fff; border: 1px solid #606060; font-size: 12px; width: 138px;}
+.header-nav div#google_translate_element .goog-te-gadget .goog-te-combo option { background:#fff; color: #666; padding: 1px 0; margin: 0; }
+/* --- */
+
+.logo {padding:10px 0;}
+
+.sign-in {float:right; margin-top:-87px; width: 650px; text-align: right;}
+.sign-in a:link, .sign-in a:visited {color:#333; font-weight:bold; text-decoration:none;}
+.sign-in a:hover, .sign-in a:active {text-decoration:underline;}
+
+.main-menu {background:url('http://www.bromley.gov.uk/site/styles/css_img/main-menu.gif') no-repeat; width:689px; height:45px; margin-top:-60px; float:right; clear:right;}
+.main-menu li {float:left; width:126px; padding-right:2px; text-align:center; font:150%/45px 'Gill Sans', 'Trebuchet MS', Calibri, sans-serif;}
+.main-menu li a:link, .main-menu li a:visited {color:#fff; display:block; text-decoration:none;}
+.main-menu li a:hover, .main-menu li a:active {background:url('http://www.bromley.gov.uk/site/styles/css_img/main-menu-hover.gif') repeat-x;}
+.main-menu li.home a:hover, .main-menu li.home a:active {background:url('http://www.bromley.gov.uk/site/styles/css_img/main-menu-hover-home.gif') repeat-x;}
+
+#search { float: right; padding: 10px 17px; width: 270px; }
+#search label {display:none;}
+#search input { background: #ececec; border: 1px solid #768b9a; border-color: #768b9a #d1dee8 #d1dee8 #768b9a; line-height: 9px; padding: 6px 5px 4px; width: 184px; }
+#search input.button { background: #fff; border: 1px solid #8596a8; color: #333; font-family: 'Gill Sans', 'Trebuchet MS', Calibri, sans-serif; font-size:133%; height: 27px; line-height: 27px; padding: 0; vertical-align: top; width: 70px; }
+
+// #footer renamed to #bromley-footer, image removed from background, width removed for no scrollbar, fixed font size.
+#bromley-footer { background: #666; clear: both; padding:15px 15px 50px; margin-left:-15px; color:#fff; font-size:11px;}
+#bromley-footer a:link,
+#bromley-footer a:visited { color: #fff; text-decoration: none; }
+#bromley-footer a:hover,
+#bromley-footer a:active { text-decoration: underline;}
+#bromley-footer img { float: right; margin-top: -18px; }
+#bromley-footer .footer-nav { float: right; height:35px; margin-top: -15px; }
+#bromley-footer .footer-nav li { border-right:1px solid #fff; float: left; line-height: 1; padding: 0 20px; }
+#bromley-footer .footer-nav li:last-child { border: none; }
+
+// Bromley IE specific CSS
+.ie6 {
+ #search input { padding: 8px 5px 2px; }
+ #search input.button { padding: 0; width: 68px; line-height: 24px; }
+ input.button { overflow: visible; width: 1%; }
+}
+.ie7 {
+ #search input { padding: 8px 5px 2px; }
+ #search input.button { padding: 0; width: 68px; line-height: 24px; }
+ input.button { overflow: visible; }
+}
+.ie8 {
+ #search input { padding: 8px 5px 2px; }
+ #search input.button { padding: 0; line-height: 24px; }
+}
+
+// mySociety additions
+#bromley-header { font-size: 12px; }
+.header-nav ul { margin: 0; }
+.header-nav li { list-style-type: none; }
+.main-menu ul { margin: 0; }
+.main-menu li { list-style-type: none; }
+#search input { display: inline; margin: 0; @include border-radius(0em); }
+#search input.button { font-weight: normal; text-transform: none; }
+#bromley-footer { margin: 2em 0 0; }
+#bromley-footer .footer-nav li { list-style-type: none; }
+#bromley-footer p { margin: 0; }
+
diff --git a/web/cobrands/bromley/favicon.ico b/web/cobrands/bromley/favicon.ico
new file mode 100644
index 000000000..cf0577755
--- /dev/null
+++ b/web/cobrands/bromley/favicon.ico
Binary files differ
diff --git a/web/cobrands/bromley/fixmystreet.js b/web/cobrands/bromley/fixmystreet.js
new file mode 100644
index 000000000..051f46c64
--- /dev/null
+++ b/web/cobrands/bromley/fixmystreet.js
@@ -0,0 +1,593 @@
+/*
+ * fixmystreet.js
+ * FixMyStreet JavaScript
+ */
+
+function form_category_onchange() {
+ var cat = $('#form_category');
+ var args = {
+ category: cat.val()
+ };
+
+ if ( typeof fixmystreet !== 'undefined' ) {
+ args.latitude = fixmystreet.latitude;
+ args.longitude = fixmystreet.longitude;
+ } else {
+ args.latitude = $('input[name="latitude"]').val();
+ args.longitude = $('input[name="longitude"]').val();
+ }
+
+ $.getJSON('/report/new/category_extras', args, function(data) {
+ if ( data.category_extra ) {
+ if ( $('#category_meta').size() ) {
+ $('#category_meta').html( data.category_extra);
+ } else {
+ $('#form_category_row').after( data.category_extra );
+ }
+ } else {
+ $('#category_meta').empty();
+ }
+ });
+}
+
+/*
+ * general height fixing function
+ *
+ * elem1: element to check against
+ * elem2: target element
+ * offset: this will be added (if present) to the final value, useful for height errors
+ */
+function heightFix(elem1, elem2, offset){
+ var h1 = $(elem1).height(),
+ h2 = $(elem2).height();
+ if(offset === undefined){
+ offset = 0;
+ }
+ if(h1 > h2){
+ $(elem2).css({'min-height':h1+offset});
+ }
+}
+
+
+/*
+ * very simple tab function
+ *
+ * elem: trigger element, must have an href attribute (so probably needs to be an <a>)
+ */
+function tabs(elem, indirect) {
+ var href = elem.attr('href');
+ //stupid IE sometimes adds the full uri into the href attr, so trim
+ var start = href.indexOf('#'),
+ target = href.slice(start, href.length);
+
+ if (indirect) {
+ elem = $(target + '_tab');
+ }
+
+ if(!$(target).hasClass('open'))
+ {
+ //toggle class on nav
+ $('.tab-nav .active').removeClass('active');
+ elem.addClass('active');
+
+ //hide / show the right tab
+ $('.tab.open').hide().removeClass('open');
+ $(target).show().addClass('open');
+ }
+}
+
+
+$(function(){
+ var $html = $('html');
+
+ $html.removeClass('no-js').addClass('js');
+
+ // Preload the new report pin
+ document.createElement('img').src = '/i/pin-green.png';
+
+ var last_type;
+ $(window).resize(function(){
+ var type = $('#site-header').css('borderTopWidth');
+ if (type == '4px') { type = 'mobile'; }
+ else if (type == '0px') { type = 'desktop'; }
+ else { return; }
+ if (last_type == type) { return; }
+ if (type == 'mobile') {
+ $html.addClass('mobile');
+ $('#map_box').prependTo('.content').css({
+ zIndex: '', position: '',
+ top: '', left: '', right: '', bottom: '',
+ width: '', height: '10em',
+ margin: ''
+ });
+ if (typeof fixmystreet !== 'undefined') {
+ fixmystreet.state_map = ''; // XXX
+ }
+ if (typeof fixmystreet !== 'undefined' && fixmystreet.page == 'around') {
+ // Immediately go full screen map if on around page
+ // $('#site-header').hide();
+ $('#map_box').prependTo('.wrapper').css({
+ position: 'absolute',
+ top: 0, left: 0, right: 0, bottom: 0,
+ height: 'auto',
+ margin: 0
+ });
+ $('#fms_pan_zoom').css({ top: '2.75em !important' });
+ $('.big-green-banner')
+ .addClass('mobile-map-banner')
+ .appendTo('#map_box')
+ .text('Place pin on map')
+ .prepend('<a href="/">home</a>');
+ }
+ $('span.report-a-problem-btn').on('click.reportBtn', function(){
+ $('html, body').animate({scrollTop:0}, 500);
+ }).css({ cursor:'pointer' }).on('hover.reportBtn', function(){
+ $(this).toggleClass('hover');
+ });
+ } else {
+ // Make map full screen on non-mobile sizes.
+ $html.removeClass('mobile');
+ var map_pos = 'fixed', map_height = '100%';
+ //if ($html.hasClass('ie6')) {
+ map_pos = 'absolute';
+ map_height = $(window).height();
+ //}
+ $('#map_box').prependTo('.wrapper').css({
+ zIndex: 0, position: map_pos,
+ top: 0, left: 0, right: 0, bottom: 0,
+ width: '100%', height: map_height,
+ margin: 0
+ });
+ if (typeof fixmystreet !== 'undefined') {
+ $('#bromley-footer').hide();
+ fixmystreet.state_map = 'full';
+ }
+ if (typeof fixmystreet !== 'undefined' && fixmystreet.page == 'around') {
+ // Remove full-screen-ness
+ // $('#site-header').show();
+ $('#fms_pan_zoom').css({ top: '4.75em !important' });
+ $('.big-green-banner')
+ .removeClass('mobile-map-banner')
+ .prependTo('#side')
+ .text('Click map to report a problem');
+ }
+ $('span.report-a-problem-btn').css({ cursor:'' }).off('.reportBtn');
+ }
+ last_type = type;
+ });
+
+ //add mobile class if small screen
+ $(window).resize();
+
+ $('#pc').focus();
+
+ $('input[type=submit]').removeAttr('disabled');
+ /*
+ $('#mapForm').submit(function() {
+ if (this.submit_problem) {
+ $('input[type=submit]', this).prop("disabled", true);
+ }
+ return true;
+ });
+ */
+
+ if (!$('#been_fixed_no').prop('checked') && !$('#been_fixed_unknown').prop('checked')) {
+ $('#another_qn').hide();
+ }
+ $('#been_fixed_no').click(function() {
+ $('#another_qn').show('fast');
+ });
+ $('#been_fixed_unknown').click(function() {
+ $('#another_qn').show('fast');
+ });
+ $('#been_fixed_yes').click(function() {
+ $('#another_qn').hide('fast');
+ });
+
+ // FIXME - needs to use translated string
+ jQuery.validator.addMethod('validCategory', function(value, element) {
+ return this.optional(element) || value != '-- Pick a category --'; }, validation_strings.category );
+
+ jQuery.validator.addMethod('validName', function(value, element) {
+ var validNamePat = /\ba\s*n+on+((y|o)mo?u?s)?(ly)?\b/i;
+ return this.optional(element) || value.length > 5 && value.match( /\S/ ) && !value.match( validNamePat ); }, validation_strings.category );
+
+ var form_submitted = 0;
+ var submitted = false;
+
+ $("form.validate").validate({
+ rules: {
+ title: { required: true },
+ detail: { required: true },
+ email: { required: true },
+ update: { required: true },
+ rznvy: { required: true }
+ },
+ messages: validation_strings,
+ onkeyup: false,
+ onfocusout: false,
+ errorElement: 'div',
+ errorClass: 'form-error',
+ // we do this to stop things jumping around on blur
+ success: function (err) { if ( form_submitted ) { err.addClass('label-valid').removeClass('label-valid-hidden').html( '&nbsp;' ); } else { err.addClass('label-valid-hidden'); } },
+ errorPlacement: function( error, element ) {
+ element.before( error );
+ },
+ submitHandler: function(form) {
+ if (form.submit_problem) {
+ $('input[type=submit]', form).prop("disabled", true);
+ }
+
+ form.submit();
+ },
+ // make sure we can see the error message when we focus on invalid elements
+ showErrors: function( errorMap, errorList ) {
+ if ( submitted && errorList.length ) {
+ $(window).scrollTop( $(errorList[0].element).offset().top - 120 );
+ }
+ this.defaultShowErrors();
+ submitted = false;
+ },
+ invalidHandler: function(form, validator) { submitted = true; }
+ });
+
+ $('input[type=submit]').click( function(e) { form_submitted = 1; } );
+
+ /* set correct required status depending on what we submit
+ * NB: need to add things to form_category as the JS updating
+ * of this we do after a map click removes them */
+ $('#submit_sign_in').click( function(e) {
+ $('#form_category').addClass('required validCategory').removeClass('valid');
+ $('#form_name').removeClass();
+ } );
+
+ $('#submit_register').click( function(e) {
+ $('#form_category').addClass('required validCategory').removeClass('valid');
+ $('#form_name').addClass('required validName');
+ } );
+
+ $('#problem_submit > input[type="submit"]').click( function(e) {
+ $('#form_category').addClass('required validCategory').removeClass('valid');
+ $('#form_name').addClass('required validName');
+ } );
+
+ $('#update_post').click( function(e) {
+ $('#form_name').addClass('required').removeClass('valid');
+ } );
+
+ $('#form_category').change( form_category_onchange );
+
+ // Geolocation
+ if (geo_position_js.init()) {
+ $('#postcodeForm').after('<a href="#" id="geolocate_link">&hellip; or locate me automatically</a>');
+ $('#geolocate_link').click(function(e) {
+ e.preventDefault();
+ // Spinny thing!
+ if($('.mobile').length){
+ $(this).append(' <img src="/cobrands/fixmystreet/images/spinner-black.gif" alt="" align="bottom">');
+ }else{
+ $(this).append(' <img src="/cobrands/fixmystreet/images/spinner-yellow.gif" alt="" align="bottom">');
+ }
+ geo_position_js.getCurrentPosition(function(pos) {
+ $('img', this).remove();
+ var latitude = pos.coords.latitude;
+ var longitude = pos.coords.longitude;
+ location.href = '/around?latitude=' + latitude + ';longitude=' + longitude;
+ }, function(err) {
+ $('img', this).remove();
+ if (err.code == 1) { // User said no
+ } else if (err.code == 2) { // No position
+ $(this).html("Could not look up location");
+ } else if (err.code == 3) { // Too long
+ $('this').html("No result returned");
+ } else { // Unknown
+ $('this').html("Unknown error");
+ }
+ }, {
+ enableHighAccuracy: true,
+ timeout: 10000
+ });
+ });
+ }
+
+ /*
+ * Report a problem page
+ */
+ //desktop
+ if ($('#report-a-problem-sidebar').is(':visible')) {
+ heightFix('#report-a-problem-sidebar', '.content', 26);
+ }
+
+ //show/hide notes on mobile
+ $('.mobile #report-a-problem-sidebar').after('<a href="#" class="rap-notes-trigger button-right">How to send successful reports</a>').hide();
+ $('.rap-notes-trigger').click(function(e){
+ e.preventDefault();
+ //check if we've already moved the notes
+ if($('.rap-notes').length > 0){
+ //if we have, show and hide .content
+ $('.content').hide();
+ $('.rap-notes').show();
+ }else{
+ //if not, move them and show, hiding .content
+ $('.content').after('<div class="content rap-notes"></div>').hide();
+ $('#report-a-problem-sidebar').appendTo('.rap-notes').show().after('<a href="#" class="rap-notes-close button-left">Back</a>');
+ }
+ $('html, body').scrollTop($('#report-a-problem-sidebar').offset().top);
+ location.hash = 'rap-notes';
+ });
+ $('.mobile').on('click', '.rap-notes-close', function(e){
+ e.preventDefault();
+ //hide notes, show .content
+ $('.content').show();
+ $('.rap-notes').hide();
+ $('html, body').scrollTop($('#mob_ok').offset().top);
+ location.hash = 'report';
+ });
+
+ //move 'skip this step' link on mobile
+ $('.mobile #skip-this-step').hide();
+ $('.mobile #skip-this-step a').addClass('chevron').wrap('<li>').appendTo('#key-tools');
+
+ /*
+ * Tabs
+ */
+ //make initial tab active
+ $('.tab-nav a').first().addClass('active');
+ $('.tab').first().addClass('open');
+
+ //hide other tabs
+ $('.tab').not('.open').hide();
+
+ //set up click event
+ $(".tab-nav").on('click', 'a', function(e){
+ e.preventDefault();
+ tabs($(this));
+ });
+ $('.tab_link').click(function(e) {
+ e.preventDefault();
+ tabs($(this), 1);
+ });
+
+ /*
+ * Skip to nav on mobile
+ */
+ $('.mobile').on('click', '#nav-link', function(e){
+ e.preventDefault();
+ var offset = $('#main-nav').offset().top;
+ $('html, body').animate({scrollTop:offset}, 1000);
+ });
+
+
+ /*
+ * Show stuff on input focus
+ */
+ $('.form-focus-hidden').hide();
+ $('.form-focus-trigger').on('focus', function(){
+ $('.form-focus-hidden').fadeIn(500);
+ });
+
+ /*
+ * Show on click - pretty generic
+ */
+ $('.hideshow-trigger').on('click', function(e){
+ e.preventDefault();
+ var href = $(this).attr('href'),
+ //stupid IE sometimes adds the full uri into the href attr, so trim
+ start = href.indexOf('#'),
+ target = href.slice(start, href.length);
+
+ $(target).removeClass('hidden-js');
+
+ $(this).hide();
+ });
+
+ /*
+ * nicetable - on mobile shift 'name' col to be a row
+ */
+ $('.mobile .nicetable th.title').remove();
+ $('.mobile .nicetable td.title').each(function(i){
+ $(this).attr('colspan', 5).insertBefore($(this).parent('tr')).wrap('<tr class="heading" />');
+ });
+ // $('.mobile .nicetable tr.heading > td.title').css({'min-width':'300px'});
+ // $('.mobile .nicetable tr > td.data').css({'max-width':'12%'});
+
+ /*
+ * Map controls prettiness
+ */
+ //add links container (if its not there)
+ if($('#sub_map_links').length === 0){
+ $('<p id="sub_map_links" />').insertAfter($('#map'));
+ }
+
+// A sliding drawer from the bottom of the page, small version
+// that doesn't change the main content at all.
+$.fn.small_drawer = function(id) {
+ this.toggle(function(){
+ var $this = $(this), d = $('#' + id);
+ if (!$this.addClass('hover').data('setup')) {
+ d.hide().removeClass('hidden-js').css({
+ padding: '1em',
+ background: '#fff'
+ });
+ $this.data('setup', true);
+ }
+ d.slideDown();
+ }, function(e){
+ var $this = $(this), d = $('#' + id);
+ $this.removeClass('hover');
+ d.slideUp();
+ });
+};
+
+// A sliding drawer from the bottom of the page, large version
+$.fn.drawer = function(id, ajax) {
+ // IE7 positions the fixed tool bar 1em to the left unless it comes after
+ // the full-width section, ho-hum. Move it to where it would be after an
+ // open/close anyway
+ if ($('html.ie7').length) {
+ var $sw = $('.shadow-wrap'), $content = $('.content[role="main"]');
+ $sw.appendTo($content);
+ }
+ this.toggle(function(){
+ var $this = $(this), d = $('#' + id), $content = $('.content[role="main"]');
+ if (!$this.addClass('hover').data('setup')) {
+ // make a drawer div with an innerDiv
+ if (!d.length) {
+ d = $('<div id="' + id + '">');
+ }
+ var innerDiv = $('<div>');
+ d.wrapInner(innerDiv);
+
+ // if ajax, load it with a spinner
+ if (ajax) {
+ var href = $this.attr('href') + ';ajax=1';
+ $this.prepend(' <img class="spinner" src="/cobrands/fixmystreet/images/spinner-black-333.gif" style="margin-right:2em;">');
+ innerDiv.load(href, function(){
+ $('.spinner').remove();
+ });
+ }
+
+ // Tall drawer - put after .content for scrolling to work okay.
+ // position over the top of the main .content in precisely the right location
+ d.insertAfter($content).addClass('content').css({
+ position: 'absolute',
+ zIndex: '1100',
+ marginTop: $('html.ie6, html.ie7').length ? '-3em' : 0, // IE6/7 otherwise include the 3em padding and stay too low
+ left: 0,
+ top: $(window).height() - $content.offset().top
+ }).removeClass('hidden-js').find('h2').css({ marginTop: 0 });
+ $this.data('setup', true);
+ }
+
+ //do the animation
+ $('.shadow-wrap').prependTo(d).addClass('static');
+ d.show().animate({top:'3em'}, 1000, function(){
+ $content.fadeOut(function() {
+ d.css({ position: 'relative' });
+ });
+ });
+ }, function(e){
+ var $this = $(this), d = $('#' + id), $sw = $('.shadow-wrap'),
+ $content = $('.content[role="main"]'),
+ tot_height = $(window).height() - d.offset().top;
+ $this.removeClass('hover');
+ d.css({ position: 'absolute' }).animate({ top: tot_height }, 1000, function(){
+ d.hide();
+ $sw.appendTo($content).removeClass('static');
+ });
+ $content.show();
+ });
+};
+
+ if ($('html.mobile').length) {
+ $('#council_wards').hide().removeClass('hidden-js').find('h2').hide();
+ $('#key-tool-wards').click(function(e){
+ e.preventDefault();
+ $('#council_wards').slideToggle('800', function(){
+ $('#key-tool-wards').toggleClass('active');
+ });
+ });
+ } else {
+ $('#key-tool-wards').drawer('council_wards', false);
+ $('#key-tool-around-updates').drawer('updates_ajax', true);
+ }
+ $('#key-tool-report-updates').small_drawer('report-updates-data');
+
+ // Go directly to RSS feed if RSS button clicked on alert page
+ // (due to not wanting around form to submit, though good thing anyway)
+ $('.container').on('click', '#alert_rss_button', function(e){
+ e.preventDefault();
+ var feed = $('input[name=feed][type=radio]:checked').nextAll('a').attr('href');
+ window.location.href = feed;
+ });
+ $('.container').on('click', '#alert_email_button', function(e){
+ e.preventDefault();
+ var form = $('<form/>').attr({ method:'post', action:"/alert/subscribe" });
+ $('#alerts input[type=text], #alerts input[type=hidden], #alerts input[type=radio]:checked').each(function() {
+ var $v = $(this);
+ $('<input/>').attr({ name:$v.attr('name'), value:$v.val(), type:'hidden' }).appendTo(form);
+ });
+ form.submit();
+ });
+
+ //add permalink on desktop, force hide on mobile
+ $('#sub_map_links').append('<a href="#" id="map_permalink">Permalink</a>');
+ if($('.mobile').length){
+ $('#map_permalink').hide();
+ $('#key-tools a.feed').appendTo('#sub_map_links');
+ $('#key-tools li:empty').remove();
+ $('#report-updates-data').insertAfter($('#map_box'));
+ }
+ //add open/close toggle button on desk
+ $('#sub_map_links').prepend('<span id="map_links_toggle">&nbsp;</span>');
+
+ //set up map_links_toggle click event
+ $('#map_links_toggle').on('click', function(){
+ var maplinks_width = $('#sub_map_links').width();
+
+ if($(this).hasClass('closed')){
+ $(this).removeClass('closed');
+ $('#sub_map_links').animate({'right':'0'}, 1200);
+ }else{
+ $(this).addClass('closed');
+ $('#sub_map_links').animate({'right':-maplinks_width}, 1200);
+ }
+ });
+
+
+ /*
+ * Add close buttons for .promo's
+ */
+ if($('.promo').length){
+ $('.promo').append('<a href="#" class="close-promo">x</a>');
+ }
+ //only close its own parent
+ $('.promo').on('click', '.close-promo', function(e){
+ e.preventDefault();
+ $(this).parent('.promo').animate({
+ 'height':0,
+ 'margin-bottom':0,
+ 'padding-top':0,
+ 'padding-bottom':0
+ },{
+ duration:500,
+ queue:false
+ }).fadeOut(500);
+ });
+
+
+
+ /*
+ * Fancybox fullscreen images
+ */
+ $('a[rel=fancy]').fancybox({
+ 'overlayColor': '#000000'
+ });
+
+ /*
+ * heightfix the desktop .content div
+ *
+ * this must be kept near the end so that the
+ * rendered height is used after any page manipulation (such as tabs)
+ */
+ if (!$('html.mobile').length) {
+ if (!($('body').hasClass('frontpage'))){
+ heightFix(window, '.content', -128);
+ }
+ }
+
+});
+
+/*
+XXX Disabled because jerky on Android and makes map URL bar height too small on iPhone.
+// Hide URL bar
+$(window).load(function(){
+ window.setTimeout(function(){
+ var s = window.pageYOffset || document.compatMode === "CSS1Compat" && document.documentElement.scrollTop || document.body.scrollTop || 0;
+ if (s < 20 && !location.hash) {
+ window.scrollTo(0, 1);
+ }
+ }, 0);
+});
+*/
+
diff --git a/web/cobrands/bromley/layout.scss b/web/cobrands/bromley/layout.scss
index 3dc34c6c7..2724ac83b 100644
--- a/web/cobrands/bromley/layout.scss
+++ b/web/cobrands/bromley/layout.scss
@@ -1,11 +1,73 @@
@import "_colours";
@import "../fixmystreet/_layout";
+.wrapper {
+ position: relative;
+}
+
body {
background: #fff;
}
#front-main {
background: $primary;
+ // layout sets this because base has it slightly lighter
+ h2 {
+ color: $primary_text;
+ }
+}
+
+// Don't want FixMyStreet logo on desktop, and we have a skip to content in
+// Bromley header
+#site-header {
+ display: none;
+}
+
+// Currently hiding, but do want some internal navigation somewhere at the end
+.nav-wrapper {
+ display: none;
+}
+
+// Bit of extra spacing needed under Bromley header
+body.frontpage .table-cell .content {
+ margin-top: 15em;
+}
+.ie6, .ie7 {
+ #front-main {
+ top: -2em;
+ left: 1.5em;
+ }
+ body.frontpage .table-cell .content {
+ margin-top: 11em;
+ }
+}
+
+// White background, so no shadow needed.
+.content {
+ @include box-shadow(none);
+}
+.ie6, .ie7, .ie8 {
+ .content {
+ border: none;
+ }
+}
+// Except on map pages
+body.mappage .content {
+ @include box-shadow(0px 0px 6px 1px #000);
+}
+.ie6, .ie7, .ie8 {
+ body.mappage .content {
+ border: solid 1px #666;
+ }
+}
+
+#map_box {
+ border-top: solid 1px #666;
+ border-bottom: solid 1px #666;
+}
+
+// Perhaps fix map location (should be in central?)
+.ie6 #map_box {
+ right: -30em;
}
diff --git a/web/cobrands/bromley/tab-blue.png b/web/cobrands/bromley/tab-blue.png
new file mode 100644
index 000000000..62e6285b7
--- /dev/null
+++ b/web/cobrands/bromley/tab-blue.png
Binary files differ
diff --git a/web/cobrands/fixmystreet/_base.scss b/web/cobrands/fixmystreet/_base.scss
index 4202564f7..db348c2a4 100644
--- a/web/cobrands/fixmystreet/_base.scss
+++ b/web/cobrands/fixmystreet/_base.scss
@@ -447,7 +447,8 @@ p.label-valid {
&#mysoc-menu{
li {
a {
- background:$primary;
+ color: $primary_text;
+ background: $primary;
&#mysoc-logo {
background-image:url('/cobrands/fixmystreet/images/sprite.png');
background-repeat:no-repeat;
@@ -472,7 +473,8 @@ p.label-valid {
#user-meta {
p {
position: relative;
- background:$primary;
+ color: $primary_text;
+ background: $primary;
padding:1em 6em 1em 1em;
a {
position: absolute;
@@ -893,7 +895,7 @@ a:hover.button-left {
width:20px;
height:20px;
opacity: 0.5;
- background:#fff url(images/sprite.png) -16px -1098px no-repeat;
+ background:#fff url(/cobrands/fixmystreet/images/sprite.png) -16px -1098px no-repeat;
//hide text - http://nicolasgallagher.com/another-css-image-replacement-technique/
font: 0/0 a;
color: transparent;
@@ -1273,7 +1275,8 @@ table.nicetable {
.promo {
@extend .full-width;
- background:$primary;
+ color: $primary_text;
+ background: $primary;
padding:1em;
margin-bottom:1em;
overflow:hidden;
@@ -1286,10 +1289,10 @@ table.nicetable {
width:16px;
height:16px;
text-indent:-999999px;
- background:url(images/sprite.png) -341px -263px no-repeat;
+ background:url(/cobrands/fixmystreet/images/sprite.png) -341px -263px no-repeat;
@include border-radius(4px);
&:hover {
- background:#222 url(images/sprite.png) -341px -223px no-repeat;
+ background:#222 url(/cobrands/fixmystreet/images/sprite.png) -341px -223px no-repeat;
}
}
}
@@ -1320,7 +1323,8 @@ table.nicetable {
}
a {
@include inline-block;
- background:$primary;
+ color: $primary_text;
+ background: $primary;
padding-left:0.5em;
padding-right:0.5em;
color:#1a1a1a;
@@ -1334,7 +1338,7 @@ table.nicetable {
// this is a bit of a hack to get some differentation between desk and mobile
.desk-only {
- display:none !important;
+ display:none;
}
// hide anything with this class if js is working
diff --git a/web/cobrands/fixmystreet/_layout.scss b/web/cobrands/fixmystreet/_layout.scss
index 534b285b1..5fb65ee72 100644
--- a/web/cobrands/fixmystreet/_layout.scss
+++ b/web/cobrands/fixmystreet/_layout.scss
@@ -3,10 +3,10 @@
//hacks for desk/mob only stuff
.desk-only {
- display:block !important;
+ display: block;
}
.mob-only {
- display:none !important;
+ display: none;
}
body {
@@ -147,7 +147,8 @@ h1 {
@include background(linear-gradient(#000, #444 10%, #444 95%, #111));
}
a.report-a-problem-btn {
- background:$primary;
+ color: $primary_text;
+ background: $primary;
padding:0.25em;
margin:0.5em;
color:#333;
@@ -210,7 +211,7 @@ h1 {
.ie6, .ie7, .ie8 {
.content {
// If no box-shadow, just want a boring black border to stand it out from the map.
- border: 1px solid black;
+ border: 1px solid #666;
//take off margins so we line up properly
margin: 0;
}
@@ -919,6 +920,7 @@ body.frontpage {
border-right:1em solid #fff;
#front_stats {
background:none;
+ color: #222;
border-top:0.25em solid $primary;
padding-top:1em;
div {
diff --git a/web/js/map-OpenLayers.js b/web/js/map-OpenLayers.js
index 79740de78..5f60a4437 100644
--- a/web/js/map-OpenLayers.js
+++ b/web/js/map-OpenLayers.js
@@ -236,7 +236,7 @@ $(function(){
if (fixmystreet.state_map && fixmystreet.state_map == 'full') {
// TODO Work better with window resizing, this is pretty 'set up' only at present
- var q = $(window).width() / 4;
+ var q = $('#map_box').width() / 4;
// Need to try and fake the 'centre' being 75% from the left
fixmystreet.map.pan(-q, -25, { animate: false });
fixmystreet.map.events.register("movestart", null, function(e){
@@ -463,7 +463,12 @@ OpenLayers.Control.Click = OpenLayers.Class(OpenLayers.Control, {
// If we clicked the map somewhere inconvenient
var sidebar = $('#report-a-problem-sidebar');
if (sidebar.css('position') == 'absolute') {
- var w = sidebar.width(), h = sidebar.height(), o = sidebar.offset();
+ var w = sidebar.width(), h = sidebar.height(),
+ o = sidebar.offset(),
+ $map_box = $('#map_box'), bo = $map_box.offset();
+ // e.xy is relative to top left of map, which might not be top left of page
+ e.xy.x += bo.left;
+ e.xy.y += bo.top;
if (e.xy.y <= o.top || (e.xy.x >= o.left && e.xy.x <= o.left + w + 24 && e.xy.y >= o.top && e.xy.y <= o.top + h + 64)) {
// top of the page, pin hidden by header;
// or underneath where the new sidebar will appear
@@ -472,7 +477,7 @@ OpenLayers.Control.Click = OpenLayers.Class(OpenLayers.Control, {
fixmystreet.map.getProjectionObject()
);
var p = fixmystreet.map.getViewPortPxFromLonLat(lonlat);
- p.x -= $(window).width() / 3;
+ p.x -= $map_box.width() / 3;
lonlat = fixmystreet.map.getLonLatFromViewPortPx(p);
fixmystreet.map.panTo(lonlat);
}
diff --git a/web/js/modernizr.custom.76759.js b/web/js/modernizr.custom.76759.js
deleted file mode 100644
index 20a22d8fa..000000000
--- a/web/js/modernizr.custom.76759.js
+++ /dev/null
@@ -1,4 +0,0 @@
-/* Modernizr 2.5.3 (Custom Build) | MIT & BSD
- * Build: http://www.modernizr.com/download/#-input-shiv-mq-teststyles-load
- */
-;window.Modernizr=function(a,b,c){function v(a){i.cssText=a}function w(a,b){return v(prefixes.join(a+";")+(b||""))}function x(a,b){return typeof a===b}function y(a,b){return!!~(""+a).indexOf(b)}function z(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:x(f,"function")?f.bind(d||b):f}return!1}function A(){e.input=function(c){for(var d=0,e=c.length;d<e;d++)n[c[d]]=c[d]in j;return n.list&&(n.list=!!b.createElement("datalist")&&!!a.HTMLDataListElement),n}("autocomplete autofocus list placeholder max min multiple pattern required step".split(" "))}var d="2.5.3",e={},f=b.documentElement,g="modernizr",h=b.createElement(g),i=h.style,j=b.createElement("input"),k={}.toString,l={},m={},n={},o=[],p=o.slice,q,r=function(a,c,d,e){var h,i,j,k=b.createElement("div"),l=b.body,m=l?l:b.createElement("body");if(parseInt(d,10))while(d--)j=b.createElement("div"),j.id=e?e[d]:g+(d+1),k.appendChild(j);return h=["&#173;","<style>",a,"</style>"].join(""),k.id=g,m.innerHTML+=h,m.appendChild(k),l||(m.style.background="",f.appendChild(m)),i=c(k,a),l?k.parentNode.removeChild(k):m.parentNode.removeChild(m),!!i},s=function(b){var c=a.matchMedia||a.msMatchMedia;if(c)return c(b).matches;var d;return r("@media "+b+" { #"+g+" { position: absolute; } }",function(b){d=(a.getComputedStyle?getComputedStyle(b,null):b.currentStyle)["position"]=="absolute"}),d},t={}.hasOwnProperty,u;!x(t,"undefined")&&!x(t.call,"undefined")?u=function(a,b){return t.call(a,b)}:u=function(a,b){return b in a&&x(a.constructor.prototype[b],"undefined")},Function.prototype.bind||(Function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new TypeError;var d=p.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(p.call(arguments)));return Object(g)===g?g:f}return c.apply(b,d.concat(p.call(arguments)))};return e});for(var B in l)u(l,B)&&(q=B.toLowerCase(),e[q]=l[B](),o.push((e[q]?"":"no-")+q));return e.input||A(),v(""),h=j=null,function(a,b){function g(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x<style>"+b+"</style>",d.insertBefore(c.lastChild,d.firstChild)}function h(){var a=k.elements;return typeof a=="string"?a.split(" "):a}function i(a){var b={},c=a.createElement,e=a.createDocumentFragment,f=e();a.createElement=function(a){var e=(b[a]||(b[a]=c(a))).cloneNode();return k.shivMethods&&e.canHaveChildren&&!d.test(a)?f.appendChild(e):e},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+h().join().replace(/\w+/g,function(a){return b[a]=c(a),f.createElement(a),'c("'+a+'")'})+");return n}")(k,f)}function j(a){var b;return a.documentShived?a:(k.shivCSS&&!e&&(b=!!g(a,"article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio{display:none}canvas,video{display:inline-block;*display:inline;*zoom:1}[hidden]{display:none}audio[controls]{display:inline-block;*display:inline;*zoom:1}mark{background:#FF0;color:#000}")),f||(b=!i(a)),b&&(a.documentShived=b),a)}var c=a.html5||{},d=/^<|^(?:button|form|map|select|textarea)$/i,e,f;(function(){var a=b.createElement("a");a.innerHTML="<xyz></xyz>",e="hidden"in a,f=a.childNodes.length==1||function(){try{b.createElement("a")}catch(a){return!0}var c=b.createDocumentFragment();return typeof c.cloneNode=="undefined"||typeof c.createDocumentFragment=="undefined"||typeof c.createElement=="undefined"}()})();var k={elements:c.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",shivCSS:c.shivCSS!==!1,shivMethods:c.shivMethods!==!1,type:"default",shivDocument:j};a.html5=k,j(b)}(this,b),e._version=d,e.mq=s,e.testStyles=r,e}(this,this.document),function(a,b,c){function d(a){return o.call(a)=="[object Function]"}function e(a){return typeof a=="string"}function f(){}function g(a){return!a||a=="loaded"||a=="complete"||a=="uninitialized"}function h(){var a=p.shift();q=1,a?a.t?m(function(){(a.t=="c"?B.injectCss:B.injectJs)(a.s,0,a.a,a.x,a.e,1)},0):(a(),h()):q=0}function i(a,c,d,e,f,i,j){function k(b){if(!o&&g(l.readyState)&&(u.r=o=1,!q&&h(),l.onload=l.onreadystatechange=null,b)){a!="img"&&m(function(){t.removeChild(l)},50);for(var d in y[c])y[c].hasOwnProperty(d)&&y[c][d].onload()}}var j=j||B.errorTimeout,l={},o=0,r=0,u={t:d,s:c,e:f,a:i,x:j};y[c]===1&&(r=1,y[c]=[],l=b.createElement(a)),a=="object"?l.data=c:(l.src=c,l.type=a),l.width=l.height="0",l.onerror=l.onload=l.onreadystatechange=function(){k.call(this,r)},p.splice(e,0,u),a!="img"&&(r||y[c]===2?(t.insertBefore(l,s?null:n),m(k,j)):y[c].push(l))}function j(a,b,c,d,f){return q=0,b=b||"j",e(a)?i(b=="c"?v:u,a,b,this.i++,c,d,f):(p.splice(this.i++,0,a),p.length==1&&h()),this}function k(){var a=B;return a.loader={load:j,i:0},a}var l=b.documentElement,m=a.setTimeout,n=b.getElementsByTagName("script")[0],o={}.toString,p=[],q=0,r="MozAppearance"in l.style,s=r&&!!b.createRange().compareNode,t=s?l:n.parentNode,l=a.opera&&o.call(a.opera)=="[object Opera]",l=!!b.attachEvent&&!l,u=r?"object":l?"script":"img",v=l?"script":u,w=Array.isArray||function(a){return o.call(a)=="[object Array]"},x=[],y={},z={timeout:function(a,b){return b.length&&(a.timeout=b[0]),a}},A,B;B=function(a){function b(a){var a=a.split("!"),b=x.length,c=a.pop(),d=a.length,c={url:c,origUrl:c,prefixes:a},e,f,g;for(f=0;f<d;f++)g=a[f].split("="),(e=z[g.shift()])&&(c=e(c,g));for(f=0;f<b;f++)c=x[f](c);return c}function g(a,e,f,g,i){var j=b(a),l=j.autoCallback;j.url.split(".").pop().split("?").shift(),j.bypass||(e&&(e=d(e)?e:e[a]||e[g]||e[a.split("/").pop().split("?")[0]]||h),j.instead?j.instead(a,e,f,g,i):(y[j.url]?j.noexec=!0:y[j.url]=1,f.load(j.url,j.forceCSS||!j.forceJS&&"css"==j.url.split(".").pop().split("?").shift()?"c":c,j.noexec,j.attrs,j.timeout),(d(e)||d(l))&&f.load(function(){k(),e&&e(j.origUrl,i,g),l&&l(j.origUrl,i,g),y[j.url]=2})))}function i(a,b){function c(a,c){if(a){if(e(a))c||(j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}),g(a,j,b,0,h);else if(Object(a)===a)for(n in m=function(){var b=0,c;for(c in a)a.hasOwnProperty(c)&&b++;return b}(),a)a.hasOwnProperty(n)&&(!c&&!--m&&(d(j)?j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}:j[n]=function(a){return function(){var b=[].slice.call(arguments);a&&a.apply(this,b),l()}}(k[n])),g(a[n],j,b,n,h))}else!c&&l()}var h=!!a.test,i=a.load||a.both,j=a.callback||f,k=j,l=a.complete||f,m,n;c(h?a.yep:a.nope,!!i),i&&c(i)}var j,l,m=this.yepnope.loader;if(e(a))g(a,0,m,0);else if(w(a))for(j=0;j<a.length;j++)l=a[j],e(l)?g(l,0,m,0):w(l)?B(l):Object(l)===l&&i(l,m);else Object(a)===a&&i(a,m)},B.addPrefix=function(a,b){z[a]=b},B.addFilter=function(a){x.push(a)},B.errorTimeout=1e4,b.readyState==null&&b.addEventListener&&(b.readyState="loading",b.addEventListener("DOMContentLoaded",A=function(){b.removeEventListener("DOMContentLoaded",A,0),b.readyState="complete"},0)),a.yepnope=k(),a.yepnope.executeStack=h,a.yepnope.injectJs=function(a,c,d,e,i,j){var k=b.createElement("script"),l,o,e=e||B.errorTimeout;k.src=a;for(o in d)k.setAttribute(o,d[o]);c=j?h:c||f,k.onreadystatechange=k.onload=function(){!l&&g(k.readyState)&&(l=1,c(),k.onload=k.onreadystatechange=null)},m(function(){l||(l=1,c(1))},e),i?k.onload():n.parentNode.insertBefore(k,n)},a.yepnope.injectCss=function(a,c,d,e,g,i){var e=b.createElement("link"),j,c=i?h:c||f;e.href=a,e.rel="stylesheet",e.type="text/css";for(j in d)e.setAttribute(j,d[j]);g||(n.parentNode.insertBefore(e,n),m(c,0))}}(this,document),Modernizr.load=function(){yepnope.apply(window,[].slice.call(arguments,0))}; \ No newline at end of file
diff --git a/web/js/modernizr.custom.js b/web/js/modernizr.custom.js
new file mode 100644
index 000000000..c4d6ffdfc
--- /dev/null
+++ b/web/js/modernizr.custom.js
@@ -0,0 +1,4 @@
+/* Modernizr 2.5.3 (Custom Build) | MIT & BSD
+ * Build: http://www.modernizr.com/download/#-shiv-load
+ */
+;window.Modernizr=function(a,b,c){function t(a){i.cssText=a}function u(a,b){return t(prefixes.join(a+";")+(b||""))}function v(a,b){return typeof a===b}function w(a,b){return!!~(""+a).indexOf(b)}function x(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:v(f,"function")?f.bind(d||b):f}return!1}var d="2.5.3",e={},f=b.documentElement,g="modernizr",h=b.createElement(g),i=h.style,j,k={}.toString,l={},m={},n={},o=[],p=o.slice,q,r={}.hasOwnProperty,s;!v(r,"undefined")&&!v(r.call,"undefined")?s=function(a,b){return r.call(a,b)}:s=function(a,b){return b in a&&v(a.constructor.prototype[b],"undefined")},Function.prototype.bind||(Function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new TypeError;var d=p.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(p.call(arguments)));return Object(g)===g?g:f}return c.apply(b,d.concat(p.call(arguments)))};return e});for(var y in l)s(l,y)&&(q=y.toLowerCase(),e[q]=l[y](),o.push((e[q]?"":"no-")+q));return t(""),h=j=null,function(a,b){function g(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x<style>"+b+"</style>",d.insertBefore(c.lastChild,d.firstChild)}function h(){var a=k.elements;return typeof a=="string"?a.split(" "):a}function i(a){var b={},c=a.createElement,e=a.createDocumentFragment,f=e();a.createElement=function(a){var e=(b[a]||(b[a]=c(a))).cloneNode();return k.shivMethods&&e.canHaveChildren&&!d.test(a)?f.appendChild(e):e},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+h().join().replace(/\w+/g,function(a){return b[a]=c(a),f.createElement(a),'c("'+a+'")'})+");return n}")(k,f)}function j(a){var b;return a.documentShived?a:(k.shivCSS&&!e&&(b=!!g(a,"article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio{display:none}canvas,video{display:inline-block;*display:inline;*zoom:1}[hidden]{display:none}audio[controls]{display:inline-block;*display:inline;*zoom:1}mark{background:#FF0;color:#000}")),f||(b=!i(a)),b&&(a.documentShived=b),a)}var c=a.html5||{},d=/^<|^(?:button|form|map|select|textarea)$/i,e,f;(function(){var a=b.createElement("a");a.innerHTML="<xyz></xyz>",e="hidden"in a,f=a.childNodes.length==1||function(){try{b.createElement("a")}catch(a){return!0}var c=b.createDocumentFragment();return typeof c.cloneNode=="undefined"||typeof c.createDocumentFragment=="undefined"||typeof c.createElement=="undefined"}()})();var k={elements:c.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",shivCSS:c.shivCSS!==!1,shivMethods:c.shivMethods!==!1,type:"default",shivDocument:j};a.html5=k,j(b)}(this,b),e._version=d,e}(this,this.document),function(a,b,c){function d(a){return o.call(a)=="[object Function]"}function e(a){return typeof a=="string"}function f(){}function g(a){return!a||a=="loaded"||a=="complete"||a=="uninitialized"}function h(){var a=p.shift();q=1,a?a.t?m(function(){(a.t=="c"?B.injectCss:B.injectJs)(a.s,0,a.a,a.x,a.e,1)},0):(a(),h()):q=0}function i(a,c,d,e,f,i,j){function k(b){if(!o&&g(l.readyState)&&(u.r=o=1,!q&&h(),l.onload=l.onreadystatechange=null,b)){a!="img"&&m(function(){t.removeChild(l)},50);for(var d in y[c])y[c].hasOwnProperty(d)&&y[c][d].onload()}}var j=j||B.errorTimeout,l={},o=0,r=0,u={t:d,s:c,e:f,a:i,x:j};y[c]===1&&(r=1,y[c]=[],l=b.createElement(a)),a=="object"?l.data=c:(l.src=c,l.type=a),l.width=l.height="0",l.onerror=l.onload=l.onreadystatechange=function(){k.call(this,r)},p.splice(e,0,u),a!="img"&&(r||y[c]===2?(t.insertBefore(l,s?null:n),m(k,j)):y[c].push(l))}function j(a,b,c,d,f){return q=0,b=b||"j",e(a)?i(b=="c"?v:u,a,b,this.i++,c,d,f):(p.splice(this.i++,0,a),p.length==1&&h()),this}function k(){var a=B;return a.loader={load:j,i:0},a}var l=b.documentElement,m=a.setTimeout,n=b.getElementsByTagName("script")[0],o={}.toString,p=[],q=0,r="MozAppearance"in l.style,s=r&&!!b.createRange().compareNode,t=s?l:n.parentNode,l=a.opera&&o.call(a.opera)=="[object Opera]",l=!!b.attachEvent&&!l,u=r?"object":l?"script":"img",v=l?"script":u,w=Array.isArray||function(a){return o.call(a)=="[object Array]"},x=[],y={},z={timeout:function(a,b){return b.length&&(a.timeout=b[0]),a}},A,B;B=function(a){function b(a){var a=a.split("!"),b=x.length,c=a.pop(),d=a.length,c={url:c,origUrl:c,prefixes:a},e,f,g;for(f=0;f<d;f++)g=a[f].split("="),(e=z[g.shift()])&&(c=e(c,g));for(f=0;f<b;f++)c=x[f](c);return c}function g(a,e,f,g,i){var j=b(a),l=j.autoCallback;j.url.split(".").pop().split("?").shift(),j.bypass||(e&&(e=d(e)?e:e[a]||e[g]||e[a.split("/").pop().split("?")[0]]||h),j.instead?j.instead(a,e,f,g,i):(y[j.url]?j.noexec=!0:y[j.url]=1,f.load(j.url,j.forceCSS||!j.forceJS&&"css"==j.url.split(".").pop().split("?").shift()?"c":c,j.noexec,j.attrs,j.timeout),(d(e)||d(l))&&f.load(function(){k(),e&&e(j.origUrl,i,g),l&&l(j.origUrl,i,g),y[j.url]=2})))}function i(a,b){function c(a,c){if(a){if(e(a))c||(j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}),g(a,j,b,0,h);else if(Object(a)===a)for(n in m=function(){var b=0,c;for(c in a)a.hasOwnProperty(c)&&b++;return b}(),a)a.hasOwnProperty(n)&&(!c&&!--m&&(d(j)?j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}:j[n]=function(a){return function(){var b=[].slice.call(arguments);a&&a.apply(this,b),l()}}(k[n])),g(a[n],j,b,n,h))}else!c&&l()}var h=!!a.test,i=a.load||a.both,j=a.callback||f,k=j,l=a.complete||f,m,n;c(h?a.yep:a.nope,!!i),i&&c(i)}var j,l,m=this.yepnope.loader;if(e(a))g(a,0,m,0);else if(w(a))for(j=0;j<a.length;j++)l=a[j],e(l)?g(l,0,m,0):w(l)?B(l):Object(l)===l&&i(l,m);else Object(a)===a&&i(a,m)},B.addPrefix=function(a,b){z[a]=b},B.addFilter=function(a){x.push(a)},B.errorTimeout=1e4,b.readyState==null&&b.addEventListener&&(b.readyState="loading",b.addEventListener("DOMContentLoaded",A=function(){b.removeEventListener("DOMContentLoaded",A,0),b.readyState="complete"},0)),a.yepnope=k(),a.yepnope.executeStack=h,a.yepnope.injectJs=function(a,c,d,e,i,j){var k=b.createElement("script"),l,o,e=e||B.errorTimeout;k.src=a;for(o in d)k.setAttribute(o,d[o]);c=j?h:c||f,k.onreadystatechange=k.onload=function(){!l&&g(k.readyState)&&(l=1,c(),k.onload=k.onreadystatechange=null)},m(function(){l||(l=1,c(1))},e),i?k.onload():n.parentNode.insertBefore(k,n)},a.yepnope.injectCss=function(a,c,d,e,g,i){var e=b.createElement("link"),j,c=i?h:c||f;e.href=a,e.rel="stylesheet",e.type="text/css";for(j in d)e.setAttribute(j,d[j]);g||(n.parentNode.insertBefore(e,n),m(c,0))}}(this,document),Modernizr.load=function(){yepnope.apply(window,[].slice.call(arguments,0))}; \ No newline at end of file