This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Rotate by css fixed
#1
Hi,

I rotate an On/Off object by css but when I click on it, it rotate to original position. Is there any whay to fix position?

Thanks
Reply
#2
Add !important to your CSS rule.
Reply
#3
(09.03.2023, 11:38)admin Wrote: Add !important to your CSS rule.

I´ve done that but doens´t work

Code:
.rotate180{
transform: rotate(180deg) !important;
}
Reply
#4
Works for me as is. See if this works:
Code:
.rotate180,
.rotate180:active {
  transform: rotate(180deg) !important;
  -webkit-transform: rotate(180deg) !important;
}
Reply
#5
(09.03.2023, 12:48)admin Wrote: Works for me as is. See if this works:
Code:
.rotate180,
.rotate180:active {
  transform: rotate(180deg) !important;
  -webkit-transform: rotate(180deg) !important;
}

Hi!

It doesn´t work. I put this class (rotate45) in aditional class but it doesn´t work.  When i click it changes to original rotation.

Code:
.rotate45,
.rotate45:active{
transform:rotate(45deg)!important;
  -webkit-transform: rotate(45deg) !important;
}
Reply
#6
Which browser/OS are you using?
Reply
#7
(20.04.2023, 12:18)admin Wrote: Which browser/OS are you using?

Chrome, Mozilla and Edge. 
It doesn´t work in any of them

Which one do you use?

(21.04.2023, 09:07)DGrandes Wrote:
(20.04.2023, 12:18)admin Wrote: Which browser/OS are you using?

Chrome, Mozilla and Edge. 
It doesn´t work in any of them

Which one do you use?

I see that if I don´t check "Disable object click animation" on Vis. Configuration it works. But I don´t want animations on click. 

   
Reply
#8
Use this if click animation is disabled:
Code:
.noanim .rotate45,
.noanim .rotate45:active {
  transform: rotate(45deg) !important;
  -webkit-transform: rotate(45deg) !important;
}
Reply


Forum Jump: