看看here .
在你点击一个瓷砖后,一个房子 Sprite 应该附加到这个瓷砖上并完全显示出来。图像需要跨越多个图 block ,但是 Sprite 被相邻的图 block 覆盖。这是为什么?
.div {
background: none repeat scroll 0 0 red;
display: inline-block;
height: 20px;
width: 20px;
vertical-align:top;
transition: all 500ms ease-in-out;
cursor: url(house.png) 1 20, pointer;
}
最佳答案
这应该有效:
.div img {
position : absolute;
}
关于html - 为什么隐藏了部分图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15817538/