样式注意事项

css样式兼容性问题

color:red;   /* 所有浏览器都支持 */ 

color:red !important;   /* Firefox、IE7支持 */
_color:red;    /* IE6支持 */
*color:red;    /* IE6、IE7支持 */
*+color:red;    /* IE7支持 */
color:red\9;    /* IE9以上支持 */

color:red\0;    /* ie支持 */  

input:-webkit-autofill { -webkit-box-shadow: 0 0 0px 1000px white inset;}   //清除Chrome 自动填充的表单是淡黄色的背景

white-space:nowrap; overflow:hidden; text-overflow:ellipsis;   字体超出显示省略号  三个条件都需要满足


 text-indent:-9999em; 字隐藏


text-transform:uppercase; 字母全部大写


dashed   边框虚线


 italic   字体斜体 


text-shadow: 5px 5px 5px #FF0000;    文本阴影    


2d旋转  常用于箭头方向

transform:rotate(9deg);    旋转方向
-ms-transform:rotate(9deg); /* Internet Explorer */
-moz-transform:rotate(9deg); /* Firefox */
-webkit-transform:rotate(9deg); /* Safari 和 Chrome */
-o-transform:rotate(9deg); /* Opera */

-moz-transform: scale(1.1); -webkit-transform: scale(1.1); -o-transform: scale(1.1); -ms-transform: scale(1.1);  缩放  常用于图片滑过效果


过渡效果

transition-property:width 1s linear 2s;  过渡的css属性名称  过渡时间  曲线效果  从什么时候开始
/* Firefox 4 */
-moz-transition:width 1s linear 2s;
/* Safari and Chrome */
-webkit-transition:width 1s linear 2s;
/* Opera */
-o-transition:width 1s linear 2s;

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值