Add sponsoring slots on home, dashboard and about pages
This commit is contained in:
@@ -158,14 +158,6 @@
|
|||||||
.summary .fromShare {
|
.summary .fromShare {
|
||||||
margin-bottom: 3em;
|
margin-bottom: 3em;
|
||||||
}
|
}
|
||||||
.summary .apiTip {
|
|
||||||
font-size: 0.8em;
|
|
||||||
margin-bottom: 4em;
|
|
||||||
color: #413;
|
|
||||||
}
|
|
||||||
.summary .apiTip a {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
.summary .tweet .tweetText {
|
.summary .tweet .tweetText {
|
||||||
color: #413;
|
color: #413;
|
||||||
background: #F2F2F2;
|
background: #F2F2F2;
|
||||||
@@ -189,3 +181,11 @@
|
|||||||
.summary .tweet input {
|
.summary .tweet input {
|
||||||
font-size: 0.9em;
|
font-size: 0.9em;
|
||||||
}
|
}
|
||||||
|
.summary .sponsor {
|
||||||
|
font-size: 0.9em;
|
||||||
|
margin-bottom: 4em;
|
||||||
|
color: #413;
|
||||||
|
}
|
||||||
|
.summary .sponsor a {
|
||||||
|
color: inherit;
|
||||||
|
}
|
||||||
|
|||||||
@@ -177,3 +177,6 @@ input[type=submit].clicked {
|
|||||||
top: 0.2em;
|
top: 0.2em;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
|
.homeSponsor {
|
||||||
|
margin-top: 3em;
|
||||||
|
}
|
||||||
|
|||||||
@@ -295,6 +295,9 @@ a.linkButton {
|
|||||||
.footer .github {
|
.footer .github {
|
||||||
margin: 1em 0 0 0.5em;
|
margin: 1em 0 0 0.5em;
|
||||||
}
|
}
|
||||||
|
.footer .sponsor {
|
||||||
|
font-size: 0.9em;
|
||||||
|
}
|
||||||
[class^="icon-"]:before,
|
[class^="icon-"]:before,
|
||||||
[class*=" icon-"]:before {
|
[class*=" icon-"]:before {
|
||||||
vertical-align: baseline;
|
vertical-align: baseline;
|
||||||
|
|||||||
@@ -158,15 +158,6 @@
|
|||||||
margin-bottom: 3em;
|
margin-bottom: 3em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.summary .apiTip {
|
|
||||||
font-size: 0.8em;
|
|
||||||
margin-bottom: 4em;
|
|
||||||
color: #413;
|
|
||||||
a {
|
|
||||||
color: inherit;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.summary .tweet {
|
.summary .tweet {
|
||||||
.tweetText {
|
.tweetText {
|
||||||
color: #413;
|
color: #413;
|
||||||
@@ -190,3 +181,12 @@
|
|||||||
font-size: 0.9em;
|
font-size: 0.9em;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.summary .sponsor {
|
||||||
|
font-size: 0.9em;
|
||||||
|
margin-bottom: 4em;
|
||||||
|
color: #413;
|
||||||
|
a {
|
||||||
|
color: inherit;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -200,3 +200,7 @@ input[type=submit].clicked {
|
|||||||
top: 0.2em;
|
top: 0.2em;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.homeSponsor {
|
||||||
|
margin-top: 3em;
|
||||||
|
}
|
||||||
@@ -250,6 +250,9 @@ a.linkButton {
|
|||||||
.github {
|
.github {
|
||||||
margin: 1em 0 0 0.5em;
|
margin: 1em 0 0 0.5em;
|
||||||
}
|
}
|
||||||
|
.sponsor {
|
||||||
|
font-size: 0.9em;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[class^="icon-"]:before, [class*=" icon-"]:before {
|
[class^="icon-"]:before, [class*=" icon-"]:before {
|
||||||
|
|||||||
@@ -5,5 +5,9 @@
|
|||||||
|
|
||||||
<p>By the way, <b>it's free</b> because we are geeks, not businessmen. All we want is <a href="https://github.com/gmetais/YellowLabTools" target="_blank" class="star">a <span>★</span> on GitHub</a>. It will boost our motivation to add more awesome features!!!</p>
|
<p>By the way, <b>it's free</b> because we are geeks, not businessmen. All we want is <a href="https://github.com/gmetais/YellowLabTools" target="_blank" class="star">a <span>★</span> on GitHub</a>. It will boost our motivation to add more awesome features!!!</p>
|
||||||
|
|
||||||
|
<%if (sponsoring.about) { %>
|
||||||
|
<div class="sponsor"><%- sponsoring.about %></div>
|
||||||
|
<% } %>
|
||||||
|
|
||||||
<p><br><a href="<%= baseUrl %>">Back to index</a></p>
|
<p><br><a href="<%= baseUrl %>">Back to index</a></p>
|
||||||
</div>
|
</div>
|
||||||
@@ -55,9 +55,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div ng-if="!error && !fromSocialShare" class="apiTip">
|
<%if (sponsoring.dashboard) { %>
|
||||||
<b>Did you know?</b> You can <b>bookmark</b> this result page URL or <b>share it</b>, Yellow Lab Tools keeps test results for years!
|
<div ng-if="!error && !fromSocialShare" class="sponsor"><%- sponsoring.dashboard %></div>
|
||||||
</div>
|
<% } %>
|
||||||
|
|
||||||
|
|
||||||
<div class="tweet" ng-if="!error && !fromSocialShare">
|
<div class="tweet" ng-if="!error && !fromSocialShare">
|
||||||
<form ng-submit="sendTweet()">
|
<form ng-submit="sendTweet()">
|
||||||
|
|||||||
@@ -110,3 +110,7 @@
|
|||||||
<p>Untangles the JavaScript spaghetti code</p>
|
<p>Untangles the JavaScript spaghetti code</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<%if (sponsoring.home) { %>
|
||||||
|
<div class="homeSponsor"><%- sponsoring.home %></div>
|
||||||
|
<% } %>
|
||||||
@@ -1,6 +1,8 @@
|
|||||||
var path = require('path');
|
var path = require('path');
|
||||||
var express = require('express');
|
var express = require('express');
|
||||||
|
|
||||||
|
var serverSettings = (process.env.IS_TEST) ? require('../../../test/fixtures/settings.json') : require('../../../server_config/settings.json');
|
||||||
|
|
||||||
var FrontController = function(app) {
|
var FrontController = function(app) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
@@ -23,7 +25,8 @@ var FrontController = function(app) {
|
|||||||
app.get('/views/:viewName', function(req, res) {
|
app.get('/views/:viewName', function(req, res) {
|
||||||
res.setHeader('Cache-Control', 'public, max-age=' + cacheDuration);
|
res.setHeader('Cache-Control', 'public, max-age=' + cacheDuration);
|
||||||
res.render(path.join(__dirname, assetsPath, 'views/' + req.params.viewName), {
|
res.render(path.join(__dirname, assetsPath, 'views/' + req.params.viewName), {
|
||||||
baseUrl: app.locals.baseUrl || '/'
|
baseUrl: app.locals.baseUrl || '/',
|
||||||
|
sponsoring: serverSettings.sponsoring || {}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -9,5 +9,11 @@
|
|||||||
},
|
},
|
||||||
"maxAnonymousRunsPerDay": 99999999,
|
"maxAnonymousRunsPerDay": 99999999,
|
||||||
"maxAnonymousCallsPerDay": 99999999,
|
"maxAnonymousCallsPerDay": 99999999,
|
||||||
"blockedUrls": []
|
"blockedUrls": [],
|
||||||
|
|
||||||
|
"sponsoring" : {
|
||||||
|
"home": "(this is a private instance)",
|
||||||
|
"dashboard": null,
|
||||||
|
"about": "(this is a private instance)"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -9,5 +9,11 @@
|
|||||||
},
|
},
|
||||||
"maxAnonymousRunsPerDay": 99999999,
|
"maxAnonymousRunsPerDay": 99999999,
|
||||||
"maxAnonymousCallsPerDay": 99999999,
|
"maxAnonymousCallsPerDay": 99999999,
|
||||||
"blockedUrls": []
|
"blockedUrls": [],
|
||||||
|
|
||||||
|
"sponsoring" : {
|
||||||
|
"home": "(this is a private instance)",
|
||||||
|
"dashboard": null,
|
||||||
|
"about": "(this is a private instance)"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user