From 4e2427dbefdd97b922f2cd00765ddac74b2173fc Mon Sep 17 00:00:00 2001
From: Zamitto <167933696+zamitto@users.noreply.github.com>
Date: Sat, 1 Feb 2025 21:23:22 -0300
Subject: [PATCH] feat: refactor settings tabs
---
src/renderer/src/pages/settings/settings.tsx | 37 +++++++++++---------
1 file changed, 21 insertions(+), 16 deletions(-)
diff --git a/src/renderer/src/pages/settings/settings.tsx b/src/renderer/src/pages/settings/settings.tsx
index c752890a..a3a955e2 100644
--- a/src/renderer/src/pages/settings/settings.tsx
+++ b/src/renderer/src/pages/settings/settings.tsx
@@ -23,14 +23,26 @@ export default function Settings() {
const categories = useMemo(() => {
const categories = [
- t("general"),
- t("behavior"),
- t("download_sources"),
- "Torbox",
- "Real-Debrid",
+ { tabLabel: t("general"), contentTitle: t("general") },
+ { tabLabel: t("behavior"), contentTitle: t("behavior") },
+ { tabLabel: t("download_sources"), contentTitle: t("download_sources") },
+ {
+ tabLabel: (
+ <>
+
+ Torbox
+ >
+ ),
+ contentTitle: "TorBox",
+ },
+ { tabLabel: "Real-Debrid", contentTitle: "Real-Debrid" },
];
- if (userDetails) return [...categories, t("account")];
+ if (userDetails)
+ return [
+ ...categories,
+ { tabLabel: t("account"), contentTitle: t("account") },
+ ];
return categories;
}, [userDetails, t]);
@@ -68,25 +80,18 @@ export default function Settings() {