Await settings load

This commit is contained in:
Cohee 2024-09-01 18:01:21 +03:00
parent 2b2a29554d
commit 94ef9e8908
4 changed files with 5 additions and 5 deletions

View File

@ -502,4 +502,4 @@
#horde_model {
height: unset;
}
}
}

View File

@ -608,4 +608,4 @@ ul.li-padding-bot5 li {
ul.li-padding-bot10 li {
padding-bottom: 10px;
}
}

View File

@ -1613,7 +1613,7 @@ async function loadPowerUserSettings(settings, data) {
switchReducedMotion();
switchCompactInputArea();
reloadMarkdownProcessor(power_user.render_formulas);
loadInstructMode(data);
await loadInstructMode(data);
await loadContextSettings();
loadMaxContextUnlocked();
switchWaifuMode();
@ -1767,7 +1767,7 @@ async function loadContextSettings() {
// If the setting already exists, no need to duplicate it
// TODO: Maybe check the power_user object for the setting instead of a flag?
$element.on('input keyUp', async function () {
$element.on('input keyup', async function () {
const value = control.isCheckbox ? !!$(this).prop('checked') : $(this)[0].innerText;
if (control.isGlobalSetting) {
power_user[control.property] = value;

View File

@ -5456,4 +5456,4 @@ body:not(.movingUI) .drawer-content.maximized {
#advanced-formatting-button div[contenteditable="true"] {
overflow-wrap: anywhere;
}
}