From bf94a5dcaf18f7d7fc6601fcc917b303c04ec2d6 Mon Sep 17 00:00:00 2001 From: Robin Townsend Date: Mon, 24 Oct 2022 10:17:12 -0400 Subject: [PATCH] Make more of the lobby translateable --- public/locales/en-GB/app.json | 2 +- src/room/LobbyView.tsx | 40 ++++++++++++++++++----------------- 2 files changed, 22 insertions(+), 20 deletions(-) diff --git a/public/locales/en-GB/app.json b/public/locales/en-GB/app.json index 44e3c2f..2b1facc 100644 --- a/public/locales/en-GB/app.json +++ b/public/locales/en-GB/app.json @@ -8,6 +8,7 @@ "{{roomName}} - Walkie-talkie call": "{{roomName}} - Walkie-talkie call", "<0>Already have an account?<1><0>Log in Or <2>Access as a guest": "<0>Already have an account?<1><0>Log in Or <2>Access as a guest", "<0>Create an account Or <2>Access as a guest": "<0>Create an account Or <2>Access as a guest", + "<0>Join call now<1>Or<2>Copy call link and join later": "<0>Join call now<1>Or<2>Copy call link and join later", "<0>Oops, something's gone wrong.<1>Submitting debug logs will help us track down the problem.": "<0>Oops, something's gone wrong.<1>Submitting debug logs will help us track down the problem.", "<0>Why not finish by setting up a password to keep your account?<1>You'll be able to keep your name and set an avatar for use on future calls": "<0>Why not finish by setting up a password to keep your account?<1>You'll be able to keep your name and set an avatar for use on future calls", "Accept camera/microphone permissions to join the call.": "Accept camera/microphone permissions to join the call.", @@ -28,7 +29,6 @@ "Connection lost": "Connection lost", "Copied!": "Copied!", "Copy and share this call link": "Copy and share this call link", - "Copy call link and join later": "Copy call link and join later", "Create account": "Create account", "Debug log": "Debug log", "Debug log request": "Debug log request", diff --git a/src/room/LobbyView.tsx b/src/room/LobbyView.tsx index b246d0c..aae3f24 100644 --- a/src/room/LobbyView.tsx +++ b/src/room/LobbyView.tsx @@ -19,7 +19,7 @@ import { GroupCall, GroupCallState } from "matrix-js-sdk/src/webrtc/groupCall"; import { MatrixClient } from "matrix-js-sdk/src/client"; import { PressEvent } from "@react-types/shared"; import { CallFeed } from "matrix-js-sdk/src/webrtc/callFeed"; -import { useTranslation } from "react-i18next"; +import { Trans, useTranslation } from "react-i18next"; import styles from "./LobbyView.module.css"; import { Button, CopyButton } from "../button"; @@ -130,24 +130,26 @@ export function LobbyView({ audioOutput={audioOutput} /> )} - - Or - - {t("Copy call link and join later")} - + + + Or + + Copy call link and join later + + {!isEmbedded && (