-
{formatPlayTime(userStats.totalPlayTimeInSeconds.value)}
+
+
+ {formatPlayTime(userStats.totalPlayTimeInSeconds.value)}
+
{t("top_percentile", {
percentile: userStats.totalPlayTimeInSeconds.topPercentile,
diff --git a/src/types/index.ts b/src/types/index.ts
index 7cca371c6..8bdace2fa 100644
--- a/src/types/index.ts
+++ b/src/types/index.ts
@@ -99,6 +99,7 @@ export interface UserGame {
lastTimePlayed: Date | null;
unlockedAchievementCount: number;
achievementCount: number;
+ achievementsPointsEarnedSum: number;
}
export interface DownloadQueue {
From 32032e1c8a7827411c3d08d124313eef0e15a828 Mon Sep 17 00:00:00 2001
From: Chubby Granny Chaser
Date: Sun, 22 Dec 2024 23:38:54 +0000
Subject: [PATCH 28/62] fix: fixing download sources migration
---
src/locales/pt-BR/translation.json | 7 +-
.../src/components/header/header.css.ts | 15 +-
src/renderer/src/components/header/header.tsx | 6 +-
.../src/pages/catalogue/catalogue.scss | 16 +-
.../src/pages/catalogue/catalogue.tsx | 241 ++++++----
.../src/pages/catalogue/steam-user-tags.ts | 452 ------------------
.../src/workers/download-sources.worker.ts | 69 +--
7 files changed, 205 insertions(+), 601 deletions(-)
delete mode 100644 src/renderer/src/pages/catalogue/steam-user-tags.ts
diff --git a/src/locales/pt-BR/translation.json b/src/locales/pt-BR/translation.json
index a1197c78f..fa11ef273 100644
--- a/src/locales/pt-BR/translation.json
+++ b/src/locales/pt-BR/translation.json
@@ -279,8 +279,11 @@
"instructions": "Verifique a forma correta de instalar algum deles no seu distro Linux, garantindo assim a execução normal do jogo"
},
"catalogue": {
- "next_page": "Próxima página",
- "previous_page": "Página anterior"
+ "search": "Pesquisar…",
+ "developers": "Desenvolvedores",
+ "genres": "Gêneros",
+ "tags": "Tags",
+ "download_sources": "Fontes de download"
},
"modal": {
"close": "Botão de fechar"
diff --git a/src/renderer/src/components/header/header.css.ts b/src/renderer/src/components/header/header.css.ts
index a592f35b8..903f4a42d 100644
--- a/src/renderer/src/components/header/header.css.ts
+++ b/src/renderer/src/components/header/header.css.ts
@@ -74,9 +74,18 @@ export const search = recipe({
},
});
-export const searchButton = style({
- WebkitAppRegion: "no-drag",
-} as ComplexStyleRule);
+export const searchButton = recipe({
+ base: {
+ WebkitAppRegion: "no-drag",
+ } as ComplexStyleRule,
+ variants: {
+ hidden: {
+ true: {
+ visibility: "hidden",
+ },
+ },
+ },
+});
export const section = style({
display: "flex",
diff --git a/src/renderer/src/components/header/header.tsx b/src/renderer/src/components/header/header.tsx
index eb6a9f3b2..2c79b1d4c 100644
--- a/src/renderer/src/components/header/header.tsx
+++ b/src/renderer/src/components/header/header.tsx
@@ -35,6 +35,10 @@ export function Header() {
return t(pathTitle[location.pathname]);
}, [location.pathname, headerTitle, t]);
+ const showSearchButton = useMemo(() => {
+ return location.pathname.startsWith("/catalogue");
+ }, [location.pathname]);
+
const handleBackButtonClick = () => {
navigate(-1);
};
@@ -71,7 +75,7 @@ export function Header() {