【发布时间】:2015-12-11 07:30:50
【问题描述】:
使用第二个答案found here。我将我的图像组合成一个精灵,然后更新我的 CSS 以反映关键帧元素,就像提供的示例中一样。精灵图像(城堡)出现了,但没有出现幻灯片效果?我错过了什么?
示例 URL,主页中心元素:http://216.157.26.175/cookiedouglas/
这是我的 CSS:
.agentpress-pro-cookie .home-featured .widget {
/* background-color: rgba(255, 255, 255, 0.8); */
background: url("http://216.157.26.175/cookiedouglas/wp-content/uploads/sites/58/2015/05/fort-myers-homes-for-sale.jpg");
opacity: 0.95;
content: '';
/* position: absolute;
width: 400%;
height: 100%; */
z-index: -1;
/* background: url(http://placekitten.com/500/500/); Image is 500px by 500px, but only 200px by 50px is showing. */
animation: slide 3s infinite;
}
@keyframes slide {
20% {
left: 0;
}
40%, 60% {
left: -50%;
}
80%, 100% {
left: -100%;
}
}
【问题讨论】:
标签: css