BUG: StyleManager AppendTo not showing in custom div
Question
GrapesJS version
- I confirm to use the latest version of GrapesJS
What browser are you using?
Chrome 93
Reproducible demo link
https://codepen.io/paooolino/pen/WNOPgJy
Describe the bug
How to reproduce the bug? This is quite simple because I was using Grapes v.0.16.xx and it worked until I upgraded to the latest release and my StyleManager panel disappeared. I can provide a codepen with previous version (working) https://codepen.io/paooolino/pen/jOwdvZv
and then another one with identical code but upgraded library (not working) https://codepen.io/paooolino/pen/WNOPgJy
The code is quite simple because I just need to show the styleManager in a custom div with some sectors defined.
I looked for similar issues but I didnt found my case. I also tried with appendTo: '#panels' either with dom element as in the codepens.
What is the expected behavior? The styleManager should be shown in the defined #panels div.
What is the current behavior? The styleManager does not shows.
Maybe I missed something? Thankyou for your attention.
Code of Conduct
- I agree to follow this project's Code of Conduct
Answers (3)
I verified it is since v0.17.25
v0.17.22 >>> working v0.17.25 >>> not working
Thanks Paolo, that will be fixed in the next release. The problem is with the default StyleManager opener command, which moves the rendered part, from your container, to the default one. You can verify that by disabling the default button which activates the command (which moves the element once pressed).
editor.Panels.getButton('views', 'open-sm').set('active', false);
So, as a workaround, you should delete it or hide it with CSS
editor.Panels.removeButton('views', 'open-sm');
thankyou for the release. And sorry for reopening :-) but now the StyleManager appendTo is working, while the blockManager appendTo appears to be broken. Same problem with the previous StyleManager. I verified it was working in previous v.0.17.26 but now v.0.17.27 is not showing. 🙏Just tell me if you need a codepen.
Related Questions and Answers
Continue research with similar issue discussions.
Issue #4998
BUG: showOffsetsSelected not working
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chome v111 Reproducible demo link https://...
Issue #3938
BUG: editor.select(model,{scroll:true}) ,scroll don't work
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://code...
Issue #4310
BUG: Style Manager is inaccurate when using combined CSS selectors which contains "bout" and componentFirst = true
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome 100 Reproducible demo link https://...
Issue #4208
BUG: Style click state bug in every element
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Brave Last, tested on chrome last and Safa...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.