diff --git a/addons/urejectFX/log.js b/addons/urejectFX/log.js
index 3ea31c605..14c087826 100644
--- a/addons/urejectFX/log.js
+++ b/addons/urejectFX/log.js
@@ -3,16 +3,36 @@ function newrow(w) {
let tr = tt.insertRow(tt.rows.length);
tr.innerHTML = w;
}
-newrow('
FQDN | Servilo | Stato | Kie | Kiam |
');
-browser.runtime.sendMessage('get').then(g => {
- for (let k in g) {
- newrow('' + k + ' | ' + g[k][1] + ' | ' + g[k][2] + ' | 🔗 | ' + g[k][3] + ' |
');
- document.getElementById('export').innerHTML += k + "\n";
- }
-});
-document.body.style.display = 'block';
-document.getElementById('clear').addEventListener('click', () => {
- browser.runtime.sendMessage('clear').then(() => {
- location.reload(true);
+document.addEventListener('DOMContentLoaded', () => {
+ browser.storage.local.get(['ul']).then((r) => {
+ fetch('i18n/' + (r.ul || 'eo') + '.json', {
+ method: 'GET'
+ }).then(j => j.json()).then(j => {
+ document.querySelectorAll('span[transk]').forEach(x => {
+ x.innerText = j[x.getAttribute('transk')];
+ });
+ newrow('FQDN | ' + j['lj1'] + ' | ' + j['lj2'] + ' | ' + j['lj3'] + ' | ' + j['lj4'] + ' |
');
+ browser.runtime.sendMessage('get').then(g => {
+ for (let k in g) {
+ newrow('' + k + ' | ' + g[k][1] + ' | ' + g[k][2] + ' | 🔗 | ' + g[k][3] + ' |
');
+ document.getElementById('export').innerHTML += k + "\n";
+ }
+ });
+ document.body.style.display = 'block';
+ });
+ });
+ document.getElementById('clear').addEventListener('click', () => {
+ browser.runtime.sendMessage('clear').then(() => {
+ location.reload(true);
+ });
+ });
+ document.getElementById('myul').addEventListener('change', () => {
+ if (document.getElementById('myul').value != '') {
+ browser.storage.local.set({
+ 'ul': document.getElementById('myul').value
+ }).then(() => {
+ location.reload(true);
+ });
+ }
});
});
\ No newline at end of file