GrapesJS Issues

3,464 parsed GitHub issues โ€” 370 solved ยท 90 open. Search, filter and explore battle-tested answers.

3,464 issues found

#6409February 18, 2025by Shuja-Mahmood4 answers
0 reactions

Cannot drag to move components on mobile

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v133 Reproducible demo link https://jsfiddle.net/2hjdrb7L/1/ Describe the bug How to reproduce the bug? Initialize a grapesjs editor using grapesjs v0.22.x with the grapesjs-touch plugin v0.1.1. What is the expected...

bamiendev

Same issue

federica-capobianco

did you manage to solve it? Facing a kind of similar issue

Shuja-Mahmood

Issue still exists in v0.22.6

#6407February 16, 2025by gopukinapp2 answers
0 reactions

Custom traits are not loading inside a custom block

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Version 133.0.6943.98 Reproducible demo link https://codesandbox.io/p/sandbox/loving-breeze-mdls43?file=%2Findex.js%3A77%2C6 Describe the bug Iam trying to add some custom triats to my block unfortunately i can only see th...

artf

Your component has inner components, so if you select one of those, you will see traits of those components, not event-block. If you properly select event-block, you'll see your traits. <img width="856" alt="Image" src="https://github.com/...

GJS Helper

The issue you're encountering, where custom traits don't load for a custom block when its components property contains complex HTML but do load with a simple string, is a known behavior related to how GrapesJS parses and manages component...

#6394February 1, 2025by spyjo1 answer
0 reactions

layer manager bug on Safari Mac

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Safari 18.3 Macos 14.7.3 Reproducible demo link https://grapesjs.com/demo.html Describe the bug How to reproduce the bug? Open the Layer Manager on the right panel Try to hide "body", or open it OR click on an element, the...

GJS Helper

It appears you've encountered a known rendering quirk specific to Safari, particularly with how it handles flexbox layouts and potentially icon fonts within those layouts. The GrapesJS Layer Manager utilizes a flexbox structure for its lay...

#6376January 18, 2025by Harshsne261 answer
0 reactions

setting min value to stylemanager config

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://codepen.io/Harshsne/pen/ZYzjaYe Describe the bug What is the expected behavior? border width should be incremented from 1 when min is set to 1. What is the current behavior? But the va...

GJS Helper

The issue you're encountering with the min value not affecting the initial display of 0 for border-width is a common point of confusion. The min property in GrapesJS style manager primarily affects the stepper/slider controls and validatio...

#6374January 17, 2025by Harshsne262 answers
1 reactions

Cursor position misplaced

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://codepen.io/Harshsne/pen/gbYjOWO Describe the bug How to reproduce the bug? I have called onactive on single click so that i can edit the textbox in single click. The cursor should be p...

mohamedsalem401

Hey, I've checked your code and tried to debug it. It seems to me that the code is not passing the mouse event to the onActive method, which is needed: ```js componentEl.addEventListener('click', (ev) => { component.view.onActive(ev); });

GJS Helper

The issue you're experiencing, where the cursor always goes to the beginning of the text box when activating editing on a single click, stems from how contenteditable elements are programmatically activated versus how they behave with nati...

#6373January 16, 2025by ChipiKaf2 answers
1 reactions

Resizing of Child with absolute drag enabled positions element wrongly when in Parent with relative position

GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Version 131.0.6778.265 Reproducible demo link https://codepen.io/chipikaf/pen/KwPexjL Describe the bug How to reproduce the bug? Drop the button component in the Middle section Move the button anywhere in the section Resiz...

ChipiKaf

@artf I have a fix for it locally. Essentially what I do is check if the element has a parent with relative position, then offset the rect by the height of the parent if it exists and is position relative. I can create a PR for it if that'...

GJSBlock

Thanks for reporting this, @ChipiKaf. Great question about Resizing of Child with absolute drag enabled positions element wrongly when in Parent with relative position. The recommended approach with Components is to use the event-driven AP...

#6369January 14, 2025by hubermat2 answers
0 reactions

Display order of border radius is not correct

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v130 Reproducible demo link https://grapesjs.com/demo-newsletter-editor.html Describe the bug How to reproduce the bug?in the editor, select any elementin the styles section, go to border radius What is the expected...

DarrenHou1993

This change fixes the UI issue, but it introduces a value issue here. When setting the bottom-left corner radius, it actually modifies the bottom-right corner instead.

GJS Helper

The issue you've identified regarding the swapped display order of border-bottom-left-radius and border-bottom-right-radius in the GrapesJS Style Manager is a known quirk in the default configuration of older GrapesJS versions or specific...

#6365January 8, 2025by MLMarxx4 answers
0 reactions

Style Manager Fails to Interpret Descendant Selectors Correctly

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Version 131.0.6778.205 Reproducible demo link https://codesandbox.io/p/sandbox/naughty-microservice-5hp3h4 Describe the bug How to reproduce the bug:Add the dark-style class to the body: js editor.CssComposer.addRul...

artf

Yeah, that's not supported as there might be some performance implications trying to match any possible rule there. What you can do though is select any rule via styleManager.select

MLMarxx

Ok, thanks for clarification - currently using select, any ideas how to target media tags that way?

artf

You can get the CSSRule you need (getRule) and then pass it to styleManager.select

#6358December 19, 2024by rhoenerSBS2 answers
0 reactions

BlockManager config "appendOnClick" does not work anymore

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v131 Reproducible demo link https://jsfiddle.net/0uaxn2vc/2/ Describe the bug How to reproduce the bug?open link to fiddleselect body or other component where components can be addedtry to add component only by clic...

artf

Thanks @rhoenerSBS the issue was fixed here and will be available in the next release.

GJS Helper

The appendOnClick option in GrapesJS's BlockManager is indeed broken in recent versions, leading to the Uncaught TypeError: c.setDropContent is not a function error. This issue stems from a change in how the BlockView handles click events...

#6357December 13, 2024by Harshsne261 answer
0 reactions

!important is added to every component styles

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://codepen.io/Harshsne/pen/YPKwRBg Describe the bug How to reproduce the bug?Add row component from blockmanager.change its width in stylemanager .(!important is added because its default...

GJSBlock

Thanks for reporting this, @Harshsne26. Great question about !important is added to every component styles. The recommended approach with StyleManager is to use the event-driven API. Start here: Check the GrapesJS documentation for your sp...