Pārlūkot izejas kodu

Update Connection indicator and popover js

master
Ilya Daynatovich 8 gadus atpakaļ
vecāks
revīzija
83e7f23d0f

+ 2
- 2
modules/UI/util/JitsiPopover.js Parādīt failu

@@ -29,8 +29,8 @@ var JitsiPopover = (function () {
29 29
         this.element = element;
30 30
         this.template = ' <div class="jitsipopover ' + this.options.skin +
31 31
             '"><div class="arrow"></div>' +
32
-            '<div class="jitsipopover-content"></div>' +
33
-            '<div class="jitsiPopupmenuPadding"></div></div>';
32
+            '<div class="jitsipopover__content"></div>' +
33
+            '<div class="jitsipopover__menu-padding"></div></div>';
34 34
         var self = this;
35 35
         this.element.on("mouseenter", function () {
36 36
             self.elementIsHovered = true;

+ 19
- 19
modules/UI/videolayout/ConnectionIndicator.js Parādīt failu

@@ -80,10 +80,10 @@ ConnectionIndicator.prototype.generateText = function () {
80 80
         packetLoss = "N/A";
81 81
     } else {
82 82
 
83
-        packetLoss = "<span class='jitsipopover_green'>&darr;</span>" +
83
+        packetLoss = "<span class='jitsipopover__green'>&darr;</span>" +
84 84
             (this.packetLoss.download !== null ?
85 85
                 this.packetLoss.download : "N/A") +
86
-            "% <span class='jitsipopover_orange'>&uarr;</span>" +
86
+            "% <span class='jitsipopover__orange'>&uarr;</span>" +
87 87
             (this.packetLoss.upload !== null? this.packetLoss.upload : "N/A") +
88 88
             "%";
89 89
     }
@@ -97,29 +97,29 @@ ConnectionIndicator.prototype.generateText = function () {
97 97
 
98 98
     var result = "<table style='width:100%'>" +
99 99
         "<tr>" +
100
-        "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.bitrate'>" +
100
+        "<td><span data-i18n='connectionindicator.bitrate'>" +
101 101
         translate("connectionindicator.bitrate") + "</span></td>" +
102
-        "<td><span class='jitsipopover_green'>&darr;</span>" +
103
-        downloadBitrate + " <span class='jitsipopover_orange'>&uarr;</span>" +
102
+        "<td><span class='jitsipopover__green'>&darr;</span>" +
103
+        downloadBitrate + " <span class='jitsipopover__orange'>&uarr;</span>" +
104 104
         uploadBitrate + "</td>" +
105 105
         "</tr><tr>" +
106
-        "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.packetloss'>" +
106
+        "<td><span data-i18n='connectionindicator.packetloss'>" +
107 107
         translate("connectionindicator.packetloss") + "</span></td>" +
108 108
         "<td>" + packetLoss  + "</td>" +
109 109
         "</tr><tr>" +
110
-        "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.resolution'>" +
110
+        "<td><span data-i18n='connectionindicator.resolution'>" +
111 111
         translate("connectionindicator.resolution") + "</span></td>" +
112 112
         "<td>" + resolutionStr + "</td></tr></table>";
113 113
 
114 114
     if(this.videoContainer.videoSpanId == "localVideoContainer") {
115
-        result += "<div class=\"jitsipopover_showmore\" " +
115
+        result += "<a class=\"jitsipopover__showmore link\" " +
116 116
             "onclick = \"APP.UI.connectionIndicatorShowMore('" +
117 117
             // FIXME: we do not know local id when this text is generated
118 118
             //this.id + "')\"  data-i18n='connectionindicator." +
119 119
             "local')\"  data-i18n='connectionindicator." +
120 120
                 (this.showMoreValue ? "less" : "more") + "'>" +
121 121
             translate("connectionindicator." + (this.showMoreValue ? "less" : "more")) +
122
-            "</div><br />";
122
+            "</a>";
123 123
     }
124 124
 
125 125
     if (this.showMoreValue) {
@@ -138,7 +138,7 @@ ConnectionIndicator.prototype.generateText = function () {
138 138
 
139 139
         if (!this.transport || this.transport.length === 0) {
140 140
             transport = "<tr>" +
141
-                "<td><span class='jitsipopover_blue' " +
141
+                "<td><span " +
142 142
                 "data-i18n='connectionindicator.address'>" +
143 143
                 translate("connectionindicator.address") + "</span></td>" +
144 144
                 "<td> N/A</td></tr>";
@@ -171,7 +171,7 @@ ConnectionIndicator.prototype.generateText = function () {
171 171
             var local_address_key = "connectionindicator.localaddress";
172 172
             var remote_address_key = "connectionindicator.remoteaddress";
173 173
             var localTransport =
174
-                "<tr><td><span class='jitsipopover_blue' data-i18n='" +
174
+                "<tr><td><span data-i18n='" +
175 175
                 local_address_key +"' data-i18n-options='" +
176 176
                     JSON.stringify({count: data.localIP.length}) + "'>" +
177 177
                     translate(local_address_key, {count: data.localIP.length}) +
@@ -179,7 +179,7 @@ ConnectionIndicator.prototype.generateText = function () {
179 179
                 ConnectionIndicator.getStringFromArray(data.localIP) +
180 180
                 "</td></tr>";
181 181
             transport =
182
-                "<tr><td><span class='jitsipopover_blue' data-i18n='" +
182
+                "<tr><td><span data-i18n='" +
183 183
                 remote_address_key + "' data-i18n-options='" +
184 184
                     JSON.stringify({count: data.remoteIP.length}) + "'>" +
185 185
                     translate(remote_address_key,
@@ -193,14 +193,14 @@ ConnectionIndicator.prototype.generateText = function () {
193 193
 
194 194
             transport += "<tr>" +
195 195
                 "<td>" +
196
-                "<span class='jitsipopover_blue' data-i18n='" + key_remote +
196
+                "<span data-i18n='" + key_remote +
197 197
                 "' data-i18n-options='" +
198 198
                 JSON.stringify({count: this.transport.length}) + "'>" +
199 199
                 translate(key_remote, {count: this.transport.length}) +
200 200
                 "</span></td><td>";
201 201
             localTransport += "<tr>" +
202 202
                 "<td>" +
203
-                "<span class='jitsipopover_blue' data-i18n='" + key_local +
203
+                "<span data-i18n='" + key_local +
204 204
                 "' data-i18n-options='" +
205 205
                 JSON.stringify({count: this.transport.length}) + "'>" +
206 206
                 translate(key_local, {count: this.transport.length}) +
@@ -213,7 +213,7 @@ ConnectionIndicator.prototype.generateText = function () {
213 213
             transport += "</td></tr>";
214 214
             transport += localTransport + "</td></tr>";
215 215
             transport +="<tr>" +
216
-                "<td><span class='jitsipopover_blue' data-i18n='connectionindicator.transport'>" +
216
+                "<td><span data-i18n='connectionindicator.transport'>" +
217 217
                 translate("connectionindicator.transport") + "</span></td>" +
218 218
                 "<td>" + this.transport[0].type + "</td></tr>";
219 219
 
@@ -222,17 +222,17 @@ ConnectionIndicator.prototype.generateText = function () {
222 222
         result += "<table  style='width:100%'>" +
223 223
             "<tr>" +
224 224
             "<td>" +
225
-            "<span class='jitsipopover_blue' data-i18n='connectionindicator.bandwidth'>" +
225
+            "<span data-i18n='connectionindicator.bandwidth'>" +
226 226
             translate("connectionindicator.bandwidth") + "</span>" +
227 227
             "</td><td>" +
228
-            "<span class='jitsipopover_green'>&darr;</span>" +
228
+            "<span class='jitsipopover__green'>&darr;</span>" +
229 229
             downloadBandwidth +
230
-            " <span class='jitsipopover_orange'>&uarr;</span>" +
230
+            " <span class='jitsipopover__orange'>&uarr;</span>" +
231 231
             uploadBandwidth + "</td></tr>";
232 232
 
233 233
         result += transport + "</table>";
234 234
     }
235
-
235
+    
236 236
     return result;
237 237
 };
238 238
 

Notiek ielāde…
Atcelt
Saglabāt