GrapesJS Issues

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

644 issues found

๐Ÿ” components
#1341August 6, 2018by HakuTheWolfSpirit3 answers
0 reactions

[Question] How to work with Custom Components

Hello, I have some questions and issues about and with the grapes editorProblem 1 In a component, which class is there extended? Is it really this class?Problem 2 I have created a codesandbox which shows which issues I currently have. It is oriented on the mjml-pluginSandbox Output Sandbox CodeSteps to reproduceDrag t...

artf

Problem 1 It depends (you can extend other types), but that is the base for all the componentsProblem 2 Here you should point out only issues related to the core library and not its pluginsProblem 3 Please read carefully this https://grape...

HakuTheWolfSpirit

Please read carefully this https://grapesjs.com/docs/modules/Components.html Yeah, forgot an important line defaults: { ...defaultModel.prototype.defaults, ...props } Here you should point out only issues related to the core library and no...

adelliinaa

What are the steps of importing a customised component?

#1336August 3, 2018by emilsedgh3 answers
0 reactions

[Question] Can I make everything unselectable by default?

Currently all components are selectable/hoverable by default. And if you want you can change that behavior by providing data-gjs-hoverable=fase in the template. Is there any way to change this so selectable/hoverable is false by default, unless data-gjs-hoverable=true is provided? Thank you btw. Grapes is amazing.

YashPrince

Hello @emilsedgh Please check the below code it may help you.

emilsedgh

Thank you very much @YashPrince I suppose I can use a custom data attribute to exclude the ones I want to be editable right? Feel free to close this question btw. Thanks for answering.

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.

#1328August 1, 2018by jorgecgll2 answers
0 reactions

[Question/bug] Reordering components in the canvas

I've noticed some inconsistencies when moving DOM components around in the canvas. Description in the gif below using the Webpage Demo: In my case, I do see the DOM component "moves" being reflected when I output editor.DomComponents.getComponents(). They actually get reordered, but the Canvas does not reflect those m...

artf

Never had time to debug it but I think it caused somehow by components with float: right style applied

jmrgz

Yes, it is related to the float right property. Actually, that is the real behavior of the float right property (the last html element appears the first) so I do not see an easy solution.

#1325July 30, 2018by ploutos273 answers
1 reactions

How to disable drop for specific blocks/components

Hello, with the following code we are able to indicate if it's possible to drop other component(blocks) inside that particular component...: We are looking to indicate if it's possible to drop other components only for specific blocks. For example: A. Container Block - > we want to drop only columns B. Column Block -...

artf

From the https://github.com/artf/grapesjs/releases/tag/v0.14.17 you get data-gjs-type on all rendered components, therefore you can do something like this: droppable: '[data-gjs-type="column"], [data-gjs-type="other"]',

ploutos27

Thank you! :)

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.

#1323July 27, 2018by jvillena2 answers
0 reactions

Loading HTML content inject ids belongs to styles

@artf When I load the html content, this is including in all the components a random identifier that in your examples "Websites" and "Newsletter" I don't see them. So How I can force to keep my stylesheet and don't use random identifiers in all the components? I'm asking you this question because if I change the ident...

jvillena

@artf I've just fixed I was including the variable avoidInlineStyle: true, and it has to be avoidInlineStyle: 0

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.

#1321July 26, 2018by maryia-kabash2 answers
1 reactions

[Bug]: Image component is not deleted

The bug is reproducible on GrapesJs demo page. Steps to reproduce:Drag&Drop or select an Image component.Click delete icon from the toolbar. Result: nothing happens, as ed.Canvas.hasFocus() (file commands/view/ComponentDelete.js) returns false.Select any other componentSelect image again and try to delete it. Result:...

artf

Thanks Maryia, it should be actually fixed with the latest version https://github.com/artf/grapesjs/releases/tag/v0.14.25 (same as #1298)

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.

#1308July 23, 2018by manishkumaruit1 answer
0 reactions

I am not able to insert icon and its class in html element

bm.add('test-block', { label: "Icons", category: "Prismanote Blocks", content: { script: function () { var d = window.parent.window.modalJ; d.setTitle('ICONS'); d.setContent( <style> .tabs{ width: 600px; display: block; margin: 0px auto; position: relative; padding: 0px !important; } .tabs .tab{ float: left; display:...

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.

#1304July 23, 2018by sanskipk2 answers
0 reactions

"CanvasView.frame.el.contentDocument is null" in angular4

Hi I integrated grapejs with angular4.I added custom button.After click on edit button throwing error:- TypeError โ€‹ columnNumber: 7 โ€‹ fileName: "http://localhost:4200/vendor.js" โ€‹ lineNumber: 78800 โ€‹ message: "CanvasView.frame.el.contentDocument is null" ngOnInit() { console.log('oninit') this.editor = grapesjs.init({...

artf

There is a very similar issue #1288 please discuss it here. BTW I'd need a minimal live demo for such a 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.

#1292July 17, 2018by ploutos272 answers
1 reactions

Passing custom classes on components block..

Hi there, Components parameters are not allow us to pass a custom specific className, p.s: I don't want to pass the className inside the content.... Is there a way to do that ? Or we should build a plugin for that ?? Thanks !

ploutos27

fixed:

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.

#1289July 16, 2018by acamenhas2 answers
0 reactions

data-gjs-custom-name question

I've created a simple block content with a custom data-gjs-custom-name = "test". When i save the page i cant see those attributes on the generated HTML. Then, when i load that HTML, those custom components appears as BOX. Is there any way to keep those attributes?

artf

No, those attributes are only used for the import. Please, learn how to store correctly your templates https://grapesjs.com/docs/modules/Storage.html#store-and-load-templates

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.