#927March 5, 2018by JulyanoF2 answers
I was looking for it in wiki but I didn't found anything about it. I would like to disable resize for all current and future images for default. Is it possible?
artf
Extend the image Component and put as a model property resizable: false
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.
#926March 5, 2018by NealWalters3 answers
If grapejs requires NodeJS, the doc/wiki should say that clearly upfront somewhere (i.e. list major dependencies and what type of server is needed to run it). You mention it runs in a CMS, but don't state that it will create a full page and can or cannot run outside of a CMS. Question: If it runs with NodeJS - will it...
artf
If grapejs requires NodeJS, the doc/wiki should say that clearly upfront somewhere Indeed it doesn't... you need nodejs just for the development purposeYou mention it runs in a CMS, but don't state that it will create a full page and can o...
NealWalters
Thanks Art. Okay - let's re-read this: "GrapesJS was designed to be used inside a CMS to speed up the creation of dynamic templates." That could mean I need a CMS then I paste GrapeJS into it; or it could mean it was meant for a person to...
artf
Yeah it's not only about CMS but a general purpose use. Inside grapes.min.js you will get everything you need, NodeJS is just for a correct development server (testing, merging dependencies, etc..)
#925March 4, 2018by hadifarnoud2 answers
I could not figure out how can one add H1 or any other header text tag. this is important because of SEO
artf
Probably you should read more about Blocks Seems like someone has made a plugin for headings :) https://github.com/olivmonnier/grapesjs-plugin-header
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.
#924March 4, 2018by jadebayo2 answers
This is a piece of code that i am an using: this.editor = grapesjs.init(this.config) const commandManager = this.editor.Commands commandManager.get('preview').run(this.editor) I want the editor to go into preview mode immediately upon loading. It does go into preview mode but the offsets are still displaying. Hovering...
artf
Yeah, you should make use of this
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.
#923March 3, 2018by sura2k3 answers
I have read the code and only I could find out that there is only a list of ToolbarButton associated with the toolbar. I have a special trait that I would like to put it into the toolbar because it is very important to see the user which component has this trait and also to change it on the designer/canvas without hav...
sura2k
I was able to manage it by modifying ToolbarButton and its view. But later I decided to expose them by adding those to DomComponents via separate property rather than modifying ToolBar..., so I can extend them and since the changes are few...
vtsoft
Hi @sura2k, I also want to add a select option to toolbar. Can you please share your ideas/code/script on how did you implement it? Thanks in advance.
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.
#922March 2, 2018by mbleverage3 answers
I have been working on integrating grapesjs into a new development I'm working on. I have had much success with the documentation and wiki forum but am running into a few issues I'm hoping someone out there can help me with. I am working with a mobile view only, I have set the default device to mobile and hidden the o...
artf
Your change on the block doesn't work because you don't change the actual component (just the block's property) With cssComposer instead, by default, selectorManager accepts classes An easier way to add custom CSS might be this one But be...
mbleverage
Thank you! I was able to get that working with: protectedCss: 'img {max-width:100%;}', I have the same issue with videos and iframes (for youtube) being dropped onto the template larger than the screen size and the protectedCss solution di...
artf
protectedCss is loaded so the CSS is here, if it doesn't work probably your CSS technique is not correct
#921March 2, 2018by dmmprog3 answers
Hi everyone, Is it possible to set focus in a section html with Grapes, like as an anchor? I have a panel button and it just select the section that I want but not focus to element. Here is the code: panel.addButton('options', [{ id: 'link', className: 'fa fa-th-list', command: function linkChap(e) { editor.DomCompone...
artf
If for focus you mean scrolling the view to the component, unfortunately, there is no such a method, but you can actually implement it by relying on editor.Canvas.getBody().scrollTop
Amir2828
Did you manage to make it work?
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.
#919March 2, 2018by AlessandroMagri2 answers
Hi all, I'm writing an application that include grapesjs fron an ajax call in a specific div. Obviusly I'd use an external menu to navigate in the application. If I reopen the page that init the grapesjs firefox give me an error: "TypeError: this.frame.el.contentDocument is null". I hope I've explained myself. Is ther...
artf
Subscribe to #914 probably this will be fixed 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.
#918March 1, 2018by lorrandavid2 answers
After searching for a while, I couldn't find how to change only the trait label without overwriting everything. This is my attempt that didn't work out I saw people overwriting the entire module, is that the way it should be done?
artf
Currently, to change the trait's label you have to do it on the component level
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.
#917March 1, 2018by chthomos2 answers
Is it possible to have custom style property UI per element. For example, consider that I want the font-size to be shown as textbox for text components and as a radio for a custom component of mine. The font-size property can be in the same sector. How can this be achieved?
artf
Yes, I've used the same trick for the flex grid. In your Style Manager configuration create a property in this way then in your custom component model require the property
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.