1. @charset "utf-8";
  2. html, body {
  3. background: #fff;
  4. color: #505050;
  5. font-size: 10px;
  6. -moz-user-select: none; /*火狐*/
  7. -webkit-user-select: none; /*webkit浏览器*/
  8. -ms-user-select: none; /*IE10*/
  9. -khtml-user-select: none; /*早期浏览器*/
  10. user-select: none;
  11. -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  12. -webkit-tap-highlight-color: transparent;/*这个属性只用于iOS (iPhone和iPad)。当你点击一个链接或者通过Javascript定义的可点击元素的时候,它就会出现一个半透明的灰色背景。要重设这个表现,
                                你可以设置-webkit-tap-highlight-color为任何颜色。想要禁用这个高亮,设置颜色的alpha值为0即可*/
  1. -webkit-touch-callout: none;/*系统默认菜单被禁用*/
  2. font-family:Tahoma,Arial,Roboto,'Droid Sans','Helvetica Neue','Droid Sans Fallback','Heiti SC',sans-self;
  3. }
  4. body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td, hr, button, article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {
  5. margin: 0;
  6. padding: 0;
  7. }
  8. body, button, input, select, textarea {
  9. line-height: 1;
  10. }
  11. h1, h2, h3, h4, h5, h6 {
  12. font-weight: normal;
  13. }
  14. html, body, form, fieldset, p, div, h1, h2, h3, h4, h5, h6 {
  15. -webkit-text-size-adjust: none;
  16. }
  17. body {
  18. max-width: 750px;
  19. margin: 0 auto;
  20. }
  21. img {
  22. width: 100%;
  23. vertical-align: middle;
  24. }
  25. /*阻止旋转屏幕时自动调整字体大小*/
  26. textarea {
  27. resize: none;
  28. }
  29. /*取消按钮在inphone上的默认样式*/
  30. input[type=button] {
  31. -webkit-appearance: none;
  32. outline: none
  33. }
  34. input::-webkit-input-placeholder {
  35. color: #F0F0F0;
  36. }
  37. textarea::-webkit-input-placeholder {
  38. color: #F0F0F0;
  39. }
  40. input::-webkit-input-speech-button {
  41. display: none
  42. }
  43. table {
  44. border-collapse: collapse;
  45. border-spacing: 0;
  46. }
  47. th {
  48. text-align: inherit;
  49. }
  50. fieldset, img {
  51. border: none;
  52. }
  53. abbr, acronym {
  54. border: none;
  55. font-variant: normal;
  56. }
  57. del {
  58. text-decoration: line-through;
  59. }
  60. ol, ul {
  61. list-style: none;
  62. }
  63. caption, th {
  64. text-align: left;
  65. }
  66. sub, sup {
  67. font-size: 75%;
  68. line-height: 0;
  69. position: relative;
  70. vertical-align: baseline;
  71. }
  72. sup {
  73. top: -0.5em;
  74. }
  75. sub {
  76. bottom: -0.25em;
  77. }
  78. ins, a, a:hover {
  79. text-decoration: none;
  80. }
  81. a:focus, *:focus {
  82. outline: none;
  83. }
  84. small{ font-size: 90%;}
  85. /*清除浮动*/
  86. .clearfix:before, .clearfix:after, header:before, header:after, footer:before, footer:after,
  87. .col-1:before, .col-1:after, .col-2:before, .col-2:after, .col-3:before, .col-3:after,
  88. .col-4:before, .col-4:after, .col-5:before, .col-5:after, .col-6:before, .col-6:after,
  89. .col-7:before, .col-7:after, .col-8:before, .col-8:after, .col-9:before, .col-9:after,
  90. .col-10:before, .col-10:after, .col-11:before, .col-11:after, .col-12:before, .col-12:after,
  91. .row:before, .row:after {
  92. content: "";
  93. display: table;
  94. }
  95. .clearfix:after, footer:after, header:after, .col-1:after, .col-2:after, .col-3:after,
  96. .col-4:after, .col-5:after, .col-6:after, .col-7:after, .col-8:after, .col-9:after,
  97. .col-10:after, .col-11:after, .col-12:after {
  98. clear: both;
  99. }
  100. .clearfix {
  101. zoom: 1;
  102. }
  103. .clear {
  104. clear: both;
  105. display: block;
  106. font-size: 0;
  107. height: 0;
  108. line-height: 0;
  109. overflow: hidden;
  110. }
  111. .hide {
  112. display: none;
  113. }
  114. .block {
  115. display: block;
  116. }
  117. .outL {
  118. white-space: normal;
  119. word-break: break-all;
  120. width: 100px;
  121. }
  122. .outH {
  123. overflow: hidden;
  124. text-overflow: ellipsis;
  125. white-space: nowrap;
  126. width: 100px;
  127. }
  128. /*布局*/
  129. .fl {
  130. float: left;
  131. display: inline;
  132. }
  133. .fr {
  134. float: right;
  135. display: inline;
  136. }
  137. .cb {
  138. clear: both;
  139. }
  140. .cl {
  141. clear: left;
  142. }
  143. .cr {
  144. clear: right;
  145. }
  146. .rel {
  147. position: relative;
  148. }
  149. .abs {
  150. position: absolute;
  151. }
  152. .tac {
  153. text-align: center;
  154. }
  155. .tal {
  156. text-align: left;
  157. }
  158. .tar {
  159. text-align: right;
  160. }
  161. .dib {
  162. display: inline-block;
  163. }
  164. .vab {
  165. vertical-align: bottom;
  166. }
  167. .vam {
  168. vertical-align: middle;
  169. }
  170. .vat {
  171. vertical-align: top;
  172. }
  173. /*元素垂直 水平居中*/
  174. .box {
  175. display: -webkit-box;
  176. -webkit-box-orient: horizontal;
  177. -webkit-box-pack: center;
  178. -webkit-box-align: center;
  179. display: -moz-box;
  180. -moz-box-orient: horizontal;
  181. -moz-box-pack: center;
  182. -moz-box-align: center;
  183. display: -o-box;
  184. -o-box-orient: horizontal;
  185. -o-box-pack: center;
  186. -o-box-align: center;
  187. display: -ms-box;
  188. -ms-box-orient: horizontal;
  189. -ms-box-pack: center;
  190. -ms-box-align: center;
  191. display: box;
  192. box-orient: horizontal;
  193. box-pack: center;
  194. box-align: center;
  195. }
  196. /*flex*/
  197. .row {
  198. display: -webkit-flex;
  199. display: flex;
  200. -webkit-flex-wrap: wrap;
  201. flex-wrap: wrap;
  202. flex-direction: wrap;
  203. display: -webkit-box;
  204. -webkit-box-orient: horizontal;
  205. -webkit-box-lines: multiple;
  206. width: 100%;
  207. height: auto;
  208. margin: auto;
  209. }
  210. .flex1 {
  211. -webkit-box-flex: 1;
  212. -webkit-flex: 1;
  213. flex: 1;
  214. }
  215. .flex2 {
  216. -webkit-box-flex: 2;
  217. -webkit-flex: 2;
  218. flex: 2;
  219. }
  220. .flex3 {
  221. -webkit-box-flex: 3;
  222. -webkit-flex: 3;
  223. flex: 3;
  224. }
  225. /*flex*/
  226. /*宽度*/
  227. .col-1,.col-2,.col-3,.col-4,.col-5,.col-6,
  228. .col-7,.col-8,.col-9,.col-10 .col-11,.col-12{
  229. float: left;
  230. }
  231. .col-1 {
  232. width: 8.33333333%;
  233. }
  234. .col-2 {
  235. width: 16.66666667%;
  236. }
  237. .col-3 {
  238. width: 25%;
  239. }
  240. .col-4 {
  241. width: 33.33333333%;
  242. }
  243. .col-5 {
  244. width: 41.66666667%;
  245. }
  246. .col-6 {
  247. width: 50%;
  248. }
  249. .col-7 {
  250. width: 58.33333333%;
  251. }
  252. .col-8 {
  253. width: 66.66666667%;
  254. }
  255. .col-9 {
  256. width: 75%;
  257. }
  258. .col-10 {
  259. width: 83.33333333%;
  260. }
  261. .col-11 {
  262. width: 91.66666667%;
  263. }
  264. .col-12 {
  265. width: 100%;
  266. }

  

