开发者

Having trouble with a dynamic fade in/fade out hover transition (jsfiddle included)

http://jsfiddle.net/XztsH/1/

The hover class seems to be pushed down a 20 pixel and I'm not quite sure why.

Maybe it's la开发者_如何学Cte and my brain is dead...


The shift occured because the 'Close' text was occupying the line. Updated the fiddle for you: http://jsfiddle.net/XztsH/3/


Although you put the text far over the to left, it's still taking vertical space. The simplest fix would be to add this:

line-height: 0;

See it updated.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