diff --git a/src/renderer/components/ft-search-filters/ft-search-filters.js b/src/renderer/components/ft-search-filters/ft-search-filters.js index 56b55fea..49a66d3b 100644 --- a/src/renderer/components/ft-search-filters/ft-search-filters.js +++ b/src/renderer/components/ft-search-filters/ft-search-filters.js @@ -10,28 +10,12 @@ export default Vue.extend({ }, data: function () { return { - sortByTitle: 'Sort By', - sortByLabels: [ - 'Most Relevant', - 'Rating', - 'Upload Date', - 'View Count' - ], sortByValues: [ 'relevance', 'rating', 'upload_date', 'view_count' ], - timeTitle: 'Time', - timeLabels: [ - 'Any Time', - 'Last Hour', - 'Today', - 'This Week', - 'This Month', - 'This Year' - ], timeValues: [ '', 'hour', @@ -40,25 +24,12 @@ export default Vue.extend({ 'month', 'year' ], - typeTitle: 'Type', - typeLabels: [ - 'All Types', - 'Videos', - 'Channels', - 'Playlists' - ], typeValues: [ 'all', 'video', 'channel', 'playlist' ], - durationTitle: 'Duration', - durationLabels: [ - 'All Durations', - 'Short (< 4 minutes)', - 'Long (> 20 minutes)' - ], durationValues: [ '', 'short', @@ -69,6 +40,43 @@ export default Vue.extend({ computed: { searchSettings: function () { return this.$store.getters.getSearchSettings + }, + + sortByLabels: function () { + return [ + this.$t('Search Filters.Sort By.Most Relevant'), + this.$t('Search Filters.Sort By.Rating'), + this.$t('Search Filters.Sort By.Upload Date'), + this.$t('Search Filters.Sort By.View Count') + ] + }, + + timeLabels: function () { + return [ + this.$t('Search Filters.Time.Any Time'), + this.$t('Search Filters.Time.Last Hour'), + this.$t('Search Filters.Time.Today'), + this.$t('Search Filters.Time.This Week'), + this.$t('Search Filters.Time.This Month'), + this.$t('Search Filters.Time.This Year') + ] + }, + + typeLabels: function () { + return [ + this.$t('Search Filters.Type.All Types'), + this.$t('Search Filters.Type.Videos'), + this.$t('Search Filters.Type.Channels'), + this.$t('Playlists') + ] + }, + + durationLabels: function () { + return [ + this.$t('Search Filters.Duration.All Durations'), + this.$t('Search Filters.Duration.Short (< 4 minutes)'), + this.$t('Search Filters.Duration.Long (> 20 minutes)') + ] } }, methods: { diff --git a/src/renderer/components/ft-search-filters/ft-search-filters.vue b/src/renderer/components/ft-search-filters/ft-search-filters.vue index e641548b..8b35d107 100644 --- a/src/renderer/components/ft-search-filters/ft-search-filters.vue +++ b/src/renderer/components/ft-search-filters/ft-search-filters.vue @@ -1,32 +1,32 @@