Emi Matchu
0011fdf76a
My intent is to next add behavior to save this state across pageloads, for power users to not have to always reopen it!
13 lines
435 B
JavaScript
13 lines
435 B
JavaScript
const headers = document.querySelectorAll(".item-header");
|
|
for (const header of headers) {
|
|
try {
|
|
const form = header.querySelector(".user-lists-form");
|
|
const opener = header.querySelector(".user-lists-form-opener");
|
|
opener.addEventListener("click", (event) => {
|
|
form.toggleAttribute("hidden");
|
|
event.preventDefault();
|
|
});
|
|
} catch (error) {
|
|
console.error(`Error applying dialog behavior to item header:`, error);
|
|
}
|
|
}
|