From 3ba913bb21cad6a4eef13876144e19f7440435df Mon Sep 17 00:00:00 2001 From: lebaudantoine Date: Mon, 16 Sep 2024 11:28:26 +0200 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=EF=B8=8F(frontend)=20use=20keyprefix?= =?UTF-8?q?=20args?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit My bad, avoid repeating the same prefix. --- .../src/features/rooms/livekit/prefabs/ControlBar.tsx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/frontend/src/features/rooms/livekit/prefabs/ControlBar.tsx b/src/frontend/src/features/rooms/livekit/prefabs/ControlBar.tsx index 7fc24085..4631b00f 100644 --- a/src/frontend/src/features/rooms/livekit/prefabs/ControlBar.tsx +++ b/src/frontend/src/features/rooms/livekit/prefabs/ControlBar.tsx @@ -66,7 +66,7 @@ export function ControlBar({ onDeviceError, ...props }: ControlBarProps) { - const { t } = useTranslation('rooms') + const { t } = useTranslation('rooms', { keyPrefix: 'controls' }) const [isChatOpen, setIsChatOpen] = React.useState(false) const layoutContext = useMaybeLayoutContext() React.useEffect(() => { @@ -156,11 +156,7 @@ export function ControlBar({ } > {showText && - t( - isScreenShareEnabled - ? 'controls.stopScreenShare' - : 'controls.shareScreen' - )} + t(isScreenShareEnabled ? 'stopScreenShare' : 'shareScreen')} )}