1、取消a標籤在移動端點擊時的藍色css
-webkit-tap-highlight-
color
: rgba(
255
,
255
,
255
,
0
);
-webkit-user-select:
none
;
-moz-user-focus:
none
;
-moz-user-select:
none
;
2、使用圖片做爲a標籤的點擊按鈕時,當觸發touchstart的時候,每每會有一個灰色的背景 ios
a,a:hover,a:active,a:visited,a:link,a:focus{
-webkit-tap-highlight-
color
:rgba(
0
,
0
,
0
,
0
);
-webkit-tap-highlight-
color
:
transparent
;
outline
:
none
;
background
:
none
;
text-decoration
:
none
;
}
3、改變選中內容的背景顏色web
::selection {
post
background
:
#FFF
;
color
:
#333
;
}
::-moz-selection {
background
:
#FFF
;
color
:
#333
;
}
::-webkit-selection {
background
:
#FFF
;
color
:
#333
;
}
4、去除ios input框點擊時的灰色背景spa
-webkit-tap-highlight-
color
:rgba(
0
,
0
,
0
,
0);
code