Skip to content

Commit ca83115

Browse files
committed
Use .slide-full-width and .slide-cover-width on slider and slide
1 parent 5bf17d3 commit ca83115

File tree

4 files changed

+14
-29
lines changed

4 files changed

+14
-29
lines changed

public/css/slider.css

Lines changed: 5 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/index.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ <h3>Single image</h3>
290290

291291
<h3>Full width slides with centered content</h3>
292292
<p>
293-
Add the <code>slider-full-width</code> class to the <code>.slider</code>
293+
Add the <code>slide-full-width</code> class to the <code>.slider</code>
294294
to make all slides 100% width.<br>
295295
Or add the <code>slide-full-width</code> class to any
296296
<code>.slide</code> to make only that one 100% width.
@@ -299,7 +299,7 @@ <h3>Full width slides with centered content</h3>
299299
Notice only the slides content is clickable.
300300
</p>
301301

302-
<div class="slider slider-full-width">
302+
<div class="slider slide-full-width">
303303

304304
<a href="#" class="slider-prev">&langle;</a>
305305
<a href="#" class="slider-next">&rangle;</a>
@@ -331,14 +331,14 @@ <h3>Full width slides with centered content</h3>
331331

332332
<h3>Full width slides with covered content</h3>
333333
<p>
334-
Add the <code>slider-cover-width</code> class to the <code>.slider</code>
334+
Add the <code>slide-cover-width</code> class to the <code>.slider</code>
335335
to make all slides 100% width.<br>
336336
Or add the <code>slide-cover-width</code> class to any
337337
<code>.slide</code> to make only that one 100% width.
338338
</p>
339339
<p>Notice the entire slide is now clickable.</p>
340340

341-
<div class="slider slider-cover-width">
341+
<div class="slider slide-cover-width">
342342

343343
<a href="#" class="slider-prev">&langle;</a>
344344
<a href="#" class="slider-next">&rangle;</a>
@@ -375,7 +375,7 @@ <h3>Full width slides with covered content</h3>
375375
div with <code>background-size: cover</code>.
376376
</p>
377377

378-
<div class="slider slider-cover-width">
378+
<div class="slider slide-cover-width">
379379

380380
<a href="#" class="slider-prev">&langle;</a>
381381
<a href="#" class="slider-next">&rangle;</a>
@@ -410,7 +410,7 @@ <h3>Content slider</h3>
410410
</p>
411411
<p>Full width...</p>
412412

413-
<div class="slider slider-full-width">
413+
<div class="slider slide-full-width">
414414

415415
<a href="#" class="slider-prev">&langle;</a>
416416
<a href="#" class="slider-next">&rangle;</a>

src/scss/_slide-image.scss

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,4 @@
9191
}
9292
}
9393

94-
.slider-cover-width .slide-image {
95-
width: 100%;
96-
}
97-
9894
}

src/scss/_slide.scss

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,8 @@
3232
}
3333

3434
&-full-width, &-cover-width {
35-
flex-basis: 100%;
35+
.slide, &.slide {
36+
flex-basis: 100%;
37+
}
3638
}
3739
}
38-
39-
.slider-full-width .slide,
40-
.slider-cover-width .slide {
41-
flex-basis: 100%;
42-
}

0 commit comments

Comments
 (0)