🌐(frontend) prepare translation keys for expanded recording types
Restructure translation keys to support a more extensive set of recording types in the future.
This commit is contained in:
committed by
aleb_the_flash
parent
d537a4449a
commit
69381a6c4b
@@ -7,13 +7,14 @@ import { useTranslation } from 'react-i18next'
|
|||||||
import { NotificationType } from '../NotificationType'
|
import { NotificationType } from '../NotificationType'
|
||||||
|
|
||||||
export function ToastTranscript({ state, ...props }: ToastProps) {
|
export function ToastTranscript({ state, ...props }: ToastProps) {
|
||||||
const { t } = useTranslation('notifications')
|
const { t } = useTranslation('notifications', { keyPrefix: 'transcript' })
|
||||||
const ref = useRef(null)
|
const ref = useRef(null)
|
||||||
const { toastProps, contentProps } = useToast(props, state, ref)
|
const { toastProps, contentProps } = useToast(props, state, ref)
|
||||||
const participant = props.toast.content.participant
|
const participant = props.toast.content.participant
|
||||||
const type = props.toast.content.type
|
const type = props.toast.content.type
|
||||||
|
|
||||||
const key = `recording${type == NotificationType.TranscriptionStarted ? 'Started' : 'Stopped'}`
|
const key =
|
||||||
|
type == NotificationType.TranscriptionStarted ? 'started' : 'stopped'
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<StyledToastContainer {...toastProps} ref={ref}>
|
<StyledToastContainer {...toastProps} ref={ref}>
|
||||||
|
|||||||
@@ -11,7 +11,9 @@ import { NotificationType } from '@/features/notifications/NotificationType'
|
|||||||
import { TranscriptionStatus, transcriptionStore } from '@/stores/transcription'
|
import { TranscriptionStatus, transcriptionStore } from '@/stores/transcription'
|
||||||
|
|
||||||
export const TranscriptStateToast = () => {
|
export const TranscriptStateToast = () => {
|
||||||
const { t } = useTranslation('rooms', { keyPrefix: 'recording.transcript' })
|
const { t } = useTranslation('rooms', {
|
||||||
|
keyPrefix: 'recordingBadge.transcript',
|
||||||
|
})
|
||||||
const room = useRoomContext()
|
const room = useRoomContext()
|
||||||
|
|
||||||
const transcriptionSnap = useSnapshot(transcriptionStore)
|
const transcriptionSnap = useSnapshot(transcriptionStore)
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
"open": "",
|
"open": "",
|
||||||
"accept": ""
|
"accept": ""
|
||||||
},
|
},
|
||||||
"recordingStarted": "",
|
"transcript": {
|
||||||
"recordingStopped": ""
|
"started": "",
|
||||||
|
"stopped": ""
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -292,7 +292,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"recording": {
|
"recordingBadge": {
|
||||||
"transcript": {
|
"transcript": {
|
||||||
"started": "",
|
"started": "",
|
||||||
"starting": "",
|
"starting": "",
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
"open": "Open",
|
"open": "Open",
|
||||||
"accept": "Accept"
|
"accept": "Accept"
|
||||||
},
|
},
|
||||||
"recordingStarted": "{{name}} started the meeting transcription.",
|
"transcript": {
|
||||||
"recordingStopped": "{{name}} stopped the meeting transcription."
|
"started": "{{name}} started the meeting transcription.",
|
||||||
|
"stopped": "{{name}} stopped the meeting transcription."
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -291,7 +291,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"recording": {
|
"recordingBadge": {
|
||||||
"transcript": {
|
"transcript": {
|
||||||
"started": "Transcribing",
|
"started": "Transcribing",
|
||||||
"starting": "Transcription starting",
|
"starting": "Transcription starting",
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
"open": "Afficher",
|
"open": "Afficher",
|
||||||
"accept": "Accepter"
|
"accept": "Accepter"
|
||||||
},
|
},
|
||||||
"recordingStarted": "{{name}} a démarré la transcription de la réunion.",
|
"transcript": {
|
||||||
"recordingStopped": "{{name}} a arrêté la transcription de la réunion."
|
"started": "{{name}} a démarré la transcription de la réunion.",
|
||||||
|
"stopped": "{{name}} a arrêté la transcription de la réunion."
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -291,7 +291,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"recording": {
|
"recordingBadge": {
|
||||||
"transcript": {
|
"transcript": {
|
||||||
"started": "Transcription en cours",
|
"started": "Transcription en cours",
|
||||||
"starting": "Démarrage de la transcription",
|
"starting": "Démarrage de la transcription",
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
"open": "Openen",
|
"open": "Openen",
|
||||||
"accept": "Accepteren"
|
"accept": "Accepteren"
|
||||||
},
|
},
|
||||||
"recordingStarted": "{{name}} is de transcriptie van de vergadering gestart.",
|
"transcript": {
|
||||||
"recordingStopped": "{{name}} heeft de transcriptie van de vergadering gestopt."
|
"started": "{{name}} is de transcriptie van de vergadering gestart.",
|
||||||
|
"stopped": "{{name}} heeft de transcriptie van de vergadering gestopt."
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -291,7 +291,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"recording": {
|
"recordingBadge": {
|
||||||
"transcript": {
|
"transcript": {
|
||||||
"started": "Transcriptie bezig",
|
"started": "Transcriptie bezig",
|
||||||
"starting": "Transcriptie begint",
|
"starting": "Transcriptie begint",
|
||||||
|
|||||||
Reference in New Issue
Block a user