Skip to content

Commit 5dacbfc

Browse files
mirshkogillesdemey
authored andcommitted
New styles (#83)
* Cleaning up _header, _vars, app for PR * Cleaning up _griditem for PR * Cleaning up _listitem for PR * Cleaned up _mediaplayer for PR Should all be good now for PR
1 parent 1b18257 commit 5dacbfc

File tree

6 files changed

+66
-46
lines changed

6 files changed

+66
-46
lines changed

app/scss/_griditem.scss

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
width: 100%;
3333
height: 100%;
3434

35-
background-color: rgba(0, 0, 0, .3);
35+
background-color: rgba($black, .3);
3636

3737
transition: all 150ms;
3838
opacity: 0;
@@ -46,7 +46,7 @@
4646
width: 100%;
4747
height: 100%;
4848

49-
color: #fff;
49+
color: $white;
5050
font-size: 60px;
5151

5252
line-height: 200px;
@@ -88,9 +88,9 @@
8888
padding: 2px 5px 0px 5px;
8989

9090
position: absolute;
91-
color: #fff;
91+
color: $white;
9292

93-
background-color: rgba(0, 0, 0, 0.85);
93+
background-color: rgba($black, 0.87);
9494

9595
left: 10px;
9696
pointer-events: none;
@@ -102,13 +102,13 @@
102102

103103
.grid-item .item__artist {
104104
bottom: 33px;
105-
color: #C1C1C1;
105+
color: $grey-400;
106106
}
107107

108108
.item__footer {
109109
height: 16px;
110110
font-size: 12px;
111-
color: #666;
111+
color: $grey-700;
112112

113113
margin-top: 15px;
114114
}

app/scss/_header.scss

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
* Header styles
33
*/
44
header {
5-
$height: 42px;
6-
background-color: #333;
5+
$height: 48px;
6+
background-color: $grey-900;
77

88
height: $height;
99
line-height: $height;
@@ -18,26 +18,26 @@ header {
1818
li { flex: 1; }
1919

2020
a {
21+
-webkit-user-drag: none;
2122
display: block;
2223
height: $height;
2324

24-
color: rgba(255, 255, 255, .6);
25+
color: $secondary-text;
2526
font-size: 13px;
2627
font-weight: 500;
2728

2829
text-transform: uppercase;
2930
text-decoration: none;
3031
text-align: center;
31-
text-shadow: 0 0 1px rgba(0, 0, 0, 1);
3232

3333
letter-spacing: 0.5px;
3434

3535
transition: background-color 150ms;
3636

37-
&.active, &:hover { color: rgba(255, 255, 255, .85); }
37+
&.active, &:hover { color: $primary-text; }
3838

3939
&.active {
40-
border-bottom: solid 2px #f50;
40+
border-bottom: solid 4px $soundcloud;
4141
}
4242
}
4343

app/scss/_listitem.scss

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,23 @@
11
@import 'mixins';
22

33
.list-item {
4-
&:nth-child(odd) { background-color: #FCFCFC; }
5-
&:nth-child(even) { background-color: #FFF; }
4+
background-color: $white;
65

76
// tracks within a playlist
87
.list-item {
9-
&:nth-child(odd) { background-color: #FFF; }
10-
&:nth-child(even) { background-color: #FCFCFC; }
8+
background-color: $white;
119
}
1210

1311
}
1412

1513
// playlist headers should always be white in the playlists views
1614
.content__view__playlists {
17-
.list-item.playlist { background-color: #FFF; }
15+
.list-item.playlist { background-color: $white; }
1816
}
1917

2018
.list-item {
2119
$height: 64px;
22-
background-color: #fff;
20+
background-color: $white;
2321

2422
overflow: hidden;
2523
width: 100%;
@@ -29,28 +27,28 @@
2927
&:not(.playlist) {
3028

3129
&:hover, &.active {
32-
background-color: rgba(#f50, 0.05);
30+
background-color: rgba($black, 0.05);
3331
}
3432

3533
&:hover .cover__overlay { opacity: 1; }
3634

3735
&.active {
38-
.item__title { color: #f50; }
36+
.item__title { color: $soundcloud; }
3937
.cover__overlay { opacity: 1; }
4038
}
4139

4240
}
4341

4442
&.playlist .playlist__header {
4543
&:hover, &.active {
46-
background-color: rgba(#f50, 0.05);
44+
background-color: rgba($black, 0.05);
4745
}
4846
&:hover .cover__overlay { opacity: 1; }
4947
}
5048

5149
&.playlist.active {
5250
.playlist__header {
53-
.item__title { color: #f50; }
51+
.item__title { color: $soundcloud; }
5452
.cover__overlay { opacity: 1; }
5553
}
5654
}
@@ -75,9 +73,9 @@
7573
width: 100%;
7674
height: 100%;
7775

78-
background-color: rgba(#f50, .85);
76+
background-color: rgba($soundcloud, .70);
7977

80-
transition: all 100ms;
78+
transition: all .2s;
8179
opacity: 0;
8280
}
8381

@@ -87,7 +85,7 @@
8785
width: 100%;
8886
height: 100%;
8987

90-
color: #fff;
88+
color: $white;
9189
font-size: 35px;
9290

9391
line-height: 100%;
@@ -124,7 +122,7 @@
124122
}
125123

126124
.item__artist {
127-
color: #888;
125+
color: $grey-700;
128126
}
129127

130128
.item__title {}

app/scss/_mediaplayer.scss

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,13 @@
55
width: 100%;
66
height: auto;
77

8-
background-color: #f2f2f2;
8+
background-color: $white;
99

1010
transition: transform 300ms, height 300ms;
1111

1212
.media-player__controls {
1313
position: relative;
14-
background-image: linear-gradient(180deg, #FFF, #E3E3E3);
15-
16-
box-shadow: 0 1px 5px rgba(0, 0, 0, 0.15);
14+
background-color: $white;
1715

1816
.controls__play-pause-skip {
1917
display: flex;
@@ -36,13 +34,13 @@
3634
font-size: 28px;
3735
padding: 0;
3836

39-
color: #555;
37+
color: $grey-700;
4038

4139
width: 35px;
4240
vertical-align: middle;
4341

4442
i.fi {
45-
background-image: linear-gradient(0deg, #999, #333);
43+
background-color: $grey-700;
4644
-webkit-background-clip: text;
4745
-webkit-text-fill-color: transparent;
4846
}
@@ -53,7 +51,7 @@
5351
button[disabled] i,
5452
button[disabled] i {
5553
background-image: none;
56-
background-color: #CCC;
54+
background-color: $grey-300;
5755
}
5856

5957
.controls__actions {
@@ -67,8 +65,9 @@
6765
font-size: 16px;
6866
}
6967

70-
.meta__favorite {
71-
i.active { background-image: linear-gradient(0deg, #F70, #F30); }
68+
.meta__favorite i {
69+
&.fi { background-color: $grey-300; }
70+
&.active { background-color: $soundcloud; }
7271
}
7372

7473
.controls__next,
@@ -157,15 +156,14 @@
157156
width: 100%;
158157
height: 2px;
159158
cursor: pointer;
160-
background: #F50;
159+
background: $soundcloud;
161160
border-radius: 1.3px;
162161
}
163162
input[type=range]::-webkit-slider-thumb {
164163
height: 12px;
165164
width: 12px;
166165
border-radius: 12px;
167-
background: linear-gradient(180deg, #FFF, #E3E3E3);
168-
box-shadow: 0 0 5px rgba(0, 0, 0, 0.4);
166+
background: $soundcloud;
169167
cursor: pointer;
170168
-webkit-appearance: none;
171169
margin-top: -5.2px;
@@ -181,8 +179,7 @@
181179
text-align: center;
182180
cursor: default;
183181

184-
color: #666;
185-
text-shadow: 0 1px 0 rgba(#fff, .85);
182+
color: $grey-700;
186183

187184
-webkit-user-select: none;
188185
}
@@ -220,11 +217,11 @@
220217
}
221218

222219
.seeker__progress-bar::-webkit-progress-bar {
223-
background-color: rgba(#C1C1C1, .85);
220+
background-color: rgba($grey-300, .85);
224221
}
225222

226223
.seeker__progress-bar::-webkit-progress-value {
227-
background-color: #f50;
224+
background-color: $soundcloud;
228225
transition: all 200ms;
229226
}
230227

@@ -240,7 +237,7 @@
240237

241238
float: right;
242239

243-
background-color: #f50;
240+
background-color: $soundcloud;
244241

245242
cursor: pointer;
246243
}
@@ -252,22 +249,25 @@
252249

253250
.media-player__meta {
254251
font-size: 13px;
255-
color: #fff;
252+
color: $white;
256253
padding: 10px;
257254

258255
.meta__artist,
259256
.meta__title {
260257
cursor: pointer;
261258
}
262259

260+
.meta__title {
261+
margin-top: -1px; // Adjust the height of author and title so they seem as part of the same box
262+
}
263263
> div {
264264
max-width: 100%;
265265
@include truncate();
266266

267267
display: block;
268268

269269
> span {
270-
background-color: rgba(0, 0, 0, .9);
270+
background-color: rgba($black, .9);
271271
padding: 4px 6px;
272272
line-height: 25px;
273273

app/scss/_vars.scss

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* Variables
3+
*/
4+
$soundcloud: #f50 !default;
5+
6+
$primary-text: rgba(255, 255, 255, 1.00) !default;
7+
$secondary-text: rgba(255, 255, 255, 0.70) !default;
8+
$disabled-text: rgba(255, 255, 255, 0.50) !default;
9+
10+
$white: #fff !default;
11+
$black: #000 !default;
12+
13+
$grey-50: #FAFAFA !default;
14+
$grey-100: #F5F5F5 !default;
15+
$grey-200: #EEEEEE !default;
16+
$grey-300: #E0E0E0 !default;
17+
$grey-400: #BDBDBD !default;
18+
19+
$grey-700: #616161 !default;
20+
$grey-800: #424242 !default;
21+
$grey-900: #212121 !default;

app/scss/app.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
@import 'mixins';
2+
@import 'vars';
23

34
* {
45
box-sizing: border-box;
@@ -85,7 +86,7 @@ i.fi {
8586

8687
position: fixed;
8788

88-
background-color: #f50;
89+
background-color: $soundcloud;
8990
-webkit-mask: url('../assets/loader.svg') no-repeat 50% 50%;
9091
-webkit-mask-size: cover;
9192

0 commit comments

Comments
 (0)