type Translation = (...args: any) => string;
export type TBaseTranslationsMap = {
    [key: string]: Translation;
};
export type TranslationsMapByLocale<T extends TBaseTranslationsMap, K extends string> = {
    [language in K]: T;
};
type RemoveIndex<T> = {
    [K in keyof T as string extends K ? never : number extends K ? never : K]: T[K];
};
type KnownKeys<T> = keyof RemoveIndex<T>;
/**
 * Translator API
 * This class uses generic T to define the translation entries and JSON structure, as well as K which defines available languages
 * Each entry in the translations index returns a function reference that should return the resulting string
 *
 * Example:
 * //Define the locales and translation key structure
 * type languages = "SE" | "EN"
 * interface MyTranslationsMap extends TBaseTranslationsMap {
 *   A: () => string,
 *   B: () => string
 * }
 *
 * //Write some implementatons in different languages
 * const SE: MyTranslationsMap = {
 *   A: () => "Hej",
 *   B: () => "Världen"
 * }
 * const EN: MyTranslationsMap = {
 *   A: () => "Hello",
 *   B: () => "World"
 * }
 *
 * //Create a locale object
 * const languagesByLocale: TranslationsMapByLocale<MyTranslationsMap, languages> = {
 *   SE: SE,
 *   EN: EN
 * };
 *
 * //Instanstiate the translator instance and include the generic assignments
 * const translator = new TranslatorAPI<MyTranslationsMap, languages>(languagesByLocale, "SE")
 *
 * //Translate stuff!
 * translator.setLanguage("SE")
 * translator.setLanguage("Error!!")
 *
 * translator.getTranslations().A()
 * translator.getTranslations().Error()
 *
 * translator.translate("A")()
 * translator.translate("Error!!")()
 */
export default class TranslatorAPI<T extends TBaseTranslationsMap, K extends string> {
    private translationsByLocale;
    private language;
    private defaultLanguage;
    private isDebugMode;
    constructor(translationsByLocale: TranslationsMapByLocale<T, K>, language: K);
    setLanguage(str: K): void;
    translate(str: KnownKeys<T>): (() => keyof RemoveIndex<T>) | TranslationsMapByLocale<T, K>[K][keyof RemoveIndex<T>];
    getTranslations(): T;
    enableDebugMode(): void;
    disableDebugMode(): void;
}
export {};
