1(function ($, Drupal) { 2 Drupal.behaviors.showPopupCookiePreferences = { 3 attach: function (context, settings) { 4 $('a[href="#show-privacy-center"]', context).once('showPrivacyCenter').click(function (e) { 5 e.preventDefault(); 6 Didomi.preferences.show(); 7 }); 8 } 9 }; 10})(jQuery, Drupal); 11; 12/* 13 * Superfish v1.4.8 - jQuery menu widget 14 * Copyright (c) 2008 Joel Birch 15 * 16 * Dual licensed under the MIT and GPL licenses: 17 * http://www.opensource.org/licenses/mit-license.php 18 * http://www.gnu.org/licenses/gpl.html 19 * 20 * CHANGELOG: http://users.tpg.com.au/j_birch/plugins/superfish/changelog.txt 21 */ 22/* 23 * This is not the original jQuery Superfish plugin. 24 * Please refer to the README for more information. 25 */ 26 27(function($){ 28 $.fn.superfish = function(op){ 29 var sf = $.fn.superfish, 30 c = sf.c, 31 $arrow = $(['<span class="',c.arrowClass,'"> »</span>'].join('')), 32 over = function(){ 33 var $$ = $(this), menu = getMenu($$); 34 clearTimeout(menu.sfTimer); 35 $$.showSuperfishUl().siblings().hideSuperfishUl(); 36 }, 37 out = function(){ 38 var $$ = $(this), menu = getMenu($$), o = sf.op; 39 clearTimeout(menu.sfTimer); 40 menu.sfTimer=setTimeout(function(){ 41 if ($$.children('.sf-clicked').length == 0){ 42 o.retainPath=($.inArray($$[0],o.$path)>-1); 43 $$.hideSuperfishUl(); 44 if (o.$path.length && $$.parents(['li.',o.hoverClass].join('')).length<1){over.call(o.$path);} 45 } 46 },o.delay); 47 }, 48 getMenu = function($menu){ 49 var menu = $menu.parents(['ul.',c.menuClass,':first'].join(''))[0]; 50 sf.op = sf.o[menu.serial]; 51 return menu; 52 }, 53 addArrow = function($a){ $a.addClass(c.anchorClass).append($arrow.clone()); }; 54 55 return this.each(function() { 56 var s = this.serial = sf.o.length; 57 var o = $.extend({},sf.defaults,op); 58 o.$path = $('li.'+o.pathClass,this).slice(0,o.pathLevels), 59 p = o.$path; 60 for (var l = 0; l < p.length; l++){ 61 p.eq(l).addClass([o.hoverClass,c.bcClass].join(' ')).filter('li:has(ul)').removeClass(o.pathClass); 62 } 63 sf.o[s] = sf.op = o; 64 65 $('li:has(ul)',this)[($.fn.hoverIntent && !o.disableHI) ? 'hoverIntent' : 'hover'](over,out).each(function() { 66 if (o.autoArrows) addArrow( $(this).children('a:first-child, span.nolink:first-child') ); 67 }) 68 .not('.'+c.bcClass) 69 .hideSuperfishUl(); 70 71 var $a = $('a, span.nolink',this); 72 $a.each(function(i){ 73 var $li = $a.eq(i).parents('li'); 74 $a.eq(i).focus(function(){over.call($li);}).blur(function(){out.call($li);}); 75 }); 76 o.onInit.call(this); 77 78 }).each(function() { 79 var menuClasses = [c.menuClass], 80 addShadow = true; 81 if ($.browser !== undefined){ 82 if ($.browser.msie && $.browser.version < 7){ 83 addShadow = false; 84 } 85 } 86 if (sf.op.dropShadows && addShadow){ 87 menuClasses.push(c.shadowClass); 88 } 89 $(this).addClass(menuClasses.join(' ')); 90 }); 91 }; 92 93 var sf = $.fn.superfish; 94 sf.o = []; 95 sf.op = {}; 96 sf.IE7fix = function(){ 97 var o = sf.op; 98 if ($.browser !== undefined){ 99 if ($.browser.msie && $.browser.version > 6 && o.dropShadows && o.animation.opacity != undefined) { 100 this.toggleClass(sf.c.shadowClass+'-off'); 101 } 102 } 103 }; 104 sf.c = { 105 bcClass: 'sf-breadcrumb', 106 menuClass: 'sf-js-enabled', 107 anchorClass: 'sf-with-ul', 108 arrowClass: 'sf-sub-indicator', 109 shadowClass: 'sf-shadow' 110 }; 111 sf.defaults = { 112 hoverClass: 'sfHover', 113 pathClass: 'overideThisToUse', 114 pathLevels: 1, 115 delay: 800, 116 animation: {opacity:'show'}, 117 speed: 'fast', 118 autoArrows: true, 119 dropShadows: true, 120 disableHI: false, // true disables hoverIntent detection 121 onInit: function(){}, // callback functions 122 onBeforeShow: function(){}, 123 onShow: function(){}, 124 onHide: function(){} 125 }; 126 $.fn.extend({ 127 hideSuperfishUl : function(){ 128 var o = sf.op, 129 not = (o.retainPath===true) ? o.$path : ''; 130 o.retainPath = false;
131 var $ul = $(['li.',o.hoverClass].join(''),this).add(this).not(not).removeClass(o.hoverClass) 132 .children('ul').addClass('sf-hidden'); 133 o.onHide.call($ul); 134 return this; 135 }, 136 showSuperfishUl : function(){ 137 var o = sf.op, 138 sh = sf.c.shadowClass+'-off', 139 $ul = this.addClass(o.hoverClass) 140 .children('ul.sf-hidden').hide().removeClass('sf-hidden'); 141 sf.IE7fix.call($ul); 142 o.onBeforeShow.call($ul); 143 $ul.animate(o.animation,o.speed,function(){ sf.IE7fix.call($ul); o.onShow.call($ul); }); 144 return this; 145 } 146 }); 147})(jQuery);; 148/* 149 * Supposition v0.2 - an optional enhancer for Superfish jQuery menu widget. 150 * 151 * Copyright (c) 2008 Joel Birch - based mostly on work by Jesse Klaasse and credit goes largely to him. 152 * Special thanks to Karl Swedberg for valuable input. 153 * 154 * Dual licensed under the MIT and GPL licenses: 155 * http://www.opensource.org/licenses/mit-license.php 156 * http://www.gnu.org/licenses/gpl.html 157 */ 158/* 159 * This is not the original jQuery Supposition plugin. 160 * Please refer to the README for more information. 161 */ 162 163(function($){ 164 $.fn.supposition = function(){ 165 var $w = $(window), /*do this once instead of every onBeforeShow call*/ 166 _offset = function(dir) { 167 return window[dir == 'y' ? 'pageYOffset' : 'pageXOffset'] 168 || document.documentElement && document.documentElement[dir=='y' ? 'scrollTop' : 'scrollLeft'] 169 || document.body[dir=='y' ? 'scrollTop' : 'scrollLeft']; 170 }, 171 onHide = function(){ 172 this.css({bottom:''}); 173 }, 174 onBeforeShow = function(){ 175 this.each(function(){ 176 var $u = $(this); 177 $u.css('display','block'); 178 var $mul = $u.closest('.sf-menu'), 179 level = $u.parents('ul').length, 180 menuWidth = $u.width(), 181 menuParentWidth = $u.closest('li').outerWidth(true), 182 menuParentLeft = $u.closest('li').offset().left, 183 totalRight = $w.width() + _offset('x'), 184 menuRight = $u.offset().left + menuWidth, 185 exactMenuWidth = (menuRight > (menuParentWidth + menuParentLeft)) ? menuWidth - (menuRight - (menuParentWidth + menuParentLeft)) : menuWidth; 186 if ($u.parents('.sf-js-enabled').hasClass('rtl')) { 187 if (menuParentLeft < exactMenuWidth) { 188 if (($mul.hasClass('sf-horizontal') && level == 1) || ($mul.hasClass('sf-navbar') && level == 2)){ 189 $u.css({left:0,right:'auto'}); 190 } 191 else { 192 $u.css({left:menuParentWidth + 'px',right:'auto'}); 193 } 194 } 195 } 196 else { 197 if (menuRight > totalRight && menuParentLeft > menuWidth) { 198 if (($mul.hasClass('sf-horizontal') && level == 1) || ($mul.hasClass('sf-navbar') && level == 2)){ 199 $u.css({right:0,left:'auto'}); 200 } 201 else { 202 $u.css({right:menuParentWidth + 'px',left:'auto'}); 203 } 204 } 205 } 206 var windowHeight = $w.height(), 207 offsetTop = $u.offset().top, 208 menuParentShadow = ($mul.hasClass('sf-shadow') && $u.css('padding-bottom').length > 0) ? parseInt($u.css('padding-bottom').slice(0,-2)) : 0, 209 menuParentHeight = ($mul.hasClass('sf-vertical')) ? '-' + menuParentShadow : $u.parent().outerHeight(true) - menuParentShadow, 210 menuHeight = $u.height(), 211 baseline = windowHeight + _offset('y'); 212 var expandUp = ((offsetTop + menuHeight > baseline) && (offsetTop > menuHeight)); 213 if (expandUp) { 214 $u.css({bottom:menuParentHeight + 'px',top:'auto'}); 215 } 216 $u.css('display','none'); 217 }); 218 }; 219 220 return this.each(function() { 221 var o = $.fn.superfish.o[this.serial]; /* get this menu's options */ 222 223 /* if callbacks already set, store them */ 224 var _onBeforeShow = o.onBeforeShow, 225 _onHide = o.onHide; 226 227 $.extend($.fn.superfish.o[this.serial],{ 228 onBeforeShow: function() { 229 onBeforeShow.call(this); /* fire our Supposition callback */ 230 _onBeforeShow.call(this); /* fire stored callbacks */ 231 }, 232 onHide: function() { 233 onHide.call(this); /* fire our Supposition callback */ 234 _onHide.call(this); /* fire stored callbacks */ 235 } 236 }); 237 }); 238 }; 239})(jQuery);; 240/* 241 * sf-Touchscreen v1.3b - Provides touchscreen compatibility for the jQuery Superfish plugin. 242 * 243 * Developer's note: 244 * Built as a part of the Superfish project for Drupal (http://drupal.org/project/superfish) 245 * Found any bug? have any cool ideas? contact me right away! http://drupal.org/user/619294/contact 246 * 247 * jQuery version: 1.3.x or higher. 248 * 249 * Dual licensed under the MIT and GPL licenses: 250 * http://www.opensource.org/licenses/mit-license.php 251 * http://www.gnu.org/licenses/gpl.html 252 */ 253 254(function($){ 255 $.fn.sftouchscreen = function(options){ 256 options = $.extend({ 257 mode: 'inactive', 258 breakpoint: 768, 259 breakpointUnit: 'px', 260 useragent: '', 261 behaviour: 2, 262 disableHover: false 263 }, options); 264 265 function activate(menu){ 266 var eventHandler = (('ontouchstart' in window) || (window.DocumentTouch && document instanceof DocumentTouch)) ? ['click touchstart','mouseup touchend'] : ['click','mouseup']; 267 // Select hyperlinks from parent menu items. 268 menu.find('li:has(ul)').children('a,span.nolink').each(function(){ 269 var item = $(this), 270 parent = item.closest('li'); 271 if (options.disableHover){ 272 parent.unbind('mouseenter mouseleave'); 273 } 274 if (options.behaviour == 2){ 275 if (parent.children('a.menuparent,span.nolink.menuparent').length > 0 && parent.children('ul').children('.sf-clone-parent').length == 0){ 276 var 277 // Cloning the hyperlink of the parent menu item. 278 cloneLink = parent.children('a.menuparent,span.nolink.menuparent').clone(), 279 // Wrapping the hyerplinks in <li>. 280 cloneLink = $('<li class="sf-clone-parent" />').html(cloneLink); 281 // Removing unnecessary stuff. 282 cloneLink.find('.sf-sub-indicator').remove(), 283 // Adding a helper class and attaching them to the sub-menus. 284 parent.children('ul').addClass('sf-has-clone-parent').prepend(clone
284Link); 285 } 286 } 287 // No .toggle() here as it's not possible to reset it. 288 item.bind(eventHandler[0], function(event){ 289 // Already clicked? 290 if (item.hasClass('sf-clicked')){ 291 // Depending on the preferred behaviour, either proceed to the URL. 292 if (options.behaviour == 0){ 293 window.location = item.attr('href'); 294 } 295 // or collapse the sub-menu. 296 else if (options.behaviour == 1 || options.behaviour == 2){ 297 event.preventDefault(); 298 item.removeClass('sf-clicked'); 299 parent.hideSuperfishUl().find('a,span.nolink').removeClass('sf-clicked'); 300 } 301 } 302 // Prevent the default action otherwise. 303 else { 304 event.preventDefault(); 305 item.addClass('sf-clicked'); 306 parent.showSuperfishUl().siblings('li:has(ul)').hideSuperfishUl().find('.sf-clicked').removeClass('sf-clicked'); 307 } 308 }); 309 }); 310 311 $(document).bind(eventHandler[1], function(event){ 312 if (menu.not(event.target) && menu.has(event.target).length === 0){ 313 menu.find('.sf-clicked').removeClass('sf-clicked'); 314 menu.find('li:has(ul)').hideSuperfishUl(); 315 } 316 }); 317 } 318 // Return original object to support chaining. 319 // This is not necessary actually because of the way the module uses these plugins. 320 for (var b = 0; b < this.length; b++) { 321 var menu = $(this).eq(b), 322 mode = options.mode; 323 // The rest is crystal clear, isn't it? :) 324 if (mode == 'always_active'){ 325 activate(menu); 326 } 327 else if (mode == 'window_width'){ 328 var breakpoint = (options.breakpointUnit == 'em') ? (options.breakpoint * parseFloat($('body').css('font-size'))) : options.breakpoint, 329 windowWidth = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth, 330 timer; 331 if ((typeof Modernizr === 'undefined' || typeof Modernizr.mq !== 'function') && windowWidth < breakpoint){ 332 activate(menu); 333 } 334 else if (typeof Modernizr !== 'undefined' && typeof Modernizr.mq === 'function' && Modernizr.mq('(max-width:' + (breakpoint - 1) + 'px)')) { 335 activate(menu); 336 } 337 $(window).resize(function(){ 338 clearTimeout(timer); 339 timer = setTimeout(function(){ 340 var windowWidth = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; 341 if ((typeof Modernizr === 'undefined' || typeof Modernizr.mq !== 'function') && windowWidth < breakpoint){ 342 activate(menu); 343 } 344 else if (typeof Modernizr !== 'undefined' && typeof Modernizr.mq === 'function' && Modernizr.mq('(max-width:' + (breakpoint - 1) + 'px)')) { 345 activate(menu); 346 } 347 }, 50); 348 }); 349 } 350 else if (mode == 'useragent_custom'){ 351 if (options.useragent != ''){ 352 var ua = RegExp(options.useragent, 'i'); 353 if (navigator.userAgent.match(ua)){ 354 activate(menu); 355 } 356 } 357 } 358 else if (mode == 'useragent_predefined' && navigator.userAgent.match(/(android|bb\d+|meego)|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i)){ 359 activate(menu); 360 } 361 } 362 return this; 363 } 364})(jQuery); 365; 366/** 367* hoverIntent r6 // 2011.02.26 // jQuery 1.5.1+ 368* <http://cherne.net/brian/resources/jquery.hoverIntent.html> 369* 370* @param f onMouseOver function || An object with configuration options 371* @param g onMouseOut function || Nothing (use configuration options object) 372* @author Brian Cherne brian(at)cherne(dot)net 373*/ 374(function($){$.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=$.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY;var track=function(ev){cX=ev.pageX;cY=ev.pageY};var compare=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);if((Math.abs(pX-cX)+Math.abs(pY-cY))<cfg.sensitivity){$(ob).unbind("mousemove",track);ob.hoverIntent_s=1;return cfg.over.apply(ob,[ev])}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}};var delay=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);ob.hoverIntent_s=0;return cfg.out.apply(ob,[ev])};var handleHover=function(e){var ev=jQuery.extend({},e);var ob=this;if(ob.hoverIntent_t){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t)}if(e.type=="mouseenter"){pX=ev.pageX;pY=ev.pageY;$(ob).bind("mousemove",track);if(ob.hoverIntent_s!=1){ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}}else{$(ob).unbind("mousemove",track);if(ob.hoverIntent_s==1){ob.hoverIntent_t=setTimeout(function(){delay(ev,ob)},cfg.timeout)}}};return this.bind('mouseenter',handleHover).bind('mouseleave',handleHover)}})(jQuery);; 375/* 376 * Supersubs v0.4b - jQuery plugin 377 * Copyright (c) 2013 Joel Birch 378 * 379 * Dual licensed under the MIT and GPL licenses: 380 * http://www.opensource.org/licenses/mit-license.php 381 * http://www.gnu.org/licenses/gpl.html 382 * 383 * This plugin automatically adjusts submenu widths of suckerfish-style menus to that of 384 * their longest list item children. If you use this, please expect bugs and report them 385 * to the jQuery Google Group with the word 'Superfish' in the subject line. 386 * 387 */ 388/* 389 * This is not the original jQuery Supersubs plugin. 390 * Please refer to the README for more information. 391 */ 392 393(function($){ // $ will refer to jQuery within this closure 394 $.fn.supersubs = function(options){ 395 var opts = $.extend({}, $.fn.supersubs.defaults, options);
396 // return original object to support chaining 397 // Although this is unnecessary due to the way the module uses these plugins. 398 for (var a = 0; a < this.length; a++) { 399 // cache selections 400 var $$ = $(this).eq(a), 401 // support metadata 402 o = $.meta ? $.extend({}, opts, $$.data()) : opts; 403 // Jump one level if it's a "NavBar" 404 if ($$.hasClass('sf-navbar')) { 405 $$ = $$.children('li').children('ul'); 406 } 407 // cache all ul elements 408 var $ULs = $$.find('ul'), 409 // get the font size of menu. 410 // .css('fontSize') returns various results cross-browser, so measure an em dash instead 411 fontsize = $('<li id="menu-fontsize">—</li>'), 412 size = fontsize.attr('style','padding:0;position:absolute;top:-99999em;width:auto;') 413 .appendTo($$)[0].clientWidth; //clientWidth is faster than width() 414 // remove em dash 415 fontsize.remove(); 416 417 // loop through each ul in menu 418 for (var b = 0; b < $ULs.length; b++) { 419 var 420 // cache this ul 421 $ul = $ULs.eq(b); 422 // If a multi-column sub-menu, and only if correctly configured. 423 if (o.megamenu && $ul.hasClass('sf-megamenu') && $ul.find('.sf-megamenu-column').length > 0){ 424 // Look through each column. 425 var $column = $ul.find('div.sf-megamenu-column > ol'), 426 // Overall width. 427 mwWidth = 0; 428 for (var d = 0; d < $column.length; d++){ 429 resize($column.eq(d)); 430 // New column width, in pixels. 431 var colWidth = $column.width(); 432 // Just a trick to convert em unit to px. 433 $column.css({width:colWidth}) 434 // Making column parents the same size. 435 .parents('.sf-megamenu-column').css({width:colWidth}); 436 // Overall width. 437 mwWidth += parseInt(colWidth); 438 } 439 // Resizing the columns container too. 440 $ul.add($ul.find('li.sf-megamenu-wrapper, li.sf-megamenu-wrapper > ol')).css({width:mwWidth}); 441 } 442 else { 443 resize($ul); 444 } 445 } 446 } 447 function resize($ul){ 448 var 449 // get all (li) children of this ul 450 $LIs = $ul.children(), 451 // get all anchor grand-children 452 $As = $LIs.children('a'); 453 // force content to one line and save current float property 454 $LIs.css('white-space','nowrap'); 455 // remove width restrictions and floats so elements remain vertically stacked 456 $ul.add($LIs).add($As).css({float:'none',width:'auto'}); 457 // this ul will now be shrink-wrapped to longest li due to position:absolute 458 // so save its width as ems. 459 var emWidth = $ul.get(0).clientWidth / size; 460 // add more width to ensure lines don't turn over at certain sizes in various browsers 461 emWidth += o.extraWidth; 462 // restrict to at least minWidth and at most maxWidth 463 if (emWidth > o.maxWidth) {emWidth = o.maxWidth;} 464 else if (emWidth < o.minWidth) {emWidth = o.minWidth;} 465 emWidth += 'em'; 466 // set ul to width in ems 467 $ul.css({width:emWidth}); 468 // restore li floats to avoid IE bugs 469 // set li width to full width of this ul 470 // revert white-space to normal 471 $LIs.add($As).css({float:'',width:'',whiteSpace:''}); 472 // update offset position of descendant ul to reflect new width of parent. 473 // set it to 100% in case it isn't already set to this in the CSS 474 for (var c = 0; c < $LIs.length; c++) { 475 var $childUl = $LIs.eq(c).children('ul'); 476 var offsetDirection = $childUl.css('left') !== undefined ? 'left' : 'right'; 477 $childUl.css(offsetDirection,'100%'); 478 } 479 } 480 return this; 481 }; 482 // expose defaults 483 $.fn.supersubs.defaults = { 484 megamenu: true, // define width for multi-column sub-menus and their columns. 485 minWidth: 12, // requires em unit. 486 maxWidth: 27, // requires em unit. 487 extraWidth: 1 // extra width can ensure lines don't sometimes turn over due to slight browser differences in how they round-off values 488 }; 489})(jQuery); // plugin code ends 490; 491/** 492 * @file 493 * The Superfish Drupal Behavior to apply the Superfish jQuery plugin to lists. 494 */ 495 496(function ($) { 497 Drupal.behaviors.superfish = { 498 attach: function (context, settings) { 499 // Take a look at each list to apply Superfish to. 500 $.each(settings.superfish || {}, function(index, options) { 501 // Process all Superfish lists. 502 $('#superfish-' + options.id, context).once('superfish', function() { 503 var list = $(this); 504 505 // Check if we are to apply the Supersubs plug-in to it. 506 if (options.plugins || false) { 507 if (options.plugins.supersubs || false) { 508 list.supersubs(options.plugins.supersubs); 509 } 510 } 511 512 // Apply Superfish to the list. 513 list.superfish(options.sf); 514 515 // Check if we are to apply any other plug-in to it. 516 if (options.plugins || false) { 517 if (options.plugins.touchscreen || false) { 518 list.sftouchscreen(options.plugins.touchscreen); 519 } 520 if (options.plugins.smallscreen || false) { 521 list.sfsmallscreen(options.plugins.smallscreen); 522 } 523 if (options.plugins.supposition || false) { 524 list.supposition(); 525 } 526 if (options.plugins.bgiframe || false) { 527 list.find('ul').bgIframe({opacity:false}); 528 } 529 } 530 }); 531 }); 532 } 533 }; 534})(jQuery);;
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.