根据之前的一些项目,总结了一下重置CSS:
@charset "UTF-8";
html {
background: #FFF;
font-size: 62.5%;
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
}
html,
legend,
input,
select,
textarea {
color: $defaultColor;
}
body {
color: inherit;
background: transparent;
}
html,
body,
legend,
input,
select,
textarea {
font: normal normal normal 12px/1.5 'Microsoft YaHei',Arial, Helvetica, sans-serif,'\5B8B\4F53';
}
body,
div,
header,
footer,
nav,
aside,
article,
section,
hgroup,
figure,
figcaption,
video,
audio,
embed,
mark,
summary,
progress,
canvas,
dl,
dt,
dd,
ul,
ol,
li,
h1,
h2,
h3,
h4,
h5,
h6,
pre,
code,
form,
fieldset,
legend,
input,
textarea,
p,
blockquote,
th,
td {
margin:;
padding: 0
}
table {
border-collapse: collapse;
border-spacing:;
_font-size: 12px;
}
td,
th {
color: inherit;
font-family: inherit;
vertical-align: top;
}
fieldset,
img,
iframe {
border: none;
}
address,
caption,
cite,
code,
dfn,
em,
strong,
th,
var {
font-style: normal;
font-weight: normal;
}
ol,
ul,
li {
list-style: none;
}
header,
footer,
nav,
aside,
article,
section,
hgroup,
figure,
figcaption {
display: block;
}
caption,
th {
text-align: left;
}
h1,
h2,
h3,
h4,
h5,
h6 {
font-size: inherit;
font-weight: normal;
}
q:before,
q:after {
content: '';
}
pre {
white-space: pre-wrap;
}
small {
font-size: 0.8em;
}
mark {
background: #ff0;
color: #000;
}
abbr[title] {
border-bottom: 1px dotted;
}
abbr,
acronym {
border:;
font-variant: normal;
}
sup,
sub {
font-size: 0.75em;
}
sup {
vertical-align: text-top;
}
sub {
vertical-align: text-bottom;
}
button,
select {
text-transform: none;
}
input:-webkit-autofill {
-webkit-box-shadow: 0 0 0px 1000px white inset;
}
input,
textarea,
select {
font-family: inherit;
font-size: inherit;
font-weight: inherit;
color: inherit;
line-height: 1.2;
&:focus {
outline: none;
}
}
textarea {
overflow-x: hidden;
overflow-y: auto;
vertical-align: top;
resize: none;
}
input[type='checkbox'],
input[type='radio'] {
width: auto;
vertical-align: middle;
}
.button,
button,
html input[type="button"],
input[type="reset"],
input[type="submit"] {
-webkit-appearance: button;
cursor: pointer;
}
label{
cursor: pointer;
}
button[disabled],
html input[disabled] {
cursor: default;
}
input::-ms-clear,
input::-ms-reveal {
display: none; /* For IE10+ */
}
input[type="checkbox"],
input[type="radio"] {
box-sizing: border-box;
padding:;
}
input[type="search"] {
-webkit-appearance: textfield;
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box;
box-sizing: content-box;
}
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
a {
background: transparent; /* For IE10+ */
}
a,
a:link,
a:hover,
a:active,
a:visited {
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
a:focus {
outline: none;
}
code,
kbd,
pre,
samp {
font-family: monospace, serif;
font-size: inherit;
}
::-webkit-input-placeholder {
color: #AAA;
opacity:;
}
::-moz-placeholder {
color: #AAA;
opacity:; /* For Firefox */
}
:-ms-input-placeholder {
color: #AAA;
opacity:;
}
::selection,
::-moz-selection {
background: inherit;
color: white;
} /* Firefox for button vertical center */
button::-moz-focus-inner,
input[type="reset"]::-moz-focus-inner,
input[type="button"]::-moz-focus-inner,
input[type="submit"]::-moz-focus-inner,
input[type="file"] > input[type="button"]::-moz-focus-inner {
border: none;
padding:;
} /* -- Normalize End-- */