master
rob 2 years ago
parent abb20bcaf6
commit df0637b62c

@ -4,7 +4,7 @@ mixin renderCommentComposer (actionUrl, options = { })
if options.replyTo if options.replyTo
input(type="hidden", name="replyTo", value= options.replyTo) input(type="hidden", name="replyTo", value= options.replyTo)
.uk-card.uk-card-secondary.uk-card-small .uk-card.uk-card-default.uk-card-small
.uk-card-body .uk-card-body
textarea( textarea(
id="content", id="content",
@ -28,7 +28,7 @@ mixin renderCommentComposer (actionUrl, options = { })
data-target-element="content", data-target-element="content",
title="Add an emoji", title="Add an emoji",
onclick="return dtp.app.showEmojiPicker(event);", onclick="return dtp.app.showEmojiPicker(event);",
).uk-button.dtp-button-default ).uk-button.uk-button-default
span span
i.far.fa-smile i.far.fa-smile
li(title="Not Safe For Work will hide your comment text by default") li(title="Not Safe For Work will hide your comment text by default")
@ -38,6 +38,6 @@ mixin renderCommentComposer (actionUrl, options = { })
if options.showCancel if options.showCancel
.uk-width-auto .uk-width-auto
button(type="submit").uk-button.dtp-button-secondary Cancel button(type="submit").uk-button.uk-button-secondary Cancel
.uk-width-auto .uk-width-auto
button(type="submit").uk-button.dtp-button-primary Post button(type="submit").uk-button.uk-button-primary Post

@ -3,7 +3,7 @@ block content
include ../components/page-sidebar include ../components/page-sidebar
article(dtp-page-id= page._id) article(dtp-page-id= page._id).content-block
.uk-margin .uk-margin
div(uk-grid) div(uk-grid)
.uk-width-expand .uk-width-expand

@ -14,7 +14,7 @@ block content
include components/author-credit include components/author-credit
article(dtp-post-id= post._id) article(dtp-post-id= post._id).content-block
.uk-margin .uk-margin
h1.article-title= post.title h1.article-title= post.title
@ -52,26 +52,29 @@ block content
.uk-margin .uk-margin
.uk-article-meta This post was updated on #{moment(post.updated).format('MMMM DD, YYYY, [at] hh:mm a')}. .uk-article-meta This post was updated on #{moment(post.updated).format('MMMM DD, YYYY, [at] hh:mm a')}.
.content-block
.uk-margin .uk-margin
h4 Post author +renderSectionTitle('Post author')
+renderPostAuthorCredit(post.author) +renderPostAuthorCredit(post.author)
if user && post.flags.enableComments && user.permissions.canComment if user && post.flags.enableComments && user.permissions.canComment
+renderSectionTitle('Add a comment') .content-block
.uk-margin
.uk-margin +renderSectionTitle('Add a comment')
+renderCommentComposer(`/post/${post._id}/comment`) .uk-margin-small
+renderCommentComposer(`/post/${post._id}/comment`)
.uk-text-small.uk-text-muted Each site has it's own #[a(href='/policy/terms-of-service') Terms of Service]. Please read it before commenting.
if featuredComment if featuredComment
#featured-comment.uk-margin-large .content-block
.uk-margin #featured-comment.uk-margin-large
+renderSectionTitle('Linked Comment') .uk-margin
+renderComment(featuredComment) +renderSectionTitle('Linked Comment')
+renderComment(featuredComment)
.uk-margin .content-block
+renderSectionTitle('Comments') +renderSectionTitle('Comments')
.uk-margin
if Array.isArray(comments) && (comments.length > 0) if Array.isArray(comments) && (comments.length > 0)
ul#post-comment-list.uk-list.uk-list-divider.uk-list-large ul#post-comment-list.uk-list.uk-list-divider.uk-list-large
+renderCommentList(comments, { countPerPage, rootUrl: `/post/${post.slug}/comment` }) +renderCommentList(comments, { countPerPage, rootUrl: `/post/${post.slug}/comment` })

Loading…
Cancel
Save