On mouse over event initial background color is changed

Heily Hindrea shared this problem 6 years ago

On mouse over event changing border color also changes rectangle ́s background to white.


Rectangle initial color: green

Rectangle initial border color: grey

On mouse over change border color -> black

Expected result - If I enter the rectangle with my mouse -> background stays green, border gets colored.

Actual result - Border gets colored black (which is ok) and background gets colored white (which is totally not ok).

Comments (4)


It seems to work ok in Chromium (the simulation engine). Could you tell me what browser you use to see the prototype please?



I am really sorry, I oversimplified the description. As i described earlier it really works.

Here is the little prototype where it doesn ́t work.

1. click the check sign to color the circle to green.

2. hover over

Result - it changes the background and i dont understand why.

I also used different border colors here.



It's a limitation of the way we have to generate the HTML. Well, let's say it's a bug and we are going to try to fix it. The real problem is that background and border style are, in fact, linked. Specially when you define rounded borders. So your 'change style' event that is triggered when you move the mouse over the circle is also applying a background white. Yes, I know it doesn't make any sense... But that's how it's working right now. So, the workaround would be to define a background color in the change style event as well as a border style and, in your example, control when that background should be green and when it should be white using the variable.


Fixed it in version 5.5