diff options
Diffstat (limited to 'ext/bg')
-rw-r--r-- | ext/bg/js/options.js | 3 | ||||
-rw-r--r-- | ext/bg/js/settings.js | 2 | ||||
-rw-r--r-- | ext/bg/settings.html | 5 |
3 files changed, 9 insertions, 1 deletions
diff --git a/ext/bg/js/options.js b/ext/bg/js/options.js index 7d993987..2197c72c 100644 --- a/ext/bg/js/options.js +++ b/ext/bg/js/options.js @@ -219,7 +219,8 @@ function optionsSetDefaults(options) { delay: 20, length: 10, modifier: 'shift', - deepDomScan: false + deepDomScan: false, + popupNestingMaxDepth: 0 }, dictionaries: {}, diff --git a/ext/bg/js/settings.js b/ext/bg/js/settings.js index f5d669b2..de1616f3 100644 --- a/ext/bg/js/settings.js +++ b/ext/bg/js/settings.js @@ -51,6 +51,7 @@ async function formRead() { optionsNew.scanning.delay = parseInt($('#scan-delay').val(), 10); optionsNew.scanning.length = parseInt($('#scan-length').val(), 10); optionsNew.scanning.modifier = $('#scan-modifier-key').val(); + optionsNew.scanning.popupNestingMaxDepth = parseInt($('#popup-nesting-max-depth').val(), 10); optionsNew.anki.enable = $('#anki-enable').prop('checked'); optionsNew.anki.tags = $('#card-tags').val().split(/[,; ]+/); @@ -192,6 +193,7 @@ async function onReady() { $('#scan-delay').val(options.scanning.delay); $('#scan-length').val(options.scanning.length); $('#scan-modifier-key').val(options.scanning.modifier); + $('#popup-nesting-max-depth').val(options.scanning.popupNestingMaxDepth); $('#dict-purge-link').click(utilAsync(onDictionaryPurge)); $('#dict-file').change(utilAsync(onDictionaryImport)); diff --git a/ext/bg/settings.html b/ext/bg/settings.html index cc140023..a0d08ec5 100644 --- a/ext/bg/settings.html +++ b/ext/bg/settings.html @@ -215,6 +215,11 @@ <option value="shift">Shift</option> </select> </div> + + <div class="form-group options-advanced"> + <label for="popup-nesting-max-depth">Maximum nested popup depth</label> + <input type="number" min="0" id="popup-nesting-max-depth" class="form-control"> + </div> </div> <div> |