@@ -81,14 +81,19 @@ export const getPosterQuery =
81
81
} satisfies ImageQuery ;
82
82
} ;
83
83
84
- const i18n = useI18n ( 'common' , 'tag' ) ;
84
+ const i18n = useI18n ( 'common' ) ;
85
+
86
+ const i18nEpisode = i18n ( 'episode' , 'common' , 'tag' ) ;
87
+ const i18nSeason = i18n ( 'season' , 'common' , 'tag' ) ;
88
+ const openInEpisode = i18n ( 'open_episode_in_trakt' , 'common' , 'tooltip' ) ;
89
+ const openInSeason = i18n ( 'open_season_in_trakt' , 'common' , 'tooltip' ) ;
90
+
85
91
export const getTags = ( item : Pick < ListScrollSourceItem , 'episode' | 'season' > , type : ListScrollItem [ 'type' ] ) : ListScrollItem [ 'tags' ] => {
86
92
const tags : ListScrollItem [ 'tags' ] = [ ] ;
87
93
if ( type === 'episode' && item . episode ) {
88
94
tags . push ( {
89
- label : `${ i18n ( 'season' ) } ${ item . episode . season . toString ( ) . padStart ( 2 , '0' ) } ${ i18n ( 'episode' ) } ${ item . episode . number
90
- . toString ( )
91
- . padStart ( 2 , '0' ) } `,
95
+ label : `${ i18nSeason } ${ item . episode . season . toString ( ) . padStart ( 2 , '0' ) } ${ i18nEpisode } ${ item . episode . number . toString ( ) . padStart ( 2 , '0' ) } ` ,
96
+ title : openInEpisode ,
92
97
type : 'warning' ,
93
98
bordered : true ,
94
99
url : ResolveExternalLinks . search ( {
@@ -113,7 +118,8 @@ export const getTags = (item: Pick<ListScrollSourceItem, 'episode' | 'season'>,
113
118
}
114
119
} else if ( type === 'season' && item . season ) {
115
120
tags . push ( {
116
- label : `Season ${ item . season . number . toString ( ) . padStart ( 2 , '0' ) } ` ,
121
+ label : `${ i18nSeason } ${ item . season . number . toString ( ) . padStart ( 2 , '0' ) } ` ,
122
+ title : openInSeason ,
117
123
type : 'warning' ,
118
124
url : ResolveExternalLinks . search ( {
119
125
type : 'season' ,
0 commit comments