HTML标签默认样式

Chrome 55

html

font-size: 16px;

body

margin: 8px;

div

ul

list-style-type: disc;
margin: 1em 0; /* html默认字体大小是16px,所以1em = 16px; */
padding-left: 40px;

ol

list-style-type: decimal;
margin: 1em 0;
padding-left: 40px;

dl

margin: 1em 0;

li

dt

dd

margin-left: 40px;

h1

font-size: 2em; /* 32px ,默认字体大小是16px,下同 */
margin: 0.67em 0; /* 21.44px */

h2

font-size: 1.5em; /* 24px */
margin: 0.83em 0; /* 19.92px */

h3

font-size: 1.17em; /* 18.72px */
margin: 1em 0; /* 18.72px */

h4

margin: 1.33em 0; /* 21.28px */

h5

font-size: 0.83em; /* 13.28px */
margin: 1.67em 0; /* 22.187px */

h6

font-size: 0.67em; /* 10.72px */
margin: 2.33em 0; /* 27.96px */

p

margin: 1em 0;

a

color: -webkit-link; /* rgb(0, 0, 238) / #00e */
text-decoration: underline;
cursor: auto;

span

strong, b

 font-weight: bold;

em, i

 font-style: italic;

form

input

border: 2px inset initial;
padding: 1px 0;
font: 13.3333px Arial;

label

select

box-sizing: border-box;
white-space: pre;
font: 13.3333px Arial;
color: #000;
border: 1px solid rgb(169, 169, 169); /* #a9a9a9 */

textarea

padding: 2px;
word-wrap: break-word;
border: 1px solid;

button

padding: 1px 6px;
border: 2px outset buttonface; /* rgb(192,192,192) / #c0c0c0 */
min-height: 1.2em;
white-space: pre;

table

display: table;
border-collapse: separate;
border-spacing: 2px;
border-color: grey; /* rgb(128, 128, 128) / #808080 */

thead

display: table-header-group;
vertical-align: middle;
border-color: inherit;

tbody

display: table-row-group;
vertical-align: middle;
border-color: inherit;

tr

display: table-row;

th

display: table-cell;
font-weight: bold;
text-align: -internal-center;
/* padding: 1px; */

td

display: table-cell;
/* padding: 1px; */
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容

  • 本文是针对刚学编程的小白,都是一些基础知识,如果想了解更多深层一点的东西,欢迎移步本人博客!! 博客地址 点击跳转...
    西巴撸阅读 551评论 0 0
  • 问答题47 /72 常见浏览器兼容性问题与解决方案? 参考答案 (1)浏览器兼容问题一:不同浏览器的标签默认的外补...
    _Yfling阅读 13,796评论 1 92
  • HTML5 标签comment 注释标签用于在源文档中插入注释。注释内容不会被浏览器显示。为代码编写注释的好处是...
    才気莮孒阅读 4,082评论 1 25
  • 腾讯QQ官网 样式初始化 body,ol,ul,h1,h2,h3,h4,h5,h6,p,th,td,dl,dd,f...
    ASOASM阅读 517评论 0 1
  • 12年的时候我参加了一个中法红酒会。我对酒没什么兴趣,也就凑个热闹。在场有几个美女,基本上都是迎来往送,八面玲珑,...
    泡泡恋爱学阅读 4,245评论 2 12