import { createContext, useContext } from "react"; export type Translate = (key: string, params?: Record) => string; const TranslationContext = createContext(undefined); export const TranslationProvider = TranslationContext.Provider; export function useTranslate() { return useContext(TranslationContext); }