GrapesJS Issues

Search parsed GitHub issues, see highlighted answers, and open the original discussion when needed.

3464 issues found

#1159June 1, 2018by Buubiye2 answers
0 reactions

how can i add a file importer to grape.js

I want to add a div where the user can add his own code to grape.js. So he can edit his pre-made code with grape.js. Any help will be greatly appreciated.

artf

Check this #324

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.

#1158June 1, 2018by JulyanoF2 answers
0 reactions

[Question] Is there some way to know last time was stored?

I'm using autosave option in storeManager and I would like to know if is there some way to get last time content was stored

artf

Just make use of storage:store event and store it by yourself

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.

#1157June 1, 2018by krunal0393 answers
0 reactions

Return span randomly in custom component

I have custom component and on trait change wanted to updated html but randomly it returned span/textnode in trait change function insted of html element. Below is html generated by component and on title change want to updated h4 element.linkModel.get("components").at(0) returns "div.programme-description" correctlyl...

artf

Well from what you've posted I can't tell what is happening but definitely, there is nothing generated randomly, just go deeper with the debug. BTW you can solve this easier by using find(query) method:

krunal039

@artf I tried to debug but no luck as it is happening on some pages and not on all pages. also this.find is undefined

artf

Just update grapesjs

#1156June 1, 2018by Deepak8133 answers
0 reactions

Plugin gjs-style-gradient not found

Hi @artf, I am getting this issue in gradient plugin "Plugin gjs-style-gradient not found".Used below code to include in our file: editor = grapesjs.init({ plugins: [ 'gjs-style-gradient'], pluginsOpts: { 'gjs-style-gradient': { colorPicker: 'default', grapickOpts: { min: 1, max: 99, } }, Also, i have reference this i...

ssabrewolf

you need to inlude the plugin js , here is working live version https://jsfiddle.net/ssabrewolf/7ur0cwq3/32/

Deepak813

Hi @ssabrewolf, Thanks for the message. I have used the same code but some time i get the same error "Plugin gjs-style-gradient not found" .See the code below: editor.StyleManager.addProperty('Page Settings', { name: 'Gradient', property:...

ssabrewolf

to discard problems in your enviroment simply create a fork ,is one cilck from the above link and use the same code your using to init

#1155June 1, 2018by grizzm02 answers
1 reactions

Custom component used as HTML in block

I've extended the default image component Then I've got a block where I'm going to use the extended image. The following works fine. However, this block will contain nested HTML (kind of a card) and one of the childs needs to be this custom image component. Using the following the img element is not recognized as my c...

artf

el.tagName === 'IMG'

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.

#1154June 1, 2018by alfaalex812 answers
0 reactions

[BUG] Droppable propagation

I found a problem with droppable propagation. I do an example. I drop "3 columns" inside my template (yellow zone in jsfiddle), now, if i want add an image inside one of the columns, the green selector not appear. If I remove all data-gjs the system works correctly https://jsfiddle.net/7tdkjj6a/

artf

This happens because in the inner box you propagate droppable and when you drop the table its droppable goes to columns BTW use always the latest version

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.

#1153June 1, 2018by ssabrewolf2 answers
1 reactions

Create minimalist Panel left sidebar

Hi grapesjs Team Is it possible to create a quick access left panel sidebar with the most popular blocks(text,image,2column,etc), this way is always visible because selecting any component on canvas automatically hides the main right blocks panel, if so, how could the same drag n drop behaviour from original blocks co...

artf

Check this example https://codepen.io/artf/full/MQpZPj/

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.

#1152June 1, 2018by milapshah153 answers
3 reactions

Listen to any change in the canvas

Hello Folks, I have a requirement where I added a button which saves the configuration to the remote DB.Now I would like to listen to any change in the canvas to enable/disable the button.For example, If there is any change, enable the save button for user to save it.I have gone through available events but I found no...

IStirton10

Actually I think there is an event that could serve this purpose. Could you try defining your method callback on 'change:changesCount'? grapesjs\src\editor\model\Editor.js:64 this.on('change:changesCount', this.updateChanges, this);

IStirton10

I'm not sure if there's one exclusive event that listens for any changes to the canvas. Perhaps you could have your method run on all of the canvas events instead? https://github.com/artf/grapesjs/blob/dev/src/editor/index.js#L53## Canvas...

milapshah15

@IStirton10 Let me try it out.I guess this should work. Warm regards Milap

#1150May 31, 2018by afaraha84033 answers
1 reactions

[Question] Get Uploads as Base64

Hello All, I need help integrating this into a web app that I have. Everything renders and works as expected but I am trying to get the uploaded images (through drag and drop) as a base64. Using an endpoint is not an option I can use. This is the code that I have Also after I process my external upload function do I j...

artf

Have you tried with this?

afaraha8403

Yes I tried that. But what I am looking for it to get the base64 file so I can upload to the plateform I am using and then adding the return url to grapesjs

artf

Well then use uploadFile and if you don't know how to get the base64 of the file try to copy embedAsBase64

#1149May 31, 2018by ionic6662 answers
0 reactions

Change the content in <td>

hi ,bro.Now, tables can't change the content.How can I modify the content in td

artf

@ionic666 follow the issue template, please, I don't even understand the context of your question

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.