GrapesJS Issues

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

569 issues found

๐Ÿ” canvas
#612December 6, 2017by vishal50332 answers
0 reactions

Urgent : Duplicate other blocks when used custom asset manager

Hello, We have modified the Assset manager with custom one. But we are having problem now. If we drop one image into canvase and then add any other component , it will duplicate that component. If we add another image then it would triplet other component. Can you please help us. Below is the code snippet that we have...

artf

If you get duplicate components only when using your custom Asset Manager, well you should check how you assign the src, I can't help you more

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.

#598November 30, 2017by Geczy3 answers
2 reactions

Can't "cancel" a drag

Drag component to canvasDon't release mouseDrag back to blocks panelComponent is still applied to canvas It should instead cancel

artf

Drag back to blocks panel Honestly, never seen kind of UX... why not the classic Esc? (which works already)

artf

@Geczy Now blocks support HTML5 D&D https://github.com/artf/grapesjs/releases/tag/v0.13.5

Geczy

This is a very common UX anywhere you go https://w3c.github.io/html/editing.html#drag-and-dropHowever it is implemented, drag-and-drop operations must have a starting point (e.g., where the mouse was clicked, or the start of the selection...

#595November 30, 2017by ateshuseyin3 answers
0 reactions

Cannot drag with fast actions

When I move a block on the canvas before showing clone element, editor does nothing. Only move clone of the block symbol.

ateshuseyin

Any one have an idea?

artf

unfortunately, I didn't find the time yet to investigate this

ateshuseyin

Is this fixed?

#591November 29, 2017by krunal0393 answers
0 reactions

Show hover toottip on block

I want to add hover preview for block under block manager before user add to canvas. is there way to achieve it?

artf

@krunal039 definitely is possible, but I'd say you have to make it by yourself as it's totally not an essential feature for the editor

krunal039

@artf thanks for reply. is there any event I can use for same? or it has to be out side of editor?

artf

use native js events

#583November 28, 2017by gabrigcl2 answers
0 reactions

Event stop:preview doesn't fire

Hi. I need the firing of this event in this situation: I have some elements out of the canvas that need to be hide at preview mode and shown when I exit preview mode. However, the event stop:preview doesn't fire when I exit the preview and turn back to canvas editing. I've made a solution myself that works well, but I...

theanhmx

@artf sorry for this stupid question, but when will the fix available in the npm package? or from which branch i can manually pull the code with this fix and build?

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.

#580November 28, 2017by faizansaiyed3 answers
3 reactions

[Question] Any/Trigger event when any block is dropped inside canvas?

Hey, How can I trigger some event when any new block or content inside canvas is updated? Something like editor.onCanvasUpdate() Thanks!

ryandeba

Hi @fsaiyedOB, I've been able to accomplish this with the component:update event listed here: https://github.com/artf/grapesjs/wiki/API-Editor#available-events My code looks something like

duskhacker

When I asked to find out when the canvas is dirty to provide an indicator, @artf told me:

artf

I'd add also a block specific event

#571November 25, 2017by suraj7403 answers
3 reactions

import content dynamically

Hi @artf , how can i import content dynamically from program that automatically reflect in canvas.

duskhacker

@suraj740 editor.setComponents() will take both html/css, so you could just skip the setStyle call. As for the rest, you did look at the storage manager documentation, yes? You can call load/store on it programmatically without clicking a...

duskhacker

In my project, I set data- attributes on an HTML element and extract them via .dataset in Javascript, once the editor is configured, I run: Be aware that the HTML must be set up so that grapesjs can understand it. I believe that it must ad...

duskhacker

@suraj740 ^^

#557November 22, 2017by krunal0393 answers
1 reactions

Classes are missing on editor.gethtml()

I can see classes are added on canvas but when I get html via editor.gethtml(), i so some of classes are not included and it is just divs without any classes. attached screenshot with html on canvas and html via editor.gethtml()

Geczy

Don't think gjs- prefixed classes will return

arthuralmeidap

When you use the editor.getHtml it returns just the html . If you need the css too, you can use the editor.getCss().

Geczy

I use newsletter-plugin and const html = window.grapesjs.editors[0].runCommand('gjs-get-inlined-html')

#530November 15, 2017by tomichal2 answers
0 reactions

Elements hidden through the layer manager can no longer be brought back after saving the content.

Steps to reproduce on http://grapesjs.com/demo.html :Click on the Layer Manager.Hide any layer, e.g.: the Header.Save the content - this happens automatically on the demo - which uses browser local storage, with auto-saving every single step.Reload the page. Result: The hidden layer is not visible on canvas, but still...

artf

Thanks for the catch @tomichal the fix will be available in 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.

#528November 15, 2017by krunal0391 answer
0 reactions

Model and Component sample code and issue

@artf Sorry for creating another issue but I tried below code also I have created codepen for same. Codepen and still it only return empty div via editor.getHtml(), I can see html updated in canvas but not on model. Also updateSrc() and updateh2Content() function has var linkModel = this.get("components").at(0); undef...

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.