From 30066ee8d894c9337dbb71c511fa78903fb19967 Mon Sep 17 00:00:00 2001 From: ppoffice Date: Fri, 5 Jul 2019 00:50:52 -0400 Subject: [PATCH] chore(comment): add an option for gitalk --- includes/specs/comment.spec.js | 6 ++++++ layout/comment/gitalk.ejs | 1 + 2 files changed, 7 insertions(+) diff --git a/includes/specs/comment.spec.js b/includes/specs/comment.spec.js index 78784af..da78521 100644 --- a/includes/specs/comment.spec.js +++ b/includes/specs/comment.spec.js @@ -59,6 +59,12 @@ const GitmentGitalkSpec = { [required]: true } }, + create_issue_manually: { + [type]: 'boolean', + [doc]: 'Create GitHub issue manually for each page', + [defaultValue]: false, + [requires]: comment => comment.type === 'gitalk' + }, distraction_free_mode: { [type]: 'boolean', [doc]: 'Facebook-like distraction free mode', diff --git a/layout/comment/gitalk.ejs b/layout/comment/gitalk.ejs index 1817e40..69f44fe 100644 --- a/layout/comment/gitalk.ejs +++ b/layout/comment/gitalk.ejs @@ -16,6 +16,7 @@ repo: '<%= get_config('comment.repo') %>', owner: '<%= get_config('comment.owner') %>', admin: <%- JSON.stringify(get_config('comment.admin'))%>, + createIssueManually: <%= get_config('comment.create_issue_manually', false) %>, distractionFreeMode: <%= get_config('comment.distraction_free_mode', false) %> }) gitalk.render('comment-container')