update
This commit is contained in:
@@ -29,6 +29,11 @@
|
|||||||
|
|
||||||
.btn-arrow {
|
.btn-arrow {
|
||||||
max-width: 85px;
|
max-width: 85px;
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-arrow.visible {
|
||||||
|
display: inline-block !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media(min-width: 991px) {
|
@media(min-width: 991px) {
|
||||||
@@ -403,8 +408,6 @@
|
|||||||
},
|
},
|
||||||
on: {
|
on: {
|
||||||
init: function () {
|
init: function () {
|
||||||
// Ocultar prev en el primer slide
|
|
||||||
$('.btn-prev').css('opacity', '.5').addClass('disabled');
|
|
||||||
},
|
},
|
||||||
slideChange: function () {
|
slideChange: function () {
|
||||||
const activeIndex = this.activeIndex;
|
const activeIndex = this.activeIndex;
|
||||||
@@ -415,16 +418,16 @@
|
|||||||
if (activeIndex === 0) {
|
if (activeIndex === 0) {
|
||||||
$('.btn-prev').css('opacity', '.5').addClass('disabled');
|
$('.btn-prev').css('opacity', '.5').addClass('disabled');
|
||||||
} else {
|
} else {
|
||||||
$('.btn-prev').css('opacity', '1').removeClass('disabled');
|
$('.btn-prev').addClass('visible').css('opacity', '1').removeClass('disabled');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (activeIndex === totalSlides - 1) {
|
if (activeIndex === totalSlides - 1) {
|
||||||
$('.btn-next').css('opacity', '.5').addClass('disabled');
|
$('.btn-next').css('opacity', '.5').addClass('disabled');
|
||||||
} else {
|
} else {
|
||||||
$('.btn-next').css('opacity', '1').removeClass('disabled');
|
$('.btn-next').addClass('visible').css('opacity', '1').removeClass('disabled');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (slides[activeIndex]) slides[activeIndex].classList.add("visited", "completed");
|
slides[activeIndex].classList.add("visited", "completed");
|
||||||
|
|
||||||
const completedSlides = $(".cid1 .swiper-slide.completed").length;
|
const completedSlides = $(".cid1 .swiper-slide.completed").length;
|
||||||
|
|
||||||
@@ -441,6 +444,7 @@
|
|||||||
audiom14.on('end', function () {
|
audiom14.on('end', function () {
|
||||||
$('.cid1').show();
|
$('.cid1').show();
|
||||||
mySwiper.update();
|
mySwiper.update();
|
||||||
|
$('.btn-next').addClass('visible');
|
||||||
CourseNav.audioController.stopAllSoundsAndPlay(audios[0]);
|
CourseNav.audioController.stopAllSoundsAndPlay(audios[0]);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user