fix: adding translations for spanish

This commit is contained in:
Chubby Granny Chaser 2024-09-14 21:40:34 +01:00
parent 5432ef311a
commit aa8b685108
No known key found for this signature in database
12 changed files with 231 additions and 105 deletions

View File

@ -260,11 +260,6 @@
"request_accepted": "Žádost přijata",
"user_blocked_successfully": "Uživatel úspěšně zablokován",
"user_block_modal_text": "Tohle zablokuje {{displayName}}",
"settings": "Nastavení",
"public": "Veřejné",
"private": "Soukromé",
"friends_only": "Pouze přátelé",
"privacy": "Soukromí",
"blocked_users": "Zablokovaní uživatelé",
"unblock": "Odblokovat",
"no_friends_added": "Nemáš přidané žádné přátele",

View File

@ -260,11 +260,6 @@
"request_accepted": "Anfrage akzeptiert",
"user_blocked_successfully": "Nutzer erfolgreich blockiert",
"user_block_modal_text": "{{displayName}} wird dadurch blockiert",
"settings": "Einstellungen",
"public": "Öffentlich",
"private": "Privat",
"friends_only": "Nur Freunde",
"privacy": "Privatsphäre",
"blocked_users": "Blockierte Nutzer",
"unblock": "Freigeben",
"no_friends_added": "Du hast noch keine Freunde hinzugefügt",

View File

@ -213,7 +213,9 @@
"profile_visibility_description": "Choose who can see your profile and library",
"required_field": "This field is required",
"source_already_exists": "This source has been already added",
"must_be_valid_url": "The source must be a valid URL"
"must_be_valid_url": "The source must be a valid URL",
"blocked_users": "Blocked users",
"user_unblocked": "User has been unblocked"
},
"notifications": {
"download_complete": "Download complete",
@ -296,6 +298,17 @@
"image_process_failure": "Failure while processing the image",
"required_field": "This field is required",
"displayname_min_length": "Display name must be at least 3 characters long",
"displayname_max_length": "Display name must be at most 50 characters long"
"displayname_max_length": "Display name must be at most 50 characters long",
"report_profile": "Report this profile",
"report_reason": "Why are you reporting this profile?",
"report_description": "Additional information",
"report_description_placeholder": "Additional information",
"report": "Report",
"report_reason_hate": "Hate speech",
"report_reason_sexual_content": "Sexual content",
"report_reason_violence": "Violence",
"report_reason_spam": "Spam",
"report_reason_other": "Other",
"profile_reported": "Profile reported"
}
}

View File

