mirror of
https://github.com/documenso/documenso.git
synced 2025-11-13 16:23:06 +10:00
feat: add organisations (#1820)
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
import type { I18n, MessageDescriptor } from '@lingui/core';
|
||||
import { i18n } from '@lingui/core';
|
||||
import type { MacroMessageDescriptor } from '@lingui/core/macro';
|
||||
|
||||
import type { I18nLocaleData, SupportedLanguageCodes } from '../constants/i18n';
|
||||
import { APP_I18N_OPTIONS } from '../constants/i18n';
|
||||
@ -84,3 +85,10 @@ export const extractLocaleData = ({ headers }: ExtractLocaleDataOptions): I18nLo
|
||||
export const parseMessageDescriptor = (_: I18n['_'], value: string | MessageDescriptor) => {
|
||||
return typeof value === 'string' ? value : _(value);
|
||||
};
|
||||
|
||||
export const parseMessageDescriptorMacro = (
|
||||
t: (descriptor: MacroMessageDescriptor) => string,
|
||||
value: string | MessageDescriptor,
|
||||
) => {
|
||||
return typeof value === 'string' ? value : t(value);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user