So I am using local Storage. I added some events to the component this way. Every time I add the component it works just fine. However, If I reload the page the component is still there but it is not triggering the click event or dblclick anymore. I noticed that this happens in Chrome and Safari browser. To solve this...
artf
You should add that code as a plugin
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.
Thank for this awesome library. I am gonna to add style controller to sector. This style will be for only one class name and won't set target. For example ".xxx-wrapper div.active button:before" (xxx will be identifier of component so that inside buttons will be controlled by this sector) I tried to find in document b...
artf
No style manager can only change style properties (CSS) for any other thing you have to use Traits
webdeveloper0429
Thank you artf. so we can't use nested css selector (".xxx-wrapper div.active button:before") in cssCompose?
artf
You can create any CSS Rule by using setRule method but only class-based are visible in Style Manager
Hi. I know the grapesjs will generate the unique id for each HTML. when I store that HTML and CSS. the HTML id is not stored in my database. so when i reloaded my saved data into grapesjs it shows new unique id for each HTML element. before saving the HTML. we have id="i63ss1" as u can see in the below image but after...
artf
@maryia-kabash IDs are created when required (added component-related style, component has scripts, etc.)
artf
You shouldn't load the HTML/CSS but the JSON data Read this please https://grapesjs.com/docs/modules/Storage.html
maryia-kabash
@artf JSON doesn't have ids as well (you can see it on GrapesJS Demo page). Is there any way to force saving ids?
Hi @artf, Thanks for making this amazing framework. Recently I made a custom component based on your flexbox plugin. The red arrow is the actual value of the model. The green arrow is what I expected to be. Is that possible to set unitWidth as px but the output to be percent? Here is what I've triedI separated them as...
artf
Ah wait, my fault, opts is the 3rd one updateWidth(model, value, opts = {}) { btw the second argument in setStyle are options (eg, { silent: true } to avoid triggering change listeners) and you get those options also in the callback of you...
afdallah
You are the man!!! ๐ ๐ Thank you so much @artf.
artf
Hi @afdallah, from the resizer point of view you'd need to use updateTarget option to customize the target but unfortunately, you can't as it already heavily used by the SelectCommand So I'd ask you to try to use this in your updateWidth f...
Hi, I need to call the method before remove the HTML component. how can I do that calling method like editor.on('block:drag:stop', function (model) {})
artf
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.
is it possible to make modal that can be a canvas? I want to make a button that displays modal, then I can add the modal component from the block manager, Thank's
artf
Probably you're looking for components with js
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.
how do I make it possible to add new components after the component I selected, at this time I use editor.DomComponents.addComponent (block); , but new components are added at the end, not after the selected component, Thank you
artf
You can also use this to get the index of the component index = editor.getSelected().index()
fmr411
clear, I use index
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 all, I am using the plugins 'gjs-preset-webpage', and 'grapesjs-custom-code'. I have noticed that the import modal and the custom-code modal are opening just once. I have tried last versions for Mozilla and Chrome but this is not solving the issue. Once they open and close once, I am not able to open them again. I...
artf
Thanks for the report, this is actually due to the breaking change in https://github.com/artf/grapesjs/releases/tag/v0.14.55 I didn't manage well the state of those commands, I'll try to release soon the patch for both
artf
Fixed released https://github.com/artf/grapesjs-preset-webpage/releases/tag/v0.1.11 https://github.com/artf/grapesjs-custom-code/releases/tag/v0.1.2
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, have I modified my HTML using the toHTML function in traits. An HTML element is updated but the gjs-component is not updated still it shows the old code. my traits are but its shows older code like type="radio" is not stored in gjs-component after i loaded my saved screens before saving the screen after saved and...
artf
I barely understand you here... please provide a reproducible demo
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.