Save settings after switching style toggle

61c148a5f0510ccc1cd0080faabae3a5256d1d99

Cohee <18619528+Cohee1207@users.noreply.github.com>

1 files changed, +10 -10Ignore whitespace
public/scripts/power-user.js+10 -10
@@ -3503,36 +3503,36 @@ $(document).ready(() => {
3503 $('#messageTimerEnabled').on('input', function () {3503 $('#messageTimerEnabled').on('input', function () {
3504 const value = !!$(this).prop('checked');3504 const value = !!$(this).prop('checked');
3505 power_user.timer_enabled = value;3505 power_user.timer_enabled = value;
3506 saveSettingsDebounced();
3507 switchTimer();3506 switchTimer();
3507 saveSettingsDebounced();
3508 });3508 });
35093509
3510 $('#messageTimestampsEnabled').on('input', function () {3510 $('#messageTimestampsEnabled').on('input', function () {
3511 const value = !!$(this).prop('checked');3511 const value = !!$(this).prop('checked');
3512 power_user.timestamps_enabled = value;3512 power_user.timestamps_enabled = value;
3513 saveSettingsDebounced();
3514 switchTimestamps();3513 switchTimestamps();
3514 saveSettingsDebounced();
3515 });3515 });
35163516
3517 $('#messageModelIconEnabled').on('input', function () {3517 $('#messageModelIconEnabled').on('input', function () {
3518 const value = !!$(this).prop('checked');3518 const value = !!$(this).prop('checked');
3519 power_user.timestamp_model_icon = value;3519 power_user.timestamp_model_icon = value;
3520 saveSettingsDebounced();
3521 switchIcons();3520 switchIcons();
3521 saveSettingsDebounced();
3522 });3522 });
35233523
3524 $('#messageTokensEnabled').on('input', function () {3524 $('#messageTokensEnabled').on('input', function () {
3525 const value = !!$(this).prop('checked');3525 const value = !!$(this).prop('checked');
3526 power_user.message_token_count_enabled = value;3526 power_user.message_token_count_enabled = value;
3527 saveSettingsDebounced();
3528 switchTokenCount();3527 switchTokenCount();
3528 saveSettingsDebounced();
3529 });3529 });
35303530
3531 $('#expandMessageActions').on('input', function () {3531 $('#expandMessageActions').on('input', function () {
3532 const value = !!$(this).prop('checked');3532 const value = !!$(this).prop('checked');
3533 power_user.expand_message_actions = value;3533 power_user.expand_message_actions = value;
3534 saveSettingsDebounced();
3535 switchMessageActions();3534 switchMessageActions();
3535 saveSettingsDebounced();
3536 });3536 });
35373537
3538 $('#enableZenSliders').on('input', function () {3538 $('#enableZenSliders').on('input', function () {
@@ -3544,8 +3544,8 @@ $(document).ready(() => {
3544 return;3544 return;
3545 }3545 }
3546 power_user.enableZenSliders = value;3546 power_user.enableZenSliders = value;
3547 saveSettingsDebounced();
3548 switchZenSliders();3547 switchZenSliders();
3548 saveSettingsDebounced();
3549 });3549 });
35503550
3551 $('#enableLabMode').on('input', function () {3551 $('#enableLabMode').on('input', function () {
@@ -3558,22 +3558,22 @@ $(document).ready(() => {
3558 }3558 }
35593559
3560 power_user.enableLabMode = value;3560 power_user.enableLabMode = value;
3561 saveSettingsDebounced();
3562 switchLabMode();3561 switchLabMode();
3562 saveSettingsDebounced();
3563 });3563 });
35643564
3565 $('#mesIDDisplayEnabled').on('input', function () {3565 $('#mesIDDisplayEnabled').on('input', function () {
3566 const value = !!$(this).prop('checked');3566 const value = !!$(this).prop('checked');
3567 power_user.mesIDDisplay_enabled = value;3567 power_user.mesIDDisplay_enabled = value;
3568 saveSettingsDebounced();
3569 switchMesIDDisplay();3568 switchMesIDDisplay();
3569 saveSettingsDebounced();
3570 });3570 });
35713571
3572 $('#hideChatAvatarsEnabled').on('input', function () {3572 $('#hideChatAvatarsEnabled').on('input', function () {
3573 const value = !!$(this).prop('checked');3573 const value = !!$(this).prop('checked');
3574 power_user.hideChatAvatars_enabled = value;3574 power_user.hideChatAvatars_enabled = value;
3575 saveSettingsDebounced();
3576 switchHideChatAvatars();3575 switchHideChatAvatars();
3576 saveSettingsDebounced();
3577 });3577 });
35783578
3579 $('#hotswapEnabled').on('input', function () {3579 $('#hotswapEnabled').on('input', function () {
@@ -3688,8 +3688,8 @@ $(document).ready(() => {
3688 $('#ui_mode_select').on('change', function () {3688 $('#ui_mode_select').on('change', function () {
3689 const value = $(this).find(':selected').val();3689 const value = $(this).find(':selected').val();
3690 power_user.ui_mode = Number(value);3690 power_user.ui_mode = Number(value);
3691 saveSettingsDebounced();
3692 switchSimpleMode();3691 switchSimpleMode();
3692 saveSettingsDebounced();
3693 });3693 });
36943694
3695 $('#bogus_folders').on('input', function () {3695 $('#bogus_folders').on('input', function () {