[QUESTION] How to place a component at the end of the canvas.
How can I put my footer at the end of the canvas?
I want the editor to not allow placing a block/widget below the footer.
example
<!-- only allow dragging/placing of widgets here -->
FOOTER
<!-- Should not have blocks/widgets below this -->
You can use something like this
const footer = '<div style="padding: 100px">My footer</div>';
editor.getWrapper().getEl().insertAdjacentHTML('afterEnd', footer);
@artf Do we have something like removeAdjacentHTML()
editor.getWrapper().getEl().removeAdjacentHTML('afterEnd', footer);
because when we used
const footer = '<div style="padding: 100px">My footer</div>';
editor.getWrapper().getEl().insertAdjacentHTML('afterEnd', footer);
it keeps duplicating every after you reload the window.
I'm looking for a way to solve this but no luck :( Seems like a bug?
Do we have something like removeAdjacentHTML()
getEl() gives you the HTMLElement instance so insertAdjacentHTML is from DOM API, not GrapesJS
it keeps duplicating every after you reload the window.
... can you create a reproducible demo?
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.