设置浏览器默认样式
選中文本時(shí)的字體顏色
::selection { color: white; background: #0aa284;}
去掉chrome記住密碼后自動(dòng)填充表單的黃色背景
input:-webkit-autofill {-webkit-box-shadow:0 0 0px 1000px white inset; border : 1px solid #CCC !important ;}
chrome字體縮小
.chrome_adjust { font-size: 9px; -webkit-transform: scale(0.75); }
手機(jī)上取消高亮邊框
{ -webkit-appearance: none; -webkit-tap-highlight-color: rgba(0,0,0,0);}
一行省略號
.ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
去掉默認(rèn)表單元素樣式
-webkit-appearance: none;
加上這個(gè)讓瀏覽器支持touch和自動(dòng)滾動(dòng)這樣界面就可以滾動(dòng)了
overflow-y: auto; -webkit-overflow-scrolling:touch;
使用 viewport meta 標(biāo)簽在手機(jī)瀏覽器上控制布局
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1" />
通過快捷方式打開時(shí)全屏顯示
<meta name="apple-mobile-web-app-capable" content="yes" />
隱藏狀態(tài)欄
<meta name="apple-mobile-web-app-status-bar-style" content="blank" />
iPhone會(huì)將看起來像電話號碼的數(shù)字添加電話連接,應(yīng)當(dāng)關(guān)閉
<meta name="format-detection" content="telephone=no" />
?
抗鋸齒
-webkit-font-smoothing: antialiased;?text-shadow: 1px 1px 1px rgba(0,0,0,0.004);
?
轉(zhuǎn)載于:https://www.cnblogs.com/iloveyou-sky/p/4773376.html
總結(jié)
- 上一篇: 推荐一个golang的json库
- 下一篇: Netty 源码走读