Merge pull request #114 from koloml/bugfix/missing-re-initialization-for-tags-list

Tags List: Fixed re-initialization of the component after tags were submitted
This commit is contained in:
koloml authored and GitHub committed 2025-03-26 21:06:15 +04:00
commit c26c4bcf62
1 file changed
+8 -1
+8 -1
View File
@@ -196,6 +196,13 @@ export function initializeAllTagsLists() {
export function watchForUpdatedTagLists() {
on(document, eventFormEditorUpdated, event => {
event.detail.closest('#image_tags_and_source')
const tagsListElement = event.detail.closest<HTMLElement>('#image_tags_and_source');
if (!tagsListElement || getComponent(tagsListElement)) {
return;
}
new TagsListBlock(tagsListElement)
.initialize();
});
}