GrapesJS Issues

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

644 issues found

🔍 components
#1617November 29, 2018by coder-strange2 answers
3 reactions

[Question] How can I stop the drop from block:drag:start event? Also is there any event to listen Invalid target position?

First of all, I really appreciate your replies on my questions. Thank you for all. Question 1 : I've a situation where if a particular block is already in the canvas, I can't let that block to be added again. What I'm doing is, I'm listing to block:drag:start and compares if the component is already dropped (in gjs-co...

artf

Question 1 : I've a situation where if a particular block is already in the canvas, I can't let that block to be added again. What I'm doing is, I'm listing to block:drag:start and compares if the component is already dropped (in gjs-compo...

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.

#1611November 27, 2018by ThomasLaigneau3 answers
0 reactions

Script tag create JSON error

Hi. I'm creating blocks in Grapesjs and I need to use JS on them for hover effect and more.. Everything works fine for the creation, store, load and the style of each blocks. I have a problem when I add the <script></script> tag to my block. It works fine when I drag the block for the first time but when I store and r...

artf

https://stackoverflow.com/questions/28259389/how-to-put-script-in-a-javascript-string

ThomasLaigneau

Sorry, I tried to follow the tips in the stackoverflow post but nothing works.. still got that error even if I escaped the / from the </script> tag

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.

#1604November 26, 2018by umairabid2 answers
0 reactions

Issue with grapjs.init()

Apparently options passed to grapjs.init() are not being deep cloned and same object is being mutated which was originally passed. This is creating a weird issue, I cannot do this Mutation can be seen by logging myOptions before init and the result is very weird, editor without any components <img width="1440" alt="sc...

artf

The option object is passed to the plugin as it is and there is no reason to clone 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.

#1592November 19, 2018by dlorenzo2 answers
0 reactions

Highlightable seems to have no effect

Setting 'highlightable' to false seems to have no effect on components when using version v0.14.40. Dotted lines are still visible. Can't reproduce with version v0.12.17.

artf

Yeah, I've noticed that just after the release, the fix should be ready for the next release

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.

#1588November 16, 2018by vvladev3 answers
1 reactions

[QUESTION]

Hi guys and thank you for your magnificent work and this API! I have a question about the box, which wraps all components after saving. For example lets say I have custom element something like <div class="myclass" data-gjs-type="custom"></div>. After saving the template and reloading it for farther editing in layer p...

cjpollard

Same issue as https://github.com/artf/grapesjs/issues/1554 .

vvladev

O, yes, I'm sorry! Thank you, cjpollard !

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.

#1587November 16, 2018by Geelik2 answers
0 reactions

How to distinguish events for custom components

Hi, I have an issue with events. I would like to distinguish events wwhen a component is loaded using 'fromElement' config from when it's loaded by dragging a block. The problem is init or initialize are called in both case and i didn't find a property that change between both case.

artf

For the component dropped from the block manager you can use this event block:drag:stop. As arguments for the callback you get, the dropped component model (if dropped successfully) and the model of the block

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.

#1584November 15, 2018by coder-strange3 answers
1 reactions

Not getting the Script of Block from editor.getComponents()

Below is the Component that I'm adding. this.editor.BlockManager.add('dob-mmyy-pii', { id: 'dob-mmyy', label: DOB (MM, YYYY) (PII), category: 'Forms', attributes: {class:'fa fa-birthday-cake'}, content : { content : <div> <label>DOB (Month and Year)</label> <input name='dob' class="form-control"> </div>, script : func...

artf

@taufeek6 #1576

artf

If the script is a function and you can't serialize it in a JSON. I think, in your case, you need a new custom component type (you're just adding a block) then you'll export only changed properties (the script will be part of the component...

coder-strange

Bingo! that worked perfectly fine but it's letting all of the element to be selected in the block (By directly giving the block html in 'content', content : { content : 'html' } was working fine) so how do I forbid the elements to be selec...

#1581November 14, 2018by FjStudioDev2 answers
0 reactions

[Question] AssetManager not shown uploaded images

Hi all, I'm using grapesjs - 0.14.33. I have successfull implemented StorageManager in remote mode, I can load and store data. I have successfull implemented AssetManager, I can load/upload image. I'm not able to understand why asset correctly upload are not shown in asset pop up window (select image) I have read docs...

FjStudioDev

Found workaround follow this #372

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.

#1569November 9, 2018by wirelessed2 answers
0 reactions

Components & JS Question

Hi, In your Components & JS documentation, it is mentioned that scripts can be added into the "block" section under a script attribute. However, after some trial and error, whenever the page is saved and reloaded, the script seems to have disappeared. When I tried to add the script into the "model" section instead, it...

artf

Probably you're not storing correctly https://grapesjs.com/docs/modules/Storage.html BTW you can add a script inside blocks but I highly recommend creating a custom component for that case

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.

#1564November 7, 2018by MisterFK2 answers
0 reactions

Css/fonts/icons issues

Hi, i have an CSS issue with my project GrapesJS and i don't know why... I try to do the tuto and i haven't icons. Other issue, i can't split the window in 2 columns. I work with the last css and js version. Organisation : assets/js/grapes.js assets/css/grapes.min.css assets/fonts/FontAwesome.otf [...] main-fonts.woff...

artf

Somehow you're not able to load fonts, check in your dev-tools, probably you will see the error

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.