移动web开发------公用css----自己总结的更多相关文章

  1. web开发:css总结与应用

    一.常用标签的使用 二.边界圆角 三.背景样式 四.精灵图 五.盒模型布局细节 六.盒模型案例 七.w3c主页 一.常用标签的使用 <!DOCTYPE html> <html> ...

  2. Java Web开发——HTML CSS JavaScript 杂记

    HTML是一种在互联网上常见的网页制作标注性语言,并不能算作一种程序设计语言.因为它相对程序设计语言来说缺少了其应所有的特征.对于网站设计人员来说,只使用HTML是不够的,需要在页面中引入CSS样式. ...

  3. web开发:css基础

    一.w3c架构分析 二.css三种引入 三.三种引入的优先级 四.基础选择器 五.长度单位与颜色 六.文件样式操作 七.display 一.w3c架构分析 <!DOCTYPE html> ...

  4. iOS Web开发激活css的active伪类

    最近在做一个资讯客户端,用到UIWebview展示一些网页内容,本来想做一个简单的按压效果,发现在css中设置active属性一直不管用. 查阅了一下资料,今天发现,要让css active伪类生效, ...

  5. web开发: css高级与盒模型

    一.组合选择器 二.复制选择器优先级 三.伪类选择器 四.盒模型 五.盒模型显示区域 六.盒模型布局 一.组合选择器 <!DOCTYPE html> <html> <he ...

  6. 6. web前端开发分享-css,js移动篇

    随着移动市场的逐步扩大及相关技术的日趋完善,对前端开发提出了新的岗位要求,在继承前人成果的基础上需要在新的历史条件下有新的创新.移动端的开发,虽然没有IE6众多问题的折磨,但是多平台,多设备的兼容,也 ...

  7. Web开发中20个很有用的CSS库

    来源: 微信公众号文章 在过去的几年中,CSS已经成为一大部分开发者和设计者的最爱,因为它提供了一系列功能和特性.每个月都有无数个围绕CSS的工具被开发者发布以简化WEB开发.像CSS库,框架,应用这 ...

  8. Wee – 为现代 Web 开发打造的 CSS 脚手架

    Wee 包含许多开发人员在搭建响应的,互动的网站和应用程序时需要的组件.正如它的名字一样,Wee 是一个微小.移动优先的 CSS 复位框架.Wee 组织在一个简单的.可扩展的层次结构,拥有一致的样式和 ...

  9. Normalize.css – 现代 Web 开发必备的 CSS resets

    Normalize.css 是一个可定制的 CSS 文件,使浏览器呈现的所有元素,更一致和符合现代标准.它正是针对只需要统一的元素样式.该项目依赖于研究浏览器默认元素风格之间的差异,精确定位需要重置的 ...

