Closed sriya-srinivasan closed 3 years ago
Hey @sriya-srinivasan can you create a reproducible demo, please?
@sriya-srinivasan any update please?
Yeah Im trying but its proprietary code, so it'll take a while to create and include a similar component. But it is related to this issue. They are using a component created in plain JS, the one we are working on is using lit-element.
Posted a workaround here https://github.com/artf/grapesjs/issues/3693
This is related to lit-element version update. Link to the issue here.
Here is the link to a reproducible demo.
@artf do we need to reopen this issue?
hey guys, from what I see, is more like an issue related to lit 3, which doesn't allow the reuse of web components across same-origin iframes, am I right? In that case, not being a user of the framework I'd ask you to let me know if there is anything I can do.
ps. being an issue with an external framework, I'd keep the issue closed
Hi @artf , is there any way we can define the element in iframe as the author of lit had suggested
@GaikwadShubham you might use canvas.scripts
option to load external scripts in the iframe but as Web Components are supposed to work across same-origin iframes, I'm not sure is the right approach.
Version: 0.17.19
What is the current behavior? That the added webcomponent is visible:
When adding web components inside grapesjs container, the component is empty/blank, if the component has elements in the shadow DOM. (If not using shadow dom to create components there is no issue.) It is visible in layer manager, but empty
Here we can see the diffrence between the element inside and outside. The shadow root is not visible.
What is the expected behavior? The webcomponent inside grapesjs canvas needs to be rendered and look similar to the one outside, on top of the editor.
Are you able to attach screenshots, screencasts or a live demo?
This is the error in the console.