fix translation values in details tab (#5841)

Signed-off-by: si458 <simonsmith5521@gmail.com>

Simon Smith committed Feb 21, 2024 at 15:00 UTC a80c0ef48c24abc0ef86cf99c97ce3eb58fedf13
1 file changed +10 -8
views/default.handlebars
+10 -8
@@ -8127,7 +8127,7 @@
8127
8128 function deviceMessageFunction() {
8129 if (xxdialogMode) return;
8130 - var x = '<div style=margin-bottom:4px>Display a message box on the remote device.</div>';
8130 + var x = '<div style=margin-bottom:4px>' + "Display a message box on the remote device" + '</div>';
8131 x += '<textarea id=d2devMessage style=background-color:#fcf3cf;width:100%;height:80px;resize:none;overflow-y:scroll;box-sizing:border-box;margin-bottom:4px></textarea>';
8132 x += '<select style=width:100% id=d2devTimeout>';
8133 x += '<option value=2 selected>' + "Show for 2 Minutes (Default)" + '</option>';
@@ -11719,8 +11719,8 @@
11719 data: {
11720 labels: [],
11721 datasets: [
11722 - { label: 'CPU', backgroundColor: 'rgba(134, 16, 158, .5)', borderColor: 'rgb(134, 16, 158)', data: [], fill: true },
11723 - { label: 'Memory', backgroundColor: 'rgba(255, 99, 132, .5)', borderColor: 'rgb(255, 99, 132)', data: [], fill: true }
11722 + { label: "CPU", backgroundColor: 'rgba(134, 16, 158, .5)', borderColor: 'rgb(134, 16, 158)', data: [], fill: true },
11723 + { label: "Memory", backgroundColor: 'rgba(255, 99, 132, .5)', borderColor: 'rgb(255, 99, 132)', data: [], fill: true }
11724 ] },
11725 options: {
11726 events: ['click'],
@@ -12040,9 +12040,9 @@
12040 if (tpm.SpecVersion) { x += addDetailItem("SpecVersion", parseFloat(EscapeHtml(tpm.SpecVersion)).toFixed(1), s); }
12041 if (tpm.ManufacturerId) { x += addDetailItem("ManufacturerId", EscapeHtml(tpm.ManufacturerId), s); }
12042 if (tpm.ManufacturerVersion) { x += addDetailItem("ManufacturerVersion", EscapeHtml(tpm.ManufacturerVersion), s); }
12043 - if (tpm.IsActivated != null) { x += addDetailItem("IsActivated", EscapeHtml(tpm.IsActivated), s); }
12044 - if (tpm.IsEnabled != null) { x += addDetailItem("IsEnabled", EscapeHtml(tpm.IsEnabled), s); }
12045 - if (tpm.IsOwned != null) { x += addDetailItem("IsOwned", EscapeHtml(tpm.IsOwned), s); }
12043 + if (tpm.IsActivated != null) { x += addDetailItem("IsActivated", (tpm.IsActivated ? "Yes" : "No"), s); }
12044 + if (tpm.IsEnabled != null) { x += addDetailItem("IsEnabled", (tpm.IsEnabled ? "Yes" : "No"), s); }
12045 + if (tpm.IsOwned != null) { x += addDetailItem("IsOwned", (tpm.IsOwned ? "Yes" : "No"), s); }
12046 if (x != '') { sections.push({ name: "TPM", html: x, img: 'tpm64.png'}); }
12047 }
12048
@@ -12134,12 +12134,14 @@
12134 var fsize = (j === 0 ? `${m.size} ${sizes[j]}` : `${(m.size / (1024 ** j)).toFixed(2)} ${sizes[j]}`);
12135 x += addDetailItem("Capacity", EscapeHtml(fsize), s);
12136 }
12137 - if (m.type) { x += addDetailItem("File System", (m.removable == true ? ("Removable" + ' / ') : '') + EscapeHtml(m.type), s); }
12137 + if (m.type) { x += addDetailItem("File System", (m.removable == true ? ("Removable" + ' / ') : '') + (m.type == 'Unknown' ? "Unknown" : EscapeHtml(m.type)), s); }
12138
12139 if (m.protectionStatus || m.volumeStatus) {
12140 var bitlockerState = [];
12141 if (m.protectionStatus) bitlockerState.push("Enabled");
12142 - if (m.volumeStatus) bitlockerState.push(EscapeHtml(m.volumeStatus));
12142 + if (m.volumeStatus && m.volumeStatus == 'FullyDecrypted') bitlockerState.push("Fully Decrypted");
12143 + if (m.volumeStatus && m.volumeStatus == 'EncryptionInProgress') bitlockerState.push("Encryption In Progress");
12144 + if (m.volumeStatus && m.volumeStatus == 'FullyEncrypted') bitlockerState.push("Fully Encrypted");
12145 bitlockerState = bitlockerState.join(' - ');
12146 if (m.recoveryPassword) { bitlockerState += addKeyLink('', 'deviceDetailsShowBitlockerInfo(\"' + encodeURIComponentEx(i) + '\",\"' + encodeURIComponentEx(m.identifier) + '\",\"' + encodeURIComponentEx(m.recoveryPassword) + '\")'); }
12147 x += addDetailItem("BitLocker", bitlockerState, s);