GrapesJS Issues

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

3464 issues found

#2321October 9, 2019by glassdimly2 answers
0 reactions

Drag and drop re-ordering of components?

I've got a several bolt-interactive-steps within bolt-interactive-pathway and I wish to order them, but grapesJS dragger only allows me to drop it inside bolt-interactive-pathway to be appended to the end: no ordering. This is compounded by the fact that this actually works about 10% of the time.

artf

Is it only within Layers or also on canvas? Can you create a reproducible demo, please?

no-response[bot]

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take ac...

#2320October 9, 2019by eduardonunesp3 answers
2 reactions

[HELP] Missing fonts after compile with Webpack

The project is using webpack to compile the project in order to distribute as bundle, it's a kind of plugin using GrapesJS as editor, everything works fine except the fonts loaded by GrapesJS are missing, when running with webpack-dev-server everything looks fine, but when building with webpack and try to run on a sim...

pouyamiralayi

using outputPath option, you specify the output folder where webpack will emit files. and based on you saying:running with webpack-dev-server everything looks fine project is loaded on another folder it seems to be an output path problem....

eduardonunesp

Great, thanks @pouyamiralayi I'll double check the outputPath this night

pouyamiralayi

did you try using `file-loader instead of url-loader for ttf` or other font types?

#2319October 8, 2019by glassdimly1 answer
0 reactions

How to Force Component Re-Render?

When I try the following in place of pathwaysParent.render(), it obviously creates an infinite loop: I can access the el at pathwaysParent.view.el, but I'm still looking for a good way to force the DOM component to re-render in a non-hacky way.

glassdimly

I ended up firing an event on each object removed that caused them to trigger their own updates. I did this with a config object, but here's a more specific draft of my code. These are shadow dom components so this.parent().closest('pathwa...

#2318October 8, 2019by navewiNo answers
0 reactions

[QUESTION]: How can I translate the StyleManager properties?

Hello, I already know this way: grapesjs.init({ // ... styleManager: { textLayer: 'MyLayer', } }) But i don't want to translate it in the init function if possible. For the blocks there is the set() function to translate the label for example. Is there something equal to this for the style manager to translate the pro...

#2317October 8, 2019by suchiitsme3 answers
0 reactions

Need a feature to integrate modal form

[FEATURE REQUESTS] I have to add block which should a open a modal with form fields. Based on the form data selected I have to generate a html string and insert it to editor. and on click /double click of the component, modal should open again with the form details. How can I do this? Please help.

jcarizza

Hello @suchiitsme i think you can implement a component type.

suchiitsme

Hello @suchiitsme i think you can implement a component type. Thank you. I will give a try!!

suchiitsme

Hi How do I link this to block?

#2316October 8, 2019by kickbk3 answers
10 reactions

Customizing the assets-manager view

I would like to create a custom assets-manager modal to open in bootstrap modal. I'd like to keep the original assets manager functionality (like drop image zone, input to fetch image from remove, and I'd like to use datatable for the images/assets). In addition, I would like to integrate with Pixabay API so images ca...

PriyankaPrabhu

@kickbk did you achieve the custom asset manager ? If yes please share the code

khoa-justuno

You can do this with a custom modal by overwriting the default image asset manager. When you want to set an image use this.

artf

I'd suggest the same solution proposed by @khoa-justuno If you need a new modal it will be easier to create the Asset Manager UI from scratch, reusing the DOM elements created by GrapesJS, in this case, would be just a pain to maintain

#2315October 7, 2019by tom-sherman3 answers
1 reactions

Allow returning promises from StorageManager `.load` and `.store` methods

This would offer a more modern and clean API than the current callback based approach. Proposed API: --- There are a few ways this could be implemented:Detect if the load/save method is thenable, if so await This would complicate the API and code a little as users would need to make a choice between using either the c...

tom-sherman

Thanks for your thoughts! Hopefully I'll have time to implement it this week

artf

Really cool feature request Tom, I'd totally appreciate a PR. For sure I'd go with your first approach, not breaking the current API is always a goal to reach. Just adding the ability to create async-await enabled custom storage managers w...

artf

With the new StorageManager refactor this can be closed https://github.com/artf/grapesjs/pull/4223

#2314October 7, 2019by alimajedcme1 answer
0 reactions

[BUG] grapesjs does not handle correctly outlook specific HTML

Hello all, I have a template that includes outlook specific HTML as shown below: <!--[if (gte mso 9)|(IE)]><table width="100%" border="0" cellpadding="0" cellspacing="0"><![endif]--> When I import this HTML, and try to add a block above or below this specific location in the DOM, the green line showing where the compo...

artf

Probably you would need to create a custom component to handle such a case

#2313October 7, 2019by TheComputerM3 answers
4 reactions

[BUG] Scripts do not work when added dynamically added to iframe <head>

I am using the latest version of grapesjs (0.15.8) and running it on Windows 10 x64 on Electron (this is not a issue with electron) and am facing a problem when I try to dynamically attach scripts to the editor iframe, I have included a link to CodePen for more on this issue. In my project I have to dynamically change...

pouyamiralayi

Hi there! see if this can help you out: cheers!

TheComputerM

Thank you very much, the fix worked, but why does it not work with jQuery?

TheComputerM

Ok thanks a lot.

#2312October 6, 2019by DamodarSojka2 answers
1 reactions

[QUESTION] - More control over panel buttons, dynamic panel buttons

Hi, I am trying to implement several more dynamic buttons for the panel, for example a save button that depending on some flag will show an animated loading spinner, save icon or "Saved" text. In order to achieve that I need to be able to dynamically set the content, potentially size and also use not only icons but al...

DamodarSojka

Thank you for a very quick response, didn't know about the label property as it doesn't seem to be mentioned in the docs.

artf

Well you can change the attribute and the content in this way for anything else more specific you can go with direct DOM manipulation