mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-21 10:45:20 -04:00
Update dependency i18next to v21.5.2 (#1643)
* Update dependency i18next to v21.5.2 Signed-off-by: Renovate Bot <bot@renovateapp.com> * Fix i18n imports Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de> Co-authored-by: Renovate Bot <bot@renovateapp.com> Co-authored-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
29e646e180
commit
c75978c9a4
5 changed files with 11 additions and 12 deletions
|
@ -5,7 +5,7 @@
|
|||
*/
|
||||
|
||||
import type { TOptions } from 'i18next'
|
||||
import i18n from 'i18next'
|
||||
import { t } from 'i18next'
|
||||
import { store } from '../index'
|
||||
import type { DismissUiNotificationAction, DispatchOptions } from './types'
|
||||
import { UiNotificationActionType } from './types'
|
||||
|
@ -75,7 +75,7 @@ export const dismissUiNotification = (notificationId: number): void => {
|
|||
export const showErrorNotification =
|
||||
(messageI18nKey: string, messageI18nOptions?: TOptions | string) =>
|
||||
(error: Error): void => {
|
||||
log.error(i18n.t(messageI18nKey, messageI18nOptions), error)
|
||||
log.error(t(messageI18nKey, messageI18nOptions), error)
|
||||
void dispatchUiNotification('common.errorOccurred', messageI18nKey, {
|
||||
contentI18nOptions: messageI18nOptions,
|
||||
icon: 'exclamation-triangle'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue