mirror of
https://github.com/Theodor-Springmann-Stiftung/musenalm.git
synced 2026-02-04 10:35:30 +00:00
+Dynamic textarea sizing
This commit is contained in:
@@ -245,6 +245,19 @@ export class DivManager extends HTMLElement {
|
||||
this.renderMenu();
|
||||
this.renderButton();
|
||||
this.updateTargetVisibility();
|
||||
|
||||
// Resize any textareas in the newly shown element
|
||||
if (typeof window.TextareaAutoResize === "function") {
|
||||
const textareas = child.node.querySelectorAll("textarea");
|
||||
if (textareas.length > 0) {
|
||||
// Small delay to ensure element is visible before measuring
|
||||
setTimeout(() => {
|
||||
textareas.forEach((textarea) => {
|
||||
window.TextareaAutoResize(textarea);
|
||||
});
|
||||
}, 10);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
renderMenu() {
|
||||
|
||||
Reference in New Issue
Block a user