X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=lib%2Ftemplate-helper.js;h=7e51bcfbb9058a25287bf934978d9234b368bf80;hb=c7fb39b664bc0a7eaf310c2ae7666e3cf26824bf;hp=2a218f88020c3542a5bc24dffe849293f748c76b;hpb=a2c0e2fc57bb8f25f694e16eb4e51d6970b28829;p=squeep-html-template-helper diff --git a/lib/template-helper.js b/lib/template-helper.js index 2a218f8..7e51bcf 100644 --- a/lib/template-helper.js +++ b/lib/template-helper.js @@ -15,7 +15,7 @@ const { lazy } = require('@squeep/lazy-property'); const initContext = (ctx) => { ctx.errors = []; ctx.notifications = []; -} +}; /** * Some fields may have values outside normal dates, handle them here. @@ -100,7 +100,7 @@ const timeElement = (date, options = {}) => { dateFormat(date, pInf, nInf, otherwise), '', ].join(''); -} +}; /** @@ -118,7 +118,7 @@ const secondsToPeriod = (seconds) => { result.push(`${r} ${label}${r != 1 ? 's' : ''}`); } value = factor ? Math.floor(value / factor) : value; - } + }; nextResult(60, 'second'); nextResult(60, 'minute'); @@ -160,8 +160,8 @@ function htmlHead(pagePathLevel, ctx, options) { return `\t \t\t \t\t -\t\t -\t\t +\t\t +\t\t ${headElements.map((e) => '\t\t' + e).join('\n')} \t\t${pageTitle} \t`;