aboutsummaryrefslogtreecommitdiff
path: root/app/components/comment.js
diff options
context:
space:
mode:
authorBen Beltran <ben@nsovocal.com>2017-01-31 00:53:36 -0600
committerBen Beltran <ben@nsovocal.com>2017-01-31 00:53:36 -0600
commita3f9e2603dfdf8c492ec0dc355cd434fc6100f06 (patch)
tree52c84831a3a6070e3e01c5ada5b862fd56f28327 /app/components/comment.js
parent7eb26514c478cfa06a797e9d63a29ef6a6d16d59 (diff)
parentf74591da2d5c42b8a1e658d17310e604bedcf856 (diff)
Merge branch 'release/1.0.0'HEADmain
Diffstat (limited to 'app/components/comment.js')
-rw-r--r--app/components/comment.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/app/components/comment.js b/app/components/comment.js
new file mode 100644
index 0000000..33ce2c7
--- /dev/null
+++ b/app/components/comment.js
@@ -0,0 +1,17 @@
+import Vue from 'vue';
+
+const internals = {};
+
+export default internals.CommentComponent = Vue.component('comment', {
+ template: '<article class="comment">' +
+ '<aside class="comment-meta">' +
+ '<img :src="comment.userImage" v-bind:alt="\'Avatar for @\' + comment.userId">' +
+ '<a v-bind:href="\'https://twitter.com/\' + comment.userId">{{comment.userName}}</a> said on ' +
+ '<time v-bind:datetime="comment.timestamp | datetime">{{comment.timestamp | usertime}}</time>' +
+ '</aside>' +
+ '<div class="comment-content">{{comment.content}}</div>' +
+ '</article>',
+
+ props: ['comment']
+});
+