grapesjs icon indicating copy to clipboard operation
grapesjs copied to clipboard

BUG Box shadow - not working in the demo too

Open jmrgz opened this issue 8 years ago • 3 comments

I have noticed this too late, a few days after finishing my project. I wanna cry :(

To reproduce the steps:

1- Go to the demo and select any "card" block (any of the blocks under the ### Flex is the new black title). Be sure that you are selecting the main parent (.card class)

2- As long as you select it, they automatically lose their normal state box shadow (values are bugged after selection).

3- Now change to hover state, they will lose their shadow too (again bugged values)

This happens with every design when you save/open or when you reload the page on the current design.

Any workaround? I would not like to remove the whole box shadow property from my project.

Thank you very much!

jmrgz avatar Jul 25 '18 16:07 jmrgz

Unfortunately, this is caused by the browser's CSS parser which rearranges the order of box-shadow values, so if you import your templates from HTML we can do nothing until we'll be able to use custom CSS parsers (I close this in favor of #1079), but if you create templates from the editor and store them correctly it should be ok

artf avatar Jul 25 '18 23:07 artf

Thank you @artf

Is there any clue of what part of the code "explodes" the browser parser attributes to fill in complex style manager properties? (it happens when you open the style manager)

I would love to know where you transform this: box-shadow:10px 10px 5px 10px black ;

Into this: X position: 10px; Y position: 10px; Blur: 5px; Spread: 10px; Color: black;

That would allow me to detect and try to correct this bug. Unfortunately, with my current latest grapesjs init, the box shadow border still happens even if you create the templates in the editor.

Thanks!

jmrgz avatar Jul 26 '18 13:07 jmrgz

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.

lock[bot] avatar Sep 17 '19 09:09 lock[bot]