From 3156baf78e118ad86c017cd5e3590197434f8315 Mon Sep 17 00:00:00 2001 From: Shisuys Date: Sat, 11 Jan 2025 11:40:48 -0300 Subject: [PATCH 1/6] Limit visible sources --- src/locales/pt-BR/translation.json | 1 + .../src/components/game-card/game-card.tsx | 29 ++++++++++++------- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/src/locales/pt-BR/translation.json b/src/locales/pt-BR/translation.json index 9c51e68e..563d9f27 100644 --- a/src/locales/pt-BR/translation.json +++ b/src/locales/pt-BR/translation.json @@ -280,6 +280,7 @@ "quit": "Fechar" }, "game_card": { + "available": "Disponível", "no_downloads": "Sem downloads disponíveis" }, "binary_not_found_modal": { diff --git a/src/renderer/src/components/game-card/game-card.tsx b/src/renderer/src/components/game-card/game-card.tsx index d51a322b..95f15a8e 100644 --- a/src/renderer/src/components/game-card/game-card.tsx +++ b/src/renderer/src/components/game-card/game-card.tsx @@ -44,6 +44,9 @@ export function GameCard({ game, ...props }: GameCardProps) { const { numberFormatter } = useFormat(); + const firstThreeRepackers = uniqueRepackers.slice(0, 3); + const remainingCount = uniqueRepackers.length - 3; + return ( From dddc5bfd96a34ddc79cfded2ce1df3be003b43be Mon Sep 17 00:00:00 2001 From: Shisuys Date: Tue, 11 Feb 2025 19:17:58 -0300 Subject: [PATCH 6/6] Update game-card.tsx --- .../src/components/game-card/game-card.tsx | 66 +++++++++---------- 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/src/renderer/src/components/game-card/game-card.tsx b/src/renderer/src/components/game-card/game-card.tsx index 8423ebc1..9859fe1e 100644 --- a/src/renderer/src/components/game-card/game-card.tsx +++ b/src/renderer/src/components/game-card/game-card.tsx @@ -75,40 +75,40 @@ export function GameCard({ game, ...props }: GameCardProps) {

{game.title}

-{uniqueRepackers.length > 0 ? ( - -) : ( -

{t("no_downloads")}

-)} - -
-
- - - {stats ? numberFormatter.format(stats.downloadCount) : "…"} - -
-
- - - {stats ? numberFormatter.format(stats.playerCount) : "…"} - -
-
+ {uniqueRepackers.length > 0 ? ( + + ) : ( +

{t("no_downloads")}

+ )} +
+
+ + + {stats ? numberFormatter.format(stats.downloadCount) : "…"} + +
+
+ + + {stats ? numberFormatter.format(stats.playerCount) : "…"} + +
+