Answer the question
In order to leave comments, you need to log in
How to show icon only on small screens?
I understand how noob the question is. There is the usual little "call us" icon. It should be visible only on small screens.
Answer the question
In order to leave comments, you need to log in
Animation is not needed here + you set the background image only for the :checked state. Accordingly, if it is not there, then the background image is instantly removed, because this is not an animated property in principle (background-image). You need to initially set all the styles, then use the animated properties (opacity, transform).
var b=document.getElementById("myimg2");
function onMouseIconComm(){
this.src="img/close_2.png";
}
function outMouseIconComm(){
this.src = "img/close_3.png";
}
b.onmouseover=onMouseIconComm;
b.onmouseout=outMouseIconComm;
@media only screen and (min-width:1000px){
#ikonka{
display:none;
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question