linter fixes

This commit is contained in:
AUTOMATIC1111 2023-08-10 12:58:00 +03:00
parent 6c23061a7d
commit faca86620d
2 changed files with 7 additions and 7 deletions

View File

@ -10,16 +10,16 @@ var observerAccordionOpen = new MutationObserver(function(mutations) {
checkbox.checked = open;
updateInput(checkbox);
extra = gradioApp().querySelector('#' + accordion.id + "-extra");
if(extra){
var extra = gradioApp().querySelector('#' + accordion.id + "-extra");
if (extra) {
extra.style.display = open ? "" : "none";
}
});
});
function inputAccordionChecked(id, checked){
function inputAccordionChecked(id, checked) {
var label = gradioApp().querySelector('#' + id + " .label-wrap");
if(label.classList.contains('open') != checked){
if (label.classList.contains('open') != checked) {
label.click();
}
}
@ -30,8 +30,8 @@ onUiLoaded(function() {
observerAccordionOpen.observe(labelWrap, {attributes: true, attributeFilter: ['class']});
var extra = gradioApp().querySelector('#' + accordion.id + "-extra");
if(extra){
labelWrap.insertBefore(extra, labelWrap.lastElementChild)
if (extra) {
labelWrap.insertBefore(extra, labelWrap.lastElementChild);
}
}
});

View File

@ -13,7 +13,7 @@ from PIL import Image, PngImagePlugin # noqa: F401
from modules.call_queue import wrap_gradio_gpu_call, wrap_queued_call, wrap_gradio_call
from modules import gradio_extensons # noqa: F401
from modules import sd_hijack, sd_models, script_callbacks, ui_extensions, deepbooru, extra_networks, ui_common, ui_postprocessing, progress, ui_loadsave, errors, shared_items, ui_settings, timer, sysinfo, ui_checkpoint_merger, ui_prompt_styles, scripts, sd_samplers, processing, devices, ui_extra_networks
from modules import sd_hijack, sd_models, script_callbacks, ui_extensions, deepbooru, extra_networks, ui_common, ui_postprocessing, progress, ui_loadsave, errors, shared_items, ui_settings, timer, sysinfo, ui_checkpoint_merger, ui_prompt_styles, scripts, sd_samplers, processing, ui_extra_networks
from modules.ui_components import FormRow, FormGroup, ToolButton, FormHTML, InputAccordion
from modules.paths import script_path
from modules.ui_common import create_refresh_button