css+div实现照片悬浮折叠折纸动画效果代码
代码语言:html
所属分类:悬停
代码描述:css+div实现照片悬浮折叠折纸动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> * { margin: 0; padding: 0; } body { display: flex; justify-content: center; align-items: center; min-height: 100vh; background: #2f364f; } .box { width: 640px; height: 360px; transform: rotate(-25deg) skew(25deg); transition: 0.5s; display: flex; } .box span { width: 25%; height: 100%; background: url(//repo.bfw.wiki/bfwrepo/image/63534d857657c.png); background-size: cover; background-position: calc(-160px * var(--i)); display: block; transition: 0.5s; pointer-events: none; border-top: 5px solid #fff; border-bottom: 5px solid #fff; } .box span:first-child { border-left: 5px solid #fff; } .box span:last-child .........完整代码请登录后点击上方下载按钮下载查看
网友评论0