aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/settings/scan-inputs-controller.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2020-09-12 11:22:17 -0400
committerGitHub <noreply@github.com>2020-09-12 11:22:17 -0400
commit41db9ec89b8eb76009f0cf8894aa0f6e2cc2f8bd (patch)
treeaa58d7b8b7a004c1cd35b43c73c61a654608b400 /ext/bg/js/settings/scan-inputs-controller.js
parent568775c6dc9ff4acc2386b8983cda037b87655e0 (diff)
Use a grid layout for scanning inputs (#814)
Diffstat (limited to 'ext/bg/js/settings/scan-inputs-controller.js')
-rw-r--r--ext/bg/js/settings/scan-inputs-controller.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/ext/bg/js/settings/scan-inputs-controller.js b/ext/bg/js/settings/scan-inputs-controller.js
index 3151e4fd..5895ccea 100644
--- a/ext/bg/js/settings/scan-inputs-controller.js
+++ b/ext/bg/js/settings/scan-inputs-controller.js
@@ -129,10 +129,10 @@ class ScanInputField {
prepare(container, include, exclude) {
const node = this._instantiateTemplate('#scan-input-template');
- const includeInputNode = node.querySelector('.scan-input-include .scan-input-field');
- const includeMouseButton = node.querySelector('.scan-input-include .mouse-button');
- const excludeInputNode = node.querySelector('.scan-input-exclude .scan-input-field');
- const excludeMouseButton = node.querySelector('.scan-input-exclude .mouse-button');
+ const includeInputNode = node.querySelector('.scan-input-field[data-property=include]');
+ const includeMouseButton = node.querySelector('.mouse-button[data-property=include]');
+ const excludeInputNode = node.querySelector('.scan-input-field[data-property=exclude]');
+ const excludeMouseButton = node.querySelector('.mouse-button[data-property=exclude]');
const removeButton = node.querySelector('.scan-input-remove');
this._node = node;
@@ -149,8 +149,8 @@ class ScanInputField {
this._eventListeners.addEventListener(removeButton, 'click', this._onRemoveClick.bind(this));
for (const typeCheckbox of node.querySelectorAll('.scan-input-type-checkbox')) {
- const {type} = typeCheckbox.dataset;
- typeCheckbox.dataset.setting = `scanning.inputs[${this._index}].types.${type}`;
+ const {property} = typeCheckbox.dataset;
+ typeCheckbox.dataset.setting = `scanning.inputs[${this._index}].types.${property}`;
}
}