GrapesJS Issues

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

545 issues found

🔍 typescript
#5330Aug 24, 2023by rozek3 answers
0 reactions

Latest version (commit 4f0c5b1) no longer compiles without errors

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? none Reproducible demo link none Describe the bug yarn build fails with two errors: This may just be a problem with TypeScript being too picky, becauseyou may disable the error messages using // @ts-ignore and compile agai...

artf

Thanks @rozek I'll fix it now

rozek

thank you very much!

GJS Helper

Thank you for reporting this issue. You've accurately identified a TypeScript compilation error (TS2532: Object is possibly 'undefined') occurring in the test/specs/utils/Sorter.ts file when running yarn build on GrapesJS commit 4f0c5b1. R...

#5328Aug 22, 2023by sdimitrenco2 answers
0 reactions

Editable text after remove focus of RTE, returns back previous state of content.

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://jsfiddle.net/sdimitrenco/wao1rh0q/30/ Describe the bug That is my components struct If I change the text in the span tag in the text editor, then remove focus from that word, it return...

artf

You shouldn't have "content" inside your text span, indeed if you replace it with "components": "[email protected]", it will work properly.

GJS Helper

The issue you're experiencing, where editable text within a nested span (a text component) inside a link component reverts to its previous state after losing focus, is a known synchronization challenge in GrapesJS when dealing with nested...

#5320Aug 18, 2023by SwapnilSoni19994 answers
0 reactions

Upload Image or Asset is not triggering on File/Image selection

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v114 Reproducible demo link none Describe the bug How to reproduce the bug?I'm using grapesjs-react and using assetManagerMy config looks like this PS: I do have a working endpoint which I've tested already.Now goto...

iamuddeshya

Facing same issue

deepanshu-ht

++ 1

artf

Just tried the same configuration and all works as expected. Might be related to your grapesjs version or the grapesjs-react itself. Please avoid creating BUG issues if you're not able to provide a reproducible demo with the latest version...

#5312Aug 17, 2023by srinivas9772 answers
0 reactions

Issue with rich text editor Indent action for Lists

GrapesJS version[X] I confirm to use the latest version of GrapesJSWhat browser are you using? Chrome V115Reproducible demo link https://jsfiddle.net/srinivas977/ahgLxv6e/10/Describe the bug How to reproduce the bug? In the provided JSFiddle, include a pair of text lines and select lists. Next, append a sub-list, and...

artf

Unfortunately, as the default implementation relies on the deprecated execCommand, there are too many edge cases to handle and it isn't worth spending time on it anymore. I'd suggest relying on it only for basic formatting (eg. bold, itali...

GJSBlock

Thanks for reporting this, @srinivas977. Great suggestion about Issue with rich text editor Indent action for Lists! While this specific feature isn't yet in the core API, there are several ways to achieve similar behavior. Using the event...

#5305Aug 13, 2023by rajevar2 answers
0 reactions

"component:add" event triggers when components are moved

GrapesJS version 0.21.4[X] I confirm to use the latest version of GrapesJSWhat browser are you using? Chrome Version 113.0.5672.63 Reproducible demo link https://jsfiddle.net/szLp8h4n/11/Describe the bug How to reproduce the bug? Move any of the text components around in the page. An alert will be displayed. could be...

artf

Hi @rajevar I think you're looking for component:create event, as component:add works as expected (eg. might be used to track any new movement inside a specific component)

GJS Helper

You've correctly identified a common point of confusion with GrapesJS event handling. The component:add event indeed triggers not only when a new component is dragged from the blocks panel onto the canvas but also when an existing componen...

#5288Aug 9, 2023by pittleCheung2 answers
0 reactions

Use tsup-node build grapesjs appear Uncaught Error: Dynamic require of "codemirror/lib/codemirror" is not supported

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? latest version of Chrome Reproducible demo link null Describe the bug How to reproduce the bug?tsup-node src/index.ts --format esm,cjs --legacy-output --watch What is the expected behavior? I use vite to build grapesjs Wha...

artf

I think you have to address that to Vite community, the core is using webpack right now and it works as expected

GJS Helper

The error "Uncaught Error: Dynamic require of "codemirror/lib/codemirror" is not supported" arises when you're trying to bundle GrapesJS (or a library that uses GrapesJS) with a modern bundler like tsup (especially when targeting ESM) that...

#5286Aug 8, 2023by saharhagekr2 answers
0 reactions

Border of images and some elements in the wrong position

On smaller laptop screens (macbooks for example), the border of images and some elements are in the wrong position (when i click to move or resize an image) I am not having this issue when the editor gets rendered on bigger screens. I am not sure if there is a config step that i'm missing. Can anyone please assist? Is...

artf

@saharelhage please avoid converting discussions to issues. The GitHub Issues should only be created from here by properly following the template.

GJS Helper

The issue you're experiencing with the selection and resize borders appearing in the wrong position on smaller screens, particularly MacBooks, is a common problem often related to how browsers render content under different scaling conditi...

#5269Aug 2, 2023by sannila1 answer
0 reactions

Object literal may only specify known properties, and 'el' does not exist in type 'PanelProps'.

GrapesJS version[X] I confirm to use the latest version of GrapesJSWhat browser are you using? Chrome 115.0Reproducible demo link https://jsfiddle.net/varyqjo7/Describe the bug How to reproduce the bug?Create a new Angular project (version 16.1.3)Install grapesjs latest version (npm i grapesjs)Add css and js in angula...

GJS Helper

The issue you're encountering, "Object literal may only specify known properties, and 'el' does not exist in type 'PanelProps'", is a TypeScript compilation error. It indicates that the el property is not a valid or recognized property wit...

#5263Jul 28, 2023by pittleCheung4 answers
3 reactions

Deleting a component without deleting its corresponding style, will adding new components later cause style conflicts?

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? latest version of Chrome Reproducible demo link null Describe the bug How to reproduce the bug? <img width="1666" alt="image" src="https://github.com/GrapesJS/grapesjs/assets/114127651/c37e339a-e14f-486b-85fb-34c170b855dd"...

pittleCheung

Yes , you are right, I copying all matched styles ,so I can paste anywhere , even cross-browser paste, I find this to be extremely useful. When I delete a component, it does not remove the corresponding styles. This is a major issue, And w...

pittleCheung

it‘s still a problem

artf

I don't see how this is a core bug. You're using your own copy/paste logic and it doesn't even seem correct, you should take care of the unique ids of each component/rule.After deleting these child components, their styles still remain. If...

#5249Jul 24, 2023by pittleCheung3 answers
0 reactions

Editor?.Css.addRules(targetCss);

GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? latest version of Chrome Reproducible demo link null Describe the bug How to reproduce the bug? editor?.Css.addRules(targetCss); What is the expected behavior? editor?.Css.addRules(targetCss); it add style at end <img widt...

artf

This is not a bug, Css.addRules doesn't have any option argument. You can open a discussion in regard to this topic and we can see if it makes sense to introduce it

pittleCheung

ok, I get it,I need to add some styles in front of an array, not at the end. such as arr.unshift(css) How can I do that? I might need a little help from you

GJS Helper

The behavior you're observing with editor.Css.addRules() is actually the expected and intended functionality of the GrapesJS CSS API. By default, when you use editor.Css.addRules(targetCss);, the new CSS rules are appended to the end of th...

Browse all topics