Replies: 2 comments 2 replies
-
Give this a try, I was putting together a test demo to get something working with a similar but different request. I stopped working on it because the others in the chat couldn't agree on direction. As a demo, it was coded in 5 minutes, so it isn't structured as an extension/built-in, it's done in a nasty way. While running the webui and loaded in browser, open your browsers devtools and go to the js console. You can try ctrl+shift+j. My question is, is there a use for a filter like this, should I try and make it an option. I noticed you mentioned a search feature for extras, I'm unfamiliar with it, but will check it out to get more familiar with what you had in mind. let myInput = document.createElement("input");
let modelDropdown = gradioApp().getElementById("setting_sd_model_checkpoint");
myInput.classList = gradioApp().getElementById("txt2img_prompt").querySelector("textarea").classList;
modelDropdown.nextElementSibling.insertAdjacentElement("afterend", myInput);
let selectOptions = modelDropdown.querySelectorAll("select option");
myInput.addEventListener('input', function() {
let inputValue = this.value.toLowerCase().replace(/\*/g, '.*');
let regex = new RegExp(inputValue);
selectOptions.forEach(option => {
if (option.innerText.toLowerCase().match(regex)) {
option.style.display = 'block';
} else {
option.style.display = 'none';
}
});
}); |
Beta Was this translation helpful? Give feedback.
-
Regarding checkpoint models, I would like to ask if it is possible, to have an option where we can manage all checkpoints for the "copy&paste" case when useing XYZ plot with the checkpoints. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
don't know about anyone else, but I have almost 300 models now and the dropdown menu is getting kind of tiresome.
now that there was an added search feature for 'extra networks', can't the checkpoints get the same treatment?
Beta Was this translation helpful? Give feedback.
All reactions