The color picker in grapesjs does not work the same between Chrome and Firefox. When you open the picker on a selected component that has never had it's background color set before (for instance...) the color picker opens with opacity set to 100% in Chrome and 0% in Firefox. The issue is that the user may hot even loo...
mhowey
@artf Another difference to note between Firefox and Chrome is what is displayed in the palette. Firefox shows a transparent box while Chrome shows a gray one.
artf
Seems to be solved on the latest Firefox version
GJSBlock
Thanks for reporting this, @mhowey. The issue with Color Picker Transparency slider is at 0 in firefox. appears to be a race condition or state management timing problem. This typically happens when component lifecycle events and DOM modif...
Hello, I have a custom component, let's call it a Section Block. I want to prevent the user from dropping Section Blocks inside other Section Blocks. Is that possible? Ref: https://grapesjs.com/docs/modules/Components.html#define-custom-component-type I am aware of the draggable/droppable options that I can define on...
artf
You can use :not() selector, eg. :not(.except-this-class)
stljeff1
Thanks @artf . This solution works, mostly. Now I am encountering a new problem where some placeholder text is disappearing. On some elements inside my blocks, I'll have an HTML element with a text node, then some other nested html element...
artf
You're defining the component with the old API, which requires other stuff to work properly and that might be the cause of the issue (I've tried on my side and everything works as expected). Please check here for the correct API https://gr...
Hello, I've hit weird bug when I tried to get block category. block.get('category') returns object in Chrome, but in Firefox the same code returns string: Left - Chrome, rIght - Firefox Also with enabled adblock or selenium extensions this code also returns string. Some other extensions might cause this problem too, s...
xinnai
@kuhelbeher I got same issue, did you resolve your problem?
artf
This seems to be solved with the latest version of GrapesJS
GJSBlock
Thanks for reporting this, @kuhelbeher. The issue with block.get('category') returns different results in Chrome and Firefox appears to be a race condition or state management timing problem. This typically happens when component lifecycle...
WARNING READ and FOLLOW next 3 steps, then REMOVE them before posting the issueFollow CONTRIBUTING Guidelines https://github.com/artf/grapesjs/blob/master/CONTRIBUTING.mdDo a quick SEARCH first, to see if someone else didn't open the same issueAll relative statements/questions have to be filled/answered, otherwise, th...
kumarabhishek008
Issue has been resolved
GJSBlock
Thanks for reporting this, @kumarabhishek008. The issue with Background Image of wrapper component is not loading in second time when updating appears to be a race condition or state management timing problem. This typically happens when c...
maybe can you help me... i want remove the label ".gjs-traits-label" when traitManager's opened. i tried something like this:
artf
GJSBlock
Thanks for reporting this, @alemenciones. Great question about How to hide ".gjs-traits-label" in traitManager?. The recommended approach with GrapesJS is to use the event-driven API. Start here: Check the GrapesJS documentation for your s...
Hi, We are encountering an issue - color of property name such as "Width" is blue when dragging a new component to canvas, but we don't modify its value. Grapesjs is powerful, and very helpful to us. However, we are new to grapesjs, and have spent much time on this issue with no progress. Would you please tell us the...
artf
Hi @luziye9 for sure you're using a block/component with a custom style property on it... Anyway, if you're opening a BUG issue, you have to follow the template (grapesjs version, reproducible demo, etc.). So, for now, I'm closing this as...
GJSBlock
Thanks for reporting this, @luziye9. Great question about How does the property color changes to blue when value changed?. The recommended approach with Canvas is to use the event-driven API. Start here: Check the GrapesJS documentation fo...
I was fiddling with ways that you could change the style of elements inside the canvas and i noticed that by using the color-picker trait to set the inline style color property of the element (not the inline style tag that you get through the getCS() ), that style property was completely gone when getHtml() was used.I...
artf
Hi @DodoTrip the reason is that with inline CSS you can't define styles with states (eg. :hover) and media queries, so I've always seen it as a useless limitation instead of a feature. Despite that, you can still use that option if you don...
ThetripGr
Hi @artf and thank you, for your reply. Mind giving me an example on how it is done right now or should avoidInlineStyle make it work easily?
artf
Honestly, I've stopped using avoidInlineStyle a long time ago, but I guess it should work π
Hey, @artf. I want to access the json that is generated when a template is stored without actually storing the template. The json object can be accessed using the events but I don't want to call editor.store() and then use the events. Is there a way I can do get the json object (a function call on editor or some prope...
Joshmamroud
@theSC0RP Is this what you're looking for? editor.getComponents()
artf
@theSC0RP it's not clear if you want the storage functionality or not, but what proposed Josh is correct or you can always add your storage (and do nothing inside if need to...) https://grapesjs.com/docs/modules/Storage.html#define-new-sto...
theSC0RP
you can always add your storage (and do nothing inside if need to...) https://grapesjs.com/docs/modules/Storage.html#define-new-storage Thanks @artf. This is what I ended up doing. With editor.getComponents(), you get a cyclic structure st...
Hi @artf - what you've built is magnificent. It's been a gentle struggle as I'm far from being a JS wizard. However, I've got just about everything fully configured - except for this! I want to set traits that display when an image is selected (alt, src, id). I am sure it can be done once at initialisation, but I'm bu...
artf
Hi Freddy, you can simply extend the image component in this case
GJSBlock
Thanks for reporting this, @fmay. Great question about Question : Traits. The recommended approach with Components is to use the event-driven API. Start here: Check the GrapesJS documentation for your specific module Look for the on() even...
I would like to create a new custom trait to use, that has the input of the color picker and a checkbox so that the end result is either the predefined color coming from the checked checkbox or if unchecked choosing from the picker. This is too specific for my case so my question is if i can use pre-existing trait typ...
artf
Not at the moment, I'm working on a new UI module that will allow the reuse and override of internal UI elements.
GJSBlock
Thanks for reporting this, @ThetripGr. Great question about Is it possible to use existing trait types in new custom traits? (e.g the colorpicker). The recommended approach with GrapesJS is to use the event-driven API. Start here: Check th...