mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2025-08-09 07:45:01 +02:00
Collapsibles for the embeddings dialog
Harmonization with the modifiers dialog
This commit is contained in:
@ -129,6 +129,31 @@ function tryLoadOldCollapsibles() {
|
||||
return null
|
||||
}
|
||||
|
||||
function collapseAll(selector) {
|
||||
const collapsibleElems = document.querySelectorAll(selector); // needs to have ";"
|
||||
|
||||
[...collapsibleElems].forEach((elem) => {
|
||||
const isActive = elem.classList.contains("active")
|
||||
|
||||
if(isActive) {
|
||||
elem?.click()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function expandAll(selector) {
|
||||
const collapsibleElems = document.querySelectorAll(selector); // needs to have ";"
|
||||
|
||||
[...collapsibleElems].forEach((elem) => {
|
||||
const isActive = elem.classList.contains("active")
|
||||
|
||||
if (!isActive) {
|
||||
elem?.click()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
function permute(arr) {
|
||||
let permutations = []
|
||||
let n = arr.length
|
||||
|
Reference in New Issue
Block a user