修改placeholder样式

 1 /* 修改placeholder样式,兼容性 新版火狐,IE10+ */
 2         .login-input::-webkit-input-placeholder {
 3             color: #000;
 4             font-size: 0.3rem;
 5             transition: .5s;
 6             transform-origin: left top;
 7         }
 8         .login-input::-moz-placeholder {
 9             color: #000;
10             font-size: 0.3rem;
11             transition: .5s;
12             transform-origin: left top;
13         }
14         .login-input:-ms-input-placeholder {
15             color: #000;
16             font-size: 0.3rem;
17             transition: .5s;
18             transform-origin: left top;
19         }
20         /* 兼容性 新版火狐,IE10+ */
21         .login-input:focus::-webkit-input-placeholder {
22             color: #aaa;
23             transform: scale(0.7) translateY(-0.28rem);
24         }
25         .login-input:focus::-moz-placeholder {
26             color: #aaa;
27             transform: scale(0.7) translateY(-0.28rem);
28         }
29         .login-input:focus:-ms-input-placeholder {
30             color: #aaa;
31             transform: scale(0.7) translateY(-0.28rem);
32         }

 

posted @ 2018-11-09 09:25  叶子玉  阅读(200)  评论(0编辑  收藏  举报