GrapesJS Issues

3,464 parsed GitHub issues 370 solved · 90 open. Search, filter and explore battle-tested answers.

1,399 issues found

🔍 outdated
#1561Nov 5, 2018by froderf2 answers
0 reactions

Css shorthand

Hello @artf , is there a way to not convert a css added into shorthand? for example: border: 4px solid rgb(239, 13, 24); after visiting the code viewer, the above css is converted to the following ------------------------------------------------------------------------------------ how can I prevent this kind of conver...

artf

That happens due to the browser's CSS parser, which is used by default in GrapesJS. You can prevent that by using grapesjs-parser-postcss

lock[bot]

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.

#1560Nov 3, 2018by froderf2 answers
0 reactions

Apply changes in style mager to one class

Hi @artf, I noticed that when I used the style manager it applies the style to the whole class of the component selected for example if i have a component that has class like this <div class="class1 class2 c1234"></div> the style manager applies the style to is there a way to apply the style only in ".c1234" class? so...

artf

https://github.com/artf/grapesjs/issues/1558

lock[bot]

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.

#1559Nov 3, 2018by jotakar1 answer
0 reactions

Issue: broken links in docs

I've found a pair of broken links in docs https://grapesjs.com/docs/modules/Components/ in page https://grapesjs.com/docs/modules/Blocks.html And https://grapesjs.com/docs/modules/Components-&-JS in https://grapesjs.com/docs/modules/Components.html#components-js Bye.

lock[bot]

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.

#1558Nov 2, 2018by froderf2 answers
0 reactions

Code manager set code

Hi @artf. Is there something similar to this editor.CodeManager.setCode(component, 'css', {cssc: editor.CssComposer} to update the css rule of the selected block returned from editor.CodeManager.getCode(component, 'css', {cssc: editor.CssComposer}); For example: This is the returned css rule collection from using edit...

artf

Hi @froderf, for now, the only way to get that rule is to use CssComposer.get method. In your case, .classx .c1234 is stored inside selectorsAdd as not being a single level class selector (eg. .class1.class2)

lock[bot]

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.

#1557Nov 1, 2018by nine-2-five2 answers
0 reactions

Custom css / z-index in UI

Is there a way to set z-index for a cell/row in the UI (not code)?

artf

If you're looking for how to extend Style Manager check this https://grapesjs.com/docs/getting-started.html#style-manager

lock[bot]

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.

#1556Nov 1, 2018by thanhpd562 answers
0 reactions

Add new block to block manager: predefined content and editor content is different

I try to use template engine with grapesjs. Add new block by this: Drag new block to editor then the content of editor is different from above: (the {% for orderline in order.orderlines %} is moved up) How can i prevent this? Thanks.

artf

If you drop a not valid HTML structure it will be rearranged by the browser, you can't prevent it

lock[bot]

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.

#1555Oct 31, 2018by JulyanoF2 answers
0 reactions

Force block to bottom and single element

Is there some way to force a block to be dropped only at bottom of wrapper and be droppend only a single time (if user remove, can drop it again)?

artf

You can use draggable and droppable properties of the Component as CSS selectors to control what can be dropped and where, so you have the same limits of CSS selectors

lock[bot]

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.

#1554Oct 31, 2018by Aitortilla223 answers
2 reactions

Problem with my Cells when I load again the html and css.

When I retrieve my template from the database. My Cells have become box and I can not modify their width as when they are cells. Can I make my Cells remain cells without becoming something else by retrieving the template? Creating Template Reloading Template

cjpollard

Looks like you're storing/loading incorrectly. Check here. https://grapesjs.com/docs/modules/Storage.html#store-and-load-templates

Aitortilla22

Looks like you're storing/loading incorrectly. Check here. https://grapesjs.com/docs/modules/Storage.html#store-and-load-templates Thank's @cjpollard I wasn't save the components only saved the html. Now I save the components and when I re...

lock[bot]

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.

#1553Oct 31, 2018by nine-2-five3 answers
0 reactions

Use jQuery in view update

I need to manipulate DOM with jQuery, when my model changes, but it seems the View is unaware of it.

yomeshgupta

Yes, $ is available would be available under editor.$ However, I am not sure if that would be full fledged jQuery. You can always insert custom JS scripts in the canvas during initialisation. If you want, you can add jQuery there and then...

artf

@isvaljek use this.$el instead of this.el

lock[bot]

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.

#1550Oct 30, 2018by froderf2 answers
0 reactions

Remove Duplicate Css Rule by Class

Hi @artf , I'm reading and experimenting the setStyle method but when i used setStyle editor.getSelectedToStyle().setStyle({ color: 'red' }) it duplicates the css rule of that class e.g What I want is either removed the existing class or update that existing class css rule This issue is very similar to issue 932. I ne...

froderf

If there's no work around for this issue. what I need right now is used cssComposer.getClassRule() but the problem is, it is selecting the first class and not this updated class

lock[bot]

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.

Browse all topics