图片悬停放大动画效果
代码语言:html
所属分类:悬停
代码描述:图片悬停放大动画效果
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <style> @import url("https://fonts.googleapis.com/css2?family=Montserrat&display=swap"); * { box-sizing: border-box; } body { display: flex; align-items: center; justify-content: center; height: 100vh; margin: 0; font-family: 'Montserrat', sans-serif; font-size: 14px; background-color: #f4f6f8; } .container { display: flex; align-items: center; justify-content: center; height: 100%; width: 100%; overflow: hidden; } .container__image { position: relative; display: flex; flex-direction: column; justify-content: center; width: 250px; height: 250px; border-radius: 50%; background-image: url("http://repo.bfw.wiki/bfwrepo/image/5d6539613d08b.png?x-oss-process=image/auto-orient,1/resize,m_fill,w_499,h_399,/quality,q_90"); background-size: cover; transition: ease-in-out .3s; z-index: 2; } .container__image:before { content: ' '; position: absolute; width: 100%; height: 100%; top: 0; bottom: 0; left: 0; margin: auto; background: inherit; background-position: bottom; filter: blur(40px) saturate(0%); transform: scaleX(0.4); transition: ease-in-out .4s; border-radius: 120px; transform-origin: right; opacity: 0; z-index: -1; } .contain.........完整代码请登录后点击上方下载按钮下载查看
网友评论0