added notes lable translation

This commit is contained in:
Roland Osborne 2024-03-07 12:31:05 -08:00
parent 2c416d5150
commit b0fd1a2cd6
7 changed files with 26 additions and 21 deletions

View File

@ -176,7 +176,9 @@ export const en = {
integrated: 'Integrated',
microphone: 'Microphone',
camera: 'Camera'
camera: 'Camera',
notes: 'Notes',
};
export const fr = {
@ -357,7 +359,9 @@ export const fr = {
integrated: 'Intégré',
microphone: 'Microphone',
camera: 'Caméra'
camera: 'Caméra',
notes: 'Notes',
};
export const sp = {
@ -538,5 +542,7 @@ export const sp = {
integrated: 'Integrado',
microphone: 'Micrófono',
camera: 'Cámara'
camera: 'Cámara',
notes: 'Notas',
}

View File

@ -271,7 +271,7 @@ export function useRingContext() {
audioTrack.current.stop();
audioTrack.current = null;
}
updateState({ callStatus: null });
updateState({ callStatus: null, remoteVideo: false, remoteAudio: false });
}
ws.current.onopen = async () => {
ws.current.send(JSON.stringify({ AppToken: token }));
@ -394,7 +394,7 @@ export function useRingContext() {
}
catch (err) {
calling.current = null;
updateState({ callStatus: null });
updateState({ callStatus: null, remoteVideo: false, remoteAudio: false });
}
let index = 0;

View File

@ -36,6 +36,11 @@ export function Session() {
const remote = useRef();
const local = useRef();
useEffect(() => {
console.log(">> ", state.remoteVideo);
}, [state.remoteVideo]);
useEffect(() => {
let incoming = [];
for (let i = 0; i < state.ringing.length; i++) {
@ -71,9 +76,6 @@ export function Session() {
remote.current.load();
remote.current.play();
}
else {
console.log("video player not set");
}
}, [state.remoteStream]);
useEffect(() => {

View File

@ -78,7 +78,7 @@ export function useChannels() {
// set logo and label
if (memberCount === 0) {
item.img = 'solution';
item.label = 'Notes';
item.label = state.strings.notes;
}
else if (memberCount === 1) {
item.logo = logo;

View File

@ -15,6 +15,7 @@ export function useChannelHeader(contentKey) {
title: null,
offsync: false,
display: null,
strings: {},
});
const settings = useContext(SettingsContext);
@ -32,7 +33,8 @@ export function useChannelHeader(contentKey) {
}
useEffect(() => {
updateState({ display: settings.state.display });
const { display, strings } = settings.state;
updateState({ display, strings });
}, [settings.state]);
useEffect(() => {
@ -84,7 +86,7 @@ export function useChannelHeader(contentKey) {
let label;
if (memberCount === 0) {
img = 'solution';
label = 'Notes';
label = state.strings.notes;
}
else if (memberCount === 1) {
label = names.join(',');
@ -126,7 +128,7 @@ export function useChannelHeader(contentKey) {
updateState({ label, img, logo });
}
// eslint-disable-next-line
}, [conversation.state, card.state, contentKey]);
}, [conversation.state, card.state, state.strings, contentKey]);
const actions = {
resync: () => {

View File

@ -165,7 +165,7 @@ export function useDetails() {
let label;
if (memberCount === 0) {
img = 'solution';
label = 'Notes';
label = state.strings.notes;
}
else if (memberCount === 1) {
label = names.join(',');
@ -209,7 +209,7 @@ export function useDetails() {
editMembers: new Set(members) });
}
// eslint-disable-next-line
}, [conversation.state, card.state, state.contentKey]);
}, [conversation.state, card.state, state.strings, state.contentKey]);
const actions = {
setEditSubject: () => {

9
todo
View File

@ -1,15 +1,10 @@
calling:
- dark style
- translation
- layout
- fullscreen
- device selection
add languages:
spanish
portugues
german
russian
fix lint warnings
trim docker image