@ -7,7 +7,10 @@
"featured": "Destacado",
"trending": "Tendencias",
"surprise_me": "¡Sorpréndeme!",
"no_results": "No se encontraron resultados"
"no_results": "No se encontraron resultados",
"hot": "🔥 Caliente ahora",
"start_typing": "Empezando a escribir para buscar...",
"weekly": "📅 Los mejores juegos de la semana"
},
"sidebar": {
"catalogue": "Catálogo",
@ -21,7 +24,8 @@
"home": "Inicio",
"queued": "{{title}} (En Cola)",
"game_has_no_executable": "El juego no tiene un ejecutable",
"sign_in": "Iniciar sesión"
"sign_in": "Iniciar sesión",
"friends": "Amigos"
},
"header": {
"search": "Buscar juegos",
@ -114,7 +118,17 @@
"download_paused": "Descarga pausada",
"last_downloaded_option": "Última opción descargada",
"create_shortcut_success": "Atajo creado con éxito",
"create_shortcut_error": "Error al crear un atajo"
"create_shortcut_error": "Error al crear un atajo",
"allow_nsfw_content": "Continuar",
"download": "Descargar",
"download_count": "Descargas",
"download_error": "Esta opción de descarga no está disponible.",
"executable_path_in_use": "Ejecutable ya en uso por \"{{game}}\"",
"nsfw_content_description": "{{title}} incluye contenido que puede no ser adecuado para todas las edades. \n¿Estás seguro de que quieres continuar?",
"nsfw_content_title": "Este juego contiene contenido inapropiado.",
"player_count": "Jugadores activos",
"refuse_nsfw_content": "Volver",
"stats": "Estadísticas"
},
"activation": {
"title": "Activar Hydra",
@ -190,7 +204,21 @@
"found_download_option_zero": "No se encontró una opción de descarga",
"found_download_option_one": "Se encontró {{countFormatted}} opción de descarga",
"found_download_option_other": "Se encontraron {{countFormatted}} opciones de descarga",
"import": "Importar"
"import": "Importar",
"blocked_users": "Usuarios bloqueados",
"download_options_one": "",
"download_options_other": "",
"download_options_zero": "",
"friends_only": "solo amigos",
"must_be_valid_url": "La fuente debe ser una URL válida.",
"privacy": "Privacidad",
"private": "Privado",
"profile_visibility": "Visibilidad del perfil",
"profile_visibility_description": "Elige quién puede ver tu perfil y biblioteca",
"public": "Público",
"required_field": "Este campo es obligatorio",
"source_already_exists": "Esta fuente ya ha sido agregada.",
"user_unblocked": "El usuario ha sido desbloqueado"
},
"notifications": {
"download_complete": "Descarga completada",
@ -260,11 +288,6 @@
"request_accepted": "Solicitud aceptada",
"user_blocked_successfully": "Usuario bloqueado exitosamente",
"user_block_modal_text": "Esto va a bloquear a {{displayName}}",
"settings": "Ajustes",
"public": "Público",
"private": "Privado",
"friends_only": "Solo Amigos",
"privacy": "Privacidad",
"blocked_users": "Usuarios bloqueados",
"unblock": "Desbloquear",
"no_friends_added": "Todavía no tienes amigos añadidos",
@ -272,6 +295,24 @@
"no_pending_invites": "No tienes invitaciones pendientes",
"no_blocked_users": "No has bloqueado a ningún usuario",
"friend_code_copied": "Código de amigo copiado",
"undo_friendship_modal_text": "Esto deshará tu amistad con {{displayName}}"
"undo_friendship_modal_text": "Esto deshará tu amistad con {{displayName}}",
"displayname_max_length": "El nombre para mostrar debe tener como máximo 50 caracteres",
"displayname_min_length": "El nombre para mostrar debe tener al menos 3 caracteres",
"image_process_failure": "Fallo al procesar la imagen.",
"locked_profile": "Este perfil es privado.",
"privacy_hint": "Para ajustar quién puede ver esto, ve a <0>Configuración</0>.",
"profile_locked": "",
"profile_reported": "Perfil reportado",
"report": "Informe",
"report_description": "Información adicional",
"report_description_placeholder": "Información adicional",
"report_profile": "Reportar este perfil",
"report_reason": "¿Por qué estás denunciando este perfil?",
"report_reason_hate": "discurso de odio",
"report_reason_other": "Otro",
"report_reason_sexual_content": "Contenido sexual",
"report_reason_spam": "Correo basura",
"report_reason_violence": "Violencia",
"required_field": "Este campo es obligatorio"
}
}

View File

@ -212,7 +212,9 @@
"profile_visibility_description": "Escolha quem pode ver seu perfil e biblioteca",
"required_field": "Este campo é obrigatório",
"source_already_exists": "Essa fonte já foi adicionada",
"must_be_valid_url": "A fonte deve ser uma URL válida"
"must_be_valid_url": "A fonte deve ser uma URL válida",
"blocked_users": "Usuários bloqueados",
"user_unblocked": "Usuário desbloqueado"
},
"notifications": {
"download_complete": "Download concluído",
@ -300,6 +302,17 @@
"required_field": "Este campo é obrigatório",
"displayname_min_length": "Nome de exibição deve ter pelo menos 3 caracteres",
"displayname_max_length": "Nome de exibição deve ter no máximo 50 caracteres",
"locked_profile": "Este perfil é privado"
"locked_profile": "Este perfil é privado",
"report_profile": "Report this profile",
"report_reason": "Por que você deseja reportar este perfil?",
"report_description": "Informações adicionais",
"report_description_placeholder": "Insira aqui",
"report": "Reportar",
"report_reason_hate": "Discurso de ódio",
"report_reason_sexual_content": "Conteúdo sexual",
"report_reason_violence": "Violência",
"report_reason_spam": "Spam",
"report_reason_other": "Outro",
"profile_reported": "Perfil reportado"
}
}

