mirror of
https://github.com/wukko/cobalt.git
synced 2025-06-13 05:37:44 +02:00
web/translations: handle error contexts
This commit is contained in:
@ -77,7 +77,7 @@
|
|||||||
|
|
||||||
return createDialog({
|
return createDialog({
|
||||||
...defaultErrorPopup,
|
...defaultErrorPopup,
|
||||||
bodyText: $t(response.error.code),
|
bodyText: $t(response.error.code, response?.error?.context),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,6 +25,8 @@ const defaultLocale = 'en';
|
|||||||
const config: Config<{
|
const config: Config<{
|
||||||
value?: string;
|
value?: string;
|
||||||
formats?: string;
|
formats?: string;
|
||||||
|
limit?: number;
|
||||||
|
service?: string;
|
||||||
}> = {
|
}> = {
|
||||||
fallbackLocale: defaultLocale,
|
fallbackLocale: defaultLocale,
|
||||||
translations: Object.keys(parsedLocfiles).reduce((obj, lang) => {
|
translations: Object.keys(parsedLocfiles).reduce((obj, lang) => {
|
||||||
|
Reference in New Issue
Block a user