gsap+Draggable实现可横向拖动的图片列表相册效果代码
代码语言:html
所属分类:拖放
代码描述:gsap+Draggable实现可横向拖动的图片列表相册效果代码
代码标签: gsap Draggable 横向 拖动 图片 列表 相册
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> * { margin: 0; padding: 0; box-sizing: border-box; } .wrapper { width: 100%; height: 100vh; background-color: #252525; display: flex; align-items: center; } .container { width: 100%; max-width: 1400px; margin: 0 auto; overflow: hidden; border: 1px solid teal; height: 300px; } .images-container { display: flex; flex-wrap: nowrap; } .image-card { width: 400px; } </style> </head> <body translate="no"> <div class="wrapper"> <div class="container"> <div class="images-container"> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=07" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=47" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=37" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=234234247" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=343722" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=3437" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=2222227" alt=""> </div> <div class="image-card"> <img src="//repo.bfw.wiki/random/400x300/风景?rand=32347" alt=""> </div> <div class="image-card"> <img src=".........完整代码请登录后点击上方下载按钮下载查看
网友评论0