Hello, I am spinning up a new instance of grapeJS, and immediately everything breaks and I get the following error: Cannot read property 'indexOf' of undefined at grapes.js:6477 My code looks like the following: It looks like it is trying to return indexOf on self, but self isn't defined. Can you quickly help me resol...
artf
Try to disable (and then probably clean) the storage with passing storageManager: {type: null} https://jsfiddle.net/h204La5o/
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.
Hi, @artf When I try to use button type traits. It does not fire any function. Can you please help me with this. Can you please share an example of new traits type creation like "Button", not the "Content" one. traits: [ { type: 'button', label: 'Submit', name: 'blogsubmit', changeProp: 1 } ] .... init() { this.listen...
artf
Hi @Soharab-Shaikh you have to pass the command option (will be executed on click):
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.
Hello I created very simple skeleton of GrapesJS editor. HTML template: Javascript: Result of loading: As you see, component is not rendered. But if I drop blocks manually, everything is ok: If I change template and set data-gjs-type attribute to <test-tag data-gjs-type="test-component-type"></test-tag> value, everyth...
artf
There are 2 issues:You forgot to specify isComponent (used in the parsing process)Currently, new component types are not working for the initial template, so the only way is to add them via plugins (I didn't find time to see why it's happe...
a-bashtannik
@artf , thank you for your answer, but I alsotried also construction with isComponent defined but with the same result. whatever, I implemented this feature via plugins as you mentioned. Have no idea why new component types don't work too,...
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.
I am integrating GrapesJs in react application. I am using npm packages "ckeditor": "^4.11.2", "grapesjs-plugin-ckeditor": "0.0.9" import React from 'react'; import { connect } from "react-redux"; import GrapesJS from 'grapesjs'; import CKEDITOR from 'ckeditor'; import gjsCkEditor from 'grapesjs-plugin-ckeditor'; clas...
Hi @artf , I ran into a similar, if not the same issue as this one: #1327 While editing a text block, I click on an external button to get the contents of the canvas, without leaving the cursor from the canvas. At this point, if I call getHtml() or runCommand("gjs-get-inlined-html") (my grapesjs being loaded with the...
artf
Yeah, this is exactly how it works. I'll try to check if I'm able to merge the temporary state before getting the HTML data
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.
Browser = ChromeGrapesJS = Latest version ( 0.14.52 ) I am trying to create a block includes nesting content object with script, style, type properties. It works fine except adding <style> tag in the content. Issue If I create block content as a String like option (A) as below, CSS goes to CSS editor. But if I create...
artf
BTW, I think, for your case, a custom component is more appropriate
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.
Hello @artf I am using grapes.js for my website-builder tool into my website. While i double click on any image the asset-manager will open and i can choose the image from asset-manager. Now thing is that i putted the conditions like once user will choose any image from asset-manager i will replace that img tag with d...
artf
You didn't show any code but I guess you've just edited DOM elements of the component when instead you should change its Component model data (eg. imgModel.set('src', 'base64....'))
AkibDeraiya123
Hello @artf Thank you for your reply on my query. I am attaching my code here, please let me know at where i am going wrong. So, basically above code will be run while user will double-click on particular image. In this function i am going...
artf
In this function right now i am changing the image src using jQuery which is working fine. But when i get editor.getHtml() It's not reflacted. ... @AkibDeraiya123 this is exactlly what I told you in my previous comment... DON'T EDIT the DO...
Hi, I try to define the values for textNoElement after I was initialized a grapesjs. but it not reflected in grapesjs UI. can anyone please help me but its shows
artf
Do this: editor.StyleManager.getConfig().textNoElement = '...'
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.