PageSourceSearch

https://socialphobia.org/sites/default/files/js/js_c4b0okmmTv6oU25uDhjYb3yw2de2mV6io7YBp5kihWU.js

js socialphobia.org collected 2026-09-24 18:33:42 UTC 36,105 bytes, 465 lines download raw bytes

1/**
2 * @file
3 */
4
5(function ($) {
6
7  'use strict';
8
9  Drupal.extlink = Drupal.extlink || {};
10
11  Drupal.extlink.attach = function (context, settings) {
12    if (!settings.hasOwnProperty('extlink')) {
13      return;
14    }
15
16    // Strip the host name down, removing ports, subdomains, or www.
17    var pattern = /^(([^\/:]+?\.)*)([^\.:]{1,})((\.[a-z0-9]{1,253})*)(:[0-9]{1,5})?$/;
18    var host = window.location.host.replace(pattern, '$2$3$6');
19    var subdomain = window.location.host.replace(host, '');
20
21    // Determine what subdomains are considered internal.
22    var subdomains;
23    if (settings.extlink.extSubdomains) {
24      subdomains = '([^/]*\\.)?';
25    }
26    else if (subdomain === 'www.' || subdomain === '') {
27      subdomains = '(www\\.)?';
28    }
29    else {
30      subdomains = subdomain.replace('.', '\\.');
31    }
32
33    // Build regular expressions that define an internal link.
34    var internal_link = new RegExp('^https?://([^@]*@)?' + subdomains + host, 'i');
35
36    // Extra internal link matching.
37    var extInclude = false;
38    if (settings.extlink.extInclude) {
39      extInclude = new RegExp(settings.extlink.extInclude.replace(/\\/, '\\'), 'i');
40    }
41
42    // Extra external link matching.
43    var extExclude = false;
44    if (settings.extlink.extExclude) {
45      extExclude = new RegExp(settings.extlink.extExclude.replace(/\\/, '\\'), 'i');
46    }
47
48    // Extra external link CSS selector exclusion.
49    var extCssExclude = false;
50    if (settings.extlink.extCssExclude) {
51      extCssExclude = settings.extlink.extCssExclude;
52    }
53
54    // Extra external link CSS selector explicit.
55    var extCssExplicit = false;
56    if (settings.extlink.extCssExplicit) {
57      extCssExplicit = settings.extlink.extCssExplicit;
58    }
59
60    // Define the jQuery method (either 'append' or 'prepend') of placing the icon, defaults to 'append'.
61    var extIconPlacement = settings.extlink.extIconPlacement || 'append';
62
63    // Find all links which are NOT internal and begin with http as opposed
64    // to ftp://, javascript:, etc. other kinds of links.
65    // When operating on the 'this' variable, the host has been appended to
66    // all links by the browser, even local ones.
67    // In jQuery 1.1 and higher, we'd use a filter method here, but it is not
68    // available in jQuery 1.0 (Drupal 5 default).
69    var external_links = [];
70    var mailto_links = [];
71    $('a:not([data-extlink]), area:not([data-extlink])', context).each(function (el) {
72      try {
73        var url = '';
74        if (typeof this.href == 'string') {
75          url = this.href.toLowerCase();
76        }
77        // Handle SVG links (xlink:href).
78        else if (typeof this.href == 'object') {
79          url = this.href.baseVal;
80        }
81        if (url.indexOf('http') === 0
82          && ((!url.match(internal_link) && !(extExclude && url.match(extExclude))) || (extInclude && url.match(extInclude)))
83          && !(extCssExclude && $(this).is(extCssExclude))
84          && !(extCssExclude && $(this).parents(extCssExclude).length > 0)
85          && !(extCssExplicit && $(this).parents(extCssExplicit).length < 1)) {
86          external_links.push(this);
87        }
88        // Do not include area tags with begin with mailto: (this prohibits
89        // icons from being added to image-maps).
90        else if (this.tagName !== 'AREA'
91          && url.indexOf('mailto:') === 0
92          && !(extCssExclude && $(this).parents(extCssExclude).length > 0)
93          && !(extCssExplicit && $(this).parents(extCssExplicit).length < 1)) {
94          mailto_links.push(this);
95        }
96      }
97      // IE7 throws errors often when dealing with irregular links, such as:
98      // <a href="node/10"></a> Empty tags.
99      // <a href="http://user:[email protected]">example</a> User:pass syntax.
100      catch (error) {
101        return false;
102      }
103    });
104
105    if (settings.extlink.extClass) {
106      Drupal.extlink.applyClassAndSpan(external_links, settings.extlink.extClass, extIconPlacement);
107    }
108
109    if (settings.extlink.mailtoClass) {
110      Drupal.extlink.applyClassAndSpan(mailto_links, settings.extlink.mailtoClass, extIconPlacement);
111    }
112
113    if (settings.extlink.extTarget) {
114      // Apply the target attribute to all links.
115      $(external_links).attr('target', settings.extlink.extTarget);
116      // Add rel attributes noopener and noreferrer.
117      $(external_links).attr('rel', function (i, val) {
118        // If no rel attribute is present, create one with the values noopener and noreferrer.
119        if (val == null) {
120          return 'noopener noreferrer';
121        }
122        // Check to see if rel contains noopener or noreferrer. Add what doesn't exist.
123        if (val.indexOf('noopener') > -1 || val.indexOf('noreferrer') > -1) {
124          if (val.indexOf('noopener') === -1) {
125            return val + ' noopener';
126          }
127          if (val.indexOf('noreferrer') === -1) {
128            return val + ' noreferrer';
129          }
130          // Both noopener and noreferrer exist. Nothing needs to be added.
131          else {
132            return val;
133          }
134        }
135        // Else, append noopener and noreferrer to val.
136        else {
137          return val + ' noopener noreferrer';
138        }
139      });
140    }
141
142    Drupal.extlink = Drupal.extlink || {};
143
144    // Set up default click function for the external links popup. This should be
145    // overridden by modules wanting to alter the popup.
146    Drupal.extlink.popupClickHandler = Drupal.extlink.popupClickHandler || function () {
147      if (settings.extlink.extAlert) {
148        return confirm(settings.extlink.extAlertText);
149      }
150    };
151
152    $(external_links).click(function (e) {
153      return Drupal.extlink.popupClickHandler(e, this);
154    });
155  };
156
157  /**
158   * Apply a class and a trailing <span> to all links not containing images.
159   *
160   * @param {object[]} links
161   *   An array of DOM elements representing the links.
162   * @param {string} class_name
163   *   The class to apply to the links.
164   * @param {string} icon_placement
165   *   'append' or 'prepend' the icon to the link.
166   */
167  Drupal.extlink.applyClassAndSpan = function (links, class_name, icon_placement) {
168    var $links_to_process;
169    if (Drupal.settings.extlink.extImgClass) {
170      $links_to_process = $(links);
171    }
172    else {
173      var links_with_images = $(links).find('img').parents('a');
174      $links_to_process = $(links).not(links_with_images);
175    }
176    // Add data-extlink attribute.
177    $links_to_process.attr('data-extlink', '');
178    var i;
179    var length = $links_to_process.length;
180    for (i = 0; i < length; i++) {
181      var $link = $($links_to_process[i]);
182      if ($link.css('display') === 'inline' || $link.css('display') === 'inline-block') {
183        if (Drupal.settings.extlink.extUseFontAwesome) {
184          if (class_name === Drupal.settings.extlink.mailtoClass) {
185            $link[icon_placement]('<span class="fa-' + class_name + ' extlink"><span class="fa fa-envelope-o" title="' + Drupal.settings.extlink.mailtoLabel + '"></span><span class="element-invisible">' + Drupal.settings.extlink.mailtoLabel + '</span></span>');
186          }
187          else {
188            $link[icon_placement]('<span class="fa-' + class_name + ' extlink"><span class="fa fa-external-link" title="' + Drupal.settings.extlink.extLabel + '"></span><span class="element-invisible">' + Drupal.settings.extlink.extLabel + '</span></span>');
189          }
190        }
191        else {
192          if (class_name === Drupal.settings.extlink.mailtoClass) {
193            $link[icon_placement]('<span class="' + class_name + '"><span class="element-invisible">' + Drupal.settings.extlink.mailtoLabel + '</span></span>');
194          }
195          else {
196            $link[icon_placement]('<span class="' + class_name + '"><span class="element-invisible">' + Drupal.settings.extlink.extLabel + '</span></span>');
197          }
198        }
199      }
200    }
201  };
202
203  Drupal.behaviors.extlink = Drupal.behaviors.extlink || {};
204  Drupal.behaviors.extlink.attach = function (context, settings) {
205    // Backwards compatibility, for the benefit of modules overriding extlink
206    // functionality by defining an "extlinkAttach" global function.
207    if (typeof extlinkAttach === 'function') {
208      extlinkAttach(context);
209    }
210    else {
211      Drupal.extlink.attach(context, settings);
212    }
213  };
214
215})(jQuery);
216;
217/*!
218* jQuery Cycle2; ver: BETA-20121016
219* http://jquery.malsup.com/cycle2/
220* Copyright (c) 2012 M. Alsup; Dual licensed: MIT/GPL
221*/
222(function(a){function c(){window.console&&console.log&&console.log("[cycle2] "+Array.prototype.join.call(arguments," "))}function d(a){return(a||"").toLowerCase()}"use strict";var b="BETA-20120923";a.fn.cycle=function(b){var e;return this.length===0&&!a.isReady?(e={s:this.selector,c:this.context},c("requeuing slideshow (dom not ready)"),a(function(){a(e.s,e.c).cycle(b)}),this):this.each(function(){var e,f,g,h,i=a(this);if(i.data("cycle.opts"))return;if(i.data("cycle-log")===!1||b&&b.log===!1||f&&f.log===!1)c=a.noop;c("--c2 init--"),e=i.data();for(var j in e)e.hasOwnProperty(j)&&/^cycle[A-Z]+/.test(j)&&(h=e[j],g=j.match(/^cycle(.*)/)[1].replace(/^[A-Z]/,d),c(g+":",h,"("+typeof h+")"),e[g]=h);f=a.extend({},a.fn.cycle.defaults,e,b||{}),f.timeoutId=0,f.paused=0,f.container=i,f._maxZ=f.maxZ,f.API=a.extend({_container:i},a.fn.cycle.API),f.API.log=c,f.API.trigger=function(a,b){return f.container.trigger(a,b),f.API},i.data("cycle.opts",f),i.data("cycle.API",f.API),f.API.trigger("cycle-bootstrap",[f,f.API]),f.API.addInitialSlides(),f.API.preInitSlideshow(),f.slides.length&&f.API.initSlideshow()})},a.fn.cycle.API={opts:function(){return this._container.data("cycle.opts")},addInitialSlides:function(){var b=this.opts(),c=b.slides;b.slideCount=0,b.slides=a(),c=c.jquery?c:b.container.find(c),b.API.add(c)},preInitSlideshow:function(){var b=this.opts();b.API.trigger("cycle-pre-initialize",[b]);var c=a.fn.cycle.transitions[b.fx];c&&a.isFunction(c.preInit)&&c.preInit(b),b._preInitialized=!0},postInitSlideshow:function(){var b=this.opts();b.API.trigger("cycle-post-initialize",[b]);var c=a.fn.cycle.transitions[b.fx];c&&a.isFunction(c.postInit)&&c.postInit(b)},initSlideshow:function(){var b=this.opts(),c=b.container;b.API.calcFirstSlide(),b.container.css("position")=="static"&&b.container.css("position","relative"),a(b.slides[b.currSlide]).css("opacity",1).show(),b.API.stackSlides(b.slides[b.currSlide],b.slides[b.nextSlide],!b.reverse),b.pauseOnHover&&(b.pauseOnHover!==!0&&(c=a(b.pauseOnHover)),c.hover(function(){b.paused=1,b.API.trigger("cycle-paused",[b])},function(){b.paused=0,b.API.trigger("cycle-resumed",[b])})),b.timeout&&(b.timeoutId=setTimeout(function(){b.API.prepareTx(!1,!b.reverse)},b.timeout+b.delay)),b._initialized=!0,b.API.updateView(),b.container.on("cycle-paused cycle-resumed",function(a){b.container[a.type==="cycle-paused"?"addClass":"removeClass"]("cycle-paused")}),b.API.trigger("cycle-initialized",[b]),b.API.postInitSlideshow()},add:function(b,c){var d=this.opts(),e=d.slideCount,f=!1;a(b).each(function(b){var e,f=a(this);c?d.container.prepend(f):d.container.append(f),d.slideCount++,e=d.API.buildSlideOpts(f),c?d.slides=a(f).add(d.slides):d.slides=d.slides.add(f),d.API.initSlide(e,f,--d._maxZ),f.data("cycle.opts",e),d.API.trigger("cycle-slide-added",[d,e,f])}),d.API.updateView(),f=d._preInitialized&&e<2&&d.slideCount>=1,f&&(d._initialized?d.timeout&&(d.timeoutId=setTimeout(function(){var a=d.slides.length;d.nextSlide=d.reverse?a-1:1,d.API.prepareTx(!1,!d.reverse)},d.timeout+d.delay)):d.API.initSlideshow())},calcFirstSlide:function(){var a=this.opts(),b;b=parseInt(a.startingSlide||0,10);if(b>=a.slides.length||b<0)b=0;a.currSlide=b,a.reverse?(a.nextSlide=b-1,a.nextSlide<0&&(a.nextSlide=a.slides.length-1)):(a.nextSlide=b+1,a.nextSlide==a.slides.length&&(a.nextSlide=0))},calcNextSlide:function(){var a=this.opts(),b;a.reverse?(b=a.nextSlide-1<0,a.nextSlide=b?a.slideCount-1:a.nextSlide-1,a.currSlide=b?0:a.nextSlide+1):(b=a.nextSlide+1==a.slides.length,a.nextSlide=b?0:a.nextSlide+1,a.currSlide=b?a.slides.length-1:a.nextSlide-1)},calcTx:function(b,d){var e=b,f;return d&&e.manualFx&&(f=a.fn.cycle.transitions[e.manualFx]),f||(f=a.fn.cycle.transitions[e.fx]),f||(f=a.fn.cycle.transitions.fade,c('Transition "'+e.fx+'" not found.  Using fade.')),f},prepareTx:function(a,b){var c=this.opts(),d,e,f,g,h;
222if(c.slideCount<2){c.timeoutId=0;return}a&&(c.API.stopTransition(),c.busy=!1,clearTimeout(c.timeoutId),c.timeoutId=0);if(c.busy)return;if(c.timeoutId===0&&!a)return;e=c.slides[c.currSlide],f=c.slides[c.nextSlide],g=c.API.getSlideOpts(c.nextSlide),h=c.API.calcTx(g,a),c._tx=h,a&&g.manualSpeed!==undefined&&(g.speed=g.manualSpeed),c.nextSlide!=c.currSlide&&(a||!c.paused&&c.timeout)?(c.API.trigger("cycle-before",[g,e,f,b]),h.before&&h.before(g,e,f,b),d=function(){c.busy=!1,h.after&&h.after(g,e,f,b),c.API.trigger("cycle-after",[g,e,f,b]),c.API.queueTransition(g),c.API.updateView()},c.busy=!0,h.transition?h.transition(g,e,f,b,d):c.API.doTransition(g,e,f,b,d),c.API.calcNextSlide()):c.API.queueTransition(g)},doTransition:function(b,c,d,e,f){var g=b,h=a(c),i=a(d),j=function(){i.animate(g.animIn||{opacity:1},g.speed,g.easeIn||g.easing,f)};i.css(g.cssBefore||{}),h.animate(g.animOut||{},g.speed,g.easeOut||g.easing,function(){h.css(g.cssAfter||{}),g.sync||j()}),g.sync&&j()},queueTransition:function(a){var b=this.opts();if(b.nextSlide===0&&--b.loop===0){b.API.log("terminating; loop=0"),b.timeout=0,b.API.trigger("cycle-finished",[b]),b.nextSlide=b.currSlide;return}a.timeout&&(b.timeoutId=setTimeout(function(){b.API.prepareTx(!1,!b.reverse)},a.timeout))},stopTransition:function(){var a=this.opts();a.slides.filter(":animated").length&&(a.slides.stop(!1,!0),a.API.trigger("cycle-transition-stopped",[a])),a._tx&&a._tx.stopTransition&&a._tx.stopTransition(a)},advanceSlide:function(a){var b=this.opts();return clearTimeout(b.timeoutId),b.timeoutId=0,b.nextSlide=b.currSlide+a,b.nextSlide<0?b.nextSlide=b.slides.length-1:b.nextSlide>=b.slides.length&&(b.nextSlide=0),b.API.prepareTx(!0,a>=0),!1},buildSlideOpts:function(b){var e=this.opts(),f,g,h=b.data()||{};for(var i in h)h.hasOwnProperty(i)&&/^cycle[A-Z]+/.test(i)&&(f=h[i],g=i.match(/^cycle(.*)/)[1].replace(/^[A-Z]/,d),c("["+(e.slideCount-1)+"]",g+":",f,"("+typeof f+")"),h[g]=f);h=a.extend({},a.fn.cycle.defaults,e,h),h.slideNum=e.slideCount;try{delete h.API,delete h.slideCount,delete h.currSlide,delete h.nextSlide,delete h.slides}catch(j){}return h},getSlideOpts:function(b){var c=this.opts();b===undefined&&(b=c.currSlide);var d=c.slides[b],e=a(d).data("cycle.opts");return a.extend({},c,e)},initSlide:function(b,c,d){var e=this.opts();c.css(b.slideCss||{}),d>0&&c.css("zIndex",d),isNaN(b.speed)&&(b.speed=a.fx.speeds[b.speed]||a.fx.speeds._default),b.sync||(b.speed=b.speed/2),c.addClass(e.slideClass)},updateView:function(){var a=this.opts();if(!a._initialized)return;var b=a.API.getSlideOpts(),c=a.slides[a.currSlide];a.slideActiveClass&&a.slides.removeClass(a.slideActiveClass).eq(a.currSlide).addClass(a.slideActiveClass),a.hideNonActive&&a.slides.filter(":not(."+a.slideActiveClass+")").hide(),a.API.trigger("cycle-update-view",[a,b,c])},getComponent:function(b){var c=this.opts(),d=c[b];return typeof d=="string"?/^\s*\>/.test(d)?c.container.find(d):a(d):d.jquery?d:a(d)},stackSlides:function(b,c,d){var e=this.opts();b||(b=e.slides[e.currSlide],c=e.slides[e.nextSlide],d=!e.reverse),a(b).css("zIndex",e.maxZ);var f,g=e.maxZ-2,h=e.slideCount;if(d){for(f=e.currSlide+1;f<h;f++)a(e.slides[f]).css("zIndex",g--);for(f=0;f<e.currSlide;f++)a(e.slides[f]).css("zIndex",g--)}else{for(f=e.currSlide-1;f>=0;f--)a(e.slides[f]).css("zIndex",g--);for(f=h-1;f>e.currSlide;f--)a(e.slides[f]).css("zIndex",g--)}a(c).css("zIndex",e.maxZ-1)},getSlideIndex:function(a){return this.opts().slides.index(a)}},a.fn.cycle.log=c,a.fn.cycle.version=function(){return"Cycle2: "+b},a.fn.cycle.transitions={custom:{},none:{before:function(a,b,c,d){a.API.stackSlides(c,b,d),a.cssBefore={opacity:1,display:"block"}}},fade:{before:function(b,c,d,e){var f=b.API.getSlideOpts(b.nextSlide).slideCss||{};b.API.stackSlides(c,d,e),b.cssBefore=a.extend(f,{opacity:0,display:"block"}),b.animIn={opacity:1},b.animOut={opacity:0}
222}},fadeout:{before:function(b,c,d,e){var f=b.API.getSlideOpts(b.nextSlide).slideCss||{};b.API.stackSlides(c,d,e),b.cssBefore=a.extend(f,{opacity:1,display:"block"}),b.animOut={opacity:0}}},scrollHorz:{before:function(a,b,c,d){a.API.stackSlides(b,c,d);var e=a.container.css("overflow","hidden").width();a.cssBefore={left:d?e:-e,top:0,opacity:1,display:"block"},a.cssAfter={zIndex:a._maxZ-2},a.animIn={left:0},a.animOut={left:d?-e:e}}}},a.fn.cycle.defaults={allowWrap:!0,autoSelector:".cycle-slideshow",delay:0,easing:null,fx:"fade",hideNonActive:!0,loop:0,manualFx:undefined,manualSpeed:undefined,maxZ:100,pauseOnHover:!1,reverse:!1,slideActiveClass:"cycle-slide-active",slideClass:"cycle-slide",slideCss:{position:"absolute",top:0,left:0},slides:"> img",speed:500,startingSlide:0,sync:!0,timeout:4e3},a(document).ready(function(){a(a.fn.cycle.defaults.autoSelector).cycle()})})(jQuery),function(a){"use strict",a.extend(a.fn.cycle.defaults,{autoHeight:0}),a(document).on("cycle-initialized",function(b,c){function e(){c.container.height(c.container.width()/d)}var d;a.type(c.autoHeight)=="number"&&c.autoHeight>=0?c._sentinel=a(c.slides[c.autoHeight]).clone().css({position:"static",visibility:"hidden",display:"block"}).prependTo(c.container).removeClass().addClass("cycle-sentinel cycle-slide"):a.type(c.autoHeight)=="string"&&/\d+\:\d+/.test(c.autoHeight)&&(d=c.autoHeight.match(/(\d+)\:(\d+)/),d=d[1]/d[2],a(window).on("resize",e),c._autoHeightOnResize=e,setTimeout(function(){a(window).triggerHandler("resize")},15))}),a(document).on("cycle-destroyed",function(b,c){c._sentinel&&c._sentinel.remove(),c._autoHeightOnResize&&a(window).off("resize",c._autoHeightOnResize)})}(jQuery),function(a){"use strict",a.extend(a.fn.cycle.defaults,{caption:"> .cycle-caption",captionTemplate:"{{slideNum}} / {{slideCount}}",overlay:"> .cycle-overlay",overlayTemplate:"<div>{{title}}</div><div>{{desc}}</div>"}),a(document).on("cycle-update-view",function(b,c,d,e){var f;a.each(["caption","overlay"],function(){var a=this,b=d[a+"Template"];c[a]&&b&&(f=c.API.getComponent(a),f.html(c.API.tmpl(b,d,e)))})}),a(document).on("cycle-destroyed",function(b,c){var d;a.each(["caption","overlay"],function(){var a=this,b=c[a+"Template"];c[a]&&b&&(d=c.API.getComponent("caption"),d.empty())})})}(jQuery),function(a){"use strict";var b=a.fn.cycle;a.fn.cycle=function(c){var d,e,f,g=a.makeArray(arguments);return a.type(c)=="number"?this.cycle("goto",c):a.type(c)=="string"?this.each(function(){var h;d=c,f=a(this).data("cycle.opts");if(f===undefined){b.log('slideshow must be initialized before sending commands; "'+d+'" ignored');return}d=d=="goto"?"jump":d,e=f.API[d];if(a.isFunction(e))return h=a.makeArray(g),h.shift(),e.apply(f.API,h);b.log("unknown command: ",d)}):b.apply(this,arguments)},a.extend(a.fn.cycle,b),a.extend(b.API,{next:function(){var a=this.opts(),b=a.reverse?-1:1;if(a.allowWrap===!1&&a.currSlide+b>=a.slideCount)return;a.API.advanceSlide(b),a.API.trigger("cycle-next",[a]).log("cycle-next")},prev:function(){var a=this.opts(),b=a.reverse?1:-1;if(a.allowWrap===!1&&a.currSlide+b<0)return;a.API.advanceSlide(b),a.API.trigger("cycle-prev",[a]).log("cycle-prev")},destroy:function(){var a=this.opts();clearTimeout(a.timeoutId),a.timeoutId=0,a.API.stop(),a.API.trigger("cycle-destroyed",[a]).log("cycle-destroyed"),a.container.removeData("cycle.opts")},jump:function(a){var b,c=this.opts(),d=parseInt(a,10);if(isNaN(d)||d<0||d>=c.slides.length){c.API.log("goto: invalid slide index: "+d);return}if(d==c.currSlide){c.API.log("goto: skipping, already on slide",d);return}c.nextSlide=d,clearTimeout(c.timeoutId),c.timeoutId=0,c.API.log("goto: ",d," (zero-index)"),b=c.currSlide<c.nextSlide,c.API.prepareTx(!0,b)},stop:function(){var b=this.opts(),c=b.container;clearTimeout(b.timeoutId),b.timeoutId=0,b.API.stopTransition(),b.pauseOnHover&&(b.pauseOnHover!==!0&&(c=a(b.pauseOnHover)),c.off("mouseenter mouseleave")),b.API.trigger("cycle-stopped",[b]).log("cycle-stopped")},pause:function(){var a=this.opts();a.paused=!0,a.API.trigger("cycle-paused",[a]).log("cycle-paused")},resume:function(){var a=this.opts();a.paused=!1,a.API.trigger("cycle-resumed",[a]).log("cycle-resumed")},reinit:function(){var a=this.opts();a.API.destroy(),a.container.cycle()},remove:function(b){var c=this.opts(),d,e,f=[],g=1;for(var h=0;h<c.slides.length;h++)d=c.slides[h],h==b?e=d:(f.push(d),d.data("cycle.opts").slideNum=g,g++);e&&(c.slides=a(f),c.slideCount--,a(e).remove(),b==c.currSlide&&c.API.advanceSlide(1),c.API.trigger("cycle-slide-removed",[c,b,e]).log("cycle-slide-removed"),c.API.updateView())}}),a(document).on("click.cycle","[data-cycle-cmd]",function(b){b.preventDefault();var c=a(this),d=c.data("cycle-cmd"),e=c.data("cycle-context")||".cycle-slideshow";a(e).cycle(d,c.data("cycle-arg"))})}(jQuery),function(a){function b(b,c){var d;if(b._hashFence){b._hashFence=!1;return}d=window.location.hash.substring(1),b.slides.each(function(e){if(a(this).data("cycle-hash")===d)return c===!0?b.startingSlide=e:(b.nextSlide=e,b.API.prepareTx(!0,!1)),!1})}"use strict",a(document).on("cycle-pre-initialize",function(c,d){b(d,!0),d._onHashChange=function(){b(d,!1)},a(window).on("hashchange",d._onHashChange)}),a(document).on("cycle-update-view",function(a,b,c){c.hash&&(b._hashFence=!0,window.location.hash=c.hash)}),a(document).on("cycle-destroyed",function(b,c){c._onHashChange&&a(window).off("hashchange",c._onHashChange)})}(jQuery),function(a){"use strict",a.extend(a.fn.cycle.defaults,{loader:!1}),a(document).on("cycle-bootstrap",function(b,c){function e(b,e){function h(b){var h;c.loader=="wait"?(f.push(b),g===0&&(d.apply(c.API,[f,e]),c.container.removeClass("cycle-loading"))):(h=a(c.slides[c.currSlide]),d.apply(c.API,[b,e]),h.show(),c.container.removeClass("cycle-loading"))}var f=[];b=a(b);var g=b.length;b.hide().each(function(){function k(){--b===0&&(--g,h(i))}var b=0,i=a(this),j=i.is("img")?i:i.find("img");j=j.filter(":not(.cycle-loader-ignore)");if(!j.length){--g,f.push(i);return}b=j.length,j.each(function(){this.complete?k():a(this).load(function(){k()}).error(function(){--b===0&&(c.API.log("slide skipped;
222 img not loaded:",this.src),--g===0&&c.loader=="wait"&&d.apply(c.API,[f,e]))})})}),g&&c.container.addClass("cycle-loading")}var d;if(!c.loader)return;d=c.API.add,c.API.add=e})}(jQuery),function(a){function b(b,c,d){var e,f=b.API.getComponent("pager");f.each(function(){var f=a(this);if(c.pagerTemplate){var g=b.API.tmpl(c.pagerTemplate,c,d[0]);e=a(g).appendTo(f)}else e=f.children().eq(b.slideCount-1);e.on(b.pagerEvent,function(a){a.preventDefault(),b.API.page(f,a.currentTarget)})})}function c(a,b){var c=this.opts(),d=a.children().index(b),e=d,f=c.currSlide<e;if(c.currSlide==e)return;c.nextSlide=e,c.API.prepareTx(!0,f),c.API.trigger("cycle-pager-activated",[c,a,b])}"use strict",a.extend(a.fn.cycle.defaults,{pager:"> .cycle-pager",pagerActiveClass:"cycle-pager-active",pagerEvent:"click.cycle",pagerTemplate:"<span>&bull;</span>"}),a(document).on("cycle-bootstrap",function(a,c,d){d.buildPagerLink=b}),a(document).on("cycle-slide-added",function(a,b,d,e){b.pager&&(b.API.buildPagerLink(b,d,e),b.API.page=c)}),a(document).on("cycle-slide-removed",function(b,c,d,e){if(c.pager){var f=c.API.getComponent(c,"pager");f.each(function(){var b=a(this);a(b.children()[d]).remove()})}}),a(document).on("cycle-update-view",function(b,c,d){var e;c.pager&&(e=c.API.getComponent("pager"),e.each(function(){a(this).children().removeClass(c.pagerActiveClass).eq(c.currSlide).addClass(c.pagerActiveClass)}))}),a(document).on("cycle-destroyed",function(a,b){var c;b.pager&&b.pagerTemplate&&(c=b.API.getComponent("pager"),c.empty())})}(jQuery),function(a){"use strict",a.extend(a.fn.cycle.defaults,{next:"> .cycle-next",nextEvent:"click.cycle",disabledClass:"disabled",prev:"> .cycle-prev",prevEvent:"click.cycle",swipe:!1}),a(document).on("cycle-initialized",function(a,b){b.API.getComponent("next").off(b.nextEvent).on(b.nextEvent,function(a){a.preventDefault(),b.API.next()}),b.API.getComponent("prev").off(b.prevEvent).on(b.prevEvent,function(a){a.preventDefault(),b.API.prev()});if(b.swipe){var c=b.swipeVert?"swipeUp.cycle":"swipeLeft.cycle swipeleft.cycle",d=b.swipeVert?"swipeDown.cycle":"swipeRight.cycle swiperight.cycle";b.container.on(c,function(a){b.API.next()}),b.container.on(d,function(){b.API.prev()})}}),a(document).on("cycle-update-view",function(a,b,c,d){if(b.allowWrap)return;var e=b.disabledClass,f=b.API.getComponent("next"),g=b.API.getComponent("prev"),h=b._prevBoundry||0,i=b._nextBoundry||b.slideCount-1;b.currSlide==i?f.addClass(e).prop("disabled",!0):f.removeClass(e).prop("disabled",!1),b.currSlide===h?g.addClass(e).prop("disabled",!0):g.removeClass(e).prop("disabled",!1)}),a(document).on("cycle-destroyed",function(b,c){a(c.next).off(c.nextEvent),a(c.prev).off(c.prevEvent),c.container.off("swipeleft.cycle swiperight.cycle swipeLeft.cycle swipeRight.cycle swipeUp.cycle swipeDown.cycle")})}(jQuery),function(a){"use strict",a.extend(a.fn.cycle.defaults,{progressive:!1}),a(document).on("cycle-pre-initialize",function(b,c){if(!c.progressive)return;var d=c.API,e=d.next,f=d.prev,g=d.prepareTx,h,i=a.type(c.progressive);if(i=="array")h=c.progressive;else if(a.isFunction(c.progressive))h=c.progressive(c);else if(i=="string"){h=a(c.progressive).html();if(!a.trim(h))return;try{h=a.parseJSON(h)}catch(j){d.log("error parsing progressive slides",j);return}}g&&(d.prepareTx=function(a,b){var d,e;if(a||h.length===0){g.apply(c.API,[a,b]);return}b&&c.currSlide==c.slideCount-1?(e=h[0],h=h.slice(1),c.container.one("cycle-slide-added",function(a,b){b.API.advanceSlide(1)}),c.API.add(e)):!b&&c.currSlide===0?(d=h.length-1,e=h[d],h=h.slice(0,d),c.container.one("cycle-slide-added",function(a,b){b.currSlide=1,b.API.advanceSlide(-1)}),c.API.add(e,!0)):g.apply(c.API,[a,b])}),e&&(d.next=function(){var a=this.opts();if(h.length&&a.currSlide==a.slideCount-1){var b=h[0];h=h.slice(1),a.container.one("cycle-slide-added",function(a,b){e.apply(b.API),b.container.removeClass("cycle-loading")}),a.container.addClass("cycle-loading"),a.API.add(b)}else e.apply(a.API)}),f&&(d.prev=function(){var a=this.opts();if(h.length&&a.currSlide===0){var b=h.length-1,c=h[b];h=h.slice(0,b),a.container.one("cycle-slide-added",function(a,b){b.currSlide=1,b.API.advanceSlide(-1),b.container.removeClass("cycle-loading")}),a.container.addClass("cycle-loading"),a.API.add(c,!0)}else f.apply(a.API)})})}(jQuery),function(a){"use strict",a.extend(a.fn.cycle.API,{tmpl:function(b,c,d){if(b&&c)return b.replace(/\{\{((\.)?.*?)\}\}/g,function(b,e){var f,g,h=c,i=e.split(".");if(i.length>1){g=c;for(f=0;f<i.length;f++)h=g,g=g[i[f]]||e}else g=c[e];return a.isFunction(g)?g.call(h,c):g!==undefined&&g!==null?g:d&&d[e]!==undefined?d[e]:e})}})}(jQuery);;
223/*! carousel transition plugin for Cycle2;  version: BETA-20121016 */
224(function($) {
225"use strict";
226
227$( document ).on('cycle-bootstrap', function( e, opts, API ) {
228    if ( opts.fx !== 'carousel' )
229        return;
230
231    API.getSlideIndex = function( el ) {
232        var slides = this.opts()._carouselWrap.children();
233        var i = slides.index( el );
234        return i % slides.length;
235    };
236});
237
238
239$.fn.cycle.transitions.carousel = {
240    // transition API impl
241    preInit: function( opts ) {
242        opts.hideNonActive = false;
243        
244        opts.container.on('cycle-destroyed', $.proxy(this.onDestroy, opts.API));
245        // override default API implementation
246        opts.API.stopTransition = this.stopTransition;
247    },
248
249    // transition API impl
250    postInit: function( opts ) {
251        var pagerCutoffIndex, wrap;
252        var vert = opts.carouselVertical;
253        if (opts.carouselVisible && opts.carouselVisible > opts.slideCount)
254            opts.carouselVisible = opts.slideCount - 1;
255        var visCount = opts.carouselVisible || opts.slides.length;
256        //var slideCSS = { display: vert ? 'block' : 'inline-block', position: 'static' };
257		var slideCSS = {position: 'static', float: 'left' };
258
259        // required styles
260        opts.container.css({ position: 'relative', overflow: 'hidden' });
261        opts.slides.css( slideCSS );
262
263        opts._currSlide = opts.currSlide;
264
265		var wrapwidth = opts.slideCount * (opts.container.width() / opts.carouselVisible) * 3;
266        // wrap slides in a div; this div is what is animated
267        wrap = $('<div class="cycle-carousel-wrap clearfix"></div')
268            .prependTo( opts.container )
269            .css({ margin: 0, padding: 0, top: 0, left: 0, position: 'absolute', width: wrapwidth })
270            .append( opts.slides );
271
272        opts._carouselWrap = wrap;
273
274        if ( !vert )
275            wrap.css('white-space', 'nowrap');
276
277        if ( opts.allowWrap !== false ) {
278            // prepend and append extra slides so we don't see any empty space when we
279            // near the end of the carousel.  for fluid containers, add even more clones
280            // so there is plenty to fill the screen
281            // @todo: optimzie this based on slide sizes
282            opts.slides.slice(0, opts.slideCount).clone().css( slideCSS ).appendTo( wrap );
283            if ( opts.carouselVisible === undefined )
284                opts.slides.slice(0, opts.slideCount).clone().css( slideCSS ).appendTo( wrap );
285            opts.slides.slice(0, opts.slideCount).clone().css( slideCSS ).prependTo( wrap );
286            if ( opts.carouselVisible === undefined )
287                opts.slides.slice(0, opts.slideCount).clone().css( slideCSS ).prependTo( wrap );
288        }
289
290        if ( opts.pager && opts.allowWrap === false ) {
291            // hide "extra" pagers
292            pagerCutoffIndex = opts.slideCount - visCount;
293            $( opts.pager ).children().filter( ':gt('+pagerCutoffIndex+')' ).hide();
294        }
295
296        opts._nextBoundry = opts.slideCount - opts.carouselVisible;
297
298        this.prepareDimensions( opts );
299    },
300
301    prepareDimensions: function( opts ) {
302        var dim, offset, pagerCutoffIndex, tmp;
303        var vert = opts.carouselVertical;
304        var visCount = opts.carouselVisible || opts.slides.length;
305
306        if ( opts.carouselFluid && opts.carouselVisible ) {
307            if ( ! opts._carouselResizeThrottle ) {
308            // fluid container AND fluid slides; slides need to be resized to fit container
309                this.fluidSlides( opts );
310            }
311        }
312        else if ( opts.carouselVisible && opts.carouselSlideDimension ) {
313            dim = visCount * opts.carouselSlideDimension;
314            opts.container[ vert ? 'height' : 'width' ]( dim );
315        }
316        else if ( opts.carouselVisible ) {
317            dim = visCount * $(opts.slides[0])[vert ? 'outerHeight' : 'outerWidth'](true);
318            opts.container[ vert ? 'height' : 'width' ]( dim );
319        }
320        // else {
321        //     // fluid; don't size the container
322        // }
323
324        offset = ( opts.carouselOffset || 0 );
325        if ( opts.allowWrap !== false ) {
326            if ( opts.carouselSlideDimension ) {
327                offset -= ( (opts.slideCount + opts.currSlide) * opts.carouselSlideDimension );
328            }
329            else {
330                // calculate offset based on actual slide dimensions
331                tmp = opts._carouselWrap.children();
332                for (var j=0; j < (opts.slideCount + opts.currSlide); j++) {
333                    offset -= $(tmp[j])[vert?'outerHeight':'outerWidth'](true);
334                }
335            }
336        }
337
338        opts._carouselWrap.css( vert ? 'top' : 'left', offset );
339    },
340
341    fluidSlides: function( opts ) {
342        var timeout;
343        var slide = opts.slides.eq(0);
344        var adjustment = slide.outerWidth() - slide.width();
345        var prepareDimensions = this.prepareDimensions;
346
347        // throttle resize event
348        $(window).on( 'resize', resizeThrottle);
349
350        opts._carouselResizeThrottle = resizeThrottle;
351        onResize();
352
353        function resizeThrottle() {
354            clearTimeout( timeout );
355            timeout = setTimeout( onResize, 20 );
356        }
357
358        function onResize() {
359            opts._carouselWrap.stop( false, true );
360            var slideWidth = opts.container.width() / opts.carouselVisible;
361            slideWidth = Math.ceil( slideWidth - adjustment );
362            opts._carouselWrap.children().width( slideWidth );
363            if ( opts._sentinel )
364                opts._sentinel.width( slideWidth );
365            prepareDimensions( opts );
366        }
367    },
368
369    // transition API impl
370    transition: function( opts, curr, next, fwd, callback ) {
371        var moveBy, props = {};
372        var hops = opts.nextSlide - opts.currSlide;
373        var vert = opts.carouselVertical;
374
375        // handle all the edge cases for wrapping & non-wrapping
376        if ( opts.allowWrap === false ) {
377            fwd = hops > 0;
378            var currSlide = opts._currSlide;
379            var maxCurr = opts.slideCount - opts.carouselVisible;
380            if ( hops > 0 && opts.nextSlide > maxCurr && currSlide == maxCurr ) {
381                hops = 0;
382            }
383            else if ( hops > 0 && opts.nextSlide > maxCurr ) {
384                hops = opts.nextSlide - currSlide - (opts.nextSlide - maxCurr);
385            }
386            else if ( hops < 0 && opts.currSlide > maxCurr && opts.nextSlide > maxCurr ) {
387                hops = 0;
388            }
389            else if ( hops < 0 && opts.currSlide > maxCurr ) {
390                hops += opts.currSlide - maxCurr;
391            }
392            else 
393                currSlide = opts.currSlide;
394
395            moveBy = this.getScroll( opts, vert, currSlide, hops );
396            opts.API.opts()._currSlide = opts.nextSlide > maxCurr ? maxCurr : opts.nextSlide;
397        }
398        else {
399            if ( fwd && opts.nextSlide === 0 ) {
400                // moving from last slide to first
401                moveBy = this.getDim( opts, opts.currSlide, vert );
402                callback = this.genCallback( opts, fwd, vert, callback );
403            }
404            else if ( !fwd && opts.nextSlide == opts.slideCount - 1 ) {
405                // moving from first slide to last
406                moveBy = this.getDim( opts, opts.currSlide, vert );
407                callback = this.genCallback( opts, fwd, vert, callback );
408            }
409            else {
410                moveBy = this.getScroll( opts, vert, opts.currSlide, hops );
411            }
412        }
413
414        props[ vert ? 'top' : 'left' ] = fwd ? ( "-=" + moveBy ) : ( "+=" + moveBy );
415        opts._carouselWrap.animate( props, opts.speed, opts.easing, callback );
416    },
417
418    getDim: function( opts, index, vert ) {
419        var slide = $( opts.slides[index] );
420        return slide[ vert ? 'outerHeight' : 'outerWidth'](true);
421    },
422
423    getScroll: function( opts, vert, currSlide, hops ) {
424        var i, moveBy = 0;
425
426        if (hops > 0) {
427            for (i=currSlide; i < currSlide+hops; i++)
428                moveBy += this.getDim( opts, i, vert);
429        }
430        else {
431            for (i=currSlide; i > currSlide+hops; i--)
432                moveBy += this.getDim( opts, i, vert);
433        }
434        return moveBy;
435    },
436
437    genCallback: function( opts, fwd, vert, callback ) {
438        // returns callback fn that resets the left/top wrap position to the "real" slides
439        return function() {
440            var pos = $(opts.slides[opts.nextSlide]).position();
441            var offset = 0 - pos[vert?'top':'left'] - (opts.carouselOffset || 0);
442            opts._carouselWrap.css( opts.carouselVertical ? 'top' : 'left', offset );
443            callback();
444        };
445    },
446
447    // core API override
448    stopTransition: function() {
449        var opts = this.opts();
450        opts.slides.stop( false, true );
451        opts._carouselWrap.stop( false, true );
452    },
453
454    // core API supplement
455    onDestroy: function( e ) {
456        var opts = this.opts();
457        if ( opts._carouselResizeThrottle )
458            $( window ).off( 'resize', opts._carouselResizeThrottle );
459        opts.slides.prependTo( opts.container );
460        opts._carouselWrap.remove();
461    }
462};
463
464})(jQuery);
465;

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.