Files
Dorod-Sky/skyvern-frontend/src/routes/root/SideNav.tsx
Vodorod 6b69159550
Some checks failed
Run tests and pre-commit / Run tests and pre-commit hooks (push) Has been cancelled
Run tests and pre-commit / Frontend Lint and Build (push) Has been cancelled
Publish Fern Docs / run (push) Has been cancelled
Update OpenAPI Specification / update-openapi (push) Has been cancelled
feat: Add Russian i18n translations and fix CORS + API endpoint issues
- Implemented full Russian translation (ru) for 8 major pages
- Added LanguageSwitcher component with language detection
- Translated: Navigation, Settings, Workflows, Credentials, Banner, Examples
- Fixed API endpoint path: changed to use sans-api-v1 client for /v1/ endpoints
- Fixed CORS: added http://localhost:8081 to ALLOWED_ORIGINS
- Added locales infrastructure with i18next and react-i18next
- Created bilingual JSON files (en/ru) for 4 namespaces
- 220+ translation keys implemented
- Backend CORS configuration updated in .env
- Documentation: I18N implementation guides and installation docs
2026-02-21 08:29:21 +03:00

69 lines
1.7 KiB
TypeScript

import { CompassIcon } from "@/components/icons/CompassIcon";
import { NavLinkGroup } from "@/components/NavLinkGroup";
import { useSidebarStore } from "@/store/SidebarStore";
import { cn } from "@/util/utils";
import {
CounterClockwiseClockIcon,
GearIcon,
GlobeIcon,
LightningBoltIcon,
} from "@radix-ui/react-icons";
import { KeyIcon } from "@/components/icons/KeyIcon.tsx";
import { useTranslation } from "react-i18next";
function SideNav() {
const { collapsed } = useSidebarStore();
const { t } = useTranslation("common");
return (
<nav
className={cn("space-y-5", {
"items-center": collapsed,
})}
>
<NavLinkGroup
title={t("nav.build")}
links={[
{
label: t("nav.discover"),
to: "/discover",
icon: <CompassIcon className="size-6" />,
},
{
label: t("nav.workflows"),
to: "/workflows",
icon: <LightningBoltIcon className="size-6" />,
},
{
label: t("nav.runs"),
to: "/runs",
icon: <CounterClockwiseClockIcon className="size-6" />,
},
{
label: t("nav.browsers"),
to: "/browser-sessions",
icon: <GlobeIcon className="size-6" />,
},
]}
/>
<NavLinkGroup
title={t("nav.general")}
links={[
{
label: t("nav.settings"),
to: "/settings",
icon: <GearIcon className="size-6" />,
},
{
label: t("nav.credentials"),
to: "/credentials",
icon: <KeyIcon className="size-6" />,
},
]}
/>
</nav>
);
}
export { SideNav };