Initial Commit - Plugin v1.0.0
This commit is contained in:
BIN
assets/scripts/.DS_Store
vendored
Normal file
BIN
assets/scripts/.DS_Store
vendored
Normal file
Binary file not shown.
7
assets/scripts/bootstrap.min.js
vendored
Executable file
7
assets/scripts/bootstrap.min.js
vendored
Executable file
File diff suppressed because one or more lines are too long
16
assets/scripts/slider.js
Normal file
16
assets/scripts/slider.js
Normal file
@@ -0,0 +1,16 @@
|
||||
jQuery(function($) {
|
||||
|
||||
const plainDotSVG = '<svg class="icon icon-dot-plain d-block" aria-hidden="true" role="img"><use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#icon-dot-plain"></use></svg>';
|
||||
const emptyDotSVG = '<svg class="icon icon-dot-empty d-block" aria-hidden="true" role="img"><use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#icon-dot-empty"></use></svg>';
|
||||
|
||||
$(document).ready(function() {
|
||||
$('#ratings-slider').on('slide.bs.carousel', function (e) {
|
||||
const fromElmt = $('.carousel-indicators li:eq('+e.from+')');
|
||||
const toElmt = $('.carousel-indicators li:eq('+e.to+')');
|
||||
fromElmt.find('svg').remove();
|
||||
fromElmt.append(emptyDotSVG);
|
||||
toElmt.find('svg').remove()
|
||||
toElmt.append(plainDotSVG);
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user