diff --git a/src/renderer/components/watch-video-comments/watch-video-comments.css b/src/renderer/components/watch-video-comments/watch-video-comments.css
index 86f49e5d..ddb33846 100644
--- a/src/renderer/components/watch-video-comments/watch-video-comments.css
+++ b/src/renderer/components/watch-video-comments/watch-video-comments.css
@@ -12,6 +12,10 @@
text-align: center;
}
+.commentSort {
+ float: right;
+}
+
.comment {
padding: 15px;
position: relative;
diff --git a/src/renderer/components/watch-video-comments/watch-video-comments.js b/src/renderer/components/watch-video-comments/watch-video-comments.js
index 69dda7c7..a318bd37 100644
--- a/src/renderer/components/watch-video-comments/watch-video-comments.js
+++ b/src/renderer/components/watch-video-comments/watch-video-comments.js
@@ -2,14 +2,17 @@ import Vue from 'vue'
import { mapActions } from 'vuex'
import FtCard from '../ft-card/ft-card.vue'
import FtLoader from '../../components/ft-loader/ft-loader.vue'
-import CommentScraper from 'yt-comment-scraper'
+import FtSelect from '../../components/ft-select/ft-select.vue'
import FtTimestampCatcher from '../../components/ft-timestamp-catcher/ft-timestamp-catcher.vue'
+import CommentScraper from 'yt-comment-scraper'
+
export default Vue.extend({
name: 'WatchVideoComments',
components: {
'ft-card': FtCard,
'ft-loader': FtLoader,
+ 'ft-select': FtSelect,
'ft-timestamp-catcher': FtTimestampCatcher
},
props: {
@@ -38,13 +41,34 @@ export default Vue.extend({
invidiousInstance: function () {
return this.$store.getters.getInvidiousInstance
+ },
+
+ sortNames: function () {
+ return [
+ this.$t('Comments.Top comments'),
+ this.$t('Comments.Newest first')
+ ]
+ },
+
+ sortValues: function () {
+ return [
+ 'top',
+ 'newest'
+ ]
}
},
methods: {
- onTimestamp: function(timestamp) {
+ onTimestamp: function (timestamp) {
this.$emit('timestamp-event', timestamp)
},
+ handleSortChange: function (sortType) {
+ console.log(sortType)
+ this.showToast({
+ message: 'Not currently implemented'
+ })
+ },
+
getCommentData: function () {
this.isLoading = true
switch (this.backendPreference) {
diff --git a/src/renderer/components/watch-video-comments/watch-video-comments.vue b/src/renderer/components/watch-video-comments/watch-video-comments.vue
index d3594d79..a8ce3b32 100644
--- a/src/renderer/components/watch-video-comments/watch-video-comments.vue
+++ b/src/renderer/components/watch-video-comments/watch-video-comments.vue
@@ -17,6 +17,15 @@
>
{{ $t("Comments.Click to View Comments") }}
+