Skip to content
Snippets Groups Projects
Verified Commit 45d63d52 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

feat: check if element is in a shadowroot.

parent 713fd903
No related branches found
No related tags found
No related merge requests found
...@@ -543,6 +543,15 @@ function internalTemplateLookUp(container, key, ref, path) { ...@@ -543,6 +543,15 @@ function internalTemplateLookUp(container, key, ref, path) {
} }
} }
const rootNode = container.getRootNode();
if (rootNode instanceof ShadowRoot) {
templateID = rootNode.host.getAttribute(ATTRIBUTE_UPDATER_INSERT_TEMPLATE_ID);
template = findDocumentTemplate(templateID, container);
if (template instanceof HTMLTemplateElement) {
return template;
}
}
return findDocumentTemplate(templateID, container); return findDocumentTemplate(templateID, container);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment