Unique ID on block content without inline style
@pouyamiralayi My bad - worked it out, I had some old 'CssComposer.setRule' still hanging about!!!!!! (since I had debug enabled on my development pc) That was appending the .row class. (That is embarrassing) Thanks for the point in the right direction regarding the selector 'private: false' - it's working a treat :)...
Read full answer below ↓Question
Hi All, I made a custom block manager element, but when the element is edited, it applies the style to the class, which means all the same elements are also impacted. If I set an inline style to the element, it then applies the style to the custom class / ID. Without in line style: Code: With inline style: Code: Is it possible to force the style manager (my be the wrong name) to create the custom ID / Class and then apply the style to that? Instead of amending the noncustom class?
Answers (3)
@pouyamiralayi My bad - worked it out, I had some old 'CssComposer.setRule' still hanging about!!!!!! (since I had debug enabled on my development pc) That was appending the .row class. (That is embarrassing) Thanks for the point in the right direction regarding the selector 'private: false' - it's...
Hi @adamwpe here are the approaches which block unwanted selectors: #1979 comment and #404 comment Cheers!
@adamwpe can you confirm that by deactivating row selector: active:false in the add:selector event, you are still receiving the selector?
Related Questions and Answers
Continue research with similar issue discussions.
Issue #3512
Child elements not draggable ,droppable highlightable. also the CSS of all child elements not pushed in style section while develop a banner component in as plugin
Hello @artf , I am trying to develop a simple banner plugin which will be include a heading , subheading and link. and every element can be...
Issue #2651
[QUESTION] Background image via inline style not accessible?
This is very simple, but i can not access the background image set via CSS, within my custom block 'content'. How do i change the backgroun...
Issue #661
Class attribute not removed
Hello ! I noticed a problem with style manager when we add/remove classes. When we remove all classes it doesn't remove then from the gener...
Issue #4529
When we resize an image with a class 'xyz', all the elements on the page with same class also gets resized because editor adds css to those classes.
GrapesJS version[X] I confirm to use the latest version of GrapesJSWhat browser are you using? Version 104.0.5112.101 (Official Build) (arm...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins →Premium plugins ship with support, regular updates, and production-ready features — save days of integration work.
Browse premium plugins →Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.