diff --git a/include/util/console.js b/include/util/console.js index edf0926..22e8dc4 100644 --- a/include/util/console.js +++ b/include/util/console.js @@ -1,6 +1,6 @@ let chalk; try { - chalk = require('chalk'); + chalk = require('chalk'); // eslint-disable-line node/no-extraneous-require } catch (e) { } module.exports = new Proxy({}, { @@ -8,8 +8,8 @@ module.exports = new Proxy({}, { if (chalk) { return chalk[prop]; } - return function () { + return function() { return arguments.length === 1 ? arguments[0] : arguments; - }.bind(obj); + }; } }); diff --git a/layout/common/article-media.jsx b/layout/common/article-media.jsx index 9f05fb5..9ce8751 100644 --- a/layout/common/article-media.jsx +++ b/layout/common/article-media.jsx @@ -20,7 +20,7 @@ module.exports = class extends Component { : null}

-

{title}

+

{title}

{categoryTags.length ? categoryTags : null}

; diff --git a/layout/common/article.jsx b/layout/common/article.jsx index 8004e7d..f8afe6b 100644 --- a/layout/common/article.jsx +++ b/layout/common/article.jsx @@ -66,7 +66,7 @@ module.exports = class extends Component { : null} {/* Title */} -

+

{index ? {page.title} : page.title}

{/* Content/Excerpt */} @@ -79,7 +79,7 @@ module.exports = class extends Component { })} : null} {/* "Read more" button */} - {index && page.excerpt ? {__('article.more')} : null} + {index && page.excerpt ? {__('article.more')} : null} {/* Share button */} {!index ? : null} diff --git a/layout/common/comment.jsx b/layout/common/comment.jsx index 638703f..26860b0 100644 --- a/layout/common/comment.jsx +++ b/layout/common/comment.jsx @@ -12,7 +12,7 @@ module.exports = class extends Component { return
-

{__('article.comments')}

+

{__('article.comments')}

{(() => { try { const Comment = require('../comment/' + comment.type); diff --git a/layout/common/footer.jsx b/layout/common/footer.jsx index a524dc3..12f20a5 100644 --- a/layout/common/footer.jsx +++ b/layout/common/footer.jsx @@ -36,7 +36,7 @@ class Footer extends Component { {Object.keys(links).map(name => { const link = links[name]; return

- + {link.icon ? : name}

; diff --git a/layout/misc/paginator.jsx b/layout/misc/paginator.jsx index 4da1497..7bb2df5 100644 --- a/layout/misc/paginator.jsx +++ b/layout/misc/paginator.jsx @@ -27,12 +27,12 @@ module.exports = class extends Component { for (const i of range) { if (l) { if (i - l === 2) { - elements.push(
  • {l + 1}
  • ); + elements.push(
  • {l + 1}
  • ); } else if (i - l !== 1) { - elements.push(
  • ); + elements.push(
  • ); } } - elements.push(
  • {i}
  • ); + elements.push(
  • {i}
  • ); l = i; } return elements; diff --git a/layout/widget/profile.jsx b/layout/widget/profile.jsx index 4513ab6..d0ffc9a 100644 --- a/layout/widget/profile.jsx +++ b/layout/widget/profile.jsx @@ -9,7 +9,7 @@ class Profile extends Component { } return
    {links.filter(link => typeof link === 'object').map(link => { - return {'icon' in link ? : link.name} ; @@ -32,14 +32,14 @@ class Profile extends Component { return