mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
add toggle for mobile gestures
This commit is contained in:
@ -132,7 +132,6 @@ let power_user = {
|
||||
|
||||
custom_css: '',
|
||||
|
||||
|
||||
waifuMode: false,
|
||||
movingUI: false,
|
||||
movingUIState: {},
|
||||
@ -140,7 +139,7 @@ let power_user = {
|
||||
noShadows: false,
|
||||
theme: 'Default (Dark) 1.7.1',
|
||||
|
||||
|
||||
gestures: true,
|
||||
auto_swipe: false,
|
||||
auto_swipe_minimum_length: 0,
|
||||
auto_swipe_blacklist: [],
|
||||
@ -892,7 +891,6 @@ function loadPowerUserSettings(settings, data) {
|
||||
const timestamps = localStorage.getItem(storage_keys.timestamps_enabled);
|
||||
const mesIDDisplay = localStorage.getItem(storage_keys.mesIDDisplay_enabled);
|
||||
const expandMessageActions = localStorage.getItem(storage_keys.expand_message_actions);
|
||||
console.log(expandMessageActions)
|
||||
power_user.fast_ui_mode = fastUi === null ? true : fastUi == "true";
|
||||
power_user.movingUI = movingUI === null ? false : movingUI == "true";
|
||||
power_user.noShadows = noShadows === null ? false : noShadows == "true";
|
||||
@ -901,7 +899,6 @@ function loadPowerUserSettings(settings, data) {
|
||||
power_user.timestamps_enabled = timestamps === null ? true : timestamps == "true";
|
||||
power_user.mesIDDisplay_enabled = mesIDDisplay === null ? true : mesIDDisplay == "true";
|
||||
power_user.expand_message_actions = expandMessageActions === null ? true : expandMessageActions == "true";
|
||||
console.log(power_user.expand_message_actions)
|
||||
power_user.avatar_style = Number(localStorage.getItem(storage_keys.avatar_style) ?? avatar_styles.ROUND);
|
||||
//power_user.chat_display = Number(localStorage.getItem(storage_keys.chat_display) ?? chat_styles.DEFAULT);
|
||||
power_user.chat_width = Number(localStorage.getItem(storage_keys.chat_width) ?? 50);
|
||||
@ -930,6 +927,7 @@ function loadPowerUserSettings(settings, data) {
|
||||
$('#continue_on_send').prop("checked", power_user.continue_on_send);
|
||||
$('#quick_continue').prop("checked", power_user.quick_continue);
|
||||
$('#mes_continue').css('display', power_user.quick_continue ? '' : 'none');
|
||||
$('#gestures-checkbox').prop("checked", power_user.gestures);
|
||||
$('#auto_swipe').prop("checked", power_user.auto_swipe);
|
||||
$('#auto_swipe_minimum_length').val(power_user.auto_swipe_minimum_length);
|
||||
$('#auto_swipe_blacklist').val(power_user.auto_swipe_blacklist.join(", "));
|
||||
@ -2184,6 +2182,11 @@ $(document).ready(() => {
|
||||
saveSettingsDebounced();
|
||||
});
|
||||
|
||||
$('#gestures-checkbox').on('change', function () {
|
||||
power_user.gestures = !!$('#gestures-checkbox').prop('checked');
|
||||
saveSettingsDebounced();
|
||||
});
|
||||
|
||||
$('#auto_swipe').on('input', function () {
|
||||
power_user.auto_swipe = !!$(this).prop('checked');
|
||||
saveSettingsDebounced();
|
||||
|
Reference in New Issue
Block a user