-
Notifications
You must be signed in to change notification settings - Fork 0
/
sane-reset.css
98 lines (82 loc) · 2.47 KB
/
sane-reset.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
/*!sane-reset*/
/** if IE, import full css reset */
@import "https://cdnjs.cloudflare.com/ajax/libs/meyer-reset/2.0/reset.min.css" screen and (-ms-high-contrast: active), (-ms-high-contrast: none);
/** remove user agent styles */
:not(input), *::before, *::after {
all: unset;
}
/** add back in the basic ones */
html, address,
blockquote,
body, dd, div,
dl, dt, fieldset, form,
h1, h2, h3, h4, h5, h6,
ol, p, ul, dir, br,
hr, menu, pre,
table, center { display: block; }
button, textarea, input, select { display: inline-block }
li { display: list-item }
head, [hidden] { display: none }
caption { display: table-caption }
kbd, samp { font-family: monospace }
pre { white-space: pre }
/** shame people for using deprecated tags */
acronym, applet, basefont, big, center, dir, font,
frame, frameset, isindex, noframes, s, strike, tt, u,
.do-not-use-deprecated-tags {
outline: 8px dashed red;
}
/** shame people for using tables */
table { display: block }
table::after { content: 'Do not use <table>'; color: red; font: 900 1.5em monospace }
table * { display: none }
/** sensible browser things used in chrome and firefox */
slot { display: contents }
/** useful 99% of the time, and overrideable */
*, *::before, *::after {
box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
font: inherit;
letter-spacing: inherit;
color: inherit;
outline-offset: 0;
}
html {
font-size: 16px;
font-weight: 400;
line-height: 1;
overflow-y: scroll;
}
hr {
box-sizing: content-box;
height: 0;
overflow: visible;
border-style: solid;
border-width: 1px 0 0;
}
svg:not(:root) {
overflow: hidden;
}
/** Normalize input elements manually */
/* Remove the default vertical scrollbar in IE 11. */
textarea {
overflow: auto;
}
/* Correct the cursor style of increment and decrement buttons in Chrome. */
[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
height: auto;
}
/* Correct the odd appearance in Chrome and Safari. */
[type="search"] {
-webkit-appearance: textfield;
}
/* Remove the inner padding in Chrome and Safari on macOS. */
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/* Correct the inability to style clickable types in iOS and Safari. */
::-webkit-file-upload-button {
-webkit-appearance: button;
}