Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

Merge branch 'master' into translations-update

damenchoefed4bf13cdc
diff --cc modules/UI/authentication/LoginDialog.js
index 89f2b756dd,6ee3606f32..8eb01d22fc
--- a/modules/UI/authentication/LoginDialog.js
+++ b/modules/UI/authentication/LoginDialog.js
@@@ -8,13 -8,15 +8,14 @@@ function getPasswordInputHtml()
let placeholder = config.hosts.authdomain
? "user identity"
+
return `
- <h2 data-i18n="dialog.passwordRequired"></h2>
- <input name="username" type="text" placeholder=${placeholder} autofocus>
+ <input name="username" type="text"
+ class="input-control__input"
+ placeholder=${placeholder} autofocus>
<input name="password" type="password"
- data-i18n="[placeholder]dialog.userPassword"
- placeholder="user password">
- `;
+ class="input-control__input"
- data-i18n="[placeholder]dialog.userPassword"
- placeholder="user password">`;
++ data-i18n="[placeholder]dialog.userPassword">`;
}
/**
@@@ -77,6 -79,7 +78,7 @@@ function LoginDialog(successCallback, c
const states = {
login: {
- title: APP.translation.translateString('dialog.passwordRequired'),
++ titleKey: 'dialog.passwordRequired',
html: getPasswordInputHtml(),
buttons: loginButtons,
focus: ':input:first',
diff --cc modules/UI/util/JitsiPopover.js
index f8addfee52,6331c647a3..adaab69458
--- a/modules/UI/util/JitsiPopover.js
+++ b/modules/UI/util/JitsiPopover.js
@@@ -76,9 -86,7 +86,9 @@@ var JitsiPopover = (function ()
*/
JitsiPopover.prototype.createPopover = function () {
$("body").append(this.template);
- let popoverElem = $(".jitsipopover > .jitsipopover-content");
- $(".jitsipopover > .jitsipopover__content").html(this.options.content);
++ let popoverElem = $(".jitsipopover > .jitsipopover__content");
+ popoverElem.html(this.options.content);
+ APP.translation.translateElement(popoverElem);
var self = this;
$(".jitsipopover").on("mouseenter", function () {
self.popoverIsHovered = true;
diff --cc modules/UI/videolayout/ConnectionIndicator.js
index f6259f4036,f3de53b1e9..43850adb1d
--- a/modules/UI/videolayout/ConnectionIndicator.js
+++ b/modules/UI/videolayout/ConnectionIndicator.js
@@@ -93,26 -95,48 +93,40 @@@ ConnectionIndicator.prototype.generateT
return `${width}x${height}`;
}).join(', ') || 'N/A';
- var result = "<table style='width:100%'>" +
- "<tr>" +
- "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.bitrate'></span></td>" +
- "<td><span class='jitsipopover_green'>&darr;</span>" +
- downloadBitrate + " <span class='jitsipopover_orange'>&uarr;</span>" +
- uploadBitrate + "</td>" +
- "</tr><tr>" +
- "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.packetloss'></span></td>" +
- "<td>" + packetLoss + "</td>" +
- "</tr><tr>" +
- "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.resolution'></span></td>" +
- "<td>" + resolutionStr + "</td></tr></table>";
+ let result = (
+ `<table class="connection-info__container" style='width:100%'>
+ <tr>
+ <td>
- <span data-i18n='connectionindicator.bitrate'>
- ${translate("connectionindicator.bitrate")}
- </span>
++ <span data-i18n='connectionindicator.bitrate'></span>
+ </td>
+ <td>
+ <span class='connection-info__download'>&darr;</span>${downloadBitrate}
+ <span class='connection-info__upload'>&uarr;</span>${uploadBitrate}
+ </td>
+ </tr>
+ <tr>
+ <td>
- <span data-i18n='connectionindicator.packetloss'>
- ${translate("connectionindicator.packetloss")}
- </span>
++ <span data-i18n='connectionindicator.packetloss'></span>
+ </td>
+ <td>${packetLoss}</td>
+ </tr>
+ <tr>
+ <td>
- <span data-i18n='connectionindicator.resolution'>
- ${translate("connectionindicator.resolution")}
- </span>
++ <span data-i18n='connectionindicator.resolution'></span>
+ </td>
+ <td>
+ ${resolutionStr}
+ </td>
+ </tr>
+ </table>`);
if(this.videoContainer.videoSpanId == "localVideoContainer") {
- result += "<div class=\"jitsipopover_showmore\" " +
+ result += "<a class=\"jitsipopover__showmore link\" " +
"onclick = \"APP.UI.connectionIndicatorShowMore('" +
// FIXME: we do not know local id when this text is generated
//this.id + "')\" data-i18n='connectionindicator." +
"local')\" data-i18n='connectionindicator." +
- (this.showMoreValue ? "less" : "more") + "'></div><br />";
- (this.showMoreValue ? "less" : "more") + "'>" +
- translate("connectionindicator." + (this.showMoreValue ? "less" : "more")) +
- "</a>";
++ (this.showMoreValue ? "less" : "more") + "'></a>";
}
if (this.showMoreValue) {
@@@ -131,8 -155,9 +145,8 @@@
if (!this.transport || this.transport.length === 0) {
transport = "<tr>" +
- "<td><span class='jitsipopover_blue' " +
+ "<td><span " +
- "data-i18n='connectionindicator.address'>" +
- translate("connectionindicator.address") + "</span></td>" +
+ "data-i18n='connectionindicator.address'></span></td>" +
"<td> N/A</td></tr>";
} else {
var data = {remoteIP: [], localIP:[], remotePort:[], localPort:[]};
@@@ -163,15 -188,20 +177,17 @@@
var local_address_key = "connectionindicator.localaddress";
var remote_address_key = "connectionindicator.remoteaddress";
var localTransport =
- "<tr><td><span class='jitsipopover_blue' data-i18n='" +
+ "<tr><td><span data-i18n='" +
local_address_key +"' data-i18n-options='" +
- JSON.stringify({count: data.localIP.length}) + "'></span></td><td> " +
- JSON.stringify({count: data.localIP.length}) + "'>" +
- translate(local_address_key, {count: data.localIP.length}) +
- "</span></td><td> " +
++ JSON.stringify({count: data.localIP.length})
++ + "'></span></td><td> " +
ConnectionIndicator.getStringFromArray(data.localIP) +
"</td></tr>";
transport =
- "<tr><td><span class='jitsipopover_blue' data-i18n='" +
+ "<tr><td><span data-i18n='" +
remote_address_key + "' data-i18n-options='" +
- JSON.stringify({count: data.remoteIP.length}) + "'></span></td><td> " +
- JSON.stringify({count: data.remoteIP.length}) + "'>" +
- translate(remote_address_key,
- {count: data.remoteIP.length}) +
- "</span></td><td> " +
++ JSON.stringify({count: data.remoteIP.length})
++ + "'></span></td><td> " +
ConnectionIndicator.getStringFromArray(data.remoteIP) +
"</td></tr>";
@@@ -180,14 -210,18 +196,16 @@@
transport += "<tr>" +
"<td>" +
- "<span class='jitsipopover_blue' data-i18n='" + key_remote +
+ "<span data-i18n='" + key_remote +
"' data-i18n-options='" +
- JSON.stringify({count: this.transport.length}) + "'></span></td><td>";
- JSON.stringify({count: this.transport.length}) + "'>" +
- translate(key_remote, {count: this.transport.length}) +
- "</span></td><td>";
++ JSON.stringify({count: this.transport.length})
++ + "'></span></td><td>";
localTransport += "<tr>" +
"<td>" +
- "<span class='jitsipopover_blue' data-i18n='" + key_local +
+ "<span data-i18n='" + key_local +
"' data-i18n-options='" +
- JSON.stringify({count: this.transport.length}) + "'></span></td><td>";
- JSON.stringify({count: this.transport.length}) + "'>" +
- translate(key_local, {count: this.transport.length}) +
- "</span></td><td>";
++ JSON.stringify({count: this.transport.length})
++ + "'></span></td><td>";
transport +=
ConnectionIndicator.getStringFromArray(data.remotePort);
@@@ -196,19 -230,21 +214,20 @@@
transport += "</td></tr>";
transport += localTransport + "</td></tr>";
transport +="<tr>" +
- "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.transport'></span></td>" +
+ "<td><span data-i18n='connectionindicator.transport'>" +
- translate("connectionindicator.transport") + "</span></td>" +
++ "</span></td>" +
"<td>" + this.transport[0].type + "</td></tr>";
}
- result += "<table style='width:100%'>" +
+ result += "<table class='connection-info__container' style='width:100%'>" +
"<tr>" +
"<td>" +
- "<span class='jitsipopover_blue' data-i18n='connectionindicator.bandwidth'></span>" +
- "<span data-i18n='connectionindicator.bandwidth'>" +
- translate("connectionindicator.bandwidth") + "</span>" +
++ "<span data-i18n='connectionindicator.bandwidth'></span>" +
"</td><td>" +
- "<span class='jitsipopover_green'>&darr;</span>" +
+ "<span class='connection-info__download'>&darr;</span>" +
downloadBandwidth +
- " <span class='jitsipopover_orange'>&uarr;</span>" +
+ " <span class='connection-info__upload'>&uarr;</span>" +
uploadBandwidth + "</td></tr>";
result += transport + "</table>";
@@@ -247,8 -283,9 +266,9 @@@ ConnectionIndicator.prototype.create =
this.connectionIndicatorContainer);
this.popover = new JitsiPopover(
$("#" + this.videoContainer.videoSpanId + " > .connectionindicator"),
- {content: "<div class=\"connection_info\" data-i18n='connectionindicator.na'></div>",
- {content: "<div class=\"connection-info\" data-i18n='connectionindicator.na'>" +
- APP.translation.translateString("connectionindicator.na") + "</div>",
-- skin: "black"});
++ {content: "<div class=\"connection-info\" " +
++ "data-i18n='connectionindicator.na'></div>",
++ skin: "black"});
// override popover show method to make sure we will update the content
// before showing the popover
@@@ -359,8 -396,9 +379,8 @@@ ConnectionIndicator.prototype.updatePop
// popover is visible or we force to do so.
if(this.popover.popoverShown || force) {
this.popover.updateContent(
- `<div class="connection_info">${this.generateText()}</div>`
+ `<div class="connection-info">${this.generateText()}</div>`
);
- APP.translation.translateElement($(".connection-info"));
}
};