GrapesJS Issues

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

3464 issues found

#2199August 16, 2019by ghost3 answers
1 reactions

Issue in editing sample content by changing color and font in GrapesJS editor

1) I am seeing unexpected behavior in GrapesJS editor. can someone please assist me with the issue with GrapesJS editor? if I am copying content from outlook and directly pasting into GrapesJS editor. it's adding some outlook specific tags (Junk Tags Like : MsoNormal, </o:p> , etc ) into the content, because of these...

pouyamiralayi

one solution might be defining these custom outlook tags as custom component types; editor is not recognizing these tags unless you define it. cheers.

inaLar

@arju1503, this usually happens when the message is forwarded in Outlook. Forwarded e-mail is a different thing than a sent e-mail in terms of markup. But it can happen with e-mails also as since Outlook 2007, Outlook uses Microsoft Word t...

ghost

@arju1503, this usually happens when the message is forwarded in Outlook. Forwarded e-mail is a different thing than a sent e-mail in terms of markup. But it can happen with e-mails also as since Outlook 2007, Outlook uses Microsoft Word t...

#2196August 15, 2019by devgru3 answers
3 reactions

[Bug] Link element selection shows no toolbar

Steps to reproduce: add Text, select a word, click on Link icon in RTE panel, select a Link. Expected behaviour: when I select Link I expect it to display toolbar (with 'select parent' button) alongside its badge. Actual behaviour: If a link was in startup HTML, Link is properly initialised and selecting it results in...

simplecommerce

@Abhisheknanda1344463 Hi @artf @simplecommerce @devgru Any update on this. Is there any way to fix this manually? Thanks I am not sure if it will work for you but this is what I did to work around it.

Abhisheknanda1344463

@simplecommerce Thank you Man. It's worked. Thanks

artf

Closing the issue as it seems to be fixed.

#2195August 15, 2019by Jogai3 answers
5 reactions

[Question] Define components in template

QuestionsHow can I make a part of my template a component ?How can I set draggableComponents on such a component?If so, then can I stop setting selectable: false, highlightable: false, hoverable: false on the child nodes inside said component?Is it possible to supply a different external link to the component? More ex...

pouyamiralayi

if you want to initialize the editor with some components already placed into the canvas, you need this: cheers.

artf

for the moment grapes has some issue on storing custom components defined outside plugins. Actually, are stored correctly, it's just about loading components that are not recognized because the custom type doesn't exist yet, so this is the...

Jogai

Thanks for the answer and the links. They are really helpful. For this question however I was looking for a way to do this within a template. Currently we dont use the blockmanager, our users only drag stuff around. They never add anything.

#2194August 14, 2019by Ramkumar-Murugesan2 answers
0 reactions

CKEditor blocks is not editable[QUESTION]

Hi guys, I added the custom CKEditor blocks and its working fine. but the actual issues is I can't able to delete, move or add the traits in the CKEditor blocks. I tried all the possible but nothing is work. I really stuck. can anyone please help me. my custom blocks: as you can see the above image that I only able to...

artf

Well, the textarea can't be selected because it's a static element generated from you component's script so it's not part of the editor, it's all correct. If your point is to change internal CKEditor configurations you have to rely on your...

artf

BTW don't do this ClassicEditor.create(document.querySelector('#ckeditor')) in this way your integration will break with multiple components of the same time. I think it would be better for you to update your stuff in this way

#2193August 14, 2019by inaLar3 answers
2 reactions

[QUESTION] Reset trait on edit the content of a custom component

Hi, I have a custom component which content can be changed by switching trait select options, but also can be edited similar to the text component type when it is already rendered inside the canvas. Is there an easy way to reset the traits related attribute on edit of a component?

inaLar

@artf, regarding the "Select" I couldn't manage to connect the change in the content and make it work on change of the trait in one flow and also to change it manually by editing it's text/content. The manual change wasn't syncing the trai...

zgover

You could attach an event listener to the content prop of the component, then in the callback fetch the trait or change the value prop of the trait, see example below taken from docs

inaLar

Thank you Zachary1748, but I can't use that in my case. Maybe I didn't explained it right. I have a custom made component. The components content can be changed in 3 ways:When dragged and droped into the canvas (you have a popup with optio...

#2191August 14, 2019by andyjoneski1 answer
2 reactions

[Question] - UrlLoad and UrlSave

hi, Grapesjs is a fantastic bit of software and I've been playing with it for a week or so now. Im struggling a little with the urlLoad. Im using an end point which is returning json as you can see here: How I've read the documentation, is this supposed to load the layout into the canvas? What I'm trying to do, is use...

artf

The result of your endpoint is totally wrong. Read carefully this part please: https://grapesjs.com/docs/modules/Storage.html#setup-the-server You should return something like this: Now, you're returning only components:

#2189August 12, 2019by rahuloftheramaneffect3 answers
2 reactions

[Question] How to add "Ordered/Unordered List" option in rte/custom block

Hi I'm trying to create an ordered list with grapesjs. I tried adding the following to the rte: And this works if my page is pre-filled with html when the editor is initialized, like below: Prefilled Editor: Create Ordered List: If, however, I drop a new block into the canvas, and then press the ordered list button, I...

thomas1204

From the above comments, I can now add ordered and unordered list. Is there any way to update existing ordered and unordered List ? @artf @rahuloftheramaneffect

artf

Can you create a reproducible demo, please? That error without a stack trace is useless(Optionally) we can use the tab key to indent the lists? You should definitely do it by yourself or rely on something like CKEditor for more advanced te...

rahuloftheramaneffect

Hey! Thanks for responding so quickly.Can you create a reproducible demo, please? That error without a stack trace is useless Here is a zip file containing a stripped down version of my editor page. Demo.zip It includes a bunch of css and...

#2188August 11, 2019by TheComputerM3 answers
4 reactions

[QUESTION] How to change tagName using traits.

Hello, I want to achieve this: When user clicks on a heading tag H1, H2, H3 ... I want a trait to appear (of a select / dropdown type) which can allow the tagName of the heading to be changed

TheComputerM

I solved it after scanning the internet a bit. Add this trait

Buddhilive

@hosseinghs try this out. This is same as how @TheComputerM implemented the code before. And it works fine.

hosseinghs

hi, I'm trying to do the same! my problem is when I click one of the options from traits, my heading element won't be updated to new heading! can you help me?