css - How to make a div disappear on hover without it flickering when the mouse moves? -


i've seen answers suggesting display:none on :hover css. makes div flicker when mouse moving.

edit: added jsfiddle

display:none take element out of render tree, loses :hover state immediately, reappears , gets :hover again, disappears, reappears, etc...

what you need is:

#elem { opacity:0; filter:alpha(opacity=0); } 

it leave place empty, no flickering appear. (demo or yours updated)


Comments

Popular posts from this blog

objective c - Change font of selected text in UITextView -

php - Accessing POST data in Facebook cavas app -

c# - Getting control value when switching a view as part of a multiview -