随机推荐

  1. Go -- 一致性哈希算法

    一致性哈希算法在1997年由麻省理工学院的Karger等人在解决分布式Cache中提出的,设计目标是为了解决因特网中的热点(Hot spot)问题,初衷和CARP十分类似.一致性哈希修正了CARP使用 ...

  2. 取汉子拼音首字母的VB.Net方法

    '/ <summary> '/ 获得一个字符串的汉语拼音码 '/ </summary> '/ <param name="strText">字符串 ...

  3. 通过Python实现自动填写调查问卷

    0X00 前言 快开学了,看到空间里面各种求填写调查问卷的,我才想起来貌似我也还没做.对于这种无意义的问卷,我是不怎么感冒的,所以我打算使用”特技”来完成,也就是python,顺便重新复习一下pyth ...

  4. uml精粹——10.状态机图

    10.状态机图state machine diagram   状态机图是常见的描写叙述一个系统行为的技术. 在面向对象的方法中,为单个类绘制一个状态机图来展示单个对象的生命周期行为. 见图10.1 图 ...

  5. XStream 数组(List)输出结构

    <!-- 期望的DOM树 --> <Articles> <item> <Title>微信SDK初步结构</Title> <Descri ...

  6. 【C语言天天练(九)】动态内存分配

    引言:数组的元素存储于内存中连续的位置上.当一个数组被声明时.它所须要的内存在编译时就被分配. 可是,我们能够使用动态内存分配在执行时为它分配内存. 一块内存的生命周期能够分为四个阶段:分配.初始化. ...

  7. Effective C++ 条款四 确定对象被使用前已被初始化

    1.对于某些array不保证其内容被初始化,而vector(来自STL)却有此保证. 2.永远在使用对象前初始化.对于无任何成员的内置类型,必须手工完成.      int x = 0;      c ...

  8. Spark Streaming性能优化系列-怎样获得和持续使用足够的集群计算资源?

    一:数据峰值的巨大影响 1. 数据确实不稳定,比如晚上的时候訪问流量特别大 2. 在处理的时候比如GC的时候耽误时间会产生delay延迟 二:Backpressure:数据的反压机制 基本思想:依据上 ...

  9. PHP中的多行字符串传递给JavaScript方法两则

    PHP和JavaScript都是初学.近期有这么个需求: 例如说有一个PHP的多行字符串: $a = <<<EOF thy38 csdn blog EOF; 传递给JavaScrip ...

  10. centos 7.xx 安装LAMP环境

    一.安装Apache 1.安装yum -y install httpd2.开启apache服务systemctl start httpd.service3.设置apache服务开机启动systemct ...