blob: 10608b4875e0bd7d0169cf109b62b2b3612a8288 [file] [log] [blame]
<div id=iframe>
<div id=wrapper>
<div id=host>
<template shadowroot=open>
<span id=content>Content</span>
</template>
</div>
</div>
</div>
<script>
function sendStatus(error, hasShadow, msg) {
const name = window.name;
parent.postMessage({ name, error, hasShadow, msg }, '*');
}
window.addEventListener('load', () => {
const host = document.querySelector('#host');
if (!host)
return sendStatus(true, false, 'Unable to find host element');
return sendStatus(false, !!host.shadowRoot);
});
</script>