View File

@ -171,8 +171,6 @@
"save_changes": "Guardar alterações",
"changes_saved": "Definições guardadas com sucesso",
"download_sources_description": "O Hydra vai procurar links de transferência em todas as fontes ativadas. A URL da página de detalhes da loja não é guardada no seu dispositivo. Utilizamos um sistema de metadados criado pela comunidade para fornecer suporte a mais fontes de transferência de jogos.",
"enable_source": "Ativar",
"disable_source": "Desativar",
"validate_download_source": "Validar",
"remove_download_source": "Remover",
"add_download_source": "Adicionar fonte",
@ -268,11 +266,6 @@
"request_accepted": "Pedido de amizade aceito",
"user_blocked_successfully": "Utilizador bloqueado com sucesso",
"user_block_modal_text": "Bloquear {{displayName}}",
"settings": "Definições",
"privacy": "Privacidade",
"private": "Privado",
"friends_only": "Apenas amigos",
"public": "Público",
"blocked_users": "Utilizadores bloqueados",
"unblock": "Desbloquear",
"no_friends_added": "Ainda não adicionaste amigos",

View File

@ -7,7 +7,10 @@
"featured": "Рекомендованное",
"trending": "В тренде",
"surprise_me": "Удиви меня",
"no_results": "Ничего не найдено"
"no_results": "Ничего не найдено",
"hot": "🔥 Сейчас жарко",
"start_typing": "Начинаю вводить текст для поиска...",
"weekly": "📅 Лучшие игры недели"
},
"sidebar": {
"catalogue": "Каталог",
@ -21,7 +24,8 @@
"home": "Главная",
"queued": "{{title}} (В очереди)",
"game_has_no_executable": "Файл запуска игры не выбран",
"sign_in": "Войти"
"sign_in": "Войти",
"friends": "Друзья"
},
"header": {
"search": "Поиск",
@ -114,7 +118,17 @@
"download_paused": "Загрузка приостановлена",
"last_downloaded_option": "Последний вариант загрузки",
"create_shortcut_success": "Ярлык создан",
"create_shortcut_error": "Не удалось создать ярлык"
"create_shortcut_error": "Не удалось создать ярлык",
"allow_nsfw_content": "Продолжать",
"download": "Скачать",
"download_count": "Загрузки",
"download_error": "Этот вариант загрузки недоступен",
"executable_path_in_use": "Исполняемый файл уже используется \"{{game}}\"",
"nsfw_content_description": "{{title}} содержит контент, который может не подходить для всех возрастов. \nВы уверены, что хотите продолжить?",
"nsfw_content_title": "Эта игра содержит неприемлемый контент",
"player_count": "Активные игроки",
"refuse_nsfw_content": "Возвращаться",
"stats": "Статистика"
},
"activation": {
"title": "Активировать Hydra",
@ -190,7 +204,21 @@
"found_download_option_zero": "Не найдено вариантов загрузки",
"found_download_option_one": "Найден {{countFormatted}} вариант загрузки",
"found_download_option_other": "Найдено {{countFormatted}} вариантов загрузки",
"import": "Импортировать"
"import": "Импортировать",
"blocked_users": "Заблокированные пользователи",
"download_options_one": "",
"download_options_other": "",
"download_options_zero": "",
"friends_only": "Только друзья",
"must_be_valid_url": "Источник должен быть действительным URL-адресом.",
"privacy": "Конфиденциальность",
"private": "Частный",
"profile_visibility": "Видимость профиля",
"profile_visibility_description": "Выберите, кто может видеть ваш профиль и библиотеку",
"public": "Общественный",
"required_field": "Это поле обязательно к заполнению",
"source_already_exists": "Этот источник уже добавлен",
"user_unblocked": "Пользователь разблокирован"
},
"notifications": {
"download_complete": "Загрузка завершена",
@ -260,17 +288,31 @@
"request_accepted": "Запрос принят",
"user_blocked_successfully": "Пользователь успешно заблокирован",
"user_block_modal_text": "{{displayName}} будет заблокирован",
"settings": "Настройки",
"public": "Публичный",
"private": "Приватный",
"friends_only": "Только друзья",
"privacy": "Приватность",
"blocked_users": "Заблокированные пользователи",
"unblock": "Разблокировать",
"no_friends_added": "Вы ещё не добавили ни одного друга",
"pending": "Ожидание",
"no_pending_invites": "У вас нет запросов ожидающих ответа",
"no_blocked_users": "Вы не заблокировали ни одного пользователя",
"friend_code_copied": "Код друга скопирован"
"friend_code_copied": "Код друга скопирован",
"displayname_max_length": "Отображаемое имя должно содержать не более 50 символов.",
"displayname_min_length": "Отображаемое имя должно содержать не менее 3 символов.",
"image_process_failure": "Сбой при обработке изображения",
"locked_profile": "Этот профиль является частным",
"privacy_hint": "Чтобы указать, кто может это видеть, перейдите в <0>Настройки</0>.",
"profile_locked": "",
"profile_reported": "Профиль сообщил",
"report": "Отчет",
"report_description": "Дополнительная информация",
"report_description_placeholder": "Дополнительная информация",
"report_profile": "Пожаловаться на этот профиль",
"report_reason": "Почему вы жалуетесь на этот профиль?",
"report_reason_hate": "Разжигание ненависти",
"report_reason_other": "Другой",
"report_reason_sexual_content": "Сексуальный контент",
"report_reason_spam": "Спам",
"report_reason_violence": "Насилие",
"required_field": "Это поле обязательно к заполнению",
"undo_friendship_modal_text": "Это отменит вашу дружбу с {{displayName}}."
}
}

View File

@ -5,6 +5,7 @@ import { useTranslation } from "react-i18next";
import * as styles from "./profile-content.css";
import { Link } from "@renderer/components";
import { PersonIcon } from "@primer/octicons-react";
export function FriendsBox() {
const { userProfile, userStats } = useContext(userProfileContext);
@ -13,6 +14,8 @@ export function FriendsBox() {
const { numberFormatter } = useFormat();
if (!userProfile?.friends.length) return null;
return (
<div>
<div className={styles.sectionHeader}>
@ -27,11 +30,18 @@ export function FriendsBox() {
{userProfile?.friends.map((friend) => (
<li key={friend.id}>
<Link to={`/profile/${friend.id}`} className={styles.listItem}>
<img
src={friend.profileImageUrl!}
alt={friend.displayName}
className={styles.listItemImage}
/>
{friend.profileImageUrl ? (
<img
src={friend.profileImageUrl!}
alt={friend.displayName}
className={styles.listItemImage}
/>
) : (
<div className={styles.defaultAvatarWrapper}>
<PersonIcon size={16} />
</div>
)}
<span className={styles.friendName}>{friend.displayName}</span>
</Link>
</li>

View File

@ -176,3 +176,14 @@ export const listItemDescription = style({
alignItems: "center",
gap: `${SPACING_UNIT}px`,
});
export const defaultAvatarWrapper = style({
width: "32px",
height: "32px",
display: "flex",
justifyContent: "center",
alignItems: "center",
backgroundColor: vars.color.background,
border: `solid 1px ${vars.color.border}`,
borderRadius: "4px",
});

View File

@ -57,17 +57,9 @@ export function ProfileContent() {
return <LockedProfile />;
}
if (userProfile.libraryGames.length === 0) {
return (
<div className={styles.noGames}>
<div className={styles.telescopeIcon}>
<TelescopeIcon size={24} />
</div>
<h2>{t("no_recent_activity_title")}</h2>
{isMe && <p>{t("no_recent_activity_description")}</p>}
</div>
);
}
const hasGames = userProfile?.libraryGames.length > 0;
const shouldShowRightContent = hasGames || userProfile.friends.length > 0;
return (
<section
@ -78,57 +70,81 @@ export function ProfileContent() {
}}
>
<div style={{ flex: 1 }}>
<div className={styles.sectionHeader}>
<h2>{t("library")}</h2>
{!hasGames && (
<div className={styles.noGames}>
<div className={styles.telescopeIcon}>
<TelescopeIcon size={24} />
</div>
<h2>{t("no_recent_activity_title")}</h2>
{isMe && <p>{t("no_recent_activity_description")}</p>}
</div>
)}
{userStats && (
<span>{numberFormatter.format(userStats.libraryCount)}</span>
)}
</div>
{hasGames && (
<>
<div className={styles.sectionHeader}>
<h2>{t("library")}</h2>
<ul className={styles.gamesGrid}>
{userProfile?.libraryGames?.map((game) => (
<li
key={game.objectId}
style={{
borderRadius: 4,
overflow: "hidden",
position: "relative",
}}
className={styles.game}
>
<button
type="button"
style={{
cursor: "pointer",
}}
className={styles.gameCover}
onClick={() => navigate(buildUserGameDetailsPath(game))}
>
<img
src={steamUrlBuilder.cover(game.objectId)}
alt={game.title}
{userStats && (
<span>{numberFormatter.format(userStats.libraryCount)}</span>
)}
</div>
<ul className={styles.gamesGrid}>
{userProfile?.libraryGames?.map((game) => (
<li
key={game.objectId}
style={{
width: "100%",
objectFit: "cover",
borderRadius: 4,
overflow: "hidden",
position: "relative",
}}
/>
</button>
</li>
))}
</ul>
className={styles.game}
>
<button
type="button"
style={{
cursor: "pointer",
}}
className={styles.gameCover}
onClick={() => navigate(buildUserGameDetailsPath(game))}
>
<img
src={steamUrlBuilder.cover(game.objectId)}
alt={game.title}
style={{
width: "100%",
objectFit: "cover",
borderRadius: 4,
}}
/>
</button>
</li>
))}
</ul>
</>
)}
</div>
<div className={styles.rightContent}>
<RecentGamesBox />
<FriendsBox />
{shouldShowRightContent && (
<div className={styles.rightContent}>
<RecentGamesBox />
<FriendsBox />
<ReportProfile />
</div>
<ReportProfile />
</div>
)}
</section>
);
}, [userProfile, isMe, usersAreFriends, numberFormatter, t, navigate]);
}, [
userProfile,
isMe,
usersAreFriends,
userStats,
numberFormatter,
t,
navigate,
]);
return (
<div>

View File

@ -72,7 +72,7 @@ export function ReportProfile() {
<Modal
visible={showReportProfileModal}
onClose={() => setShowReportProfileModal(false)}
title="Report this profile"
title={t("report_profile")}
clickOutsideToClose={false}
>
<form
@ -96,7 +96,6 @@ export function ReportProfile() {
value: reason,
label: t(`report_reason_${reason}`),
}))}
disabled={isSubmitting}
/>
);
}}
@ -122,6 +121,7 @@ export function ReportProfile() {
type="button"
className={styles.reportButton}
onClick={() => setShowReportProfileModal(true)}
disabled={isSubmitting}
>
<ReportIcon size={13} />
{t("report_profile")}

View File

@ -57,16 +57,13 @@ export function SettingsPrivacy() {
unblockUser(id)
.then(() => {
fetchBlockedUsers();
// show toast
})
.catch(() => {
//show toast
showSuccessToast(t("user_unblocked"));
})
.finally(() => {
setIsUnblocking(false);
});
},
[unblockUser, fetchBlockedUsers]
[unblockUser, fetchBlockedUsers, t, showSuccessToast]
);
return (