web299.com
全部
教育
语言/资格考试
法律
互联网
政务民生
Word模板
Excel模板
PPT模板
网页特效
小程序模板
网站模板
首页
教育
语言/资格考试
法律
互联网
政务民生
Word模板
Excel模板
PPT模板
网页特效
小程序模板
网站模板
当前位置:
首页
>
网页特效
>
动画效果
CSS3商城购物卡片布局动画特效
分类:
动画效果
日期:
2024-05-14
点击(0)
评论(0)
演 示
免费下载
简介
在页面中引入bootstrap.min.css和font-awesome.min.css文件。 ```html
``` ##### HTML 使用下面的HTML结构来创建商城购物卡片布局。 ```html
Men's Shirt
$11.00
$14.00
Women's Red Top
$8.00
$12.00
``` ##### CSS样式 然后通过下面的CSS样式来完成网格布局和制作鼠标悬停时候的动画特效。 ```html .product-grid{ font-family: 'Open Sans', sans-serif; text-align: center; overflow: hidden; position: relative; transition: all 0.5s ease 0s; } .product-grid:hover{ box-shadow: 0 0 10px rgba(0,0,0,0.3); } .product-grid .product-image{ overflow: hidden; } .product-grid .product-image a{ display: block; } .product-grid .product-image img{ width: 100%; height: auto; transition: all 0.5s ease 0s; } .product-grid:hover .product-image img{ transform: scale(1.1); } .product-grid .product-content{ padding: 12px 12px 15px 12px; transition: all 0.5s ease 0s; } .product-grid:hover .product-content{ opacity: 0; } .product-grid .title{ font-size: 20px; font-weight: 600; text-transform: capitalize; margin: 0 0 10px; transition: all 0.3s ease 0s; } .product-grid .title a{ color: #000; } .product-grid .title a:hover{ color: #2e86de; } .product-grid .price { font-size: 18px; font-weight: 600; color:#2e86de; } .product-grid .price span { color: #999; font-size: 15px; font-weight: 400; text-decoration: line-through; margin-left: 7px; display: inline-block; } .product-grid .social{ background-color: #fff; width: 100%; padding: 0; margin: 0; list-style: none; opacity: 0; transform: translateX(-50%); position: absolute; bottom: -50%; left: 50%; z-index: 1; transition: all 0.5s ease 0s; } .product-grid:hover .social{ opacity: 1; bottom: 20px; } .product-grid .social li{ display: inline-block; } .product-grid .social li a{ color: #909090; font-size: 16px; line-height: 45px; text-align: center; height: 45px; width: 45px; margin: 0 7px; border: 1px solid #909090; border-radius: 50px; display: block; position: relative; transition: all 0.3s ease-in-out; } .product-grid .social li a:hover { color: #fff; background-color: #2e86de; width: 80px; } .product-grid .social li a:before, .product-grid .social li a:after{ content: attr(data-tip); color: #fff; background-color: #2e86de; font-size: 12px; letter-spacing: 1px; line-height: 20px; padding: 1px 5px; border-radius: 5px; white-space: nowrap; opacity: 0; transform:translateX(-50%); position: absolute; left: 50%; top: -30px; } .product-grid .social li a:after{ content: ''; height: 15px; width: 15px; border-radius: 0; transform:translateX(-50%) rotate(45deg); top: -20px; z-index: -1; } .product-grid .social li a:hover:before, .product-grid .social li a:hover:after{ opacity: 1; } @media only screen and (max-width:990px){ .product-grid{ margin-bottom: 30px; } } ```
相关推荐
html5浪漫粒子表白文字特效
SlidesJS幻灯片特效
html5瀑布流相册特效
css3 svg实现的情人节表白鲜花动画特效
t-scroll.js基于ES6的DOM元素,过渡动画库插件
纯js写省市区三级联动效果
广告
广告