#5746March 12, 2024by rhoenerSBS4 answers
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v122 Reproducible demo link https://grapesjs.com/docs/getting-started.html#style-manager Describe the bug How to reproduce the bug?Go to the "StyleManager" section of the "Getting Started" doc from GrapeJSTry to use...
bernesto
Hi @artf, The root issue is that we are trying to place a popover palette absolutely positioned over another element at an arbitrary location on the page. And we need to do this even when the origin element is outside of the editor contain...
artf
@bernesto can you check this one as it seems to be related to your changes
bernesto
Yes, I see the issue. The logic needs to account for when the parent is outside of the container. Let me see what I can do there.
#5040April 10, 2023by abubaker4171 answer
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Version 111.0.5563.147 (Official Build) (64-bit) Reproducible demo link I provided code Describe the bug added styleable events such that styling can be overwritten https://github.com/GrapesJS/grapesjs/issues/1041 https://...
ClaudeCode
Thanks for reporting this, @abubaker417. The issue with added style able events such that styling can be overwritten, open appears to be a race condition or state management timing problem. This typically happens when component lifecycle e...
#3255February 1, 2021by Abhisheknanda13444633 answers
Hi @artf I am trying to change the type and input values of display property like this way -: But on style-manager Button are not visible. How can we customize the display property Demo -: https://codepen.io/abhi_punk81/pen/MWbWzaq?editors=0010 Could you Please Help @artf ? Thanks
nilchu
You have to use the list property to define your options. Inside the radio option objects, it should read name instead of title. ```javascript const styleManager = editor.StyleManager; styleManager.addSector('div-only-sector', { name: 'Set...
Abhisheknanda1344463
Thanks A lot @nilchu for your help.
ClaudeCode
Thanks for reporting this, @Abhisheknanda1344463. Great question about Custom Style Manager. The recommended approach with StyleManager is to use the event-driven API. Start here: Check the GrapesJS documentation for your specific module L...
#3242January 20, 2021by Nielsticot4 answers
Version: 0.16.34 What is the expected behavior? When the editor is initialized, no element is selected, so the style manager should say "Select an element before using Style Manager" like it does when not using "appendTo" in the editor configuration. What is the current behavior? When using "appendTo" in the editor co...
mosh-tudor
I used this code to solve it:
Nielsticot
This is not what I want, my issue is before any element is selected so before the event "component:selected" is trigerred. I temporarily fixed it by selecting an element on editor load but it is not what I really want
artf
If you're using the StyleManager in a custom element you have to handle that state on your own.
#2757May 7, 2020by makkaronis4e1 answer
Hi, i want to reproduce default gjs behavior, when style-manager is hidden if no component selected. like this: But it seems like this doesnt work by default, if markup is custom, like in artf example here: https://codepen.io/artf/pen/MQpZPj
artf
Yeah, that logic is handled in this command which is not included with a custom UI, so you have to add it on your own
#2414November 15, 2019by thieuanh1995hn3 answers
https://grapesjs.com/docs/getting-started.html#style-managerHard to look.Hard to copy paste.Quite hard to get it
artf
Indeed I'm asking for help
artf
The help is welcome ๐
thieuanh1995hn
Find a newbie to read all your document and ask him . It's very suck. May be you can not reach it just because you created it .
#1379August 23, 2018by Abhisheknanda13444633 answers
hi @artf i Want to replace an icon of style manager with svg icon . As you can see screenshot attached. I tried dat way.
artf
Yeah put those changes inside your plugin
artf
???... your code is all broken (check the syntax) Probably you want something like this
Abhisheknanda1344463
Please re-open this issue. hi @artf I also tried this way pnm.getButton('views', 'open-sm').set({ label: <svg> width="1024" height="1024" viewBox="0 0 1024 1024" style="margin-left: calc(50% - 0.5em)"><g transform="scale(0.03125 0.03125)">...
#361October 1, 2017by aryeharmon3 answers
https://github.com/artf/grapesjs/wiki/API-Style-Manager#getproperty
artf
Confirmed, thanks for the catch
mklemersson
I was looking at the default example page and saw that sectors don't have the id attribute that is used as a parameter of the function getProperty After I added the attribute, I can get the property as the image below shows
artf
oops ๐
thanks @MichaelKlemersson will update the demo soon then