@@ -346,14 +346,14 @@ export default {
346
346
},
347
347
displaySortLine () {
348
348
if (this .collapsedSeries ) return null
349
- if (this .orderBy === ' mtimeMs' ) return ' Modified ' + this .$formatDate (this ._libraryItem .mtimeMs , this .dateFormat )
350
- if (this .orderBy === ' birthtimeMs' ) return ' Born ' + this .$formatDate (this ._libraryItem .birthtimeMs , this .dateFormat )
351
- if (this .orderBy === ' addedAt' ) return ' Added ' + this .$formatDate (this ._libraryItem .addedAt , this .dateFormat )
352
- if (this .orderBy === ' media.duration' ) return ' Duration : ' + this .$elapsedPrettyExtended (this .media .duration , false )
353
- if (this .orderBy === ' size' ) return ' Size : ' + this .$bytesPretty (this ._libraryItem .size )
354
- if (this .orderBy === ' media.numTracks' ) return ` ${ this .numEpisodes } Episodes `
349
+ if (this .orderBy === ' mtimeMs' ) return this . $getString ( ' LabelFileModifiedDate ' , [ this .$formatDate (this ._libraryItem .mtimeMs , this .dateFormat )] )
350
+ if (this .orderBy === ' birthtimeMs' ) return this . $getString ( ' LabelFileBornDate ' , [ this .$formatDate (this ._libraryItem .birthtimeMs , this .dateFormat )] )
351
+ if (this .orderBy === ' addedAt' ) return this . $getString ( ' LabelAddedDate ' , [ this .$formatDate (this ._libraryItem .addedAt , this .dateFormat )] )
352
+ if (this .orderBy === ' media.duration' ) return this . $strings . LabelDuration + ' : ' + this .$elapsedPrettyExtended (this .media .duration , false )
353
+ if (this .orderBy === ' size' ) return this . $strings . LabelSize + ' : ' + this .$bytesPretty (this ._libraryItem .size )
354
+ if (this .orderBy === ' media.numTracks' ) return ` ${ this .numEpisodes } ` + this . $strings . LabelEpisodes
355
355
if (this .orderBy === ' media.metadata.publishedYear' ) {
356
- if (this .mediaMetadata .publishedYear ) return ' Published ' + this .mediaMetadata .publishedYear
356
+ if (this .mediaMetadata .publishedYear ) return this . $getString ( ' LabelPublishedDate ' , [ this .mediaMetadata .publishedYear ])
357
357
return ' \u00A0 '
358
358
}
359
359
return null
@@ -710,7 +710,7 @@ export default {
710
710
toggleFinished (confirmed = false ) {
711
711
if (! this .itemIsFinished && this .userProgressPercent > 0 && ! confirmed) {
712
712
const payload = {
713
- message: ` Are you sure you want to mark " ${ this .displayTitle } " as finished? ` ,
713
+ message: this . $getString ( ' MessageConfirmMarkItemFinished ' , [ this .displayTitle ]) ,
714
714
callback : (confirmed ) => {
715
715
if (confirmed) {
716
716
this .toggleFinished (true )
@@ -755,18 +755,18 @@ export default {
755
755
.then ((data ) => {
756
756
var result = data .result
757
757
if (! result) {
758
- this .$toast .error (` Re-Scan Failed for " ${ this .title } " ` )
758
+ this .$toast .error (this . $getString ( ' ToastRescanFailed ' , [ this .displayTitle ]) )
759
759
} else if (result === ' UPDATED' ) {
760
- this .$toast .success (` Re-Scan complete item was updated ` )
760
+ this .$toast .success (this . $strings . ToastRescanUpdated )
761
761
} else if (result === ' UPTODATE' ) {
762
- this .$toast .success (` Re-Scan complete item was up to date ` )
762
+ this .$toast .success (this . $strings . ToastRescanUpToDate )
763
763
} else if (result === ' REMOVED' ) {
764
- this .$toast .error (` Re-Scan complete item was removed ` )
764
+ this .$toast .error (this . $strings . ToastRescanRemoved )
765
765
}
766
766
})
767
767
.catch ((error ) => {
768
768
console .error (' Failed to scan library item' , error)
769
- this .$toast .error (' Failed to scan library item ' )
769
+ this .$toast .error (this . $strings . ToastScanFailed )
770
770
})
771
771
.finally (() => {
772
772
this .processing = false
@@ -823,7 +823,7 @@ export default {
823
823
})
824
824
.catch ((error ) => {
825
825
console .error (' Failed to remove series from home' , error)
826
- this .$toast .error (' Failed to update user ' )
826
+ this .$toast .error (this . $strings . ToastFailedToUpdateUser )
827
827
})
828
828
.finally (() => {
829
829
this .processing = false
@@ -841,7 +841,7 @@ export default {
841
841
})
842
842
.catch ((error ) => {
843
843
console .error (' Failed to hide item from home' , error)
844
- this .$toast .error (' Failed to update user ' )
844
+ this .$toast .error (this . $strings . ToastFailedToUpdateUser )
845
845
})
846
846
.finally (() => {
847
847
this .processing = false
@@ -856,7 +856,7 @@ export default {
856
856
episodeId: this .recentEpisode .id ,
857
857
title: this .recentEpisode .title ,
858
858
subtitle: this .mediaMetadata .title ,
859
- caption: this .recentEpisode .publishedAt ? ` Published ${ this .$formatDate (this .recentEpisode .publishedAt , this .dateFormat )} ` : ' Unknown publish date ' ,
859
+ caption: this .recentEpisode .publishedAt ? this . $getString ( ' LabelPublishedDate ' , [ this .$formatDate (this .recentEpisode .publishedAt , this .dateFormat )]) : this . $strings . LabelUnknownPublishDate ,
860
860
duration: this .recentEpisode .audioFile .duration || null ,
861
861
coverPath: this .media .coverPath || null
862
862
}
@@ -906,11 +906,11 @@ export default {
906
906
axios
907
907
.$delete (` /api/items/${ this .libraryItemId } ?hard=${ hardDelete ? 1 : 0 } ` )
908
908
.then (() => {
909
- this .$toast .success (' Item deleted ' )
909
+ this .$toast .success (this . $strings . ToastItemDeletedSuccess )
910
910
})
911
911
.catch ((error ) => {
912
912
console .error (' Failed to delete item' , error)
913
- this .$toast .error (' Failed to delete item ' )
913
+ this .$toast .error (this . $strings . ToastItemDeletedFailed )
914
914
})
915
915
.finally (() => {
916
916
this .processing = false
@@ -1016,7 +1016,7 @@ export default {
1016
1016
episodeId: episode .id ,
1017
1017
title: episode .title ,
1018
1018
subtitle: this .mediaMetadata .title ,
1019
- caption: episode .publishedAt ? ` Published ${ this .$formatDate (episode .publishedAt , this .dateFormat )} ` : ' Unknown publish date ' ,
1019
+ caption: episode .publishedAt ? this . $getString ( ' LabelPublishedDate ' , [ this .$formatDate (episode .publishedAt , this .dateFormat )]) : this . $strings . LabelUnknownPublishDate ,
1020
1020
duration: episode .audioFile .duration || null ,
1021
1021
coverPath: this .media .coverPath || null
1022
1022
})
0 commit comments