SurfSense/surfsense_web/i18n/routing.ts
moduvoice d3d8f10940 feat(i18n): add Korean (ko) translation
Adds a complete Korean locale (surfsense_web/messages/ko.json) with full
key parity with en.json, and wires ko into every place locales are
currently enumerated: next-intl routing config, the client-side locale
context/loader, and the two language-switcher UIs (main app + sidebar
user profile).
2026-07-10 11:22:54 +07:00

22 lines
817 B
TypeScript

import { createNavigation } from "next-intl/navigation";
import { defineRouting } from "next-intl/routing";
/**
* Internationalization routing configuration
* Defines supported locales and routing behavior for the application
*/
export const routing = defineRouting({
// A list of all locales that are supported
locales: ["en", "es", "pt", "hi", "zh", "ko"],
// Used when no locale matches
defaultLocale: "en",
// The `localePrefix` setting controls whether the locale is included in the pathname
// 'as-needed': Only add locale prefix when not using the default locale
localePrefix: "as-needed",
});
// Lightweight wrappers around Next.js' navigation APIs
// that will consider the routing configuration
export const { Link, redirect, usePathname, useRouter, getPathname } = createNavigation(routing);