diff --git a/src/i18n/locales/en.json b/src/i18n/locales/en.json index b8dba4dd..954e3a9e 100644 --- a/src/i18n/locales/en.json +++ b/src/i18n/locales/en.json @@ -301,7 +301,12 @@ "no_content_found": "No content found", "no_content_filters": "No content found for the selected filters", "loading_content": "Loading content...", - "back": "Back" + "back": "Back", + "in_theaters": "In Theaters", + "all": "All", + "failed_tmdb": "Failed to load content from TMDB", + "movies": "Movies", + "tv_shows": "TV Shows" }, "streams": { "back_to_episodes": "Back to Episodes", diff --git a/src/i18n/locales/pt.json b/src/i18n/locales/pt.json index 8f0be62d..b8f4408a 100644 --- a/src/i18n/locales/pt.json +++ b/src/i18n/locales/pt.json @@ -301,7 +301,12 @@ "no_content_found": "Nenhum conteúdo encontrado", "no_content_filters": "Nenhum conteúdo encontrado para os filtros selecionados", "loading_content": "Carregando conteúdo...", - "back": "Voltar" + "back": "Voltar", + "in_theaters": "Em Cartaz", + "all": "Todos", + "failed_tmdb": "Falha ao carregar conteúdo do TMDB", + "movies": "Filmes", + "tv_shows": "Séries" }, "streams": { "back_to_episodes": "Voltar aos Episódios", diff --git a/src/screens/CatalogScreen.tsx b/src/screens/CatalogScreen.tsx index 4fbec6ef..05ac8534 100644 --- a/src/screens/CatalogScreen.tsx +++ b/src/screens/CatalogScreen.tsx @@ -334,7 +334,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { // Check if the name already includes content type indicators const lowerName = catalogName.toLowerCase(); - const contentType = type === 'movie' ? 'Movies' : type === 'series' ? 'TV Shows' : `${type.charAt(0).toUpperCase() + type.slice(1)}s`; + const contentType = type === 'movie' ? t('catalog.movies') : type === 'series' ? t('catalog.tv_shows') : `${type.charAt(0).toUpperCase() + type.slice(1)}s`; // If the name already contains type information, return as is if (lowerName.includes('movie') || lowerName.includes('tv') || lowerName.includes('show') || lowerName.includes('series')) { @@ -349,8 +349,8 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { const displayName = actualCatalogName ? getCustomName(addonId || '', type || '', id || '', createDisplayName(actualCatalogName)) : getCustomName(addonId || '', type || '', id || '', originalName ? createDisplayName(originalName) : '') || - (genreFilter ? `${genreFilter} ${type === 'movie' ? 'Movies' : 'TV Shows'}` : - `${type.charAt(0).toUpperCase() + type.slice(1)}s`); + (genreFilter ? `${genreFilter} ${type === 'movie' ? t('catalog.movies') : t('catalog.tv_shows')}` : + (type === 'movie' ? t('catalog.movies') : type === 'series' ? t('catalog.tv_shows') : `${type.charAt(0).toUpperCase() + type.slice(1)}s`)); // Add effect to get the actual catalog name and filter extras from addon manifest useEffect(() => { @@ -509,7 +509,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { } catch (error) { logger.error('Failed to get TMDB catalog:', error); InteractionManager.runAfterInteractions(() => { - setError('Failed to load content from TMDB'); + setError(t('catalog.failed_tmdb')); setItems([]); setLoading(false); setRefreshing(false); @@ -793,7 +793,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { color={colors.white} style={{ marginRight: 4 }} /> - In Theaters + {t('catalog.in_theaters')} ) : ( @@ -805,7 +805,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { color={colors.white} style={{ marginRight: 4 }} /> - In Theaters + {t('catalog.in_theaters')} )} @@ -818,7 +818,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { color={colors.white} style={{ marginRight: 4 }} /> - In Theaters + {t('catalog.in_theaters')} ) )} @@ -892,7 +892,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { onPress={() => navigation.goBack()} > - Back + {t('catalog.back')} {displayName || originalName || `${type.charAt(0).toUpperCase() + type.slice(1)}s`} @@ -911,7 +911,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { onPress={() => navigation.goBack()} > - Back + {t('catalog.back')} {displayName || `${type.charAt(0).toUpperCase() + type.slice(1)}s`} @@ -929,7 +929,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { onPress={() => navigation.goBack()} > - Back + {t('catalog.back')} {displayName || `${type.charAt(0).toUpperCase() + type.slice(1)}s`} @@ -955,7 +955,7 @@ const CatalogScreen: React.FC = ({ route, navigation }) => { All + ]}>{t('catalog.all')} {/* Filter options from catalog extra */} diff --git a/src/screens/SearchScreen.tsx b/src/screens/SearchScreen.tsx index 048b551b..054b9df8 100644 --- a/src/screens/SearchScreen.tsx +++ b/src/screens/SearchScreen.tsx @@ -1150,7 +1150,7 @@ const SearchScreen = () => { {/* ScreenHeader Component */} {/* Search Bar */}