aboutsummaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
Diffstat (limited to 'web')
-rw-r--r--web/cobrands/fixmystreet/header.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/web/cobrands/fixmystreet/header.js b/web/cobrands/fixmystreet/header.js
index 170073ce3..668273078 100644
--- a/web/cobrands/fixmystreet/header.js
+++ b/web/cobrands/fixmystreet/header.js
@@ -1,22 +1,18 @@
// A minimized version of this is inline in the header.
var fixmystreet = fixmystreet || {};
+fixmystreet.page = '[% page %]';
+fixmystreet.cobrand = '[% c.cobrand.moniker %]';
(function(D){
var E = D.documentElement;
E.className = E.className.replace(/\bno-js\b/, 'js');
var ie8 = E.className.indexOf('ie8') > -1;
var type = Modernizr.mq('(min-width: 48em)') || ie8 ? 'desktop' : 'mobile';
- var meta = D.getElementById('js-meta-data');
if ('IntersectionObserver' in window) {
E.className += ' lazyload';
}
- fixmystreet.page = meta.getAttribute('data-page');
- fixmystreet.cobrand = meta.getAttribute('data-cobrand');
if (type == 'mobile') {
- E.className += ' mobile';
- if (fixmystreet.page == 'around') {
- E.className += ' map-fullscreen only-map map-reporting';
- }
+ E.className += ' mobile[% " map-fullscreen only-map map-reporting" IF page == "around" %]';
}
})(document);