From eb6ebcf4ba405b6fe41675a729d70269341a5894 Mon Sep 17 00:00:00 2001 From: CKD Date: Thu, 6 Mar 2025 08:43:29 -0800 Subject: [PATCH] fix typos --- ui/src/components/Header.tsx | 2 +- ui/src/components/KvmCard.tsx | 2 +- ui/src/components/USBStateStatus.tsx | 2 +- ui/src/providers/FeatureFlagProvider.tsx | 2 +- ui/src/routes/devices.$id.mount.tsx | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ui/src/components/Header.tsx b/ui/src/components/Header.tsx index cbe439b..efbbfbd 100644 --- a/ui/src/components/Header.tsx +++ b/ui/src/components/Header.tsx @@ -42,7 +42,7 @@ export default function DashboardNavbar({ if (!res.ok) return; setUser(null); - // The root route will redirect to appropiate login page, be it the local one or the cloud one + // The root route will redirect to appropriate login page, be it the local one or the cloud one navigate("/"); }, [navigate, setUser]); diff --git a/ui/src/components/KvmCard.tsx b/ui/src/components/KvmCard.tsx index ec7fc62..1c3d20a 100644 --- a/ui/src/components/KvmCard.tsx +++ b/ui/src/components/KvmCard.tsx @@ -12,7 +12,7 @@ function getRelativeTimeString(date: Date | number, lang = navigator.language): // Get the amount of seconds between the given date and now const deltaSeconds = Math.round((timeMs - Date.now()) / 1000); - // Array reprsenting one minute, hour, day, week, month, etc in seconds + // Array representing one minute, hour, day, week, month, etc in seconds const cutoffs = [60, 3600, 86400, 86400 * 7, 86400 * 30, 86400 * 365, Infinity]; // Array equivalent to the above but in the string representation of the units diff --git a/ui/src/components/USBStateStatus.tsx b/ui/src/components/USBStateStatus.tsx index af393af..7ebb788 100644 --- a/ui/src/components/USBStateStatus.tsx +++ b/ui/src/components/USBStateStatus.tsx @@ -68,7 +68,7 @@ export default function USBStateStatus({ }; const props = StatusCardProps[state]; if (!props) { - console.log("Unsupport USB state: ", state); + console.log("Unsupported USB state: ", state); return; } diff --git a/ui/src/providers/FeatureFlagProvider.tsx b/ui/src/providers/FeatureFlagProvider.tsx index 93d75bb..f4637f6 100644 --- a/ui/src/providers/FeatureFlagProvider.tsx +++ b/ui/src/providers/FeatureFlagProvider.tsx @@ -22,7 +22,7 @@ export const FeatureFlagProvider = ({ }) => { const isFeatureEnabled = (minAppVersion: string) => { // If no version is set, feature is disabled. - // The feature flag component can deside what to display as a fallback - either omit the component or like a "please upgrade to enable". + // The feature flag component can decide what to display as a fallback - either omit the component or like a "please upgrade to enable". if (!appVersion) return false; // Extract the base versions without prerelease identifier diff --git a/ui/src/routes/devices.$id.mount.tsx b/ui/src/routes/devices.$id.mount.tsx index ec289bc..b2d96c6 100644 --- a/ui/src/routes/devices.$id.mount.tsx +++ b/ui/src/routes/devices.$id.mount.tsx @@ -121,7 +121,7 @@ export function Dialog({ onClose }: { onClose: () => void }) { triggerError(err instanceof Error ? err.message : String(err)); }) .finally(() => { - // We do this beacues the mounting is too fast and the UI gets choppy + // We do this because the mounting is too fast and the UI gets choppy // and the modal exit animation for like 500ms setTimeout(() => { setMountInProgress(false);