Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: static/scss/_utilities.scss

Issue 29603821: Noissue - Separated website-default utilities (Closed) Base URL: https://hg.adblockplus.org/website-defaults
Patch Set: Created Nov. 10, 2017, 2:04 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 // This file is part of website-defaults 1 // This file is part of website-defaults
2 // Copyright (C) 2016-present eyeo GmbH 2 // Copyright (C) 2016-present eyeo GmbH
3 // 3 //
4 // website-defaults is free software: you can redistribute it and/or 4 // website-defaults is free software: you can redistribute it and/or
5 // modify it under the terms of the GNU General Public License as published by 5 // modify it under the terms of the GNU General Public License as published by
6 // the Free Software Foundation, either version 3 of the License, or 6 // the Free Software Foundation, either version 3 of the License, or
7 // (at your option) any later version. 7 // (at your option) any later version.
8 // 8 //
9 // website-defaults is distributed in the hope that it will be useful, 9 // website-defaults is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of 10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details. 12 // GNU General Public License for more details.
13 // 13 //
14 // You should have received a copy of the GNU General Public License 14 // You should have received a copy of the GNU General Public License
15 // along with website-defaults. If not, see <http://www.gnu.org/licenses/>. 15 // along with website-defaults. If not, see <http://www.gnu.org/licenses/>.
16 16
17 /******************************************************************************* 17 /*******************************************************************************
18 * Utilities 18 * Utilities
juliandoucette 2017/11/10 14:08:04 Detail: The imports below are in alphabetical orde
ire 2017/11/13 08:33:37 If we import by component, wouldn't that mean we w
juliandoucette 2017/11/13 12:32:59 I didn't think so at the time :( Apparently the f
ire 2017/11/14 07:14:50 Ack. It would be awesome to do it this way when th
19 ******************************************************************************/ 19 ******************************************************************************/
20 20
21 /* Responsive widths 21 @import "utilities/background-colors.scss";
ire 2017/11/13 08:33:37 NIT: I think we should not have this file and have
juliandoucette 2017/11/13 12:32:59 *I just thought that* - I agree.
22 ******************************************************************************/ 22 @import "utilities/clearfix.scss";
23 23 @import "utilities/device-widths.scss";
24 /** 24 @import "utilities/responsive-widths.scss";
25 * Stretch content (e.g. images) full-width 25 @import "utilities/screen-reader-only.scss";
26 */ 26 @import "utilities/text-alignment.scss";
27 .full-width 27 @import "utilities/unstyled.scss";
28 {
29 display: block;
30 width: 100%;
31 }
32
33 /**
34 * Center content within a (responsive) fixed width
35 */
36 .container
37 {
38 width: $container-width;
39 max-width: 100%;
40 margin-right: auto;
41 margin-left: auto;
42 padding-right: $small-space;
43 padding-left: $small-space;
44 }
45
46 /* Device widths
47 ******************************************************************************/
48
49 .phone-width { width: $phone-width; }
50 .phablet-width { width: $phablet-width; }
51 .tablet-width { width: $tablet-width; }
52 .desktop-width { width: $desktop-width; }
53 .large-desktop-width { width: $large-desktop-width; }
54
55 /* Text alignment
56 ******************************************************************************/
57
58 .text-center { text-align: center; }
59 .text-left { text-align: left; }
60 .text-right { text-align: right; }
61 .text-start { text-align: left; }
62 [dir="rtl"] .text-start { text-align: right; }
63 .text-end { text-align: right; }
64 [dir="rtl"] .text-end { text-align: left; }
65
66 /* Clearfix
67 ******************************************************************************/
68
69 .clearfix:after,
70 .clearfix:before
71 {
72 display: table;
73 content: " ";
74 }
75
76 .clearfix:after
77 {
78 clear: both;
79 }
80
81 /* Screen reader only
82 ******************************************************************************/
83
84 .sr-only
85 {
86 position: absolute;
87 overflow: hidden;
88 clip: rect(0, 0, 0, 0);
89 width: 1px;
90 height: 1px;
91 margin: -1px;
92 padding: 0;
93 border: 0;
94 }
95
96 /* Unstyled elements
97 ******************************************************************************/
98
99 .unstyled,
100 .unstyled *,
101 .content .unstyled
102 {
103 margin: 0;
104 padding: 0;
105 border: 0;
106 background: none;
107 }
108
109 ul.unstyled
110 {
111 list-style: none;
112 }
113
114 /* Backgrounds
115 ******************************************************************************/
116
117 .bg-primary
118 {
119 color: $primary-light;
120 background-color: $primary-dark;
121 }
122
123 .bg-secondary
124 {
125 color: $secondary-light;
126 background-color: $secondary-dark;
127 }
128
129 .bg-accent
130 {
131 color: $accent-light;
132 background-color: $accent-dark;
133 }
134
135 .bg-error
136 {
137 color: $error-light;
138 background-color: $error-dark;
139 }
OLDNEW
« no previous file with comments | « no previous file | static/scss/utilities/_background-colors.scss » ('j') | static/scss/utilities/_responsive-widths.scss » ('J')

Powered by Google App Engine
This is Rietveld