diff --git a/manage.html b/manage.html index 78f2e6d8..0ef738a0 100644 --- a/manage.html +++ b/manage.html @@ -227,7 +227,7 @@ - + diff --git a/manage/import-export.js b/manage/import-export.js index 865915c9..87a8c92b 100644 --- a/manage/import-export.js +++ b/manage/import-export.js @@ -392,8 +392,8 @@ Object.assign(document.body, { this.ondragend(); if (event.dataTransfer.files.length) { event.preventDefault(); - if ($('#onlyUpdates input').checked) { - $('#onlyUpdates input').click(); + if ($('#only-updates input').checked) { + $('#only-updates input').click(); } importFromFile({file: event.dataTransfer.files[0]}); } diff --git a/manage/manage.css b/manage/manage.css index 1e32f78c..c48c1604 100644 --- a/manage/manage.css +++ b/manage/manage.css @@ -392,6 +392,13 @@ select { background-color: hsla(0, 0%, 50%, .2); } +#only-updates { + position: relative; + left: -5px; + margin-top: 2px; + margin-bottom: 2px; +} + .checkmate { position: relative; height: 12px; diff --git a/manage/updater-ui.js b/manage/updater-ui.js index 8149000e..216f6cee 100644 --- a/manage/updater-ui.js +++ b/manage/updater-ui.js @@ -108,7 +108,7 @@ function reportUpdateState(state, style, details) { entry.classList.add('can-update'); entry.updatedCode = style; $('.update-note', entry).textContent = ''; - $('#onlyUpdates').classList.remove('hidden'); + $('#only-updates').classList.remove('hidden'); break; case BG.updater.SKIPPED: { if (entry.classList.contains('can-update')) { @@ -151,12 +151,12 @@ function reportUpdateState(state, style, details) { function renderUpdatesOnlyFilter({show, check} = {}) { const numUpdatable = $$('.can-update').length; const mightUpdate = numUpdatable > 0 || $('.update-problem'); - const checkbox = $('#onlyUpdates input'); + const checkbox = $('#only-updates input'); show = show !== undefined ? show : mightUpdate; check = check !== undefined ? show && check : checkbox.checked && mightUpdate; - $('#onlyUpdates').classList.toggle('hidden', !show); - checkbox.checked = check; + $('#only-updates').classList.toggle('hidden', !show); + checkbox.checked = check && show; checkbox.dispatchEvent(new Event('change')); const btnApply = $('#apply-all-updates');