diff --git a/index.html b/index.html index 7fdb0b7..464ee5f 100644 --- a/index.html +++ b/index.html @@ -21,19 +21,13 @@
Apply Save to preset @@ -256,7 +267,7 @@ function appendLog(message) { * Will save the latest used settings. */ function saveLatestUsedSettings() { - var inputs = document.querySelectorAll('#controller-tab input, #experimental-tab input'); + var inputs = document.querySelectorAll('#main-container *[id$="-tab"] input'); var latest_controller_tabs_settings = {}; inputs.forEach(element => { let id = element.id; @@ -303,7 +314,7 @@ function loadLatestUsedSettings() { * Will show or display options based on apply checkboxes value. */ function toggleOptionDisplayBasedOnApplyCheckbox() { - var checkbox_toggle_options = document.querySelectorAll('#controller-tab input[id^=apply_], #experimental-tab input[id^=apply_]'); + var checkbox_toggle_options = document.querySelectorAll('#main-container *[id$="-tab"] input[id^=apply_]'); const hideOptionBasedOnInput = function (input) { if (input.checked) { input.parentElement.parentElement.nextElementSibling.removeAttribute('hidden'); @@ -476,7 +487,7 @@ function getCurrentSettings(keyType) { return settingsToBeUsed; } else { - var inputs = document.querySelectorAll('#controller-tab input, #experimental-tab input'); + var inputs = document.querySelectorAll('#main-container *[id$="-tab"] input'); var currentSettings = {}; inputs.forEach(element => { let id = element.id;