This repository has been archived by the owner on Jun 9, 2022. It is now read-only.
forked from supple-kit/supple-css
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path_reset.scss
133 lines (114 loc) · 2.56 KB
/
_reset.scss
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
/* =========================================================================
generic.reset
A thin layer on top of normalize.css that provides a starting point more
suitable for web applications.
========================================================================= */
/**
* 1. Set the global `box-sizing` state to `border-box`. As per:
* paulirish.com/2012/box-sizing-border-box-ftw
* 2. Always add the vertical scrollbar to prevent layout shifting
* 3. Fonts on OSX will look more consistent with other systems that do not
* render text using sub-pixel anti-aliasing.
* 4. Apply the `$supple-font-size` & `$supple-line-height-ratio`
*/
html {
box-sizing: border-box; /* [1] */
overflow-y: scroll; /* [2] */
min-height: 100%;
font-size: #{($supple-font-size/16px)*1em}; /* [4] */
line-height: #{$supple-line-height-ratio}; /* [4] */
-moz-osx-font-smoothing: grayscale; /* [3] */
-webkit-font-smoothing: antialiased; /* [3] */
}
*,
*::before,
*::after {
box-sizing: inherit; /* [1] */
}
/**
* Remove default margins from headings
*/
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 0;
}
/**
* Removes unwanted margins & applies vertical rhythm to designated elements
* As per: http://csswizardry.com/2012/06/single-direction-margin-declarations
*/
hgroup,
ul,
ol,
dl,
blockquote,
p,
address,
table,
fieldset,
figure,
pre,
hr {
@include supple-rem(margin, 0 0 $supple-space);
}
/**
* Default indentation value for lists
*/
ul,
ol,
dd {
@include supple-rem(margin-left, $supple-space);
}
/**
* Remove extra vertical spacing when nesting lists.
*/
li > ul,
li > ol {
margin-bottom: 0;
}
/**
* Strip unwanted paddings & styling from elements
*/
button {
background: transparent;
}
button,
fieldset,
ol,
ul {
padding: 0;
}
button,
iframe,
fieldset {
border: 0;
}
/**
* Suppress the focus outline on links that cannot be accessed via keyboard.
* This prevents an unwanted focus outline from appearing around elements that
* might still respond to pointer events.
*/
[tabindex='-1']:focus {
outline: none !important;
}
/**
* Gets rid of the annoying outline for mouse users but preserves it for
* keyboard users, and is ignored by browsers that don’t support :focus-visible.
* As per: https://twitter.com/LeaVerou/status/1045768279753666562
*/
:focus:not(:focus-visible) { // stylelint-disable-line selector-pseudo-class-no-unknown
outline: none;
}
/**
* Image
*
* 1. By default all images are fluid
* 2. Render `alt` visually offset when images don't load
*/
img {
max-width: 100%; /* [1] */
font-style: italic; /* [2] */
}