HTML图片在div中心旋转+变色 鼠标移除后 慢慢恢复原样
2017-11-30 18:24
531 查看
//鼠标移除后 慢慢恢复原样
列 th
th{ transition: all 2s; }
th:hover{
//变为原来的几倍大小
transform: scale(1.4);
}
列 th
th{ transition: all 2s; }
th:hover{
//变为原来的几倍大小
transform: scale(1.4);
}
<style> .divz { width: 500px; height: 500px; margin: 0 auto; position: relative; } .div1 { width: 500px; height: 500px; background-color: blue; } .div2 { width: 50px; height: 50px; position: absolute; display: none; top: 48%; left: 45%; height: 50px; transition: 2s; /*transform: rotate(180deg);*/ animation: me 2s; } .divz:hover .div2 { display: block; } @keyframes me { from {} to { transform: rotate(360deg); background-color: #000000; } } </style>
<div class="divz"> <div class="div1"></div> <div class="div2"> <img src="img/Cutter_2017-11-30 08_29_58.287.png" width="50px" height="50px"> </div> </div>
相关文章推荐
- 使用HTML标签的属性对图片进行旋转效果
- AS3基础:图片绕中心点旋转(Matrix) 与直接rotation不会发虚
- 鼠标onmouseover,onmouseout事件动态创建DIV 显示图片
- 只要把鼠标移上Div方框,方框就自动顺时针旋转
- HTML 多个div盒子鼠标浮动,显示结果不一样
- css3鼠标经过,图片旋转
- JS+DIV表单实例——鼠标移上背景变色和文字提示
- js实现图片旋转 js滚动鼠标中间对图片放大缩小
- MFC GDI+实现以鼠标为中心缩放图片(并且可以拖动)
- jQuery鼠标移动到Div上后切换背景,或更换图片
- H5移动端下html上传图片被旋转问题
- 实现鼠标经过背景变色的方法有很多,今天我们介绍的是用CSS+DIV实现的方法。
- JQuery鼠标移到图片改变,移出图片恢复原来图片
- Unity3d GUI中的图片跟随鼠标旋转脚本
- 如何在html页面上随着鼠标的位置显示浮动层图片或别的东东?(附代码)
- CSS+DIV实现鼠标经过背景变色
- html-鼠标移动后自动旋转
- div内部实现图片旋转、放大、缩小、拖拽
- 可编辑DIV (contenteditable="true") 在鼠标光标处插入图片或者文字
- 图片绕着中心点旋转