X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/0a83a24ab2a3daf945c6012e80d284304a73c38b..07331350ad3e880d9e0260dc061187a151c253c7:/src/wolnelektury/static/js/base.js diff --git a/src/wolnelektury/static/js/base.js b/src/wolnelektury/static/js/base.js index bdb5fbee7..2d0ebbf64 100644 --- a/src/wolnelektury/static/js/base.js +++ b/src/wolnelektury/static/js/base.js @@ -57,7 +57,7 @@ }) }); - $('.more').each(function () { + $('.more-expand').each(function () { $(this).shorten({ showChars: 150, moreText: "więcej", @@ -66,6 +66,14 @@ }); + $('.carousel').on('cycle-before', function(event, optionHash, outgoingSlideEl, incomingSlideEl, forwardFlag) { + $("iframe", outgoingSlideEl).attr("src", ''); + $("iframe", incomingSlideEl).attr("src", $("iframe", incomingSlideEl).attr('data-src')); + }); + $('.carousel section').first().each(function() { + $("iframe", this).attr("src", $("iframe", this).attr('data-src')); + }); + (function() { var $current = null;