This file is indexed.

/usr/share/javascript/jquery-galleriffic/jquery.galleriffic.min.js is in libjs-jquery-galleriffic 10-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

1
2
3
4
5
6
7
8
9
/**
 * jQuery Galleriffic plugin
 *
 * Copyright (c) 2008 Trent Foley (http://trentacular.com)
 * Licensed under the MIT License:
 *   http://www.opensource.org/licenses/mit-license.php
 *
 * Much thanks to primary contributer Ponticlaro (http://www.ponticlaro.com)
 */(function(e){var t={},n=0;e.galleriffic={version:"2.0.1",normalizeHash:function(e){return e.replace(/^.*#/,"").replace(/\?.*$/,"")},getImage:function(n){return n?(n=e.galleriffic.normalizeHash(n),t[n]):undefined},gotoImage:function(t){var n=e.galleriffic.getImage(t);if(!n)return!1;var r=n.gallery;return r.gotoImage(n),!0},removeImageByHash:function(t,n){var r=e.galleriffic.getImage(t);if(!r)return!1;var i=r.gallery;return n&&n!=i?!1:i.removeImageByIndex(r.index)}};var r={delay:3e3,numThumbs:20,preloadAhead:40,enableTopPager:!1,enableBottomPager:!0,maxPagesToShow:7,imageContainerSel:"",captionContainerSel:"",controlsContainerSel:"",loadingContainerSel:"",renderSSControls:!0,renderNavControls:!0,playLinkText:"Play",pauseLinkText:"Pause",prevLinkText:"Previous",nextLinkText:"Next",nextPageLinkText:"Next &rsaquo;",prevPageLinkText:"&lsaquo; Prev",enableHistory:!1,enableKeyboardNavigation:!0,autoStart:!1,syncTransitions:!1,defaultTransitionDuration:1e3,onSlideChange:undefined,onTransitionOut:undefined,onTransitionIn:undefined,onPageTransitionOut:undefined,onPageTransitionIn:undefined,onImageAdded:undefined,onImageRemoved:undefined};e.fn.galleriffic=function(s){e.extend(this,{version:e.galleriffic.version,isSlideshowRunning:!1,slideshowTimeout:undefined,clickHandler:function(t,n){this.pause();if(!this.enableHistory){var r=e.galleriffic.normalizeHash(e(n).attr("href"));e.galleriffic.gotoImage(r),t.preventDefault()}},appendImage:function(e){return this.addImage(e,!1,!1),this},insertImage:function(e,t){return this.addImage(e,!1,!0,t),this},addImage:function(r,i,s,o){var u=typeof r=="string"?e(r):r,a=u.find("a.thumb"),f=a.attr("href"),l=a.attr("title"),c=u.find(".caption").remove(),h=a.attr("name");n++;if(!h||t[""+h])h=n;s||(o=this.data.length);var p={title:l,slideUrl:f,caption:c,hash:h,gallery:this,index:o};s?(this.data.splice(o,0,p),this.updateIndices(o)):this.data.push(p);var d=this;return i||this.updateThumbs(function(){var e=d.find("ul.thumbs");s?e.children(":eq("+o+")").before(u):e.append(u),d.onImageAdded&&d.onImageAdded(p,u)}),t[""+h]=p,a.attr("rel","history").attr("href","#"+h).removeAttr("name").click(function(e){d.clickHandler(e,this)}),this},removeImageByIndex:function(e){if(e<0||e>=this.data.length)return!1;var t=this.data[e];return t?(this.removeImage(t),!0):!1},removeImageByHash:function(t){return e.galleriffic.removeImageByHash(t,this)},removeImage:function(e){var n=e.index;return this.data.splice(n,1),delete t[""+e.hash],this.updateThumbs(function(){var t=o.find("ul.thumbs").children(":eq("+n+")").remove();o.onImageRemoved&&o.onImageRemoved(e,t)}),this.updateIndices(n),this},updateIndices:function(e){for(i=e;i<this.data.length;i++)this.data[i].index=i;return this},initializeThumbs:function(){this.data=[];var t=this;return this.find("ul.thumbs > li").each(function(n){t.addImage(e(this),!0,!1)}),this},isPreloadComplete:!1,preloadInit:function(){if(this.preloadAhead==0)return this;this.preloadStartIndex=this.currentImage.index;var e=this.getNextIndex(this.preloadStartIndex);return this.preloadRecursive(this.preloadStartIndex,e)},preloadRelocate:function(e){return this.preloadStartIndex=e,this},preloadRecursive:function(e,t){if(e!=this.preloadStartIndex){var n=this.getNextIndex(this.preloadStartIndex);return this.preloadRecursive(this.preloadStartIndex,n)}var r=this,i=t-e;i<0&&(i=this.data.length-1-e+t);if(this.preloadAhead>=0&&i>this.preloadAhead)return setTimeout(function(){r.preloadRecursive(e,t)},500),this;var s=this.data[t];if(!s)return this;if(s.image)return this.preloadNext(e,t);var o=new Image;return o.onload=function(){s.image=this,r.preloadNext(e,t)},o.alt=s.title,o.src=s.slideUrl,this},preloadNext:function(e,t){var n=this.getNextIndex(t);if(n==e)this.isPreloadComplete=!0;else{var r=this;setTimeout(function(){r.preloadRecursive(e,n)},100)}return this},getNextIndex:function(e){var t=e+1;return t>=this.data.length&&(t=0),t},getPrevIndex:function(e){var t=e-1;return t<0&&(t=this.data.length-1),t},pause:function(){return this.isSlideshowRunning=!1,this.slideshowTimeout&&(clearTimeout(this.slideshowTimeout),this.slideshowTimeout=undefined),this.$controlsContainer&&this.$controlsContainer.find("div.ss-controls a").removeClass().addClass("play").attr("title",this.playLinkText).attr("href","#play").html(this.playLinkText),this},play:function(){this.isSlideshowRunning=!0,this.$controlsContainer&&this.$controlsContainer.find("div.ss-controls a").removeClass().addClass("pause").attr("title",this.pauseLinkText).attr("href","#pause").html(this.pauseLinkText);if(!this.slideshowTimeout){var e=this;this.slideshowTimeout=setTimeout(function(){e.ssAdvance()},this.delay)}return this},toggleSlideshow:function(){return this.isSlideshowRunning?this.pause():this.play(),this},ssAdvance:function(){return this.isSlideshowRunning&&this.next(!0),this},next:function(e,t){return this.gotoIndex(this.getNextIndex(this.currentImage.index),e,t),this},previous:function(e,t){return this.gotoIndex(this.getPrevIndex(this.currentImage.index),e,t),this},nextPage:function(e,t){var n=this.getCurrentPage(),r=this.getNumPages()-1;if(n<r){var i=n*this.numThumbs,s=i+this.numThumbs;this.gotoIndex(s,e,t)}return this},previousPage:function(e,t){var n=this.getCurrentPage();if(n>0){var r=n*this.numThumbs,i=r-this.numThumbs;this.gotoIndex(i,e,t)}return this},gotoIndex:function(t,n,r){n||this.pause(),t<0?t=0:t>=this.data.length&&(t=this.data.length-1);var i=this.data[t];return!r&&this.enableHistory?e.historyLoad(String(i.hash)):this.gotoImage(i),this},gotoImage:function(e){var t=e.index;return this.onSlideChange&&this.onSlideChange(this.currentImage.index,t),this.currentImage=e,this.preloadRelocate(t),this.refresh(),this},getDefaultTransitionDuration:function(e){return e?this.defaultTransitionDuration:this.defaultTransitionDuration/2},refresh:function(){var e=this.currentImage;if(!e)return this;var t=e.index;this.$controlsContainer&&this.$controlsContainer.find("div.nav-controls a.prev").attr("href","#"+this.data[this.getPrevIndex(t)].hash).end().find("div.nav-controls a.next").attr("href","#"+this.data[this.getNextIndex(t)].hash);var n=this.$imageContainer.find("span.current").addClass("previous").removeClass("current"),r=0;this.$captionContainer&&(r=this.$captionContainer.find("span.current").addClass("previous").removeClass("current"));var i=this.syncTransitions&&e.image,s=!0,o=this,u=function(){s=!1,n.remove(),r&&r.remove(),i||(e.image&&e.hash==o.data[o.currentImage.index].hash?o.buildImage(e,i):o.$loadingContainer&&o.$loadingContainer.show())};n.length==0?u():this.onTransitionOut?this.onTransitionOut(n,r,i,u):(n.fadeTo(this.getDefaultTransitionDuration(i),0,u),r&&r.fadeTo(this.getDefaultTransitionDuration(i),0)),i&&this.buildImage(e,i);if(!e.image){var a=new Image;a.onload=function(){e.image=this,!s&&e.hash==o.data[o.currentImage.index].hash&&o.buildImage(e,i)},a.alt=e.title,a.src=e.slideUrl}return this.relocatePreload=!0,this.syncThumbs()},buildImage:function(e,t){var n=this,r=this.getNextIndex(e.index),i=this.$imageContainer.append('<span class="image-wrapper current"><a class="advance-link" rel="history" href="#'+this.data[r].hash+'" title="'+e.title+'">&nbsp;</a></span>').find("span.current").css("opacity","0");i.find("a").append(e.image).click(function(e){n.clickHandler(e,this)});var s=0;return this.$captionContainer&&(s=this.$captionContainer.append('<span class="image-caption current"></span>').find("span.current").css("opacity","0").append(e.caption)),this.$loadingContainer&&this.$loadingContainer.hide(),this.onTransitionIn?this.onTransitionIn(i,s,t):(i.fadeTo(this.getDefaultTransitionDuration(t),1),s&&s.fadeTo(this.getDefaultTransitionDuration(t),1)),this.isSlideshowRunning&&(this.slideshowTimeout&&clearTimeout(this.slideshowTimeout),this.slideshowTimeout=setTimeout(function(){n.ssAdvance()},this.delay)),this},getCurrentPage:function(){return Math.floor(this.currentImage.index/this.numThumbs)},syncThumbs:function(){var e=this.getCurrentPage();e!=this.displayedPage&&this.updateThumbs();var t=this.find("ul.thumbs").children();return t.filter(".selected").removeClass("selected"),t.eq(this.currentImage.index).addClass("selected"),this},updateThumbs:function(e){var t=this,n=function(){e&&e(),t.rebuildThumbs(),t.onPageTransitionIn?t.onPageTransitionIn():t.show()};return this.onPageTransitionOut?this.onPageTransitionOut(n):(this.hide(),n()),this},rebuildThumbs:function(){var t=this.data.length>this.numThumbs;if(this.enableTopPager){var n=this.find("div.top");n.length==0?n=this.prepend('<div class="top pagination"></div>').find("div.top"):n.empty(),t&&this.buildPager(n)}if(this.enableBottomPager){var r=this.find("div.bottom");r.length==0?r=this.append('<div class="bottom pagination"></div>').find("div.bottom"):r.empty(),t&&this.buildPager(r)}var i=this.getCurrentPage(),s=i*this.numThumbs,o=s+this.numThumbs-1;o>=this.data.length&&(o=this.data.length-1);var u=this.find("ul.thumbs");return u.find("li").each(function(t){var n=e(this);t>=s&&t<=o?n.show():n.hide()}),this.displayedPage=i,u.removeClass("noscript"),this},getNumPages:function(){return Math.ceil(this.data.length/this.numThumbs)},buildPager:function(e){var t=this,n=this.getNumPages(),r=this.getCurrentPage(),i=r*this.numThumbs,s=this.maxPagesToShow-1,o=r-Math.floor((this.maxPagesToShow-1)/2)+1;if(o>0){var u=n-o;u<s&&(o-=s-u)}o<0&&(o=0);if(r>0){var a=i-this.numThumbs;e.append('<a rel="history" href="#'+this.data[a].hash+'" title="'+this.prevPageLinkText+'">'+this.prevPageLinkText+"</a>")}o>0&&(this.buildPageLink(e,0,n),o>1&&e.append('<span class="ellipsis">&hellip;</span>'),s--);while(s>0)this.buildPageLink(e,o,n),s--,o++;if(o<n){var f=n-1;o<f&&e.append('<span class="ellipsis">&hellip;</span>'),this.buildPageLink(e,f,n)}var l=i+this.numThumbs;return l<this.data.length&&e.append('<a rel="history" href="#'+this.data[l].hash+'" title="'+this.nextPageLinkText+'">'+this.nextPageLinkText+"</a>"),e.find("a").click(function(e){t.clickHandler(e,this)}),this},buildPageLink:function(e,t,n){var r=t+1,i=this.getCurrentPage();if(t==i)e.append('<span class="current">'+r+"</span>");else if(t<n){var s=t*this.numThumbs;e.append('<a rel="history" href="#'+this.data[s].hash+'" title="'+r+'">'+r+"</a>")}return this}}),e.extend(this,r,s),this.enableHistory&&!e.historyInit&&(this.enableHistory=!1),this.imageContainerSel&&(this.$imageContainer=e(this.imageContainerSel)),this.captionContainerSel&&(this.$captionContainer=e(this.captionContainerSel)),this.loadingContainerSel&&(this.$loadingContainer=e(this.loadingContainerSel)),this.initializeThumbs(),this.maxPagesToShow<3&&(this.maxPagesToShow=3),this.displayedPage=-1,this.currentImage=this.data[0];var o=this;this.$loadingContainer&&this.$loadingContainer.hide(),this.controlsContainerSel&&(this.$controlsContainer=e(this.controlsContainerSel).empty(),this.renderSSControls&&(this.autoStart?this.$controlsContainer.append('<div class="ss-controls"><a href="#pause" class="pause" title="'+this.pauseLinkText+'">'+this.pauseLinkText+"</a></div>"):this.$controlsContainer.append('<div class="ss-controls"><a href="#play" class="play" title="'+this.playLinkText+'">'+this.playLinkText+"</a></div>"),this.$controlsContainer.find("div.ss-controls a").click(function(e){return o.toggleSlideshow(),e.preventDefault(),!1})),this.renderNavControls&&this.$controlsContainer.append('<div class="nav-controls"><a class="prev" rel="history" title="'+this.prevLinkText+'">'+this.prevLinkText+'</a><a class="next" rel="history" title="'+this.nextLinkText+'">'+this.nextLinkText+"</a></div>").find("div.nav-controls a").click(function(e){o.clickHandler(e,this)}));var u=!this.enableHistory||!location.hash;if(this.enableHistory&&location.hash){var a=e.galleriffic.normalizeHash(location.hash),f=t[a];f||(u=!0)}return u&&this.gotoIndex(0,!1,!0),this.enableKeyboardNavigation&&e(document).keydown(function(e){var t=e.charCode?e.charCode:e.keyCode?e.keyCode:0;switch(t){case 32:o.next(),e.preventDefault();break;case 33:o.previousPage(),e.preventDefault();break;case 34:o.nextPage(),e.preventDefault();break;case 35:o.gotoIndex(o.data.length-1),e.preventDefault();break;case 36:o.gotoIndex(0),e.preventDefault();break;case 37:o.previous(),e.preventDefault();break;case 39:o.next(),e.preventDefault()}}),this.autoStart&&this.play(),setTimeout(function(){o.preloadInit()},1e3),this}})(jQuery);