Add the ability to have a site-wide message

This commit is contained in:
Rowan Manning
2013-11-15 16:27:13 +00:00
parent 98bd9ed208
commit 7a1160b257
3 changed files with 13 additions and 1 deletions

View File

@@ -54,6 +54,9 @@ The boot configurations for pa11y-dashboard are as follows. Look at the sample J
### readonly
*(boolean)* If set to `true`, users will not be able to add, delete or run URLs (defaults to `false`).
### siteMessage
*(string)* A message to display prominently on the site home page. Defaults to `null`.
Development
-----------

3
app.js
View File

@@ -54,7 +54,8 @@ function initApp (config, callback) {
repo: pkg.homepage,
bugtracker: pkg.bugs,
noindex: config.noindex,
readonly: config.readonly
readonly: config.readonly,
siteMessage: config.siteMessage
});
app.express.use(function (req, res, next) {

View File

@@ -1,5 +1,13 @@
{{#content "title"}}pa11y-dashboard{{/content}}
{{#if siteMessage}}
<div class="col-md-12 clearfix">
<div class="alert alert-info">
<p>{{siteMessage}}</p>
</div>
</div>
{{/if}}
{{#deleted}}
<div class="col-md-12 clearfix">
<div class="alert alert-info">