diff --git a/src/ui/Desktop/Apps/Terminal/SnippetsSidebar.tsx b/src/ui/Desktop/Apps/Terminal/SnippetsSidebar.tsx
index aff62244..8879f12a 100644
--- a/src/ui/Desktop/Apps/Terminal/SnippetsSidebar.tsx
+++ b/src/ui/Desktop/Apps/Terminal/SnippetsSidebar.tsx
@@ -60,7 +60,7 @@ export function SnippetsSidebar({
const data = await getSnippets();
// Defensive: ensure data is an array
setSnippets(Array.isArray(data) ? data : []);
- } catch (err) {
+ } catch {
toast.error(t("snippets.failedToFetch"));
setSnippets([]);
} finally {
@@ -94,7 +94,7 @@ export function SnippetsSidebar({
await deleteSnippet(snippet.id);
toast.success(t("snippets.deleteSuccess"));
fetchSnippets();
- } catch (err) {
+ } catch {
toast.error(t("snippets.deleteFailed"));
}
},
@@ -125,7 +125,7 @@ export function SnippetsSidebar({
}
setShowDialog(false);
fetchSnippets();
- } catch (err) {
+ } catch {
toast.error(
editingSnippet
? t("snippets.updateFailed")
@@ -155,10 +155,7 @@ export function SnippetsSidebar({
transform: "translateZ(0)",
}}
>
-
+
+ onTunnelAction={(action) =>
onTunnelAction(action, activeHost, idx)
}
compact
diff --git a/src/ui/Desktop/DesktopApp.tsx b/src/ui/Desktop/DesktopApp.tsx
index add9611d..d5d91716 100644
--- a/src/ui/Desktop/DesktopApp.tsx
+++ b/src/ui/Desktop/DesktopApp.tsx
@@ -12,13 +12,9 @@ import { AdminSettings } from "@/ui/Desktop/Admin/AdminSettings.tsx";
import { UserProfile } from "@/ui/Desktop/User/UserProfile.tsx";
import { Toaster } from "@/components/ui/sonner.tsx";
import { VersionCheckModal } from "@/components/ui/version-check-modal.tsx";
-import { getUserInfo, getCookie } from "@/ui/main-axios.ts";
+import { getUserInfo } from "@/ui/main-axios.ts";
function AppContent() {
- const [view, setView] = useState("homepage");
- const [mountedViews, setMountedViews] = useState>(
- new Set(["homepage"]),
- );
const [isAuthenticated, setIsAuthenticated] = useState(false);
const [username, setUsername] = useState(null);
const [isAdmin, setIsAdmin] = useState(false);
@@ -71,14 +67,8 @@ function AppContent() {
localStorage.setItem("topNavbarOpen", JSON.stringify(isTopbarOpen));
}, [isTopbarOpen]);
- const handleSelectView = (nextView: string) => {
- setMountedViews((prev) => {
- if (prev.has(nextView)) return prev;
- const next = new Set(prev);
- next.add(nextView);
- return next;
- });
- setView(nextView);
+ const handleSelectView = (_nextView: string) => {
+ // View switching is now handled by tabs context
};
const handleAuthSuccess = (authData: {
diff --git a/src/ui/Desktop/Homepage/HomepageAlertManager.tsx b/src/ui/Desktop/Homepage/HomepageAlertManager.tsx
index c1121f1a..96246716 100644
--- a/src/ui/Desktop/Homepage/HomepageAlertManager.tsx
+++ b/src/ui/Desktop/Homepage/HomepageAlertManager.tsx
@@ -52,7 +52,7 @@ export function HomepageAlertManager({
setAlerts(sortedAlerts);
setCurrentAlertIndex(0);
- } catch (err) {
+ } catch {
const { toast } = await import("sonner");
toast.error(t("homepage.failedToLoadAlerts"));
setError(t("homepage.failedToLoadAlerts"));
@@ -77,7 +77,7 @@ export function HomepageAlertManager({
return Math.max(0, newAlertsLength - 1);
return prevIndex;
});
- } catch (err) {
+ } catch {
setError(t("homepage.failedToDismissAlert"));
}
};