portainer/app/__mocks__/react-i18next.tsx

17 lines
312 B
TypeScript
Raw Normal View History

import { PropsWithChildren } from 'react';
import { mockT } from './i18next';
export function useTranslation() {
return {
t: mockT,
i18n: {
changeLanguage: () => new Promise(() => {}),
},
};
}
export function Trans({ children }: PropsWithChildren<unknown>) {
return <>{children}</>;
}