PageSourceSearch

https://www.gogolbordello.com/new/wp-content/themes/Gogol-2026/assets/js/foundation.js?ver=6.2.3

js gogolbordello.com collected 2026-10-02 07:40:22 UTC 246,814 bytes, 2,568 lines download raw bytes

1'use strict';var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj;}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};!function($){"use strict";var FOUNDATION_VERSION='6.3.0';// Global Foundation object
2// This is attached to the window, or used as a module for AMD/Browserify
3var Foundation={version:FOUNDATION_VERSION,/**
4   * Stores initialized plugins.
5   */_plugins:{},/**
6   * Stores generated unique ids for plugin instances
7   */_uuids:[],/**
8   * Returns a boolean for RTL support
9   */rtl:function rtl(){return $('html').attr('dir')==='rtl';},/**
10   * Defines a Foundation plugin, adding it to the `Foundation` namespace and the list of plugins to initialize when reflowing.
11   * @param {Object} plugin - The constructor of the plugin.
12   */plugin:function plugin(_plugin,name){// Object key to use when adding to global Foundation object
13// Examples: Foundation.Reveal, Foundation.OffCanvas
14var className=name||functionName(_plugin);// Object key to use when storing the plugin, also used to create the identifying data attribute for the plugin
15// Examples: data-reveal, data-off-canvas
16var attrName=hyphenate(className);// Add to the Foundation object and the plugins list (for reflowing)
17this._plugins[attrName]=this[className]=_plugin;},/**
18   * @function
19   * Populates the _uuids array with pointers to each individual plugin instance.
20   * Adds the `zfPlugin` data-attribute to programmatically created plugins to allow use of $(selector).foundation(method) calls.
21   * Also fires the initialization event for each plugin, consolidating repetitive code.
22   * @param {Object} plugin - an instance of a plugin, usually `this` in context.
23   * @param {String} name - the name of the plugin, passed as a camelCased string.
24   * @fires Plugin#init
25   */registerPlugin:function registerPlugin(plugin,name){var pluginName=name?hyphenate(name):functionName(plugin.constructor).toLowerCase();plugin.uuid=this.GetYoDigits(6,pluginName);if(!plugin.$element.attr('data-'+pluginName)){plugin.$element.attr('data-'+pluginName,plugin.uuid);}if(!plugin.$element.data('zfPlugin')){plugin.$element.data('zfPlugin',plugin);}/**
26           * Fires when the plugin has initialized.
27           * @event Plugin#init
28           */plugin.$element.trigger('init.zf.'+pluginName);this._uuids.push(plugin.uuid);return;},/**
29   * @function
30   * Removes the plugins uuid from the _uuids array.
31   * Removes the zfPlugin data attribute, as well as the data-plugin-name attribute.
32   * Also fires the destroyed event for the plugin, consolidating repetitive code.
33   * @param {Object} plugin - an instance of a plugin, usually `this` in context.
34   * @fires Plugin#destroyed
35   */unregisterPlugin:function unregisterPlugin(plugin){var pluginName=hyphenate(functionName(plugin.$element.data('zfPlugin').constructor));this._uuids.splice(this._uuids.indexOf(plugin.uuid),1);plugin.$element.removeAttr('data-'+pluginName).removeData('zfPlugin')/**
36           * Fires when the plugin has been destroyed.
37           * @event Plugin#destroyed
38           */.trigger('destroyed.zf.'+pluginName);for(var prop in plugin){plugin[prop]=null;//clean up script to prep for garbage collection.
39}return;},/**
40   * @function
41   * Causes one or more active plugins to re-initialize, resetting event listeners, recalculating positions, etc.
42   * @param {String} plugins - optional string of an individual plugin key, attained by calling `$(element).data('pluginName')`, or string of a plugin class i.e. `'dropdown'`
43   * @default If no argument is passed, reflow all currently active plugins.
44   */reInit:function reInit(plugins){var isJQ=plugins instanceof $;try{if(isJQ){plugins.each(function(){$(this).data('zfPlugin')._init();});}else{var type=typeof plugins==='undefined'?'undefined':_typeof(plugins),_this=this,fns={'object':function object(plgs){plgs.forEach(function(p){p=hyphenate(p);$('[data-'+p+']').foundation('_init');});},'string':function string(){plugins=hyphenate(plugins);$('[data-'+plugins+']').foundation('_init');},'undefined':function undefined(){this['object'](Object.keys(_this._plugins));}};fns[type](plugins);}}catch(err){console.error(err);}finally{return plugins;}},/**
45   * returns a random base-36 uid with namespacing
46   * @function
47   * @param {Number} length - number of random base-36 digits desired. Increase for more random strings.
48   * @param {String} namespace - name of plugin to be incorporated in uid, optional.
49   * @default {String} '' - if no plugin name is provided, nothing is appended to the uid.
50   * @returns {String} - unique id
51   */GetYoDigits:function GetYoDigits(length,namespace){length=length||6;return Math.round(Math.pow(36,length+1)-Math.random()*Math.pow(36,length)).toString(36).slice(1)+(namespace?'-'+namespace:'');},/**
52   * Initialize plugins on any elements within `elem` (and `elem` itself) that aren't already initialized.
53   * @param {Object}
vendor: 5,006 bytes, lines 53-85
53 elem - jQuery object containing the element to check inside. Also checks the element itself, unless it's the `document` object.
54   * @param {String|Array} plugins - A list of plugins to initialize. Leave this out to initialize everything.
55   */reflow:function reflow(elem,plugins){// If plugins is undefined, just grab everything
56if(typeof plugins==='undefined'){plugins=Object.keys(this._plugins);}// If plugins is a string, convert it to an array with one item
57else if(typeof plugins==='string'){plugins=[plugins];}var _this=this;// Iterate through each plugin
58$.each(plugins,function(i,name){// Get the current plugin
59var plugin=_this._plugins[name];// Localize the search to all elements inside elem, as well as elem itself, unless elem === document
60var $elem=$(elem).find('[data-'+name+']').addBack('[data-'+name+']');// For each plugin found, initialize it
61$elem.each(function(){var $el=$(this),opts={};// Don't double-dip on plugins
62if($el.data('zfPlugin')){console.warn("Tried to initialize "+name+" on an element that already has a Foundation plugin.");return;}if($el.attr('data-options')){var thing=$el.attr('data-options').split(';').forEach(function(e,i){var opt=e.split(':').map(function(el){return el.trim();});if(opt[0])opts[opt[0]]=parseValue(opt[1]);});}try{$el.data('zfPlugin',new plugin($(this),opts));}catch(er){console.error(er);}finally{return;}});});},getFnName:functionName,transitionend:function transitionend($elem){var transitions={'transition':'transitionend','WebkitTransition':'webkitTransitionEnd','MozTransition':'transitionend','OTransition':'otransitionend'};var elem=document.createElement('div'),end;for(var t in transitions){if(typeof elem.style[t]!=='undefined'){end=transitions[t];}}if(end){return end;}else{end=setTimeout(function(){$elem.triggerHandler('transitionend',[$elem]);},1);return'transitionend';}}};Foundation.util={/**
63   * Function for applying a debounce effect to a function call.
64   * @function
65   * @param {Function} func - Function to be called at end of timeout.
66   * @param {Number} delay - Time in ms to delay the call of `func`.
67   * @returns function
68   */throttle:function throttle(func,delay){var timer=null;return function(){var context=this,args=arguments;if(timer===null){timer=setTimeout(function(){func.apply(context,args);timer=null;},delay);}};}};// TODO: consider not making this a jQuery function
69// TODO: need way to reflow vs. re-initialize
70/**
71 * The Foundation jQuery method.
72 * @param {String|Array} method - An action to perform on the current jQuery object.
73 */var foundation=function foundation(method){var type=typeof method==='undefined'?'undefined':_typeof(method),$meta=$('meta.foundation-mq'),$noJS=$('.no-js');if(!$meta.length){$('<meta class="foundation-mq">').appendTo(document.head);}if($noJS.length){$noJS.removeClass('no-js');}if(type==='undefined'){//needs to initialize the Foundation object, or an individual plugin.
74Foundation.MediaQuery._init();Foundation.reflow(this);}else if(type==='string'){//an individual method to invoke on a plugin or group of plugins
75var args=Array.prototype.slice.call(arguments,1);//collect all the arguments, if necessary
76var plugClass=this.data('zfPlugin');//determine the class of plugin
77if(plugClass!==undefined&&plugClass[method]!==undefined){//make sure both the class and method exist
78if(this.length===1){//if there's only one, call it directly.
79plugClass[method].apply(plugClass,args);}else{this.each(function(i,el){//otherwise loop through the jQuery collection and invoke the method on each
80plugClass[method].apply($(el).data('zfPlugin'),args);});}}else{//error for no class or no method
81throw new ReferenceError("We're sorry, '"+method+"' is not an available method for "+(plugClass?functionName(plugClass):'this element')+'.');}}else{//error for invalid argument type
82throw new TypeError('We\'re sorry, '+type+' is not a valid parameter. You must use a string representing the method you wish to invoke.');}return this;};window.Foundation=Foundation;$.fn.foundation=foundation;// Polyfill for requestAnimationFrame
83(function(){if(!Date.now||!window.Date.now)window.Date.now=Date.now=function(){return new Date().getTime();};var vendors=['webkit','moz'];for(var i=0;i<vendors.length&&!window.requestAnimationFrame;++i){var vp=vendors[i];window.requestAnimationFrame=window[vp+'RequestAnimationFrame'];window.cancelAnimationFrame=window[vp+'CancelAnimationFrame']||window[vp+'CancelRequestAnimationFrame'];}if(/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent)||!window.requestAnimationFrame||!window.cancelAnimationFrame){var lastTime=0;window.requestAnimationFrame=function(callback){var now=Date.now();var nextTime=Math.max(lastTime+16,now);return setTimeout(function(){callback(lastTime=nextTime);},nextTime-now);};window.cancelAnimationFrame=clearTimeout;}/**
84   * Polyfill for performance.now, required by rAF
85   */if(!window.performance||!window.performance.now){window.performance={start:Date.now(),now:function now(){return Date.now()-this.start;}};}})();
85if(!Function.prototype.bind){Function.prototype.bind=function(oThis){if(typeof this!=='function'){// closest thing possible to the ECMAScript 5
86// internal IsCallable function
87throw new TypeError('Function.prototype.bind - what is trying to be bound is not callable');}var aArgs=Array.prototype.slice.call(arguments,1),fToBind=this,fNOP=function fNOP(){},fBound=function fBound(){return fToBind.apply(this instanceof fNOP?this:oThis,aArgs.concat(Array.prototype.slice.call(arguments)));};if(this.prototype){// native functions don't have a prototype
88fNOP.prototype=this.prototype;}fBound.prototype=new fNOP();return fBound;};}// Polyfill to get the name of a function in IE9
89function functionName(fn){if(Function.prototype.name===undefined){var funcNameRegex=/function\s([^(]{1,})\(/;var results=funcNameRegex.exec(fn.toString());return results&&results.length>1?results[1].trim():"";}else if(fn.prototype===undefined){return fn.constructor.name;}else{return fn.prototype.constructor.name;}}function parseValue(str){if('true'===str)return true;else if('false'===str)return false;else if(!isNaN(str*1))return parseFloat(str);return str;}// Convert PascalCase to kebab-case
90// Thank you: http://stackoverflow.com/a/8955580
91function hyphenate(str){return str.replace(/([a-z])([A-Z])/g,'$1-$2').toLowerCase();}}(jQuery);
92'use strict';!function($){Foundation.Box={ImNotTouchingYou:ImNotTouchingYou,GetDimensions:GetDimensions,GetOffsets:GetOffsets};/**
93 * Compares the dimensions of an element to a container and determines collision events with container.
94 * @function
95 * @param {jQuery} element - jQuery object to test for collisions.
96 * @param {jQuery} parent - jQuery object to use as bounding container.
97 * @param {Boolean} lrOnly - set to true to check left and right values only.
98 * @param {Boolean} tbOnly - set to true to check top and bottom values only.
99 * @default if no parent object passed, detects collisions with `window`.
100 * @returns {Boolean} - true if collision free, false if a collision in any direction.
101 */function ImNotTouchingYou(element,parent,lrOnly,tbOnly){var eleDims=GetDimensions(element),top,bottom,left,right;if(parent){var parDims=GetDimensions(parent);bottom=eleDims.offset.top+eleDims.height<=parDims.height+parDims.offset.top;top=eleDims.offset.top>=parDims.offset.top;left=eleDims.offset.left>=parDims.offset.left;right=eleDims.offset.left+eleDims.width<=parDims.width+parDims.offset.left;}else{bottom=eleDims.offset.top+eleDims.height<=eleDims.windowDims.height+eleDims.windowDims.offset.top;top=eleDims.offset.top>=eleDims.windowDims.offset.top;left=eleDims.offset.left>=eleDims.windowDims.offset.left;right=eleDims.offset.left+eleDims.width<=eleDims.windowDims.width;}var allDirs=[bottom,top,left,right];if(lrOnly){return left===right===true;}if(tbOnly){return top===bottom===true;}return allDirs.indexOf(false)===-1;};/**
102 * Uses native methods to return an object of dimension values.
103 * @function
104 * @param {jQuery || HTML} element - jQuery object or DOM element for which to get the dimensions. Can be any element other that document or window.
105 * @returns {Object} - nested object of integer pixel values
106 * TODO - if element is window, return only those values.
107 */function GetDimensions(elem,test){elem=elem.length?elem[0]:elem;if(elem===window||elem===document){throw new Error("I'm sorry, Dave. I'm afraid I can't do that.");}var rect=elem.getBoundingClientRect(),parRect=elem.parentNode.getBoundingClientRect(),winRect=document.body.getBoundingClientRect(),winY=window.pageYOffset,winX=window.pageXOffset;return{width:rect.width,height:rect.height,offset:{top:rect.top+winY,left:rect.left+winX},parentDims:{width:parRect.width,height:parRect.height,offset:{top:parRect.top+winY,left:parRect.left+winX}},windowDims:{width:winRect.width,height:winRect.height,offset:{top:winY,left:winX}}};}/**
108 * Returns an object of top and left integer pixel values for dynamically rendered elements,
109 * such as: Tooltip, Reveal, and Dropdown
110 * @function
111 * @param {jQuery} element - jQuery object for the element being positioned.
112 * @param {jQuery} anchor - jQuery object for the element's anchor point.
113 * @param {String} position - a string relating to the desired position of the element, relative to it's anchor
114 * @param {Number} vOffset - integer pixel value of desired vertical separation between anchor and element.
115 * @param {Number} hOffset - integer pixel value of desired horizontal separation between anchor and element.
116 * @param {Boolean} isOverflow - if a collision event is detected, sets to true to default the element to full width - any desired offset.
117 * TODO alter/rewrite to work with `em` values as well/instead of pixels
118 */function GetOffsets(element,anchor,position,vOffset,hOffset,isOverflow){var $eleDims=GetDimensions(element),$anchorDims=anchor?GetDimensions(anchor):null;switch(position){case'top':return{left:Foundation.rtl()?$anchorDims.offset.left-$eleDims.width+$anchorDims.width:$anchorDims.offset.left,top:$anchorDims.offset.top-($eleDims.height+vOffset)};break;case'left':return{left:$anchorDims.offset.left-($eleDims.width+hOffset),top:$anchorDims.offset.top};break;
118case'right':return{left:$anchorDims.offset.left+$anchorDims.width+hOffset,top:$anchorDims.offset.top};break;case'center top':return{left:$anchorDims.offset.left+$anchorDims.width/2-$eleDims.width/2,top:$anchorDims.offset.top-($eleDims.height+vOffset)};break;case'center bottom':return{left:isOverflow?hOffset:$anchorDims.offset.left+$anchorDims.width/2-$eleDims.width/2,top:$anchorDims.offset.top+$anchorDims.height+vOffset};break;case'center left':return{left:$anchorDims.offset.left-($eleDims.width+hOffset),top:$anchorDims.offset.top+$anchorDims.height/2-$eleDims.height/2};break;case'center right':return{left:$anchorDims.offset.left+$anchorDims.width+hOffset+1,top:$anchorDims.offset.top+$anchorDims.height/2-$eleDims.height/2};break;case'center':return{left:$eleDims.windowDims.offset.left+$eleDims.windowDims.width/2-$eleDims.width/2,top:$eleDims.windowDims.offset.top+$eleDims.windowDims.height/2-$eleDims.height/2};break;case'reveal':return{left:($eleDims.windowDims.width-$eleDims.width)/2,top:$eleDims.windowDims.offset.top+vOffset};case'reveal full':return{left:$eleDims.windowDims.offset.left,top:$eleDims.windowDims.offset.top};break;case'left bottom':return{left:$anchorDims.offset.left,top:$anchorDims.offset.top+$anchorDims.height+vOffset};break;case'right bottom':return{left:$anchorDims.offset.left+$anchorDims.width+hOffset-$eleDims.width,top:$anchorDims.offset.top+$anchorDims.height+vOffset};break;default:return{left:Foundation.rtl()?$anchorDims.offset.left-$eleDims.width+$anchorDims.width:$anchorDims.offset.left+hOffset,top:$anchorDims.offset.top+$anchorDims.height+vOffset};}}}(jQuery);
119/*******************************************
120 *                                         *
121 * This util was created by Marius Olbertz *
122 * Please thank Marius on GitHub /owlbertz *
123 * or the web http://www.mariusolbertz.de/ *
124 *                                         *
125 ******************************************/'use strict';!function($){var keyCodes={9:'TAB',13:'ENTER',27:'ESCAPE',32:'SPACE',37:'ARROW_LEFT',38:'ARROW_UP',39:'ARROW_RIGHT',40:'ARROW_DOWN'};var commands={};var Keyboard={keys:getKeyCodes(keyCodes),/**
126   * Parses the (keyboard) event and returns a String that represents its key
127   * Can be used like Foundation.parseKey(event) === Foundation.keys.SPACE
128   * @param {Event} event - the event generated by the event handler
129   * @return String key - String that represents the key pressed
130   */parseKey:function parseKey(event){var key=keyCodes[event.which||event.keyCode]||String.fromCharCode(event.which).toUpperCase();// Remove un-printable characters, e.g. for `fromCharCode` calls for CTRL only events
131key=key.replace(/\W+/,'');if(event.shiftKey)key='SHIFT_'+key;if(event.ctrlKey)key='CTRL_'+key;if(event.altKey)key='ALT_'+key;// Remove trailing underscore, in case only modifiers were used (e.g. only `CTRL_ALT`)
132key=key.replace(/_$/,'');return key;},/**
133   * Handles the given (keyboard) event
134   * @param {Event} event - the event generated by the event handler
135   * @param {String} component - Foundation component's name, e.g. Slider or Reveal
136   * @param {Objects} functions - collection of functions that are to be executed
137   */handleKey:function handleKey(event,component,functions){var commandList=commands[component],keyCode=this.parseKey(event),cmds,command,fn;if(!commandList)return console.warn('Component not defined!');if(typeof commandList.ltr==='undefined'){// this component does not differentiate between ltr and rtl
138cmds=commandList;// use plain list
139}else{// merge ltr and rtl: if document is rtl, rtl overwrites ltr and vice versa
140if(Foundation.rtl())cmds=$.extend({},commandList.ltr,commandList.rtl);else cmds=$.extend({},commandList.rtl,commandList.ltr);}command=cmds[keyCode];fn=functions[command];if(fn&&typeof fn==='function'){// execute function  if exists
141var returnValue=fn.apply();if(functions.handled||typeof functions.handled==='function'){// execute function when event was handled
142functions.handled(returnValue);}}else{if(functions.unhandled||typeof functions.unhandled==='function'){// execute function when event was not handled
143functions.unhandled();}}},/**
144   * Finds all focusable elements within the given `$element`
145   * @param {jQuery} $element - jQuery object to search within
146   * @return {jQuery} $focusable - all focusable elements within `$element`
147   */findFocusable:function findFocusable($element){if(!$element){return false;}
147return $element.find('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable]').filter(function(){if(!$(this).is(':visible')||$(this).attr('tabindex')<0){return false;}//only have visible elements and those that have a tabindex greater or equal 0
148return true;});},/**
149   * Returns the component name name
150   * @param {Object} component - Foundation component, e.g. Slider or Reveal
151   * @return String componentName
152   */register:function register(componentName,cmds){commands[componentName]=cmds;},/**
153   * Traps the focus in the given element.
154   * @param  {jQuery} $element  jQuery object to trap the foucs into.
155   */trapFocus:function trapFocus($element){var $focusable=Foundation.Keyboard.findFocusable($element),$firstFocusable=$focusable.eq(0),$lastFocusable=$focusable.eq(-1);$element.on('keydown.zf.trapfocus',function(event){if(event.target===$lastFocusable[0]&&Foundation.Keyboard.parseKey(event)==='TAB'){event.preventDefault();$firstFocusable.focus();}else if(event.target===$firstFocusable[0]&&Foundation.Keyboard.parseKey(event)==='SHIFT_TAB'){event.preventDefault();$lastFocusable.focus();}});},/**
156   * Releases the trapped focus from the given element.
157   * @param  {jQuery} $element  jQuery object to release the focus for.
158   */releaseFocus:function releaseFocus($element){$element.off('keydown.zf.trapfocus');}};/*
159 * Constants for easier comparing.
160 * Can be used like Foundation.parseKey(event) === Foundation.keys.SPACE
161 */function getKeyCodes(kcs){var k={};for(var kc in kcs){k[kcs[kc]]=kcs[kc];}return k;}Foundation.Keyboard=Keyboard;}(jQuery);
162'use strict';var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj;}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};!function($){// Default set of media queries
163var defaultQueries={'default':'only screen',landscape:'only screen and (orientation: landscape)',portrait:'only screen and (orientation: portrait)',retina:'only screen and (-webkit-min-device-pixel-ratio: 2),'+'only screen and (min--moz-device-pixel-ratio: 2),'+'only screen and (-o-min-device-pixel-ratio: 2/1),'+'only screen and (min-device-pixel-ratio: 2),'+'only screen and (min-resolution: 192dpi),'+'only screen and (min-resolution: 2dppx)'};var MediaQuery={queries:[],current:'',/**
164   * Initializes the media query helper, by extracting the breakpoint list from the CSS and activating the breakpoint watcher.
165   * @function
166   * @private
167   */_init:function _init(){var self=this;var extractedStyles=$('.foundation-mq').css('font-family');var namedQueries;namedQueries=parseStyleToObject(extractedStyles);for(var key in namedQueries){if(namedQueries.hasOwnProperty(key)){self.queries.push({name:key,value:'only screen and (min-width: '+namedQueries[key]+')'});}}this.current=this._getCurrentSize();this._watcher();},/**
168   * Checks if the screen is at least as wide as a breakpoint.
169   * @function
170   * @param {String} size - Name of the breakpoint to check.
171   * @returns {Boolean} `true` if the breakpoint matches, `false` if it's smaller.
172   */atLeast:function atLeast(size){var query=this.get(size);if(query){return window.matchMedia(query).matches;}return false;},/**
173   * Checks if the screen matches to a breakpoint.
174   * @function
175   * @param {String} size - Name of the breakpoint to check, either 'small only' or 'small'. Omitting 'only' falls back to using atLeast() method.
176   * @returns {Boolean} `true` if the breakpoint matches, `false` if it does not.
177   */is:function is(size){size=size.trim().split(' ');if(size.length>1&&size[1]==='only'){if(size[0]===this._getCurrentSize())return true;}else{return this.atLeast(size[0]);}return false;},/**
178   * Gets the media query of a breakpoint.
179   * @function
180   * @param {String} size - Name of the breakpoint to get.
181   * @returns {String|null} - The media query of the breakpoint, or `null` if the breakpoint doesn't exist.
182   */get:function get(size){for(var i in this.queries){if(this.queries.hasOwnProperty(i)){var query=this.queries[i];if(size===query.name)return query.value;}}return null;},/**
183   * Gets the current breakpoint name by testing every breakpoint and returning the last one to match (the biggest one).
184   * @function
185   * @private
186   * @returns {String} Name of the current breakpoint.
187   */_getCurrentSize:function _getCurrentSize(){var matched;for(var i=0;i<this.queries.length;i++){var query=this.queries[i];if(window.matchMedia(query.value).matches){matched=query;}}if((typeof matched==='undefined'?'undefined':_typeof(matched))==='object'){return matched.name;}else{return matched;}},/**
188   * Activates the breakpoint watcher, which fires an event on the window whenever the breakpoint changes.
189   * @function
190   * @private
191   */_watcher:function _watcher(){var _this=this;$(window).on('resize.zf.mediaquery',function(){var newSize=_this._getCurrentSize(),currentSize=_this.current;if(newSize!==currentSize){// Change the current media query
vendor: 7,885 bytes, lines 192-251
192_this.current=newSize;// Broadcast the media query change on the window
193$(window).trigger('changed.zf.mediaquery',[newSize,currentSize]);}});}};Foundation.MediaQuery=MediaQuery;// matchMedia() polyfill - Test a CSS media type/query in JS.
194// Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. Dual MIT/BSD license
195window.matchMedia||(window.matchMedia=function(){'use strict';// For browsers that support matchMedium api such as IE 9 and webkit
196var styleMedia=window.styleMedia||window.media;// For those that don't support matchMedium
197if(!styleMedia){var style=document.createElement('style'),script=document.getElementsByTagName('script')[0],info=null;style.type='text/css';style.id='matchmediajs-test';script&&script.parentNode&&script.parentNode.insertBefore(style,script);// 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers
198info='getComputedStyle'in window&&window.getComputedStyle(style,null)||style.currentStyle;styleMedia={matchMedium:function matchMedium(media){var text='@media '+media+'{ #matchmediajs-test { width: 1px; } }';// 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers
199if(style.styleSheet){style.styleSheet.cssText=text;}else{style.textContent=text;}// Test if media query is true or false
200return info.width==='1px';}};}return function(media){return{matches:styleMedia.matchMedium(media||'all'),media:media||'all'};};}());// Thank you: https://github.com/sindresorhus/query-string
201function parseStyleToObject(str){var styleObject={};if(typeof str!=='string'){return styleObject;}str=str.trim().slice(1,-1);// browsers re-quote string style values
202if(!str){return styleObject;}styleObject=str.split('&').reduce(function(ret,param){var parts=param.replace(/\+/g,' ').split('=');var key=parts[0];var val=parts[1];key=decodeURIComponent(key);// missing `=` should be `null`:
203// http://w3.org/TR/2012/WD-url-20120524/#collect-url-parameters
204val=val===undefined?null:decodeURIComponent(val);if(!ret.hasOwnProperty(key)){ret[key]=val;}else if(Array.isArray(ret[key])){ret[key].push(val);}else{ret[key]=[ret[key],val];}return ret;},{});return styleObject;}Foundation.MediaQuery=MediaQuery;}(jQuery);
205'use strict';!function($){/**
206 * Motion module.
207 * @module foundation.motion
208 */var initClasses=['mui-enter','mui-leave'];var activeClasses=['mui-enter-active','mui-leave-active'];var Motion={animateIn:function animateIn(element,animation,cb){animate(true,element,animation,cb);},animateOut:function animateOut(element,animation,cb){animate(false,element,animation,cb);}};function Move(duration,elem,fn){var anim,prog,start=null;// console.log('called');
209if(duration===0){fn.apply(elem);elem.trigger('finished.zf.animate',[elem]).triggerHandler('finished.zf.animate',[elem]);return;}function move(ts){if(!start)start=ts;// console.log(start, ts);
210prog=ts-start;fn.apply(elem);if(prog<duration){anim=window.requestAnimationFrame(move,elem);}else{window.cancelAnimationFrame(anim);elem.trigger('finished.zf.animate',[elem]).triggerHandler('finished.zf.animate',[elem]);}}anim=window.requestAnimationFrame(move);}/**
211 * Animates an element in or out using a CSS transition class.
212 * @function
213 * @private
214 * @param {Boolean} isIn - Defines if the animation is in or out.
215 * @param {Object} element - jQuery or HTML object to animate.
216 * @param {String} animation - CSS class to use.
217 * @param {Function} cb - Callback to run when animation is finished.
218 */function animate(isIn,element,animation,cb){element=$(element).eq(0);if(!element.length)return;var initClass=isIn?initClasses[0]:initClasses[1];var activeClass=isIn?activeClasses[0]:activeClasses[1];// Set up the animation
219reset();element.addClass(animation).css('transition','none');requestAnimationFrame(function(){element.addClass(initClass);if(isIn)element.show();});// Start the animation
220requestAnimationFrame(function(){element[0].offsetWidth;element.css('transition','').addClass(activeClass);});// Clean up the animation when it finishes
221element.one(Foundation.transitionend(element),finish);// Hides the element (for out animations), resets the element, and runs a callback
222function finish(){if(!isIn)element.hide();reset();if(cb)cb.apply(element);}// Resets transitions and removes motion-specific classes
223function reset(){element[0].style.transitionDuration=0;element.removeClass(initClass+' '+activeClass+' '+animation);}}Foundation.Move=Move;Foundation.Motion=Motion;}(jQuery);
224'use strict';!function($){var Nest={Feather:function Feather(menu){var type=arguments.length>1&&arguments[1]!==undefined?arguments[1]:'zf';menu.attr('role','menubar');var items=menu.find('li').attr({'role':'menuitem'}),subMenuClass='is-'+type+'-submenu',subItemClass=subMenuClass+'-item',hasSubClass='is-'+type+'-submenu-parent';items.each(function(){var $item=$(this),$sub=$item.children('ul');if($sub.length){$item.addClass(hasSubClass).attr({'aria-haspopup':true,'aria-label':$item.children('a:first').text()});// Note:  Drilldowns behave differently in how they hide, and so need
225// additional attributes.  We should look if this possibly over-generalized
226// utility (Nest) is appropriate when we rework menus in 6.4
227if(type==='drilldown'){$item.attr({'aria-expanded':false});}$sub.addClass('submenu '+subMenuClass).attr({'data-submenu':'','role':'menu'});if(type==='drilldown'){$sub.attr({'aria-hidden':true});}}if($item.parent('[data-submenu]').length){$item.addClass('is-submenu-item '+subItemClass);}});return;},Burn:function Burn(menu,type){var//items = menu.find('li'),
228subMenuClass='is-'+type+'-submenu',subItemClass=subMenuClass+'-item',hasSubClass='is-'+type+'-submenu-parent';menu.find('>li, .menu, .menu > li').removeClass(subMenuClass+' '+subItemClass+' '+hasSubClass+' is-submenu-item submenu is-active').removeAttr('data-submenu').css('display','');// console.log(      menu.find('.' + subMenuClass + ', .' + subItemClass + ', .has-submenu, .is-submenu-item, .submenu, [data-submenu]')
229//           .removeClass(subMenuClass + ' ' + subItemClass + ' has-submenu is-submenu-item submenu')
230//           .removeAttr('data-submenu'));
231// items.each(function(){
232//   var $item = $(this),
233//       $sub = $item.children('ul');
234//   if($item.parent('[data-submenu]').length){
235//     $item.removeClass('is-submenu-item ' + subItemClass);
236//   }
237//   if($sub.length){
238//     $item.removeClass('has-submenu');
239//     $sub.removeClass('submenu ' + subMenuClass).removeAttr('data-submenu');
240//   }
241// });
242}};Foundation.Nest=Nest;}(jQuery);
243'use strict';!function($){function Timer(elem,options,cb){var _this=this,duration=options.duration,//options is an object for easily adding features later.
244nameSpace=Object.keys(elem.data())[0]||'timer',remain=-1,start,timer;this.isPaused=false;this.restart=function(){remain=-1;clearTimeout(timer);this.start();};this.start=function(){this.isPaused=false;// if(!elem.data('paused')){ return false; }//maybe implement this sanity check if used for other things.
245clearTimeout(timer);remain=remain<=0?duration:remain;elem.data('paused',false);start=Date.now();timer=setTimeout(function(){if(options.infinite){_this.restart();//rerun the timer.
246}if(cb&&typeof cb==='function'){cb();}},remain);elem.trigger('timerstart.zf.'+nameSpace);};this.pause=function(){this.isPaused=true;//if(elem.data('paused')){ return false; }//maybe implement this sanity check if used for other things.
247clearTimeout(timer);elem.data('paused',true);var end=Date.now();remain=remain-(end-start);elem.trigger('timerpaused.zf.'+nameSpace);};}/**
248 * Runs a callback function when images are fully loaded.
249 * @param {Object} images - Image(s) to check if loaded.
250 * @param {Func} callback - Function to execute when image is fully loaded.
251 */function onImagesLoaded(images,callback){var self=this,unloaded=images.length;if(unloaded===0){callback();}images.each(function(){// Check if image is loaded
252if(this.complete||this.readyState===4||this.readyState==='complete'){singleImageLoaded();}// Force load the image
253else{// fix for IE. See https://css-tricks.com/snippets/jquery/fixing-load-in-ie-for-cached-images/
254var src=$(this).attr('src');$(this).attr('src',src+'?'+new Date().getTime());$(this).one('load',function(){singleImageLoaded();});}});function singleImageLoaded(){unloaded--;if(unloaded===0){callback();}}}Foundation.Timer=Timer;Foundation.onImagesLoaded=onImagesLoaded;}(jQuery);
255'use strict';//**************************************************
256//**Work inspired by multiple jquery swipe plugins**
257//**Done by Yohai Ararat ***************************
258//**************************************************
259(function($){$.spotSwipe={version:'1.0.0',enabled:'ontouchstart'in document.documentElement,preventDefault:false,moveThreshold:75,timeThreshold:200};var startPosX,startPosY,startTime,elapsedTime,isMoving=false;function onTouchEnd(){//  alert(this);
260this.removeEventListener('touchmove',onTouchMove);this.removeEventListener('touchend',onTouchEnd);isMoving=false;}function onTouchMove(e){if($.spotSwipe.preventDefault){e.preventDefault();}if(isMoving){var x=e.touches[0].pageX;var y=e.touches[0].pageY;var dx=startPosX-x;var dy=startPosY-y;var dir;elapsedTime=new Date().getTime()-startTime;if(Math.abs(dx)>=$.spotSwipe.moveThreshold&&elapsedTime<=$.spotSwipe.timeThreshold){dir=dx>0?'left':'right';}// else if(Math.abs(dy) >= $.spotSwipe.moveThreshold && elapsedTime <= $.spotSwipe.timeThreshold) {
261//   dir = dy > 0 ? 'down' : 'up';
262// }
263if(dir){e.preventDefault();onTouchEnd.call(this);$(this).trigger('swipe',dir).trigger('swipe'+dir);}}}function onTouchStart(e){if(e.touches.length==1){startPosX=e.touches[0].pageX;startPosY=e.touches[0].pageY;isMoving=true;startTime=new Date().getTime();this.addEventListener('touchmove',onTouchMove,false);this.addEventListener('touchend',onTouchEnd,false);}}function init(){this.addEventListener&&this.addEventListener('touchstart',onTouchStart,false);}function teardown(){this.removeEventListener('touchstart',onTouchStart);}$.event.special.swipe={setup:init};$.each(['left','up','down','right'],function(){$.event.special['swipe'+this]={setup:function setup(){$(this).on('swipe',$.noop);}};});})(jQuery);/****************************************************
264 * Method for adding psuedo drag events to elements *
265 ***************************************************/!function($){$.fn.addTouch=function(){this.each(function(i,el){$(el).bind('touchstart touchmove touchend touchcancel',function(){//we pass the original event object because the jQuery event
266//object is normalized to w3c specs and does not provide the TouchList
267handleTouch(event);});});var handleTouch=function handleTouch(event){var touches=event.changedTouches,first=touches[0],eventTypes={touchstart:'mousedown',touchmove:'mousemove',touchend:'mouseup'},type=eventTypes[event.type],simulatedEvent;if('MouseEvent'in window&&typeof window.MouseEvent==='function'){simulatedEvent=new window.MouseEvent(type,{'bubbles':true,'cancelable':true,'screenX':first.screenX,'screenY':first.screenY,'clientX':first.clientX,'clientY':first.clientY});}else{simulatedEvent=document.createEvent('MouseEvent');simulatedEvent.initMouseEvent(type,true,true,window,1,first.screenX,first.screenY,first.clientX,first.clientY,false,false,false,false,0/*left*/,null);}first.target.dispatchEvent(simulatedEvent);};};}(jQuery);//**********************************
268//**From the jQuery Mobile Library**
269//**need to recreate functionality**
270//**and try to improve if possible**
271//**********************************
272/* Removing the jQuery function ****
273************************************
274
275(function( $, window, undefined ) {
276
277	var $document = $( document ),
278		// supportTouch = $.mobile.support.touch,
279		touchStartEvent = 'touchstart'//supportTouch ? "touchstart" : "mousedown",
280		touchStopEvent = 'touchend'//supportTouch ? "touchend" : "mouseup",
281		touchMoveEvent = 'touchmove'//supportTouch ? "touchmove" : "mousemove";
282
283	// setup new event shortcuts
284	$.each( ( "touchstart touchmove touchend " +
285		"swipe swipeleft swiperight" ).split( " " ), function( i, name ) {
286
287		$.fn[ name ] = function( fn ) {
288			return fn ? this.bind( name, fn ) : this.trigger( name );
289		};
290
291		// jQuery < 1.8
292		if ( $.attrFn ) {
293			$.attrFn[ name ] = true;
294		}
295	});
296
297	function triggerCustomEvent( obj, eventType, event, bubble ) {
298		var originalType = event.type;
299		event.type = eventType;
300		if ( bubble ) {
301			$.event.trigger( event, undefined, obj );
302		} else {
303			$.event.dispatch.call( obj, event );
304		}
305		event.type = originalType;
306	}
307
308	// also handles taphold
309
310	// Also handles swipeleft, swiperight
311	$.event.special.swipe = {
312
313		// More than this horizontal displacement, and we will suppress scrolling.
314		scrollSupressionThreshold: 30,
315
316		// More time than this, and it isn't a swipe.
317		durationThreshold: 1000,
318
319		// Swipe horizontal displacement must be more than this.
320		horizontalDistanceThreshold: window.devicePixelRatio >= 2 ? 15 : 30,
321
322		// Swipe vertical displacement must be less than this.
323		verticalDistanceThreshold: window.devicePixelRatio >= 2 ? 15 : 30,
324
325		getLocation: function ( event ) {
326			var winPageX = window.pageXOffset,
327				winPageY = window.pageYOffset,
328				x = event.clientX,
329				y = event.clientY;
330
331			if ( event.pageY === 0 && Math.floor( y ) > Math.floor( event.pageY ) ||
332				event.pageX === 0 && Math.floor( x ) > Math.floor( event.pageX ) ) {
333
334				// iOS4 clientX/clientY have the value that should have been
335				// in pageX/pageY. While pageX/page/ have the value 0
336				x = x - winPageX;
337				y = y - winPageY;
338			} else if ( y < ( event.pageY - winPageY) || x < ( event.pageX - winPageX ) ) {
339
340				// Some Android browsers have totally bogus values for clientX/Y
341				// when scrolling/zooming a page. Detectable since clientX/clientY
342				// should never be smaller than pageX/pageY minus page scroll
343				x = event.pageX - winPageX;
344				y = event.pageY - winPageY;
345			}
346
347			return {
348				x: x,
349				y: y
350			};
351		},
352
353		start: function( event ) {
354			var data = event.originalEvent.touches ?
355					event.originalEvent.touches[ 0 ] : event,
356				location = $.event.special.swipe.getLocation( data );
357			return {
358						time: ( new Date() ).getTime(),
359						coords: [ location.x, location.y ],
360						origin: $( event.target )
361					};
362		},
363
364		stop: function( event ) {
365			var data = event.originalEvent.touches ?
366					event.originalEvent.touches[ 0 ] : event,
367				location = $.event.special.swipe.getLocation( data );
368			return {
369						time: ( new Date() ).getTime(),
370						coords: [ location.x, location.y ]
371					};
372		},
373
374		handleSwipe: function( start, stop, thisObject, origTarget ) {
375			if ( stop.time - start.time < $.event.special.swipe.durationThreshold &&
376				Math.abs( start.coords[ 0 ] - stop.coords[ 0 ] ) > $.event.special.swipe.horizontalDistanceThreshold &&
377				Math.abs( start.coords[ 1 ] - stop.coords[ 1 ] ) < $.event.special.swipe.verticalDistanceThreshold ) {
378				var direction = start.coords[0] > stop.coords[ 0 ] ? "swipeleft" : "swiperight";
379
380				triggerCustomEvent( thisObject, "swipe", $.Event( "swipe", { target: origTarget, swipestart: start, swipestop: stop }), true );
381				triggerCustomEvent( thisObject, direction,$.Event( direction, { target: origTarget, swipestart: start, swipestop: stop } ), true );
382				return true;
383			}
384			return false;
385
386		},
387
388		// This serves as a flag to ensure that at most one swipe event event is
389		// in work at any given time
390		eventInProgress: false,
391
392		setup: function() {
393			var events,
394				thisObject = this,
395				$this = $( thisObject ),
396				context = {};
397
398			// Retrieve the events data for this element and add the swipe context
399			events = $.data( this, "mobile-events" );
400			if ( !events ) {
401				events = { length: 0 };
402				$.data( this, "mobile-events", events );
403			}
404			events.length++;
405			events.swipe = context;
406
407			context.start = function( event ) {
408
409				// Bail if we're already working on a swipe event
410				if ( $.event.special.swipe.eventInProgress ) {
411					return;
412				}
413				$.event.special.swipe.eventInProgress = true;
414
415				var stop,
416					start = $.event.special.swipe.start( event ),
417					origTarget = event.target,
418					emitted = false;
419
420				context.move = function( event ) {
421					if ( !start || event.isDefaultPrevented() ) {
422						return;
423					}
424
425					stop = $.event.special.swipe.stop( event );
426					if ( !emitted ) {
427						emitted = $.event.special.swipe.handleSwipe( start, stop, thisObject, origTarget );
428						if ( emitted ) {
429
430							// Reset the context to make way for the next swipe event
431							$.event.special.swipe.eventInProgress = false;
432						}
433					}
434					// prevent scrolling
435					if ( Math.abs( start.coords[ 0 ] - stop.coords[ 0 ] ) > $.event.special.swipe.scrollSupressionThreshold ) {
436						event.preventDefault();
437					}
438				};
439
440				context.stop = function() {
441						emitted = true;
442
443						// Reset the context to make way for the next swipe event
444						$.event.special.swipe.eventInProgress = false;
445						$document.off( touchMoveEvent, context.move );
446						context.move = null;
447				};
448
449				$document.on( touchMoveEvent, context.move )
450					.one( touchStopEvent, context.stop );
451			};
452			$this.on( touchStartEvent, context.start );
453		},
454
455		teardown: function() {
456			var events, context;
457
458			events = $.data( this, "mobile-events" );
459			if ( events ) {
460				context = events.swipe;
461				delete events.swipe;
462				events.length--;
463				if ( events.length === 0 ) {
464					$.removeData( this, "mobile-events" );
465				}
466			}
467
468			if ( context ) {
469				if ( context.start ) {
470					$( this ).off( touchStartEvent, context.start );
471				}
472				if ( context.move ) {
473					$document.off( touchMoveEvent, context.move );
474				}
475				if ( context.stop ) {
476					$document.off( touchStopEvent, context.stop );
477				}
478			}
479		}
480	};
481	$.each({
482		swipeleft: "swipe.left",
483		swiperight: "swipe.right"
484	}, function( event, sourceEvent ) {
485
486		$.event.special[ event ] = {
487			setup: function() {
488				$( this ).bind( sourceEvent, $.noop );
489			},
490			teardown: function() {
491				$( this ).unbind( sourceEvent );
492			}
493		};
494	});
495})( jQuery, this );
496*/
497'use strict';var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj;}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};!function($){var MutationObserver=function(){var prefixes=['WebKit','Moz','O','Ms',''];for(var i=0;i<prefixes.length;i++){if(prefixes[i]+'MutationObserver'in window){return window[prefixes[i]+'MutationObserver'];}}return false;}();var triggers=function triggers(el,type){el.data(type).split(' ').forEach(function(id){$('#'+id)[type==='close'?'trigger':'triggerHandler'](type+'.zf.trigger',[el]);});};// Elements with [data-open] will reveal a plugin that supports it when clicked.
498$(document).on('click.zf.trigger','[data-open]',function(){triggers($(this),'open');});// Elements with [data-close] will close a plugin that supports it when clicked.
499// If used without a value on [data-close], the event will bubble, allowing it to close a parent component.
500$(document).on('click.zf.trigger','[data-close]',function(){var id=$(this).data('close');if(id){triggers($(this),'close');}else{$(this).trigger('close.zf.trigger');}});// Elements with [data-toggle] will toggle a plugin that supports it when clicked.
501$(document).on('click.zf.trigger','[data-toggle]',function(){var id=$(this).data('toggle');
501if(id){triggers($(this),'toggle');}else{$(this).trigger('toggle.zf.trigger');}});// Elements with [data-closable] will respond to close.zf.trigger events.
502$(document).on('close.zf.trigger','[data-closable]',function(e){e.stopPropagation();var animation=$(this).data('closable');if(animation!==''){Foundation.Motion.animateOut($(this),animation,function(){$(this).trigger('closed.zf');});}else{$(this).fadeOut().trigger('closed.zf');}});$(document).on('focus.zf.trigger blur.zf.trigger','[data-toggle-focus]',function(){var id=$(this).data('toggle-focus');$('#'+id).triggerHandler('toggle.zf.trigger',[$(this)]);});/**
503* Fires once after all other scripts have loaded
504* @function
505* @private
506*/$(window).on('load',function(){checkListeners();});function checkListeners(){eventsListener();resizeListener();scrollListener();mutateListener();closemeListener();}//******** only fires this function once on load, if there's something to watch ********
507function closemeListener(pluginName){var yetiBoxes=$('[data-yeti-box]'),plugNames=['dropdown','tooltip','reveal'];if(pluginName){if(typeof pluginName==='string'){plugNames.push(pluginName);}else if((typeof pluginName==='undefined'?'undefined':_typeof(pluginName))==='object'&&typeof pluginName[0]==='string'){plugNames.concat(pluginName);}else{console.error('Plugin names must be strings');}}if(yetiBoxes.length){var listeners=plugNames.map(function(name){return'closeme.zf.'+name;}).join(' ');$(window).off(listeners).on(listeners,function(e,pluginId){var plugin=e.namespace.split('.')[0];var plugins=$('[data-'+plugin+']').not('[data-yeti-box="'+pluginId+'"]');plugins.each(function(){var _this=$(this);_this.triggerHandler('close.zf.trigger',[_this]);});});}}function resizeListener(debounce){var timer=void 0,$nodes=$('[data-resize]');if($nodes.length){$(window).off('resize.zf.trigger').on('resize.zf.trigger',function(e){if(timer){clearTimeout(timer);}timer=setTimeout(function(){if(!MutationObserver){//fallback for IE 9
508$nodes.each(function(){$(this).triggerHandler('resizeme.zf.trigger');});}//trigger all listening elements and signal a resize event
509$nodes.attr('data-events',"resize");},debounce||10);//default time to emit resize event
510});}}function scrollListener(debounce){var timer=void 0,$nodes=$('[data-scroll]');if($nodes.length){$(window).off('scroll.zf.trigger').on('scroll.zf.trigger',function(e){if(timer){clearTimeout(timer);}timer=setTimeout(function(){if(!MutationObserver){//fallback for IE 9
511$nodes.each(function(){$(this).triggerHandler('scrollme.zf.trigger');});}//trigger all listening elements and signal a scroll event
512$nodes.attr('data-events',"scroll");},debounce||10);//default time to emit scroll event
513});}}function mutateListener(debounce){var $nodes=$('[data-mutate]');if($nodes.length&&MutationObserver){//trigger all listening elements and signal a mutate event
514//no IE 9 or 10
515$nodes.each(function(){$(this).triggerHandler('mutateme.zf.trigger');});}}function eventsListener(){if(!MutationObserver){return false;}var nodes=document.querySelectorAll('[data-resize], [data-scroll], [data-mutate]');//element callback
516var listeningElementsMutation=function listeningElementsMutation(mutationRecordsList){var $target=$(mutationRecordsList[0].target);//trigger the event handler for the element depending on type
517switch(mutationRecordsList[0].type){case"attributes":if($target.attr("data-events")==="scroll"&&mutationRecordsList[0].attributeName==="data-events"){$target.triggerHandler('scrollme.zf.trigger',[$target,window.pageYOffset]);}if($target.attr("data-events")==="resize"&&mutationRecordsList[0].attributeName==="data-events"){$target.triggerHandler('resizeme.zf.trigger',[$target]);}if(mutationRecordsList[0].attributeName==="style"){$target.closest("[data-mutate]").attr("data-events","mutate");$target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger',[$target.closest("[data-mutate]")]);}break;case"childList":$target.closest("[data-mutate]").attr("data-events","mutate");$target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger',[$target.closest("[data-mutate]")]);break;default:return false;//nothing
518}};if(nodes.length){//for each element that needs to listen for resizing, scrolling, or mutation add a single observer
519for(var i=0;i<=nodes.length-1;i++){var elementObserver=new MutationObserver(listeningElementsMutation);elementObserver.observe(nodes[i],{attributes:true,childList:true,characterData:false,subtree:true,attributeFilter:["data-events","style"]});}}}// ------------------------------------
520// [PH]
521// Foundation.CheckWatchers = checkWatchers;
522Foundation.IHearYou=checkListeners;// Foundation.ISeeYou = scrollListener;
523// Foundation.IFeelYou = closemeListener;
524}(jQuery);// function domMutationObserver(debounce) {
525//   // !!! This is coming soon and needs more work; not active  !!! //
526//   var timer,
527//   nodes = document.querySelectorAll('[data-mutate]');
528//   //
529//   if (nodes.length) {
530//     // var MutationObserver = (function () {
531//     //   var prefixes = ['WebKit', 'Moz', 'O', 'Ms', ''];
532//     //   for (var i=0; i < prefixes.length; i++) {
533//     //     if (prefixes[i] + 'MutationObserver' in window) {
534//     //       return window[prefixes[i] + 'MutationObserver'];
535//     //     }
536//     //   }
537//     //   return false;
vendor: 5,735 bytes, lines 538-606
538//     // }());
539//
540//
541//     //for the body, we need to listen for all changes effecting the style and class attributes
542//     var bodyObserver = new MutationObserver(bodyMutation);
543//     bodyObserver.observe(document.body, { attributes: true, childList: true, characterData: false, subtree:true, attributeFilter:["style", "class"]});
544//
545//
546//     //body callback
547//     function bodyMutation(mutate) {
548//       //trigger all listening elements and signal a mutation event
549//       if (timer) { clearTimeout(timer); }
550//
551//       timer = setTimeout(function() {
552//         bodyObserver.disconnect();
553//         $('[data-mutate]').attr('data-events',"mutate");
554//       }, debounce || 150);
555//     }
556//   }
557// }
558'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
559 * Abide module.
560 * @module foundation.abide
561 */var Abide=function(){/**
562   * Creates a new instance of Abide.
563   * @class
564   * @fires Abide#init
565   * @param {Object} element - jQuery object to add the trigger to.
566   * @param {Object} options - Overrides to the default plugin settings.
567   */function Abide(element){var options=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};_classCallCheck(this,Abide);this.$element=element;this.options=$.extend({},Abide.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Abide');}/**
568   * Initializes the Abide plugin and calls functions to get Abide functioning on load.
569   * @private
570   */_createClass(Abide,[{key:'_init',value:function _init(){this.$inputs=this.$element.find('input, textarea, select');this._events();}/**
571   * Initializes events for Abide.
572   * @private
573   */},{key:'_events',value:function _events(){var _this2=this;this.$element.off('.abide').on('reset.zf.abide',function(){_this2.resetForm();}).on('submit.zf.abide',function(){return _this2.validateForm();});if(this.options.validateOn==='fieldChange'){this.$inputs.off('change.zf.abide').on('change.zf.abide',function(e){_this2.validateInput($(e.target));});}if(this.options.liveValidate){this.$inputs.off('input.zf.abide').on('input.zf.abide',function(e){_this2.validateInput($(e.target));});}if(this.options.validateOnBlur){this.$inputs.off('blur.zf.abide').on('blur.zf.abide',function(e){_this2.validateInput($(e.target));});}}/**
574   * Calls necessary functions to update Abide upon DOM change
575   * @private
576   */},{key:'_reflow',value:function _reflow(){this._init();}/**
577   * Checks whether or not a form element has the required attribute and if it's checked or not
578   * @param {Object} element - jQuery object to check for required attribute
579   * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty
580   */},{key:'requiredCheck',value:function requiredCheck($el){if(!$el.attr('required'))return true;var isGood=true;switch($el[0].type){case'checkbox':isGood=$el[0].checked;break;case'select':case'select-one':case'select-multiple':var opt=$el.find('option:selected');if(!opt.length||!opt.val())isGood=false;break;default:if(!$el.val()||!$el.val().length)isGood=false;}return isGood;}/**
581   * Based on $el, get the first element with selector in this order:
582   * 1. The element's direct sibling('s).
583   * 3. The element's parent's children.
584   *
585   * This allows for multiple form errors per input, though if none are found, no form errors will be shown.
586   *
587   * @param {Object} $el - jQuery object to use as reference to find the form error selector.
588   * @returns {Object} jQuery object with the selector.
589   */},{key:'findFormError',value:function findFormError($el){var $error=$el.siblings(this.options.formErrorSelector);if(!$error.length){$error=$el.parent().find(this.options.formErrorSelector);}return $error;}/**
590   * Get the first element in this order:
591   * 2. The <label> with the attribute `[for="someInputId"]`
592   * 3. The `.closest()` <label>
593   *
594   * @param {Object} $el - jQuery object to check for required attribute
595   * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty
596   */},{key:'findLabel',value:function findLabel($el){var id=$el[0].id;var $label=this.$element.find('label[for="'+id+'"]');if(!$label.length){return $el.closest('label');}return $label;}/**
597   * Get the set of labels associated with a set of radio els in this order
598   * 2. The <label> with the attribute `[for="someInputId"]`
599   * 3. The `.closest()` <label>
600   *
601   * @param {Object} $el - jQuery object to check for required attribute
602   * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty
603   */},{key:'findRadioLabels',value:function findRadioLabels($els){var _this3=this;var labels=$els.map(function(i,el){var id=el.id;var $label=_this3.$element.find('label[for="'+id+'"]');if(!$label.length){$label=$(el).closest('label');}return $label[0];});return $(labels);}/**
604   * Adds the CSS error class as specified by the Abide settings to the label, input, and the form
605   * @param {Object} $el - jQuery object to add the class to
606   */},{key:'addErrorClasses',value:function addErrorClasses($el){var $label=this.findLabel($el);var $formError=this.findFormError($el);
606if($label.length){$label.addClass(this.options.labelErrorClass);}if($formError.length){$formError.addClass(this.options.formErrorClass);}$el.addClass(this.options.inputErrorClass).attr('data-invalid','');}/**
607   * Remove CSS error classes etc from an entire radio button group
608   * @param {String} groupName - A string that specifies the name of a radio button group
609   *
610   */},{key:'removeRadioErrorClasses',value:function removeRadioErrorClasses(groupName){var $els=this.$element.find(':radio[name="'+groupName+'"]');var $labels=this.findRadioLabels($els);var $formErrors=this.findFormError($els);if($labels.length){$labels.removeClass(this.options.labelErrorClass);}if($formErrors.length){$formErrors.removeClass(this.options.formErrorClass);}$els.removeClass(this.options.inputErrorClass).removeAttr('data-invalid');}/**
611   * Removes CSS error class as specified by the Abide settings from the label, input, and the form
612   * @param {Object} $el - jQuery object to remove the class from
613   */},{key:'removeErrorClasses',value:function removeErrorClasses($el){// radios need to clear all of the els
614if($el[0].type=='radio'){return this.removeRadioErrorClasses($el.attr('name'));}var $label=this.findLabel($el);var $formError=this.findFormError($el);if($label.length){$label.removeClass(this.options.labelErrorClass);}if($formError.length){$formError.removeClass(this.options.formErrorClass);}$el.removeClass(this.options.inputErrorClass).removeAttr('data-invalid');}/**
615   * Goes through a form to find inputs and proceeds to validate them in ways specific to their type
616   * @fires Abide#invalid
617   * @fires Abide#valid
618   * @param {Object} element - jQuery object to validate, should be an HTML input
619   * @returns {Boolean} goodToGo - If the input is valid or not.
620   */},{key:'validateInput',value:function validateInput($el){var _this4=this;var clearRequire=this.requiredCheck($el),validated=false,customValidator=true,validator=$el.attr('data-validator'),equalTo=true;// don't validate ignored inputs or hidden inputs
621if($el.is('[data-abide-ignore]')||$el.is('[type="hidden"]')){return true;}switch($el[0].type){case'radio':validated=this.validateRadio($el.attr('name'));break;case'checkbox':validated=clearRequire;break;case'select':case'select-one':case'select-multiple':validated=clearRequire;break;default:validated=this.validateText($el);}if(validator){customValidator=this.matchValidation($el,validator,$el.attr('required'));}if($el.attr('data-equalto')){equalTo=this.options.validators.equalTo($el);}var goodToGo=[clearRequire,validated,customValidator,equalTo].indexOf(false)===-1;var message=(goodToGo?'valid':'invalid')+'.zf.abide';if(goodToGo){// Re-validate inputs that depend on this one with equalto
622var dependentElements=this.$element.find('[data-equalto="'+$el.attr('id')+'"]');if(dependentElements.length){(function(){var _this=_this4;dependentElements.each(function(){if($(this).val()){_this.validateInput($(this));}});})();}}this[goodToGo?'removeErrorClasses':'addErrorClasses']($el);/**
623     * Fires when the input is done checking for validation. Event trigger is either `valid.zf.abide` or `invalid.zf.abide`
624     * Trigger includes the DOM element of the input.
625     * @event Abide#valid
626     * @event Abide#invalid
627     */$el.trigger(message,[$el]);return goodToGo;}/**
628   * Goes through a form and if there are any invalid inputs, it will display the form error element
629   * @returns {Boolean} noError - true if no errors were detected...
630   * @fires Abide#formvalid
631   * @fires Abide#forminvalid
632   */},{key:'validateForm',value:function validateForm(){var acc=[];var _this=this;this.$inputs.each(function(){acc.push(_this.validateInput($(this)));});var noError=acc.indexOf(false)===-1;this.$element.find('[data-abide-error]').css('display',noError?'none':'block');/**
633     * Fires when the form is finished validating. Event trigger is either `formvalid.zf.abide` or `forminvalid.zf.abide`.
634     * Trigger includes the element of the form.
635     * @event Abide#formvalid
636     * @event Abide#forminvalid
637     */this.$element.trigger((noError?'formvalid':'forminvalid')+'.zf.abide',[this.$element]);return noError;}/**
638   * Determines whether or a not a text input is valid based on the pattern specified in the attribute. If no matching pattern is found, returns true.
639   * @param {Object} $el - jQuery object to validate, should be a text input HTML element
640   * @param {String} pattern - string value of one of the RegEx patterns in Abide.options.patterns
641   * @returns {Boolean} Boolean value depends on whether or not the input value matches the pattern specified
642   */},{key:'validateText',value:function validateText($el,pattern){// A pattern can be passed to this function, or it will be infered from the input's "pattern" attribute, or it's "type" attribute
643pattern=pattern||$el.attr('pattern')||$el.attr('type');var inputText=$el.val();var valid=false;if(inputText.length){// If the pattern attribute on the element is in Abide's list of patterns, then test that regexp
644if(this.options.patterns.hasOwnProperty(pattern)){valid=this.options.patterns[pattern].test(inputText);}// If the pattern name isn't also the type attribute of the field, then test it as a regexp
645else if(pattern!==$el.attr('type')){valid=new RegExp(pattern).test(inputText);}
645else{valid=true;}}// An empty field is valid if it's not required
646else if(!$el.prop('required')){valid=true;}return valid;}/**
647   * Determines whether or a not a radio input is valid based on whether or not it is required and selected. Although the function targets a single `<input>`, it validates by checking the `required` and `checked` properties of all radio buttons in its group.
648   * @param {String} groupName - A string that specifies the name of a radio button group
649   * @returns {Boolean} Boolean value depends on whether or not at least one radio input has been selected (if it's required)
650   */},{key:'validateRadio',value:function validateRadio(groupName){// If at least one radio in the group has the `required` attribute, the group is considered required
651// Per W3C spec, all radio buttons in a group should have `required`, but we're being nice
652var $group=this.$element.find(':radio[name="'+groupName+'"]');var valid=false,required=false;// For the group to be required, at least one radio needs to be required
653$group.each(function(i,e){if($(e).attr('required')){required=true;}});if(!required)valid=true;if(!valid){// For the group to be valid, at least one radio needs to be checked
654$group.each(function(i,e){if($(e).prop('checked')){valid=true;}});};return valid;}/**
655   * Determines if a selected input passes a custom validation function. Multiple validations can be used, if passed to the element with `data-validator="foo bar baz"` in a space separated listed.
656   * @param {Object} $el - jQuery input element.
657   * @param {String} validators - a string of function names matching functions in the Abide.options.validators object.
658   * @param {Boolean} required - self explanatory?
659   * @returns {Boolean} - true if validations passed.
660   */},{key:'matchValidation',value:function matchValidation($el,validators,required){var _this5=this;required=required?true:false;var clear=validators.split(' ').map(function(v){return _this5.options.validators[v]($el,required,$el.parent());});return clear.indexOf(false)===-1;}/**
661   * Resets form inputs and styles
662   * @fires Abide#formreset
663   */},{key:'resetForm',value:function resetForm(){var $form=this.$element,opts=this.options;$('.'+opts.labelErrorClass,$form).not('small').removeClass(opts.labelErrorClass);$('.'+opts.inputErrorClass,$form).not('small').removeClass(opts.inputErrorClass);$(opts.formErrorSelector+'.'+opts.formErrorClass).removeClass(opts.formErrorClass);$form.find('[data-abide-error]').css('display','none');$(':input',$form).not(':button, :submit, :reset, :hidden, :radio, :checkbox, [data-abide-ignore]').val('').removeAttr('data-invalid');$(':input:radio',$form).not('[data-abide-ignore]').prop('checked',false).removeAttr('data-invalid');$(':input:checkbox',$form).not('[data-abide-ignore]').prop('checked',false).removeAttr('data-invalid');/**
664     * Fires when the form has been reset.
665     * @event Abide#formreset
666     */$form.trigger('formreset.zf.abide',[$form]);}/**
667   * Destroys an instance of Abide.
668   * Removes error styles and classes from elements, without resetting their values.
669   */},{key:'destroy',value:function destroy(){var _this=this;this.$element.off('.abide').find('[data-abide-error]').css('display','none');this.$inputs.off('.abide').each(function(){_this.removeErrorClasses($(this));});Foundation.unregisterPlugin(this);}}]);return Abide;}();/**
670 * Default settings for plugin
671 */Abide.defaults={/**
672   * The default event to validate inputs. Checkboxes and radios validate immediately.
673   * Remove or change this value for manual validation.
674   * @option
675   * @example 'fieldChange'
676   */validateOn:'fieldChange',/**
677   * Class to be applied to input labels on failed validation.
678   * @option
679   * @example 'is-invalid-label'
680   */labelErrorClass:'is-invalid-label',/**
681   * Class to be applied to inputs on failed validation.
682   * @option
683   * @example 'is-invalid-input'
684   */inputErrorClass:'is-invalid-input',/**
685   * Class selector to use to target Form Errors for show/hide.
686   * @option
687   * @example '.form-error'
688   */formErrorSelector:'.form-error',/**
689   * Class added to Form Errors on failed validation.
690   * @option
691   * @example 'is-visible'
692   */formErrorClass:'is-visible',/**
693   * Set to true to validate text inputs on any value change.
694   * @option
695   * @example false
696   */liveValidate:false,/**
697   * Set to true to validate inputs on blur.
698   * @option
699   * @example false
700   */validateOnBlur:false,patterns:{alpha:/^[a-zA-Z]+$/,alpha_numeric:/^[a-zA-Z0-9]+$/,integer:/^[-+]?\d+$/,number:/^[-+]?\d*(?:[\.\,]\d+)?$/,// amex, visa, diners
701card:/^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/,cvv:/^([0-9]){3,4}$/,// http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#valid-e-mail-address
702email:/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+$/,url:/^(https?|ftp|file|ssh):\/\/(((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/,// abc.de
703domain:/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,8}$/,datetime:/^([0-2][0-9]{3})\-([0-1][0-9])\-([0-3][0-9])T([0-5][0-9])\:([0-5][0-9])\:([0-5][0-9])(Z|([\-\+]([0-1][0-9])\:00))$/,// YYYY-MM-DD
704date:/(?:19|20)[0-9]{2}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-9])|(?:(?!02)(?:0[1-9]|1[0-2])-(?:30))|(?:(?:0[13578]|1[02])-31))$/,// HH:MM:SS
705time:/^(0[0-9]|1[0-9]|2[0-3])(:[0-5][0-9]){2}$/,dateISO:/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/,// MM/DD/YYYY
706month_day_year:/^(0[1-9]|1[012])[- \/.](0[1-9]|[12][0-9]|3[01])[- \/.]\d{4}$/,// DD/MM/YYYY
707day_month_year:/^(0[1-9]|[12][0-9]|3[01])[- \/.](0[1-9]|1[012])[- \/.]\d{4}$/,// #FFF or #FFFFFF
708color:/^#?([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/},/**
709   * Optional validation functions to be used. `equalTo` being the only default included function.
710   * Functions should return only a boolean if the input is valid or not. Functions are given the following arguments:
711   * el : The jQuery element to validate.
712   * required : Boolean value of the required attribute be present or not.
713   * parent : The direct parent of the input.
714   * @option
715   */validators:{equalTo:function equalTo(el,required,parent){return $('#'+el.attr('data-equalto')).val()===el.val();}}};// Window exports
716Foundation.plugin(Abide,'Abide');}(jQuery);
717'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
718 * Accordion module.
719 * @module foundation.accordion
720 * @requires foundation.util.keyboard
721 * @requires foundation.util.motion
722 */var Accordion=function(){/**
723   * Creates a new instance of an accordion.
724   * @class
725   * @fires Accordion#init
726   * @param {jQuery} element - jQuery object to make into an accordion.
727   * @param {Object} options - a plain object with settings to override the default options.
728   */function Accordion(element,options){_classCallCheck(this,Accordion);this.$element=element;this.options=$.extend({},Accordion.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Accordion');Foundation.Keyboard.register('Accordion',{'ENTER':'toggle','SPACE':'toggle','ARROW_DOWN':'next','ARROW_UP':'previous'});}/**
729   * Initializes the accordion by animating the preset active pane(s).
730   * @private
731   */_createClass(Accordion,[{key:'_init',value:function _init(){this.$element.attr('role','tablist');this.$tabs=this.$element.children('[data-accordion-item]');this.$tabs.each(function(idx,el){var $el=$(el),$content=$el.children('[data-tab-content]'),id=$content[0].id||Foundation.GetYoDigits(6,'accordion'),linkId=el.id||id+'-label';$el.find('a:first').attr({'aria-controls':id,'role':'tab','id':linkId,'aria-expanded':false,'aria-selected':false});$content.attr({'role':'tabpanel','aria-labelledby':linkId,'aria-hidden':true,'id':id});});var $initActive=this.$element.find('.is-active').children('[data-tab-content]');if($initActive.length){this.down($initActive,true);}this._events();}/**
732   * Adds event handlers for items within the accordion.
733   * @private
734   */},{key:'_events',value:function _events(){var _this=this;this.$tabs.each(function(){var $elem=$(this);var $tabContent=$elem.children('[data-tab-content]');if($tabContent.length){$elem.children('a').off('click.zf.accordion keydown.zf.accordion').on('click.zf.accordion',function(e){e.preventDefault();_this.toggle($tabContent);}).on('keydown.zf.accordion',function(e){Foundation.Keyboard.handleKey(e,'Accordion',{toggle:function toggle(
734){_this.toggle($tabContent);},next:function next(){var $a=$elem.next().find('a').focus();if(!_this.options.multiExpand){$a.trigger('click.zf.accordion');}},previous:function previous(){var $a=$elem.prev().find('a').focus();if(!_this.options.multiExpand){$a.trigger('click.zf.accordion');}},handled:function handled(){e.preventDefault();e.stopPropagation();}});});}});}/**
735   * Toggles the selected content pane's open/close state.
736   * @param {jQuery} $target - jQuery object of the pane to toggle (`.accordion-content`).
737   * @function
738   */},{key:'toggle',value:function toggle($target){if($target.parent().hasClass('is-active')){this.up($target);}else{this.down($target);}}/**
739   * Opens the accordion tab defined by `$target`.
740   * @param {jQuery} $target - Accordion pane to open (`.accordion-content`).
741   * @param {Boolean} firstTime - flag to determine if reflow should happen.
742   * @fires Accordion#down
743   * @function
744   */},{key:'down',value:function down($target,firstTime){var _this2=this;$target.attr('aria-hidden',false).parent('[data-tab-content]').addBack().parent().addClass('is-active');if(!this.options.multiExpand&&!firstTime){var $currentActive=this.$element.children('.is-active').children('[data-tab-content]');if($currentActive.length){this.up($currentActive.not($target));}}$target.slideDown(this.options.slideSpeed,function(){/**
745       * Fires when the tab is done opening.
746       * @event Accordion#down
747       */_this2.$element.trigger('down.zf.accordion',[$target]);});$('#'+$target.attr('aria-labelledby')).attr({'aria-expanded':true,'aria-selected':true});}/**
748   * Closes the tab defined by `$target`.
749   * @param {jQuery} $target - Accordion tab to close (`.accordion-content`).
750   * @fires Accordion#up
751   * @function
752   */},{key:'up',value:function up($target){var $aunts=$target.parent().siblings(),_this=this;if(!this.options.allowAllClosed&&!$aunts.hasClass('is-active')||!$target.parent().hasClass('is-active')){return;}// Foundation.Move(this.options.slideSpeed, $target, function(){
753$target.slideUp(_this.options.slideSpeed,function(){/**
754         * Fires when the tab is done collapsing up.
755         * @event Accordion#up
756         */_this.$element.trigger('up.zf.accordion',[$target]);});// });
757$target.attr('aria-hidden',true).parent().removeClass('is-active');$('#'+$target.attr('aria-labelledby')).attr({'aria-expanded':false,'aria-selected':false});}/**
758   * Destroys an instance of an accordion.
759   * @fires Accordion#destroyed
760   * @function
761   */},{key:'destroy',value:function destroy(){this.$element.find('[data-tab-content]').stop(true).slideUp(0).css('display','');this.$element.find('a').off('.zf.accordion');Foundation.unregisterPlugin(this);}}]);return Accordion;}();Accordion.defaults={/**
762   * Amount of time to animate the opening of an accordion pane.
763   * @option
764   * @example 250
765   */slideSpeed:250,/**
766   * Allow the accordion to have multiple open panes.
767   * @option
768   * @example false
769   */multiExpand:false,/**
770   * Allow the accordion to close all panes.
771   * @option
772   * @example false
773   */allowAllClosed:false};// Window exports
774Foundation.plugin(Accordion,'Accordion');}(jQuery);
775'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
776 * AccordionMenu module.
777 * @module foundation.accordionMenu
778 * @requires foundation.util.keyboard
779 * @requires foundation.util.motion
780 * @requires foundation.util.nest
781 */var AccordionMenu=function(){/**
782   * Creates a new instance of an accordion menu.
783   * @class
784   * @fires AccordionMenu#init
785   * @param {jQuery} element - jQuery object to make into an accordion menu.
786   * @param {Object} options - Overrides to the default plugin settings.
787   */function AccordionMenu(element,options){_classCallCheck(this,AccordionMenu);this.$element=element;this.options=$.extend({},AccordionMenu.defaults,this.$element.data(),options);Foundation.Nest.Feather(this.$element,'accordion');this._init();Foundation.registerPlugin(this,'AccordionMenu');Foundation.Keyboard.register('AccordionMenu',{'ENTER':'toggle','SPACE':'toggle','ARROW_RIGHT':'open','ARROW_UP':'up','ARROW_DOWN':'down','ARROW_LEFT':'close','ESCAPE':'closeAll'});}/**
788   * Initializes the accordion menu by hiding all nested menus.
789   * @private
790   */_createClass(AccordionMenu,[{key:'_init',value:function _init(){this.$element.find('[data-submenu]').not('.is-active').slideUp(0);//.find('a').css('padding-left', '1rem');
791this.$element.attr({'role':'menu','aria-multiselectable':this.options.multiOpe
vendor: 4,740 bytes, lines 791-828
791n});this.$menuLinks=this.$element.find('.is-accordion-submenu-parent');this.$menuLinks.each(function(){var linkId=this.id||Foundation.GetYoDigits(6,'acc-menu-link'),$elem=$(this),$sub=$elem.children('[data-submenu]'),subId=$sub[0].id||Foundation.GetYoDigits(6,'acc-menu'),isActive=$sub.hasClass('is-active');$elem.attr({'aria-controls':subId,'aria-expanded':isActive,'role':'menuitem','id':linkId});$sub.attr({'aria-labelledby':linkId,'aria-hidden':!isActive,'role':'menu','id':subId});});var initPanes=this.$element.find('.is-active');if(initPanes.length){var _this=this;initPanes.each(function(){_this.down($(this));});}this._events();}/**
792   * Adds event handlers for items within the menu.
793   * @private
794   */},{key:'_events',value:function _events(){var _this=this;this.$element.find('li').each(function(){var $submenu=$(this).children('[data-submenu]');if($submenu.length){$(this).children('a').off('click.zf.accordionMenu').on('click.zf.accordionMenu',function(e){e.preventDefault();_this.toggle($submenu);});}}).on('keydown.zf.accordionmenu',function(e){var $element=$(this),$elements=$element.parent('ul').children('li'),$prevElement,$nextElement,$target=$element.children('[data-submenu]');$elements.each(function(i){if($(this).is($element)){$prevElement=$elements.eq(Math.max(0,i-1)).find('a').first();$nextElement=$elements.eq(Math.min(i+1,$elements.length-1)).find('a').first();if($(this).children('[data-submenu]:visible').length){// has open sub menu
795$nextElement=$element.find('li:first-child').find('a').first();}if($(this).is(':first-child')){// is first element of sub menu
796$prevElement=$element.parents('li').first().find('a').first();}else if($prevElement.parents('li').first().children('[data-submenu]:visible').length){// if previous element has open sub menu
797$prevElement=$prevElement.parents('li').find('li:last-child').find('a').first();}if($(this).is(':last-child')){// is last element of sub menu
798$nextElement=$element.parents('li').first().next('li').find('a').first();}return;}});Foundation.Keyboard.handleKey(e,'AccordionMenu',{open:function open(){if($target.is(':hidden')){_this.down($target);$target.find('li').first().find('a').first().focus();}},close:function close(){if($target.length&&!$target.is(':hidden')){// close active sub of this item
799_this.up($target);}else if($element.parent('[data-submenu]').length){// close currently open sub
800_this.up($element.parent('[data-submenu]'));$element.parents('li').first().find('a').first().focus();}},up:function up(){$prevElement.focus();return true;},down:function down(){$nextElement.focus();return true;},toggle:function toggle(){if($element.children('[data-submenu]').length){_this.toggle($element.children('[data-submenu]'));}},closeAll:function closeAll(){_this.hideAll();},handled:function handled(preventDefault){if(preventDefault){e.preventDefault();}e.stopImmediatePropagation();}});});//.attr('tabindex', 0);
801}/**
802   * Closes all panes of the menu.
803   * @function
804   */},{key:'hideAll',value:function hideAll(){this.up(this.$element.find('[data-submenu]'));}/**
805   * Opens all panes of the menu.
806   * @function
807   */},{key:'showAll',value:function showAll(){this.down(this.$element.find('[data-submenu]'));}/**
808   * Toggles the open/close state of a submenu.
809   * @function
810   * @param {jQuery} $target - the submenu to toggle
811   */},{key:'toggle',value:function toggle($target){if(!$target.is(':animated')){if(!$target.is(':hidden')){this.up($target);}else{this.down($target);}}}/**
812   * Opens the sub-menu defined by `$target`.
813   * @param {jQuery} $target - Sub-menu to open.
814   * @fires AccordionMenu#down
815   */},{key:'down',value:function down($target){var _this=this;if(!this.options.multiOpen){this.up(this.$element.find('.is-active').not($target.parentsUntil(this.$element).add($target)));}$target.addClass('is-active').attr({'aria-hidden':false}).parent('.is-accordion-submenu-parent').attr({'aria-expanded':true});//Foundation.Move(this.options.slideSpeed, $target, function() {
816$target.slideDown(_this.options.slideSpeed,function(){/**
817           * Fires when the menu is done opening.
818           * @event AccordionMenu#down
819           */_this.$element.trigger('down.zf.accordionMenu',[$target]);});//});
820}/**
821   * Closes the sub-menu defined by `$target`. All sub-menus inside the target will be closed as well.
822   * @param {jQuery} $target - Sub-menu to close.
823   * @fires AccordionMenu#up
824   */},{key:'up',value:function up($target){var _this=this;//Foundation.Move(this.options.slideSpeed, $target, function(){
825$target.slideUp(_this.options.slideSpeed,function(){/**
826         * Fires when the menu is done collapsing up.
827         * @event AccordionMenu#up
828         */_this.$element.trigger('up.zf.accordionMenu',[$target]);});//});
829var $menus=$target.find('[data-submenu]').slideUp(0).addBack().attr('aria-hidden',true);$menus.parent('.is-accordion-submenu-parent').attr('aria-expanded',false);}/**
830   * Destroys an instance of accordion menu.
831   * @fires AccordionMenu#destroyed
832   */},{key:'destroy',value:function destroy(){this.$element.find('[data-submenu]').slideDown(0).css('display','');this.$element.find('a').off('click.zf.accordionMenu');Foundation.Nest.Burn(this.$element,'accordion');Foundation.unregisterPlugin(this);}}]);return AccordionMenu;}();AccordionMenu.defaults={/**
833   * Amount of time to animate the opening of a submenu in ms.
834   * @option
835   * @example 250
836   */slideSpeed:250,/**
837   * Allow the menu to have multiple open panes.
838   * @option
839   * @example true
840   */multiOpen:true};// Window exports
841Foundation.plugin(AccordionMenu,'AccordionMenu');}(jQuery);
842'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
843 * Drilldown module.
844 * @module foundation.drilldown
845 * @requires foundation.util.keyboard
846 * @requires foundation.util.motion
847 * @requires foundation.util.nest
848 */var Drilldown=function(){/**
849   * Creates a new instance of a drilldown menu.
850   * @class
851   * @param {jQuery} element - jQuery object to make into an accordion menu.
852   * @param {Object} options - Overrides to the default plugin settings.
853   */function Drilldown(element,options){_classCallCheck(this,Drilldown);this.$element=element;this.options=$.extend({},Drilldown.defaults,this.$element.data(),options);Foundation.Nest.Feather(this.$element,'drilldown');this._init();Foundation.registerPlugin(this,'Drilldown');Foundation.Keyboard.register('Drilldown',{'ENTER':'open','SPACE':'open','ARROW_RIGHT':'next','ARROW_UP':'up','ARROW_DOWN':'down','ARROW_LEFT':'previous','ESCAPE':'close','TAB':'down','SHIFT_TAB':'up'});}/**
854   * Initializes the drilldown by creating jQuery collections of elements
855   * @private
856   */_createClass(Drilldown,[{key:'_init',value:function _init(){this.$submenuAnchors=this.$element.find('li.is-drilldown-submenu-parent').children('a');this.$submenus=this.$submenuAnchors.parent('li').children('[data-submenu]');this.$menuItems=this.$element.find('li').not('.js-drilldown-back').attr('role','menuitem').find('a');this.$element.attr('data-mutate',this.$element.attr('data-drilldown')||Foundation.GetYoDigits(6,'drilldown'));this._prepareMenu();this._registerEvents();this._keyboardEvents();}/**
857   * prepares drilldown menu by setting attributes to links and elements
858   * sets a min height to prevent content jumping
859   * wraps the element if not already wrapped
860   * @private
861   * @function
862   */},{key:'_prepareMenu',value:function _prepareMenu(){var _this=this;// if(!this.options.holdOpen){
863//   this._menuLinkEvents();
864// }
865this.$submenuAnchors.each(function(){var $link=$(this);var $sub=$link.parent();if(_this.options.parentLink){$link.clone().prependTo($sub.children('[data-submenu]')).wrap('<li class="is-submenu-parent-item is-submenu-item is-drilldown-submenu-item" role="menu-item"></li>');}$link.data('savedHref',$link.attr('href')).removeAttr('href').attr('tabindex',0);$link.children('[data-submenu]').attr({'aria-hidden':true,'tabindex':0,'role':'menu'});_this._events($link);});this.$submenus.each(function(){var $menu=$(this),$back=$menu.find('.js-drilldown-back');if(!$back.length){switch(_this.options.backButtonPosition){case"bottom":$menu.append(_this.options.backButton);break;case"top":$menu.prepend(_this.options.backButton);break;default:console.error("Unsupported backButtonPosition value '"+_this.options.backButtonPosition+"'");}}_this._back($menu);});if(!this.options.autoHeight){this.$submenus.addClass('drilldown-submenu-cover-previous');}if(!this.$element.parent().hasClass('is-drilldown')){this.$wrapper=$(this.options.wrapper).addClass('is-drilldown');if(this.options.animateHeight)this.$wrapper.addClass('animate-height');this.$wrapper=this.$element.wrap(this.$wrapper).parent().css(this._getMaxDims());}}},{key:'_resize',value:function _resize(){this.$wrapper.css({'max-width':'none','min-height':'none'});// _getMaxDims has side effects (boo) but calling it should update all other necessary heights & widths
866this.$wrapper.css(this._getMaxDims());}/**
867   * Adds event handlers to elements in the menu.
868   * @function
869   * @private
870   * @param {jQuery} $elem - the current menu item to add handlers to.
871   */},{key:'_events',value:function _events($elem){var _this=this;$elem.off('click.zf.drilldown').on('click.zf.drilldown',function(e){if($(e.target).parentsUntil('ul','li').hasClass('is-drilldown-submenu-parent')){e.
vendor: 11,076 bytes, lines 871-995
871stopImmediatePropagation();e.preventDefault();}// if(e.target !== e.currentTarget.firstElementChild){
872//   return false;
873// }
874_this._show($elem.parent('li'));if(_this.options.closeOnClick){var $body=$('body');$body.off('.zf.drilldown').on('click.zf.drilldown',function(e){if(e.target===_this.$element[0]||$.contains(_this.$element[0],e.target)){return;}e.preventDefault();_this._hideAll();$body.off('.zf.drilldown');});}});this.$element.on('mutateme.zf.trigger',this._resize.bind(this));}/**
875   * Adds event handlers to the menu element.
876   * @function
877   * @private
878   */},{key:'_registerEvents',value:function _registerEvents(){if(this.options.scrollTop){this._bindHandler=this._scrollTop.bind(this);this.$element.on('open.zf.drilldown hide.zf.drilldown closed.zf.drilldown',this._bindHandler);}}/**
879   * Scroll to Top of Element or data-scroll-top-element
880   * @function
881   * @fires Drilldown#scrollme
882   */},{key:'_scrollTop',value:function _scrollTop(){var _this=this;var $scrollTopElement=_this.options.scrollTopElement!=''?$(_this.options.scrollTopElement):_this.$element,scrollPos=parseInt($scrollTopElement.offset().top+_this.options.scrollTopOffset);$('html, body').stop(true).animate({scrollTop:scrollPos},_this.options.animationDuration,_this.options.animationEasing,function(){/**
883        * Fires after the menu has scrolled
884        * @event Drilldown#scrollme
885        */if(this===$('html')[0])_this.$element.trigger('scrollme.zf.drilldown');});}/**
886   * Adds keydown event listener to `li`'s in the menu.
887   * @private
888   */},{key:'_keyboardEvents',value:function _keyboardEvents(){var _this=this;this.$menuItems.add(this.$element.find('.js-drilldown-back > a, .is-submenu-parent-item > a')).on('keydown.zf.drilldown',function(e){var $element=$(this),$elements=$element.parent('li').parent('ul').children('li').children('a'),$prevElement,$nextElement;$elements.each(function(i){if($(this).is($element)){$prevElement=$elements.eq(Math.max(0,i-1));$nextElement=$elements.eq(Math.min(i+1,$elements.length-1));return;}});Foundation.Keyboard.handleKey(e,'Drilldown',{next:function next(){if($element.is(_this.$submenuAnchors)){_this._show($element.parent('li'));$element.parent('li').one(Foundation.transitionend($element),function(){$element.parent('li').find('ul li a').filter(_this.$menuItems).first().focus();});return true;}},previous:function previous(){_this._hide($element.parent('li').parent('ul'));$element.parent('li').parent('ul').one(Foundation.transitionend($element),function(){setTimeout(function(){$element.parent('li').parent('ul').parent('li').children('a').first().focus();},1);});return true;},up:function up(){$prevElement.focus();return true;},down:function down(){$nextElement.focus();return true;},close:function close(){_this._back();//_this.$menuItems.first().focus(); // focus to first element
889},open:function open(){if(!$element.is(_this.$menuItems)){// not menu item means back button
890_this._hide($element.parent('li').parent('ul'));$element.parent('li').parent('ul').one(Foundation.transitionend($element),function(){setTimeout(function(){$element.parent('li').parent('ul').parent('li').children('a').first().focus();},1);});return true;}else if($element.is(_this.$submenuAnchors)){_this._show($element.parent('li'));$element.parent('li').one(Foundation.transitionend($element),function(){$element.parent('li').find('ul li a').filter(_this.$menuItems).first().focus();});return true;}},handled:function handled(preventDefault){if(preventDefault){e.preventDefault();}e.stopImmediatePropagation();}});});// end keyboardAccess
891}/**
892   * Closes all open elements, and returns to root menu.
893   * @function
894   * @fires Drilldown#closed
895   */},{key:'_hideAll',value:function _hideAll(){var $elem=this.$element.find('.is-drilldown-submenu.is-active').addClass('is-closing');if(this.options.autoHeight)this.$wrapper.css({height:$elem.parent().closest('ul').data('calcHeight')});$elem.one(Foundation.transitionend($elem),function(e){$elem.removeClass('is-active is-closing');});/**
896         * Fires when the menu is fully closed.
897         * @event Drilldown#closed
898         */this.$element.trigger('closed.zf.drilldown');}/**
899   * Adds event listener for each `back` button, and closes open menus.
900   * @function
901   * @fires Drilldown#back
902   * @param {jQuery} $elem - the current sub-menu to add `back` event.
903   */},{key:'_back',value:function _back($elem){var _this=this;$elem.off('click.zf.drilldown');$elem.children('.js-drilldown-back').on('click.zf.drilldown',function(e){e.stopImmediatePropagation();// console.log('mouseup on back');
904_this._hide($elem);// If there is a parent submenu, call show
905var parentSubMenu=$elem.parent('li').parent('ul').parent('li');if(parentSubMenu.length){_this._show(parentSubMenu);}});}/**
906   * Adds event listener to menu items w/o submenus to close open menus on click.
907   * @function
908   * @private
909   */},{key:'_menuLinkEvents',value:function _menuLinkEvents(){var _this=this;this.$menuItems.not('.is-drilldown-submenu-parent').off('click.zf.drilldown').on('click.zf.drilldown',function(e){// e.stopImmediatePropagation();
910setTimeout(function(){_this._hideAll();},0);});}/**
911   * Opens a submenu.
912   * @function
913   * @fires Drilldown#open
914   * @param {jQuery} $elem - the current element with a submenu to open, i.e. the `li` tag.
915   */},{key:'_show',value:function _show($elem){if(this.options.autoHeight)this.$wrapper.css({height:$elem.children('[data-submenu]').data('calcHeight')});$elem.attr('aria-expanded',true);$elem.children('[data-submenu]').addClass('is-active').attr('aria-hidden',false);/**
916     * Fires when the submenu has opened.
917     * @event Drilldown#open
918     */this.$element.trigger('open.zf.drilldown',[$elem]);}},{key:'_hide',/**
919   * Hides a submenu
920   * @function
921   * @fires Drilldown#hide
922   * @param {jQuery} $elem - the current sub-menu to hide, i.e. the `ul` tag.
923   */value:function _hide($elem){if(this.options.autoHeight)this.$wrapper.css({height:$elem.parent().closest('ul').data('calcHeight')});var _this=this;$elem.parent('li').attr('aria-expanded',false);$elem.attr('aria-hidden',true).addClass('is-closing');$elem.addClass('is-closing').one(Foundation.transitionend($elem),function(){$elem.removeClass('is-active is-closing');$elem.blur();});/**
924     * Fires when the submenu has closed.
925     * @event Drilldown#hide
926     */$elem.trigger('hide.zf.drilldown',[$elem]);}/**
927   * Iterates through the nested menus to calculate the min-height, and max-width for the menu.
928   * Prevents content jumping.
929   * @function
930   * @private
931   */},{key:'_getMaxDims',value:function _getMaxDims(){var maxHeight=0,result={},_this=this;this.$submenus.add(this.$element).each(function(){var numOfElems=$(this).children('li').length;var height=Foundation.Box.GetDimensions(this).height;maxHeight=height>maxHeight?height:maxHeight;if(_this.options.autoHeight){$(this).data('calcHeight',height);if(!$(this).hasClass('is-drilldown-submenu'))result['height']=height;}});if(!this.options.autoHeight)result['min-height']=maxHeight+'px';result['max-width']=this.$element[0].getBoundingClientRect().width+'px';return result;}/**
932   * Destroys the Drilldown Menu
933   * @function
934   */},{key:'destroy',value:function destroy(){if(this.options.scrollTop)this.$element.off('.zf.drilldown',this._bindHandler);this._hideAll();this.$element.off('mutateme.zf.trigger');Foundation.Nest.Burn(this.$element,'drilldown');this.$element.unwrap().find('.js-drilldown-back, .is-submenu-parent-item').remove().end().find('.is-active, .is-closing, .is-drilldown-submenu').removeClass('is-active is-closing is-drilldown-submenu').end().find('[data-submenu]').removeAttr('aria-hidden tabindex role');this.$submenuAnchors.each(function(){$(this).off('.zf.drilldown');});this.$submenus.removeClass('drilldown-submenu-cover-previous');this.$element.find('a').each(function(){var $link=$(this);$link.removeAttr('tabindex');if($link.data('savedHref')){$link.attr('href',$link.data('savedHref')).removeData('savedHref');}else{return;}});Foundation.unregisterPlugin(this);}}]);return Drilldown;}();Drilldown.defaults={/**
935   * Markup used for JS generated back button. Prepended  or appended (see backButtonPosition) to submenu lists and deleted on `destroy` method, 'js-drilldown-back' class required. Remove the backslash (`\`) if copy and pasting.
936   * @option
937   * @example '<\li><\a>Back<\/a><\/li>'
938   */backButton:'<li class="js-drilldown-back"><a tabindex="0">Back</a></li>',/**
939   * Position the back button either at the top or bottom of drilldown submenus.
940   * @option
941   * @example bottom
942   */backButtonPosition:'top',/**
943   * Markup used to wrap drilldown menu. Use a class name for independent styling; the JS applied class: `is-drilldown` is required. Remove the backslash (`\`) if copy and pasting.
944   * @option
945   * @example '<\div class="is-drilldown"><\/div>'
946   */wrapper:'<div></div>',/**
947   * Adds the parent link to the submenu.
948   * @option
949   * @example false
950   */parentLink:false,/**
951   * Allow the menu to return to root list on body click.
952   * @option
953   * @example false
954   */closeOnClick:false,/**
955   * Allow the menu to auto adjust height.
956   * @option
957   * @example false
958   */autoHeight:false,/**
959   * Animate the auto adjust height.
960   * @option
961   * @example false
962   */animateHeight:false,/**
963   * Scroll to the top of the menu after opening a submenu or navigating back using the menu back button
964   * @option
965   * @example false
966   */scrollTop:false,/**
967   * String jquery selector (for example 'body') of element to take offset().top from, if empty string the drilldown menu offset().top is taken
968   * @option
969   * @example ''
970   */scrollTopElement:'',/**
971   * ScrollTop offset
972   * @option
973   * @example 100
974   */scrollTopOffset:0,/**
975   * Scroll animation duration
976   * @option
977   * @example 500
978   */animationDuration:500,/**
979   * Scroll animation easing
980   * @option
981   * @example 'swing'
982   */animationEasing:'swing'// holdOpen: false
983};// Window exports
984Foundation.plugin(Drilldown,'Drilldown');}(jQuery);
985'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
986 * Dropdown module.
987 * @module foundation.dropdown
988 * @requires foundation.util.keyboard
989 * @requires foundation.util.box
990 * @requires foundation.util.triggers
991 */var Dropdown=function(){/**
992   * Creates a new instance of a dropdown.
993   * @class
994   * @param {jQuery} element - jQuery object to make into a dropdown.
995   *        Object should be of the dropdown panel, rather than 
995its anchor.
996   * @param {Object} options - Overrides to the default plugin settings.
997   */function Dropdown(element,options){_classCallCheck(this,Dropdown);this.$element=element;this.options=$.extend({},Dropdown.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Dropdown');Foundation.Keyboard.register('Dropdown',{'ENTER':'open','SPACE':'open','ESCAPE':'close'});}/**
998   * Initializes the plugin by setting/checking options and attributes, adding helper variables, and saving the anchor.
999   * @function
1000   * @private
1001   */_createClass(Dropdown,[{key:'_init',value:function _init(){var $id=this.$element.attr('id');this.$anchor=$('[data-toggle="'+$id+'"]').length?$('[data-toggle="'+$id+'"]'):$('[data-open="'+$id+'"]');this.$anchor.attr({'aria-controls':$id,'data-is-focus':false,'data-yeti-box':$id,'aria-haspopup':true,'aria-expanded':false});if(this.options.parentClass){this.$parent=this.$element.parents('.'+this.options.parentClass);}else{this.$parent=null;}this.options.positionClass=this.getPositionClass();this.counter=4;this.usedPositions=[];this.$element.attr({'aria-hidden':'true','data-yeti-box':$id,'data-resize':$id,'aria-labelledby':this.$anchor[0].id||Foundation.GetYoDigits(6,'dd-anchor')});this._events();}/**
1002   * Helper function to determine current orientation of dropdown pane.
1003   * @function
1004   * @returns {String} position - string value of a position class.
1005   */},{key:'getPositionClass',value:function getPositionClass(){var verticalPosition=this.$element[0].className.match(/(top|left|right|bottom)/g);verticalPosition=verticalPosition?verticalPosition[0]:'';var horizontalPosition=/float-(\S+)/.exec(this.$anchor[0].className);horizontalPosition=horizontalPosition?horizontalPosition[1]:'';var position=horizontalPosition?horizontalPosition+' '+verticalPosition:verticalPosition;return position;}/**
1006   * Adjusts the dropdown panes orientation by adding/removing positioning classes.
1007   * @function
1008   * @private
1009   * @param {String} position - position class to remove.
1010   */},{key:'_reposition',value:function _reposition(position){this.usedPositions.push(position?position:'bottom');//default, try switching to opposite side
1011if(!position&&this.usedPositions.indexOf('top')<0){this.$element.addClass('top');}else if(position==='top'&&this.usedPositions.indexOf('bottom')<0){this.$element.removeClass(position);}else if(position==='left'&&this.usedPositions.indexOf('right')<0){this.$element.removeClass(position).addClass('right');}else if(position==='right'&&this.usedPositions.indexOf('left')<0){this.$element.removeClass(position).addClass('left');}//if default change didn't work, try bottom or left first
1012else if(!position&&this.usedPositions.indexOf('top')>-1&&this.usedPositions.indexOf('left')<0){this.$element.addClass('left');}else if(position==='top'&&this.usedPositions.indexOf('bottom')>-1&&this.usedPositions.indexOf('left')<0){this.$element.removeClass(position).addClass('left');}else if(position==='left'&&this.usedPositions.indexOf('right')>-1&&this.usedPositions.indexOf('bottom')<0){this.$element.removeClass(position);}else if(position==='right'&&this.usedPositions.indexOf('left')>-1&&this.usedPositions.indexOf('bottom')<0){this.$element.removeClass(position);}//if nothing cleared, set to bottom
1013else{this.$element.removeClass(position);}this.classChanged=true;this.counter--;}/**
1014   * Sets the position and orientation of the dropdown pane, checks for collisions.
1015   * Recursively calls itself if a collision is detected, with a new position class.
1016   * @function
1017   * @private
1018   */},{key:'_setPosition',value:function _setPosition(){if(this.$anchor.attr('aria-expanded')==='false'){return false;}var position=this.getPositionClass(),$eleDims=Foundation.Box.GetDimensions(this.$element),$anchorDims=Foundation.Box.GetDimensions(this.$anchor),_this=this,direction=position==='left'?'left':position==='right'?'left':'top',param=direction==='top'?'height':'width',offset=param==='height'?this.options.vOffset:this.options.hOffset;if($eleDims.width>=$eleDims.windowDims.width||!this.counter&&!Foundation.Box.ImNotTouchingYou(this.$element,this.$parent)){var newWidth=$eleDims.windowDims.width,parentHOffset=0;if(this.$parent){var $parentDims=Foundation.Box.GetDimensions(this.$parent),parentHOffset=$parentDims.offset.left;if($parentDims.width<newWidth){newWidth=$parentDims.width;}}this.$element.offset(Foundation.Box.GetOffsets(this.$element,this.$anchor,'center bottom',this.options.vOffset,this.options.hOffset+parentHOffset,true)).css({'width':newWidth-this.options.hOffset*2,'height':'auto'});this.classChanged=true;return false;}this.$element.offset(Foundation.Box.GetOffsets(this.$element,this.$anchor,position,this.options.vOffset,this.options.hOffset));while(!Foundation.Box.ImNotTouchingYou(this.$element,this.$parent,true)&&this.counter){this._reposition(position);this._setPosition();}}/**
1019   * Adds event listeners to the element utilizing the triggers utility library.
1020   * @function
1021   * @private
1022   */},{key:'_events',value:function _events(){var _this=this;this.$element.on({'open.zf.trigger':this.open.bind(this),'close.zf.trigger':this.close.bind(this),'toggle.zf.trigger':this.toggle.bind(this),'resizeme.zf.trigger':this._setPosition.bind(this)});if(this.options.hover){this.$anchor.off('mouseenter.zf.dropdown mouseleave.zf.dropdown').on('mouseenter.zf.dropdown',function(){var bodyData=$('body').data();if(typeof bodyData.whatinput==='undefined'||bodyData.whatinput==='mouse'){clearTimeout(_this.timeout);_this.timeout=setTimeout(function(){_this.open();_this.$anchor.data('hover',true);},_this.options.hoverDelay);}}).on('mouseleave.zf.dropdown',function(){clearTimeout(_this.timeout);_this.timeout=setTimeout(function(){_this.close();_this.$anchor.data('hover',false);},_this.options.hoverDelay);});if(this.options.hoverPane){this.$element.off('mouseenter.zf.dropdown mouseleave.zf.dropdown').on('mouseenter.zf.dropdown',function(){clearTimeout(_this.timeout);}).on('mouseleave.zf.dropdown',function(){clearTimeout(_this.timeout);_this.timeout=setTimeout(function(){_this.close();_this.$anchor.data('hover',false);},_this.options.hoverDelay);});}}this.$anchor.add(this.$element).on('keydown.zf.dropdown',function(e){var $target=$(this),visibleFocusableElements=Foundation.Keyboard.findFocusable(_this.$element);Foundation.Keyboard.handleKey(e,'Dropdown',{open:function open(){if($target.is(_this.$anchor)){_this.open();_this.$element.attr('tabindex',-1).focus();e.preventDefault();}},close:function close(){_this.close();_this.$anchor.focus();}});});}/**
1023   * Adds an event handler to the body to close any dropdowns on a click.
1024   * @function
1025   * @private
1026   */},{key:'_addBodyHandler',value:function _addBodyHandler(){var $body=$(document.body).not(this.$element),_this=this;$body.off('click.zf.dropdown').on('click.zf.dropdown',function(e){if(_this.$anchor.is(e.target)||_this.$anchor.find(e.target).length){return;}if(_this.$element.find(e.target).length){return;}_this.close();$body.off('click.zf.dropdown');});}/**
1027   * Opens the dropdown pane, and fires a bubbling event to close other dropdowns.
1028   * @function
1029   * @fires Dropdown#closeme
1030   * @fires Dropdown#show
1031   */},{key:'open',value:function open(){// var _this = this;
1032/**
1033     * Fires to close other open dropdowns
1034     * @event Dropdown#closeme
1035     */this.$element.trigger('closeme.zf.dropdown',this.$element.attr('id'));this.$anchor.addClass('hover').attr({'aria-expanded':true});// this.$element/*.show()*/;
1036this._setPosition();this.$element.addClass('is-open').attr({'aria-hidden':false});
1036if(this.options.autoFocus){var $focusable=Foundation.Keyboard.findFocusable(this.$element);if($focusable.length){$focusable.eq(0).focus();}}if(this.options.closeOnClick){this._addBodyHandler();}if(this.options.trapFocus){Foundation.Keyboard.trapFocus(this.$element);}/**
1037     * Fires once the dropdown is visible.
1038     * @event Dropdown#show
1039     */this.$element.trigger('show.zf.dropdown',[this.$element]);}/**
1040   * Closes the open dropdown pane.
1041   * @function
1042   * @fires Dropdown#hide
1043   */},{key:'close',value:function close(){if(!this.$element.hasClass('is-open')){return false;}this.$element.removeClass('is-open').attr({'aria-hidden':true});this.$anchor.removeClass('hover').attr('aria-expanded',false);if(this.classChanged){var curPositionClass=this.getPositionClass();if(curPositionClass){this.$element.removeClass(curPositionClass);}this.$element.addClass(this.options.positionClass)/*.hide()*/.css({height:'',width:''});this.classChanged=false;this.counter=4;this.usedPositions.length=0;}this.$element.trigger('hide.zf.dropdown',[this.$element]);if(this.options.trapFocus){Foundation.Keyboard.releaseFocus(this.$element);}}/**
1044   * Toggles the dropdown pane's visibility.
1045   * @function
1046   */},{key:'toggle',value:function toggle(){if(this.$element.hasClass('is-open')){if(this.$anchor.data('hover'))return;this.close();}else{this.open();}}/**
1047   * Destroys the dropdown.
1048   * @function
1049   */},{key:'destroy',value:function destroy(){this.$element.off('.zf.trigger').hide();this.$anchor.off('.zf.dropdown');Foundation.unregisterPlugin(this);}}]);return Dropdown;}();Dropdown.defaults={/**
1050   * Class that designates bounding container of Dropdown (Default: window)
1051   * @option
1052   * @example 'dropdown-parent'
1053   */parentClass:null,/**
1054   * Amount of time to delay opening a submenu on hover event.
1055   * @option
1056   * @example 250
1057   */hoverDelay:250,/**
1058   * Allow submenus to open on hover events
1059   * @option
1060   * @example false
1061   */hover:false,/**
1062   * Don't close dropdown when hovering over dropdown pane
1063   * @option
1064   * @example true
1065   */hoverPane:false,/**
1066   * Number of pixels between the dropdown pane and the triggering element on open.
1067   * @option
1068   * @example 1
1069   */vOffset:1,/**
1070   * Number of pixels between the dropdown pane and the triggering element on open.
1071   * @option
1072   * @example 1
1073   */hOffset:1,/**
1074   * Class applied to adjust open position. JS will test and fill this in.
1075   * @option
1076   * @example 'top'
1077   */positionClass:'',/**
1078   * Allow the plugin to trap focus to the dropdown pane if opened with keyboard commands.
1079   * @option
1080   * @example false
1081   */trapFocus:false,/**
1082   * Allow the plugin to set focus to the first focusable element within the pane, regardless of method of opening.
1083   * @option
1084   * @example true
1085   */autoFocus:false,/**
1086   * Allows a click on the body to close the dropdown.
1087   * @option
1088   * @example false
1089   */closeOnClick:false};// Window exports
1090Foundation.plugin(Dropdown,'Dropdown');}(jQuery);
1091'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1092 * DropdownMenu module.
1093 * @module foundation.dropdown-menu
1094 * @requires foundation.util.keyboard
1095 * @requires foundation.util.box
1096 * @requires foundation.util.nest
1097 */var DropdownMenu=function(){/**
1098   * Creates a new instance of DropdownMenu.
1099   * @class
1100   * @fires DropdownMenu#init
1101   * @param {jQuery} element - jQuery object to make into a dropdown menu.
1102   * @param {Object} options - Overrides to the default plugin settings.
1103   */function DropdownMenu(element,options){_classCallCheck(this,DropdownMenu);this.$element=element;this.options=$.extend({},DropdownMenu.defaults,this.$element.data(),options);Foundation.Nest.Feather(this.$element,'dropdown');this._init();Foundation.registerPlugin(this,'DropdownMenu');Foundation.Keyboard.register('DropdownMenu',{'ENTER':'open','SPACE':'open','ARROW_RIGHT':'next','ARROW_UP':'up','ARROW_DOWN':'down','ARROW_LEFT':'previous','ESCAPE':'close'});}/**
1104   * Initializes the plugin, and calls _prepareMenu
1105   * @private
1106   * @function
1107   */_createClass(DropdownMenu,[{key:'_init',value:function _init(){var subs=this.$element.find('li.is-dropdown-submenu-parent');this.$element.children('.is-dropdown-submenu-parent').children('.is-dropdown-submenu').addClass('first-sub');this.$menuItems=this.$element.find('[role="menuitem"]');this.$tabs=this.$element.children('[role="menuitem"]');this.$tabs.find('ul.is-dropdown-submenu').addClass(this.options.verticalClass);if(this.$element.hasClass(this.options.rightClass)||this.options.alignment==='right'||Foundation.rtl()||this.$element.parents('.top-bar-right').is('*')){this.options.alignment='right';subs.addClass('opens-left');}else{subs.addClass('opens-right');}this.changed=false;this._events();}},{key:'_isVertical',value:function _isVertical(){return this.$tabs.css('display')==='block';}/**
1108   * Adds event listeners to elements within the menu
1109   * @private
1110   * @function
1111   */},{key:'_events',value:function _events(){var _this=this,hasTouch='ontouchstart'in window||typeof window.ontouchstart!=='undefined',parClass='is-dropdown-submenu-parent';// used for onClick and in the keyboard handlers
vendor: 4,158 bytes, lines 1112-1129
1112var handleClickFn=function handleClickFn(e){var $elem=$(e.target).parentsUntil('ul','.'+parClass),hasSub=$elem.hasClass(parClass),hasClicked=$elem.attr('data-is-click')==='true',$sub=$elem.children('.is-dropdown-submenu');if(hasSub){if(hasClicked){if(!_this.options.closeOnClick||!_this.options.clickOpen&&!hasTouch||_this.options.forceFollow&&hasTouch){return;}else{e.stopImmediatePropagation();e.preventDefault();_this._hide($elem);}}else{e.preventDefault();e.stopImmediatePropagation();_this._show($sub);$elem.add($elem.parentsUntil(_this.$element,'.'+parClass)).attr('data-is-click',true);}}};if(this.options.clickOpen||hasTouch){this.$menuItems.on('click.zf.dropdownmenu touchstart.zf.dropdownmenu',handleClickFn);}// Handle Leaf element Clicks
1113if(_this.options.closeOnClickInside){this.$menuItems.on('click.zf.dropdownmenu touchend.zf.dropdownmenu',function(e){var $elem=$(this),hasSub=$elem.hasClass(parClass);if(!hasSub){_this._hide();}});}if(!this.options.disableHover){this.$menuItems.on('mouseenter.zf.dropdownmenu',function(e){var $elem=$(this),hasSub=$elem.hasClass(parClass);if(hasSub){clearTimeout($elem.data('_delay'));$elem.data('_delay',setTimeout(function(){_this._show($elem.children('.is-dropdown-submenu'));},_this.options.hoverDelay));}}).on('mouseleave.zf.dropdownmenu',function(e){var $elem=$(this),hasSub=$elem.hasClass(parClass);if(hasSub&&_this.options.autoclose){if($elem.attr('data-is-click')==='true'&&_this.options.clickOpen){return false;}clearTimeout($elem.data('_delay'));$elem.data('_delay',setTimeout(function(){_this._hide($elem);},_this.options.closingTime));}});}this.$menuItems.on('keydown.zf.dropdownmenu',function(e){var $element=$(e.target).parentsUntil('ul','[role="menuitem"]'),isTab=_this.$tabs.index($element)>-1,$elements=isTab?_this.$tabs:$element.siblings('li').add($element),$prevElement,$nextElement;$elements.each(function(i){if($(this).is($element)){$prevElement=$elements.eq(i-1);$nextElement=$elements.eq(i+1);return;}});var nextSibling=function nextSibling(){if(!$element.is(':last-child')){$nextElement.children('a:first').focus();e.preventDefault();}},prevSibling=function prevSibling(){$prevElement.children('a:first').focus();e.preventDefault();},openSub=function openSub(){var $sub=$element.children('ul.is-dropdown-submenu');if($sub.length){_this._show($sub);$element.find('li > a:first').focus();e.preventDefault();}else{return;}},closeSub=function closeSub(){//if ($element.is(':first-child')) {
1114var close=$element.parent('ul').parent('li');close.children('a:first').focus();_this._hide(close);e.preventDefault();//}
1115};var functions={open:openSub,close:function close(){_this._hide(_this.$element);_this.$menuItems.find('a:first').focus();// focus to first element
1116e.preventDefault();},handled:function handled(){e.stopImmediatePropagation();}};if(isTab){if(_this._isVertical()){// vertical menu
1117if(Foundation.rtl()){// right aligned
1118$.extend(functions,{down:nextSibling,up:prevSibling,next:closeSub,previous:openSub});}else{// left aligned
1119$.extend(functions,{down:nextSibling,up:prevSibling,next:openSub,previous:closeSub});}}else{// horizontal menu
1120if(Foundation.rtl()){// right aligned
1121$.extend(functions,{next:prevSibling,previous:nextSibling,down:openSub,up:closeSub});}else{// left aligned
1122$.extend(functions,{next:nextSibling,previous:prevSibling,down:openSub,up:closeSub});}}}else{// not tabs -> one sub
1123if(Foundation.rtl()){// right aligned
1124$.extend(functions,{next:closeSub,previous:openSub,down:nextSibling,up:prevSibling});}else{// left aligned
1125$.extend(functions,{next:openSub,previous:closeSub,down:nextSibling,up:prevSibling});}}Foundation.Keyboard.handleKey(e,'DropdownMenu',functions);});}/**
1126   * Adds an event handler to the body to close any dropdowns on a click.
1127   * @function
1128   * @private
1129   */},{key:'_addBodyHandler',value:function _addBodyHandler(){var $body=$(document.body),_this=this;$body.off('mouseup.zf.dropdownmenu touchend.zf.dropdownmenu').on('mouseup.zf.dropdownmenu touchend.zf.dropdownmenu',function(e){var $link=_this.$element.find(e.target);if($link.length){return;}_this._hide();$body.off('mouseup.zf.dropdownmenu touchend.zf.dropdownmenu');});}/**
1130   * Opens a dropdown pane, and checks for collisions first.
1131   * @param {jQuery} $sub - ul element that is a submenu to show
1132   * @function
1133   * @private
1134   * @fires DropdownMenu#show
1135   */},{key:'_show',value:function _show($sub){var idx=this.$tabs.index(this.$tabs.filter(function(i,el){return $(el).find($sub).length>0;}));var $sibs=$sub.parent('li.is-dropdown-submenu-parent').siblings('li.is-dropdown-submenu-parent');this._hide($sibs,idx);$sub.css('visibility','hidden').addClass('js-dropdown-active').parent('li.is-dropdown-submenu-parent').addClass('is-active');var clear=Foundation.Box.ImNotTouchingYou($sub,null,true);if(!clear){var oldClass=this.options.alignment==='left'?'-right':'-left',$parentLi=$sub.parent('.is-dropdown-submenu-parent');$parentLi.removeClass('opens'+oldClass).addClass('opens-'+this.options.alignment);clear=Foundation.Box.ImNotTouchingYou($sub,null,true);if(!clear){$parentLi.removeClass('opens-'+this.options.alignment).addClass('opens-inner');}this.changed=true;}$sub.css('visibility','');if(this.options.closeOnClick){this._addBodyHandler();}/**
1136     * Fires when the new dropdown pane is visible.
1137     * @event DropdownMenu#show
1138     */this.$element.trigger('show.zf.dropdownmenu',[$sub]);}/**
1139   * Hides a single, currently open dropdown pane, if passed a parameter, otherwise, hides everything.
1140   * @function
1141   * @param {jQuery} $elem - element with a submenu to hide
1142   * @param {Number} idx - index of the $tabs collection to hide
1143   * @private
1144   */},{key:'_hide',value:function _hide($elem,idx){var $toClose;if($elem&&$elem.length){$toClose=$elem;}else if(idx!==undefined){$toClose=this.$tabs.not(function(i,el){return i===idx;});}else{$toClose=this.$element;}var somethingToClose=$toClose.hasClass('is-active')||$toClose.find('.is-active').length>0;if(somethingToClose){$toClose.find('li.is-active').add($toClose).attr({'data-is-click':false}).removeClass('is-active');$toClose.find('ul.js-dropdown-active').removeClass('js-dropdown-active');if(this.changed||$toClose.find('opens-inner').length){var oldClass=this.options.alignment==='left'?'right':'left';$toClose.find('li.is-dropdown-submenu-parent').add($toClose).removeClass('opens-inner opens-'+this.options.alignment).addClass('opens-'+oldClass);this.changed=false;}/**
1145       * Fires when the open menus are closed.
1146       * @event DropdownMenu#hide
1147       */this.$element.trigger('hide.zf.dropdownmenu',[$toClose]);}}/**
1148   * Destroys the plugin.
1149   * @function
1150   */},{key:'destroy',value:function destroy(){this.$menuItems.off('.zf.dropdownmenu').removeAttr('data-is-click').removeClass('is-right-arrow is-left-arrow is-down-arrow opens-right opens-left opens-inner');$(document.body).off('.zf.dropdownmenu');Foundation.Nest.Burn(this.$element,'dropdown');Foundation.unregisterPlugin(this);}}]);return DropdownMenu;}();/**
1151 * Default settings for plugin
1152 */DropdownMenu.defaults={/**
1153   * Disallows hover events from opening submenus
1154   * @option
1155   * @example false
1156   */disableHover:false,/**
1157   * Allow a submenu to automatically close on a mouseleave event, if not clicked open.
1158   * @option
1159   * @example true
1160   */autoclose:true,/**
1161   * Amount of time to delay opening a submenu on hover event.
1162   * @option
1163   * @example 50
1164   */hoverDelay:50,/**
1165   * Allow a submenu to open/remain open on parent click event. Allows cursor to move away from menu.
1166   * @option
1167   * @example true
1168   */clickOpen:false,/**
1169   * Amount of time to delay closing a submenu on a mouseleave event.
1170   * @option
1171   * @example 500
1172   */closingTime:500,/**
1173   * Position of the menu relative to what direction the submenus should open. Handled by JS.
1174   * @option
1175   * @example 'left'
1176   */alignment:'left',/**
1177   * Allow clicks on the body to close any open submenus.
1178   * @option
1179   * @example true
1180   */closeOnClick:true,/**
1181   * Allow clicks on leaf anchor links to close any open submenus.
1182   * @option
1183   * @example true
1184   */closeOnClickInside:true,/**
1185   * Class applied to vertical oriented menus, Foundation default is `vertical`. Update this if using your own class.
1186   * @option
1187   * @example 'vertical'
1188   */verticalClass:'vertical',/**
1189   * Class applied to right-side oriented menus, Foundation default is `align-right`. Update this if using your own class.
1190   * @option
1191   * @example 'align-right'
1192   */rightClass:'align-right',/**
1193   * Boolean to force overide the clicking of links to perform default action, on second touch event for mobile.
1194   * @option
1195   * @example false
1196   */forceFollow:true};// Window exports
1197Foundation.plugin(DropdownMenu,'DropdownMenu');}(jQuery);
1198'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1199 * Equalizer module.
1200 * @module foundation.equalizer
1201 * @requires foundation.util.mediaQuery
1202 * @requires foundation.util.timerAndImageLoader if equalizer contains images
1203 */var Equalizer=function(){/**
1204   * Creates a new instance of Equalizer.
1205   * @class
1206   * @fires Equalizer#init
1207   * @param {Object} element - jQuery object to add the trigger to.
1208   * @param {Object} options - Overrides to the default plugin settings.
1209   */function Equalizer(element,options){_classCallCheck(this,Equalizer);this.$element=element;this.options=$.extend({},Equalizer.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Equalizer');}/**
1210   * Initializes the Equalizer plugin and calls functions to get equalizer functioning on load.
1211   * @private
1212   */_createClass(Equalizer,[{key:'_init',value:function _init(){var eqId=this.$element.attr('data-equalizer')||'';var $watched=this.$element.find('[data-equalizer-watch="'+eqId+'"]');this.$watched=$watched.length?$watched:this.$element.find('[data-equalizer-watch]');this.$element.attr('data-resize',eqId||Foundation.GetYoDigits(6,'eq'));this.$element.attr('data-mutate',eqId||Foundation.GetYoDigits(6,'eq'));this.hasNested=this.$element.find('[data-equalizer]').length>0;this.isNested=this.$element.parentsUntil(document.body,'[data-equalizer]').length>0;this.isOn=false;this._bindHandler={onResizeMeBound:this._onResizeMe.bind(this),onPostEqualizedBound:this._onPostEqualized.bind(this)};var imgs=this.$element.find('img');var tooSmall;if(this.options.equalizeOn){tooSmall=this._checkMQ();$(window).on('changed.zf.mediaquery',this._checkMQ.bind(this));}else{this._events();}if(tooSmall!==undefined&&tooSmall===false||tooSmall===undefined){if(imgs.length){Foundation.onImagesLoaded(imgs,this._reflow.bind(this));}else{this._reflow();}}}/**
1213   * Removes event listeners if the breakpoint is too small.
1214   * @private
1215   */},{key:'_pauseEvents',value:function _pauseEvents(){this.isOn=false;
vendor: 4,151 bytes, lines 1215-1253
1215this.$element.off({'.zf.equalizer':this._bindHandler.onPostEqualizedBound,'resizeme.zf.trigger':this._bindHandler.onResizeMeBound,'mutateme.zf.trigger':this._bindHandler.onResizeMeBound});}/**
1216   * function to handle $elements resizeme.zf.trigger, with bound this on _bindHandler.onResizeMeBound
1217   * @private
1218   */},{key:'_onResizeMe',value:function _onResizeMe(e){this._reflow();}/**
1219   * function to handle $elements postequalized.zf.equalizer, with bound this on _bindHandler.onPostEqualizedBound
1220   * @private
1221   */},{key:'_onPostEqualized',value:function _onPostEqualized(e){if(e.target!==this.$element[0]){this._reflow();}}/**
1222   * Initializes events for Equalizer.
1223   * @private
1224   */},{key:'_events',value:function _events(){var _this=this;this._pauseEvents();if(this.hasNested){this.$element.on('postequalized.zf.equalizer',this._bindHandler.onPostEqualizedBound);}else{this.$element.on('resizeme.zf.trigger',this._bindHandler.onResizeMeBound);this.$element.on('mutateme.zf.trigger',this._bindHandler.onResizeMeBound);}this.isOn=true;}/**
1225   * Checks the current breakpoint to the minimum required size.
1226   * @private
1227   */},{key:'_checkMQ',value:function _checkMQ(){var tooSmall=!Foundation.MediaQuery.is(this.options.equalizeOn);if(tooSmall){if(this.isOn){this._pauseEvents();this.$watched.css('height','auto');}}else{if(!this.isOn){this._events();}}return tooSmall;}/**
1228   * A noop version for the plugin
1229   * @private
1230   */},{key:'_killswitch',value:function _killswitch(){return;}/**
1231   * Calls necessary functions to update Equalizer upon DOM change
1232   * @private
1233   */},{key:'_reflow',value:function _reflow(){if(!this.options.equalizeOnStack){if(this._isStacked()){this.$watched.css('height','auto');return false;}}if(this.options.equalizeByRow){this.getHeightsByRow(this.applyHeightByRow.bind(this));}else{this.getHeights(this.applyHeight.bind(this));}}/**
1234   * Manually determines if the first 2 elements are *NOT* stacked.
1235   * @private
1236   */},{key:'_isStacked',value:function _isStacked(){if(!this.$watched[0]||!this.$watched[1]){return true;}return this.$watched[0].getBoundingClientRect().top!==this.$watched[1].getBoundingClientRect().top;}/**
1237   * Finds the outer heights of children contained within an Equalizer parent and returns them in an array
1238   * @param {Function} cb - A non-optional callback to return the heights array to.
1239   * @returns {Array} heights - An array of heights of children within Equalizer container
1240   */},{key:'getHeights',value:function getHeights(cb){var heights=[];for(var i=0,len=this.$watched.length;i<len;i++){this.$watched[i].style.height='auto';heights.push(this.$watched[i].offsetHeight);}cb(heights);}/**
1241   * Finds the outer heights of children contained within an Equalizer parent and returns them in an array
1242   * @param {Function} cb - A non-optional callback to return the heights array to.
1243   * @returns {Array} groups - An array of heights of children within Equalizer container grouped by row with element,height and max as last child
1244   */},{key:'getHeightsByRow',value:function getHeightsByRow(cb){var lastElTopOffset=this.$watched.length?this.$watched.first().offset().top:0,groups=[],group=0;//group by Row
1245groups[group]=[];for(var i=0,len=this.$watched.length;i<len;i++){this.$watched[i].style.height='auto';//maybe could use this.$watched[i].offsetTop
1246var elOffsetTop=$(this.$watched[i]).offset().top;if(elOffsetTop!=lastElTopOffset){group++;groups[group]=[];lastElTopOffset=elOffsetTop;}groups[group].push([this.$watched[i],this.$watched[i].offsetHeight]);}for(var j=0,ln=groups.length;j<ln;j++){var heights=$(groups[j]).map(function(){return this[1];}).get();var max=Math.max.apply(null,heights);groups[j].push(max);}cb(groups);}/**
1247   * Changes the CSS height property of each child in an Equalizer parent to match the tallest
1248   * @param {array} heights - An array of heights of children within Equalizer container
1249   * @fires Equalizer#preequalized
1250   * @fires Equalizer#postequalized
1251   */},{key:'applyHeight',value:function applyHeight(heights){var max=Math.max.apply(null,heights);/**
1252     * Fires before the heights are applied
1253     * @event Equalizer#preequalized
1254     */this.$element.trigger('preequalized.zf.equalizer');this.$watched.css('height',max);/**
1255     * Fires when the heights have been applied
1256     * @event Equalizer#postequalized
1257     */this.$element.trigger('postequalized.zf.equalizer');}/**
1258   * Changes the CSS height property of each child in an Equalizer parent to match the tallest by row
1259   * @param {array} groups - An array of heights of children within Equalizer container grouped by row with element,height and max as last child
1260   * @fires Equalizer#preequalized
1261   * @fires Equalizer#preequalizedrow
1262   * @fires Equalizer#postequalizedrow
1263   * @fires Equalizer#postequalized
1264   */},{key:'applyHeightByRow',value:function applyHeightByRow(groups){/**
1265     * Fires before the heights are applied
1266     */this.$element.trigger('preequalized.zf.equalizer');for(var i=0,len=groups.length;i<len;i++){var groupsILength=groups[i].length,max=groups[i][groupsILength-1];if(groupsILength<=2){$(groups[i][0][0]).css({'height':'auto'});continue;}/**
1267        * Fires before the heights per row are applied
1268        * @event Equalizer#preequalizedrow
1269        */this.$element.trigger('preequalizedrow.zf.equalizer');for(var j=0,lenJ=groupsILength-1;j<lenJ;j++){$(groups[i][j][0]).css({'height':max});}/**
1270        * Fires when the heights per row have been applied
1271        * @event Equalizer#postequalizedrow
1272        */this.$element.trigger('postequalizedrow.zf.equalizer');}/**
1273     * Fires when the heights have been applied
1274     */this.$element.trigger('postequalized.zf.equalizer');}/**
1275   * Destroys an instance of Equalizer.
1276   * @function
1277   */},{key:'destroy',value:function destroy(){this._pauseEvents();this.$watched.css('height','auto');Foundation.unregisterPlugin(this);}}]);return Equalizer;}();/**
1278 * Default settings for plugin
1279 */Equalizer.defaults={/**
1280   * Enable height equalization when stacked on smaller screens.
1281   * @option
1282   * @example true
1283   */equalizeOnStack:false,/**
1284   * Enable height equalization row by row.
1285   * @option
1286   * @example false
1287   */equalizeByRow:false,/**
1288   * String representing the minimum breakpoint size the plugin should equalize heights on.
1289   * @option
1290   * @example 'medium'
1291   */equalizeOn:''};// Window exports
1292Foundation.plugin(Equalizer,'Equalizer');}(jQuery);
1293'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1294 * Interchange module.
1295 * @module foundation.interchange
1296 * @requires foundation.util.mediaQuery
1297 * @requires foundation.util.timerAndImageLoader
1298 */var Interchange=function(){/**
1299   * Creates a new instance of Interchange.
1300   * @class
1301   * @fires Interchange#init
1302   * @param {Object} element - jQuery object to add the trigger to.
1303   * @param {Object} options - Overrides to the default plugin settings.
1304   */function Interchange(element,options){_classCallCheck(this,Interchange);this.$element=element;this.options=$.extend({},Interchange.defaults,options);this.rules=[];this.currentPath='';this._init();this._events();Foundation.registerPlugin(this,'Interchange');}/**
1305   * Initializes the Interchange plugin and calls functions to get interchange functioning on load.
1306   * @function
1307   * @private
1308   */_createClass(Interchange,[{key:'_init',value:function _init(){this._addBreakpoints();this._generateRules();this._reflow();}/**
1309   * Initializes events for Interchange.
1310   * @function
1311   * @private
1312   */},{key:'_events',value:function _events(){var _this2=this;$(window).on('resize.zf.interchange',Foundation.util.throttle(function(){_this2._reflow();},50));}/**
1313   * Calls necessary functions to update Interchange upon DOM change
1314   * @function
1315   * @private
1316   */},{key:'_reflow',value:function _reflow(){var match;// Iterate through each rule, but only save the last match
1317for(var i in this.rules){if(this.rules.hasOwnProperty(i)){var rule=this.rules[i];if(window.matchMedia(rule.query).matches){match=rule;}}}if(match){this.replace(match.path);}}/**
1318   * Gets the Foundation breakpoints and adds them to the Interchange.SPECIAL_QUERIES object.
1319   * @function
1320   * @private
1321   */},{key:'_addBreakpoints',value:function _addBreakpoints(){for(var i in Foundation.MediaQuery.queries){if(Foundation.MediaQuery.queries.hasOwnProperty(i)){var query=Foundation.MediaQuery.queries[i];Interchange.SPECIAL_QUERIES[query.name]=query.value;}}}/**
1322   * Checks the Interchange element for the provided media query + content pairings
1323   * @function
1324   * @private
1325   * @param {Object} element - jQuery object that is an Interchange instance
1326   * @returns {Array} scenarios - Array of objects that have 'mq' and 'path' keys with corresponding keys
1327   */},{key:'_generateRules',value:function _generateRules(element){var rulesList=[];var rules;if(this.options.rules){rules=this.options.rules;}else{rules=this.$element.data('interchange').match(/\[.*?\]/g);}for(var i in rules){if(rules.hasOwnProperty(i)){var rule=rules[i].slice(1,-1).split(', ');var path=rule.slice(0,-1).join('');var query=rule[rule.length-1];if(Interchange.SPECIAL_QUERIES[query]){query=Interchange.SPECIAL_QUERIES[query];}rulesList.push({path:path,query:query});}}this.rules=rulesList;}/**
1328   * Update the `src` property of an image, or change the HTML of a container, to the specified path.
1329   * @function
1330   * @param {String} path - Path to the image or HTML partial.
1331   * @fires Interchange#replaced
1332   */},{key:'replace',value:function replace(path){if(this.currentPath===path)return;var _this=this,trigger='replaced.zf.interchange';// Replacing images
1333if(this.$element[0].nodeName==='IMG'){this.$element.attr('src',path).on('load',function(){_this.currentPath=path;}).trigger(trigger);}// Replacing background images
1334else if(path.match(/\.(gif|jpg|jpeg|png|svg|tiff)([?#].*)?/i)){this.$element.css({'background-image':'url('+path+')'}).trigger(trigger);}// Replacing HTML
1335else{$.get(path,function(response){_this.$element.html(response).trigger(trigger);$(response).foundation();_this.currentPath=path;});}/**
1336     * Fires when content in an Interchange element is done being loaded.
1337     * @event Interchange#replaced
1338     */// this.$element.trigger('replaced.zf.interchange');
1339}/**
1340   * Destroys an instance of interchange.
1341   * @function
1342   */},{key:'destroy',value:function destroy(){//TODO this.
1343}}]);return Interchange;}();/**
1344 * Default settings for plugin
1345 */Interchange.defaults={/**
1346   * Rules to be applied to Interchange elements. Set with the `data-interchange` array notation.
1347   * @option
1348   */rules:null};Interchange.SPECIAL_QUERIES={'landscape':'screen and (orientation: landscape)','portrait':'screen and (orientation: portrait)','retina':'only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx)'};// Window exports
1349Foundation.plugin(Interchange,'Interchange');}(jQuery);
1350'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1351 * Magellan module.
1352 * @module foundation.magellan
1353 */var Magellan=function(){/**
1354   * Creates a new instance of Magellan.
1355   * @class
1356   * @fires Magellan#init
1357   * @param {Object} element - jQuery object to add the trigger to.
1358   * @param {Object} options - Overrides to the default plugin settings.
1359   */function Magellan(element,options){_classCallCheck(this,Magellan);this.$element=element;this.options=$.extend({},Magellan.defaults,this.$element.data(),options);this._init();this.calcPoints();Foundation.registerPlugin(this,'Magellan');}/**
1360   * Initializes the Magellan plugin and calls functions to get equalizer functioning on load.
1361   * @private
1362   */_createClass(Magellan,[{key:'_init',value:function _init(){var id=this.$element[0].id||Foundation.GetYoDigits(6,'magellan');var _this=this;this.$targets=$('[data-magellan-target]');this.$links=this.$element.find('a');this.$element.attr({'data-resize':id,'data-scroll':id,'id':id});this.$active=$();this.scrollPos=parseInt(window.pageYOffset,10);this._events();}/**
1363   * Calculates an array of pixel values that are the demarcation lines between locations on the page.
1364   * Can be invoked if new elements are added or the size of a location changes.
1365   * @function
1366   */},{key:'calcPoints',value:function calcPoints(){var _this=this,body=document.body,html=document.documentElement;this.points=[];this.winHeight=Math.round(Math.max(window.innerHeight,html.clientHeight));this.docHeight=Math.round(Math.max(body.scrollHeight,body.offsetHeight,html.clientHeight,html.scrollHeight,html.offsetHeight));this.$targets.each(function(){var $tar=$(this),pt=Math.round($tar.offset().top-_this.options.threshold);$tar.targetPoint=pt;_this.points.push(pt);});}/**
1367   * Initializes events for Magellan.
1368   * @private
1369   */},{key:'_events',value:function _events(){var _this=this,$body=$('html, body'),opts={duration:_this.options.animationDuration,easing:_this.options.animationEasing};$(window).one('load',function(){if(_this.options.deepLinking){if(location.hash){_this.scrollToLoc(location.hash);}}_this.calcPoints();_this._updateActive();});this.$element.on({'resizeme.zf.trigger':this.reflow.bind(this),'scrollme.zf.trigger':this._updateActive.bind(this)}).on('click.zf.magellan','a[href^="#"]',function(e){e.preventDefault();var arrival=this.getAttribute('href');_this.scrollToLoc(arrival);});$(window).on('popstate',function(e){if(_this.options.deepLinking){_this.scrollToLoc(window.location.hash);}});}/**
1370   * Function to scroll to a given location on the page.
1371   * @param {String} loc - a properly formatted jQuery id selector. Example: '#foo'
1372   * @function
1373   */},{key:'scrollToLoc',value:function scrollToLoc(loc){// Do nothing if target does not exist to prevent errors
1374if(!$(loc).length){return false;}this._inTransition=true;var _this=this,scrollPos=Math.round($(loc).offset().top-this.options.threshold/2-this.options.barOffset);$('html, body').stop(true).animate({scrollTop:scrollPos},this.options.animationDuration,this.options.animationEasing,function(){_this._inTransition=false;_this._updateActive();});}/**
1375   * Calls necessary functions to update Magellan upon DOM change
1376   * @function
1377   */},{key:'reflow',value:function reflow(){this.calcPoints();this._updateActive();}/**
1378   * Updates the visibility of an active location link, and updates the url hash for the page, if deepLinking enabled.
1379   * @private
1380   * @function
1381   * @fires Magellan#update
1382   */},{key:'_updateActive',value:function _updateActive()/*evt, elem, scrollPos*/{if(this._inTransition){return;}var winPos=/*scrollPos ||*/parseInt(window.pageYOffset,10),curIdx;if(winPos+this.winHeight===this.docHeight){curIdx=this.points.length-1;}else if(winPos<this.points[0]){curIdx=undefined;}else{var isDown=this.scrollPos<winPos,_this=this,curVisible=this.points.filter(function(p,i){return isDown?p-_this.options.barOffset<=winPos:p-_this.options.barOffset-_this.options.threshold<=winPos;});curIdx=curVisible.length?curVisible.length-1:0;}this.$active.removeClass(this.options.activeClass);this.$active=this.$links.filter('[href="#'+this.$targets.eq(curIdx).data('magellan-target')+'"]').addClass(this.options.activeClass);if(this.options.deepLinking){var hash="";if(curIdx!=undefined){hash=this.$active[0].getAttribute('href');}if(hash!==window.location.hash){if(window.history.pushState){window.history.pushState(null,null,hash);}else{window.location.hash=hash;}}}this.scrollPos=winPos;/**
1383     * Fires when magellan is finished updating to the new active element.
1384     * @event Magellan#update
1385     */this.$element.trigger('update.zf.magellan',[this.$active]);}/**
1386   * Destroys an instance of Magellan and resets the url of the window.
1387   * @function
1388   */},{key:'destroy',value:function destroy(){this.$element.off('.zf.trigger .zf.magellan').find('.'+this.options.activeClass).removeClass(this.options.activeClass);if(this.options.deepLinking){var hash=this.$active[0].getAttribute('href');window.location.hash.replace(hash,'');}Foundation.unregisterPlugin(this);}}]);return Magellan;}();/**
1389 * Default settings for plugin
1390 */Magellan.defaults={/**
1391   * Amount of time, in ms, the animated scrolling should take between locations.
1392   * @option
1393   * @example 500
1394   */animationDuration:500,/**
1395   * Animation style to use when scrolling between locations.
1396   * @option
1397   * @example 'ease-in-out'
1398   */animationEasing:'linear',/**
1399   * Number of pixels to use as a marker for location changes.
1400   * @option
1401   * @example 50
1402   */threshold:50,/**
1403   * Class applied to the active locations link on the magellan container.
1404   * @option
1405   * @example 'active'
1406   */activeClass:'active',/**
1407   * Allows the script to manipulate the url of the current page, and if supported, alter the history.
1408   * @option
1409   * @example true
1410   */deepLinking:false,/**
1411   * Number of pixels to offset the scroll of the page on item click if using a sticky nav bar.
1412   * @option
1413   * @example 25
1414   */barOffset:0};// Window exports
1415Foundation.plugin(Magellan,'Magellan');}(jQuery);
1416'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1417 * OffCanvas module.
1418 * @module foundation.offcanvas
1419 * @requires foundation.util.mediaQuery
1420 * @requires foundation.util.triggers
1421 * @requires foundation.util.motion
1422 */var OffCanvas=function(){/**
1423   * Creates a new instance of an off-canvas wrapper.
1424   * @class
1425   * @fires OffCanvas#init
1426   * @param {Object} element - jQuery object to initialize.
1427   * @param {Object} options - Overrides to the default plugin settings.
1428   */function OffCanvas(element,options){_classCallCheck(this,OffCanvas);this.$element=element;this.options=$.extend({},OffCanvas.defaults,this.$element.data(),options);this.$lastTrigger=$();this.$triggers=$();this._init();this._events();Foundation.registerPlugin(this,'OffCanvas');Foundation.Keyboard.register('OffCanvas',{'ESCAPE':'close'});}/**
1429   * Initializes the off-canvas wrapper by adding the exit overlay (if needed).
1430   * @function
1431   * @private
1432   */_createClass(OffCanvas,[{key:'_init',value:function _init(){var id=this.$element.attr('id');this.$element.attr('aria-hidden','true');this.$element.addClass('is-transition-'+this.options.transition);// Find triggers that affect this element and add aria-expanded to them
1433this.$triggers=$(document).find('[data-open="'+id+'"], [data-close="'+id+'"], [data-toggle="'+id+'"]').attr('aria-expanded','false').attr('aria-controls',id);// Add an overlay over the content if necessary
1434if(this.options.contentOverlay===true){var overlay=document.createElement('div');var overlayPosition=$(this.$elemen
1434t).css("position")==='fixed'?'is-overlay-fixed':'is-overlay-absolute';overlay.setAttribute('class','js-off-canvas-overlay '+overlayPosition);this.$overlay=$(overlay);if(overlayPosition==='is-overlay-fixed'){$('body').append(this.$overlay);}else{this.$element.siblings('[data-off-canvas-content]').append(this.$overlay);}}this.options.isRevealed=this.options.isRevealed||new RegExp(this.options.revealClass,'g').test(this.$element[0].className);if(this.options.isRevealed===true){this.options.revealOn=this.options.revealOn||this.$element[0].className.match(/(reveal-for-medium|reveal-for-large)/g)[0].split('-')[2];this._setMQChecker();}if(!this.options.transitionTime===true){this.options.transitionTime=parseFloat(window.getComputedStyle($('[data-off-canvas]')[0]).transitionDuration)*1000;}}/**
1435   * Adds event handlers to the off-canvas wrapper and the exit overlay.
1436   * @function
1437   * @private
1438   */},{key:'_events',value:function _events(){this.$element.off('.zf.trigger .zf.offcanvas').on({'open.zf.trigger':this.open.bind(this),'close.zf.trigger':this.close.bind(this),'toggle.zf.trigger':this.toggle.bind(this),'keydown.zf.offcanvas':this._handleKeyboard.bind(this)});if(this.options.closeOnClick===true){var $target=this.options.contentOverlay?this.$overlay:$('[data-off-canvas-content]');$target.on({'click.zf.offcanvas':this.close.bind(this)});}}/**
1439   * Applies event listener for elements that will reveal at certain breakpoints.
1440   * @private
1441   */},{key:'_setMQChecker',value:function _setMQChecker(){var _this=this;$(window).on('changed.zf.mediaquery',function(){if(Foundation.MediaQuery.atLeast(_this.options.revealOn)){_this.reveal(true);}else{_this.reveal(false);}}).one('load.zf.offcanvas',function(){if(Foundation.MediaQuery.atLeast(_this.options.revealOn)){_this.reveal(true);}});}/**
1442   * Handles the revealing/hiding the off-canvas at breakpoints, not the same as open.
1443   * @param {Boolean} isRevealed - true if element should be revealed.
1444   * @function
1445   */},{key:'reveal',value:function reveal(isRevealed){var $closer=this.$element.find('[data-close]');if(isRevealed){this.close();this.isRevealed=true;this.$element.attr('aria-hidden','false');this.$element.off('open.zf.trigger toggle.zf.trigger');if($closer.length){$closer.hide();}}else{this.isRevealed=false;this.$element.attr('aria-hidden','true');this.$element.on({'open.zf.trigger':this.open.bind(this),'toggle.zf.trigger':this.toggle.bind(this)});if($closer.length){$closer.show();}}}/**
1446   * Stops scrolling of the body when offcanvas is open on mobile Safari and other troublesome browsers.
1447   * @private
1448   */},{key:'_stopScrolling',value:function _stopScrolling(event){return false;}/**
1449   * Opens the off-canvas menu.
1450   * @function
1451   * @param {Object} event - Event object passed from listener.
1452   * @param {jQuery} trigger - element that triggered the off-canvas to open.
1453   * @fires OffCanvas#opened
1454   */},{key:'open',value:function open(event,trigger){if(this.$element.hasClass('is-open')||this.isRevealed){return;}var _this=this;if(trigger){this.$lastTrigger=trigger;}if(this.options.forceTo==='top'){window.scrollTo(0,0);}else if(this.options.forceTo==='bottom'){window.scrollTo(0,document.body.scrollHeight);}/**
1455     * Fires when the off-canvas menu opens.
1456     * @event OffCanvas#opened
1457     */_this.$element.addClass('is-open');this.$triggers.attr('aria-expanded','true');this.$element.attr('aria-hidden','false').trigger('opened.zf.offcanvas');// If `contentScroll` is set to false, add class and disable scrolling on touch devices.
1458if(this.options.contentScroll===false){$('body').addClass('is-off-canvas-open').on('touchmove',this._stopScrolling);}if(this.options.contentOverlay===true){this.$overlay.addClass('is-visible');}if(this.options.closeOnClick===true&&this.options.contentOverlay===true){this.$overlay.addClass('is-closable');}if(this.options.autoFocus===true){this.$element.one(Foundation.transitionend(this.$element),function(){_this.$element.find('a, button').eq(0).focus();});}if(this.options.trapFocus===true){this.$element.siblings('[data-off-canvas-content]').attr('tabindex','-1');Foundation.Keyboard.trapFocus(this.$element);}}/**
1459   * Closes the off-canvas menu.
1460   * @function
1461   * @param {Function} cb - optional cb to fire after closure.
1462   * @fires OffCanvas#closed
1463   */},{key:'close',value:function close(cb){if(!this.$element.hasClass('is-open')||this.isRevealed){return;}var _this=this;_this.$element.removeClass('is-open');this.$element.attr('aria-hidden','true')/**
1464       * Fires when the off-canvas menu opens.
1465       * @event OffCanvas#closed
1466       */.trigger('closed.zf.offcanvas');// If `contentScroll` is set to false, remove class and re-enable scrolling on touch devices.
1467if(this.options.contentScroll===false){$('body').removeClass('is-off-canvas-open').off('touchmove',this._stopScrolling);}if(this.options.contentOverlay===true){this.$overlay.removeClass('is-visible');}if(this.options.closeOnClick===true&&this.options.contentOverlay===true){this.$overlay.removeClass('is-closable');}this.$triggers.attr('aria-expanded','false');if(this.options.trapFocus===true){this.$element.siblings('[data-off-canvas-content]').removeAttr('tabindex');Foundation.Keyboard.releaseFocus(this.$element);}}/**
1468   * Toggles the off-canvas menu open or closed.
1469   * @function
1470   * @param {Object} event - Event object passed from listener.
1471   * @param {jQuery} trigger - element that triggered the off-canvas to open.
1472   */},{key:'toggle',value:function toggle(event,trigger){if(this.$element.hasClass('is-open')){this.close(event,trigger);}else{this.open(event,trigger);}}/**
1473   * Handles keyboard input when detected. When the escape key is pressed, the off-canvas menu closes, and focus is restored to the element that opened the menu.
1474   * @function
1475   * @private
1476   */},{key:'_handleKeyboard',value:function _handleKeyboard(e){var _this2=this;Foundation.Keyboard.handleKey(e,'OffCanvas',{close:function close(){_this2.close();_this2.$lastTrigger.focus();return true;},handled:function handled(){e.stopPropagation();e.preventDefault();}});}/**
1477   * Destroys the offcanvas plugin.
1478   * @function
1479   */},{key:'destroy',value:function destroy(){this.close();this.$element.off('.zf.trigger .zf.offcanvas');this.$overlay.off('.zf.offcanvas');Foundation.unregisterPlugin(this);}}]);return OffCanvas;}();OffCanvas.defaults={/**
1480   * Allow the user to click outside of the menu to close it.
1481   * @option
1482   * @example true
1483   */closeOnClick:true,/**
1484   * Adds an overlay on top of `[data-off-canvas-content]`.
1485   * @option
1486   * @example true
1487   */contentOverlay:true,/**
1488   * Enable/disable scrolling of the main content when an off canvas panel is open.
1489   * @option
1490   * @example true
1491   */contentScroll:true,/**
1492   * Amount of time in ms the open and close transition requires. If none selected, pulls from body style.
1493   * @option
1494   * @example 500
1495   */transitionTime:0,/**
1496   * Type of transition for the offcanvas menu. Options are 'push', 'detached' or 'slide'.
1497   * @option
1498   * @example push
1499   */transition:'push',/**
1500   * Force the page to scroll to top or bottom on open.
1501   * @option
1502   * @example top
1503   */forceTo:null,/**
1504   * Allow the offcanvas to remain open for certain breakpoints.
1505   * @option
1506   * @example false
1507   */isRevealed:false,/**
1508   * Breakpoint at which to reveal. JS will use a RegExp to target standard classes, if changing classnames, pass your class with the `revealClass` option.
1509   * @option
1510   * @example reveal-for-large
1511   */revealOn:null,/**
1512   * Force focus to the offcanvas on open. If true, will focus the opening trigger on close.
1513   * @option
1514   * @example true
1515   */autoFocus:true,/**
1516   * Class used to force an offcanvas to remain open. Foundation defaults for this are `reveal-for-large` & `reveal-for-medium`.
1517   * @option
1518   * TODO improve the regex testing for this.
1519   * @example reveal-for-large
1520   */revealClass:'reveal-for-',/**
1521   * Triggers optional focus trapping when opening an offcanvas. Sets tabindex of [data-off-canvas-content] to -1 for accessibility purposes.
1522   * @option
1523   * @example true
1524   */trapFocus:false};// Window exports
1525Foundation.plugin(OffCanvas,'OffCanvas');}(jQuery);
1526'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1527 * Orbit module.
1528 * @module foundation.orbit
1529 * @requires foundation.util.keyboard
1530 * @requires foundation.util.motion
1531 * @requires foundation.util.timerAndImageLoader
1532 * @requires foundation.util.touch
1533 */var Orbit=function(){/**
1534  * Creates a new instance of an orbit carousel.
1535  * @class
1536  * @param {jQuery} element - jQuery object to make into an Orbit Carousel.
1537  * @param {Object} options - Overrides to the default plugin settings.
1538  */function Orbit(element,options){_classCallCheck(this,Orbit);this.$element=element;this.options=$.extend({},Orbit.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Orbit');Foundation.Keyboard.register('Orbit',{'ltr':{'ARROW_RIGHT':'next','ARROW_LEFT':'previous'},'rtl':{'ARROW_LEFT':'next','ARROW_RIGHT':'previous'}});}/**
1539  * Initializes the plugin by creating jQuery collections, setting attributes, and starting the animation.
1540  * @function
1541  * @private
1542  */_createClass(Orbit,[{key:'_init',value:function _init(){// @TODO: consider discussion on PR #9278 about DOM pollution by changeSlide
1543this._reset();this.$wrapper=this.$element.find('.'+this.options.containerClass);this.$slides=this.$element.find('.'+this.options.slideClass);var $images=this.$element.find('img'),initActive=this.$slides.filter('.is-active'),id=this.$element[0].id||Foundation.GetYoDigits(6,'orbit');this.$element.attr({'data-resize':id,'id':id});if(!initActive.length){this.$slides.eq(0).addClass('is-active');}if(!this.options.useMUI){this.$slides.addClass('no-motionui');}if($images.length){Foundation.onImagesLoaded($images,this._prepareForOrbit.bind(this));}else{this._prepareForOrbit();//hehe
1544}if(this.options.bullets){this._loadBullets();}this._events();if(this.options.autoPlay&&this.$slides.length>1){this.geoSync();}if(this.options.accessible){// allow wrapper to be focusable to enable arrow navigation
1545this.$wrapper.attr('tabindex',0);}}/**
1546  * Creates a jQuery collection of bullets, if they are being used.
1547  * @function
1548  * @private
1549  */},{key:'_loadBullets',value:function _loadBullets(){this.$bullets=this.$element.find('.'+this.options.boxOfBullets).find('button');}/**
1550  * Sets a `timer` object on the orbit, and starts the counter for the next slide.
1551  * @function
1552  */},{key:'geoSync',value:function geoSync(){var _this=this;this.timer=new Foundation.Timer(this.$element,{duration:this.options.timerDelay,infinite:false},function(){_this.changeSlide(true);});this.timer.start();}/**
1553  * Sets wrapper and slide heights for the orbit.
1554  * @function
1555  * @private
1556  */},{key:'_prepareForOrbit',value:function _prepareForOrbit(){var _this=this;this._setWrapperHeight();}/**
1557  * Calulates the height of each slide in the collection, and uses the tallest one for the wrapper height.
1558  * @function
1559  * @private
1560  * @param {Function} cb - a callback function to fire when complete.
1561  */},{key:'_setWrapperHeight',value:function _setWrapperHeight(cb){//rewrite this to `for` loop
1562var max=0,temp,counter=0,_this=this;this.$slides.each(function(){temp=this.getBoundingClientRect().height;
vendor: 4,174 bytes, lines 1562-1599
1562$(this).attr('data-slide',counter);if(_this.$slides.filter('.is-active')[0]!==_this.$slides.eq(counter)[0]){//if not the active slide, set css position and display property
1563$(this).css({'position':'relative','display':'none'});}max=temp>max?temp:max;counter++;});if(counter===this.$slides.length){this.$wrapper.css({'height':max});//only change the wrapper height property once.
1564if(cb){cb(max);}//fire callback with max height dimension.
1565}}/**
1566  * Sets the max-height of each slide.
1567  * @function
1568  * @private
1569  */},{key:'_setSlideHeight',value:function _setSlideHeight(height){this.$slides.each(function(){$(this).css('max-height',height);});}/**
1570  * Adds event listeners to basically everything within the element.
1571  * @function
1572  * @private
1573  */},{key:'_events',value:function _events(){var _this=this;//***************************************
1574//**Now using custom event - thanks to:**
1575//**      Yohai Ararat of Toronto      **
1576//***************************************
1577//
1578this.$element.off('.resizeme.zf.trigger').on({'resizeme.zf.trigger':this._prepareForOrbit.bind(this)});if(this.$slides.length>1){if(this.options.swipe){this.$slides.off('swipeleft.zf.orbit swiperight.zf.orbit').on('swipeleft.zf.orbit',function(e){e.preventDefault();_this.changeSlide(true);}).on('swiperight.zf.orbit',function(e){e.preventDefault();_this.changeSlide(false);});}//***************************************
1579if(this.options.autoPlay){this.$slides.on('click.zf.orbit',function(){_this.$element.data('clickedOn',_this.$element.data('clickedOn')?false:true);_this.timer[_this.$element.data('clickedOn')?'pause':'start']();});if(this.options.pauseOnHover){this.$element.on('mouseenter.zf.orbit',function(){_this.timer.pause();}).on('mouseleave.zf.orbit',function(){if(!_this.$element.data('clickedOn')){_this.timer.start();}});}}if(this.options.navButtons){var $controls=this.$element.find('.'+this.options.nextClass+', .'+this.options.prevClass);$controls.attr('tabindex',0)//also need to handle enter/return and spacebar key presses
1580.on('click.zf.orbit touchend.zf.orbit',function(e){e.preventDefault();_this.changeSlide($(this).hasClass(_this.options.nextClass));});}if(this.options.bullets){this.$bullets.on('click.zf.orbit touchend.zf.orbit',function(){if(/is-active/g.test(this.className)){return false;}//if this is active, kick out of function.
1581var idx=$(this).data('slide'),ltr=idx>_this.$slides.filter('.is-active').data('slide'),$slide=_this.$slides.eq(idx);_this.changeSlide(ltr,$slide,idx);});}if(this.options.accessible){this.$wrapper.add(this.$bullets).on('keydown.zf.orbit',function(e){// handle keyboard event with keyboard util
1582Foundation.Keyboard.handleKey(e,'Orbit',{next:function next(){_this.changeSlide(true);},previous:function previous(){_this.changeSlide(false);},handled:function handled(){// if bullet is focused, make sure focus moves
1583if($(e.target).is(_this.$bullets)){_this.$bullets.filter('.is-active').focus();}}});});}}}/**
1584   * Resets Orbit so it can be reinitialized
1585   */},{key:'_reset',value:function _reset(){// Don't do anything if there are no slides (first run)
1586if(typeof this.$slides=='undefined'){return;}if(this.$slides.length>1){// Remove old events
1587this.$element.off('.zf.orbit').find('*').off('.zf.orbit');// Restart timer if autoPlay is enabled
1588if(this.options.autoPlay){this.timer.restart();}// Reset all sliddes
1589this.$slides.each(function(el){$(el).removeClass('is-active is-active is-in').removeAttr('aria-live').hide();});// Show the first slide
1590this.$slides.first().addClass('is-active').show();// Triggers when the slide has finished animating
1591this.$element.trigger('slidechange.zf.orbit',[this.$slides.first()]);// Select first bullet if bullets are present
1592if(this.options.bullets){this._updateBullets(0);}}}/**
1593  * Changes the current slide to a new one.
1594  * @function
1595  * @param {Boolean} isLTR - flag if the slide should move left to right.
1596  * @param {jQuery} chosenSlide - the jQuery element of the slide to show next, if one is selected.
1597  * @param {Number} idx - the index of the new slide in its collection, if one chosen.
1598  * @fires Orbit#slidechange
1599  */},{key:'changeSlide',value:function changeSlide(isLTR,chosenSlide,idx
1599){if(!this.$slides){return;}// Don't freak out if we're in the middle of cleanup
1600var $curSlide=this.$slides.filter('.is-active').eq(0);if(/mui/g.test($curSlide[0].className)){return false;}//if the slide is currently animating, kick out of the function
1601var $firstSlide=this.$slides.first(),$lastSlide=this.$slides.last(),dirIn=isLTR?'Right':'Left',dirOut=isLTR?'Left':'Right',_this=this,$newSlide;if(!chosenSlide){//most of the time, this will be auto played or clicked from the navButtons.
1602$newSlide=isLTR?//if wrapping enabled, check to see if there is a `next` or `prev` sibling, if not, select the first or last slide to fill in. if wrapping not enabled, attempt to select `next` or `prev`, if there's nothing there, the function will kick out on next step. CRAZY NESTED TERNARIES!!!!!
1603this.options.infiniteWrap?$curSlide.next('.'+this.options.slideClass).length?$curSlide.next('.'+this.options.slideClass):$firstSlide:$curSlide.next('.'+this.options.slideClass)://pick next slide if moving left to right
1604this.options.infiniteWrap?$curSlide.prev('.'+this.options.slideClass).length?$curSlide.prev('.'+this.options.slideClass):$lastSlide:$curSlide.prev('.'+this.options.slideClass);//pick prev slide if moving right to left
1605}else{$newSlide=chosenSlide;}if($newSlide.length){/**
1606      * Triggers before the next slide starts animating in and only if a next slide has been found.
1607      * @event Orbit#beforeslidechange
1608      */this.$element.trigger('beforeslidechange.zf.orbit',[$curSlide,$newSlide]);if(this.options.bullets){idx=idx||this.$slides.index($newSlide);//grab index to update bullets
1609this._updateBullets(idx);}if(this.options.useMUI&&!this.$element.is(':hidden')){Foundation.Motion.animateIn($newSlide.addClass('is-active').css({'position':'absolute','top':0}),this.options['animInFrom'+dirIn],function(){$newSlide.css({'position':'relative','display':'block'}).attr('aria-live','polite');});Foundation.Motion.animateOut($curSlide.removeClass('is-active'),this.options['animOutTo'+dirOut],function(){$curSlide.removeAttr('aria-live');if(_this.options.autoPlay&&!_this.timer.isPaused){_this.timer.restart();}//do stuff?
1610});}else{$curSlide.removeClass('is-active is-in').removeAttr('aria-live').hide();$newSlide.addClass('is-active is-in').attr('aria-live','polite').show();if(this.options.autoPlay&&!this.timer.isPaused){this.timer.restart();}}/**
1611    * Triggers when the slide has finished animating in.
1612    * @event Orbit#slidechange
1613    */this.$element.trigger('slidechange.zf.orbit',[$newSlide]);}}/**
1614  * Updates the active state of the bullets, if displayed.
1615  * @function
1616  * @private
1617  * @param {Number} idx - the index of the current slide.
1618  */},{key:'_updateBullets',value:function _updateBullets(idx){var $oldBullet=this.$element.find('.'+this.options.boxOfBullets).find('.is-active').removeClass('is-active').blur(),span=$oldBullet.find('span:last').detach(),$newBullet=this.$bullets.eq(idx).addClass('is-active').append(span);}/**
1619  * Destroys the carousel and hides the element.
1620  * @function
1621  */},{key:'destroy',value:function destroy(){this.$element.off('.zf.orbit').find('*').off('.zf.orbit').end().hide();Foundation.unregisterPlugin(this);}}]);return Orbit;}();Orbit.defaults={/**
1622  * Tells the JS to look for and loadBullets.
1623  * @option
1624  * @example true
1625  */bullets:true,/**
1626  * Tells the JS to apply event listeners to nav buttons
1627  * @option
1628  * @example true
1629  */navButtons:true,/**
1630  * motion-ui animation class to apply
1631  * @option
1632  * @example 'slide-in-right'
1633  */animInFromRight:'slide-in-right',/**
1634  * motion-ui animation class to apply
1635  * @option
1636  * @example 'slide-out-right'
1637  */animOutToRight:'slide-out-right',/**
1638  * motion-ui animation class to apply
1639  * @option
1640  * @example 'slide-in-left'
1641  *
1642  */animInFromLeft:'slide-in-left',/**
1643  * motion-ui animation class to apply
1644  * @option
1645  * @example 'slide-out-left'
1646  */animOutToLeft:'slide-out-left',/**
1647  * Allows Orbit to automatically animate on page load.
1648  * @option
1649  * @example true
1650  */autoPlay:true,/**
1651  * Amount of time, in ms, between slide transitions
1652  * @option
1653  * @example 5000
1654  */timerDelay:5000,/**
1655  * Allows Orbit to infinitely loop through the slides
1656  * @option
1657  * @example true
1658  */infiniteWrap:true,/**
1659  * Allows the Orbit slides to bind to swipe events for mobile, requires an additional util library
1660  * @option
1661  * @example true
1662  */swipe:true,/**
1663  * Allows the timing function to pause animation on hover.
1664  * @option
1665  * @example true
1666  */pauseOnHover:true,/**
1667  * Allows Orbit to bind keyboard events to the slider, to animate frames with arrow keys
1668  * @option
1669  * @example true
1670  */accessible:true,/**
1671  * Class applied to the container of Orbit
1672  * @option
1673  * @example 'orbit-container'
1674  */containerClass:'orbit-container',/**
1675  * Class applied to individual slides.
1676  * @option
1677  * @example 'orbit-slide'
1678  */slideClass:'orbit-slide',/**
1679  * Class applied to the bullet container. You're welcome.
1680  * @option
1681  * @example 'orbit-bullets'
1682  */boxOfBullets:'orbit-bullets',/**
1683  * Class applied to the `next` navigation button.
1684  * @option
1685  * @example 'orbit-next'
1686  */nextClass:'orbit-next',/**
1687  * Class applied to the `previous` navigation button.
1688  * @option
1689  * @example 'orbit-previous'
1690  */prevClass:'orbit-previous',/**
1691  * Boolean to flag the js to use motion ui classes or not. Default to true for backwards compatability.
1692  * @option
1693  * @example true
1694  */useMUI:true};// Window exports
1695Foundation.plugin(Orbit,'Orbit');}(jQuery);
1696'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1697 * ResponsiveMenu module.
1698 * @module foundation.responsiveMenu
1699 * @requires foundation.util.triggers
1700 * @requires foundation.util.mediaQuery
1701 * @requires foundation.util.accordionMenu
1702 * @requires foundation.util.drilldown
1703 * @requires foundation.util.dropdown-menu
1704 */var ResponsiveMenu=function(){/**
1705   * Creates a new instance of a responsive menu.
1706   * @class
1707   * @fires ResponsiveMenu#init
1708   * @param {jQuery} element - jQuery object to make into a dropdown menu.
1709   * @param {Object} options - Overrides to the default plugin settings.
1710   */function ResponsiveMenu(element,options){_classCallCheck(this,ResponsiveMenu);this.$element=$(element);this.rules=this.$element.data('responsive-menu');this.currentMq=null;this.currentPlugin=null;this._init();this._events();Foundation.registerPlugin(this,'ResponsiveMenu');}/**
1711   * Initializes the Menu by parsing the classes from the 'data-ResponsiveMenu' attribute on the element.
1712   * @function
1713   * @private
1714   */_createClass(ResponsiveMenu,[{key:'_init',value:function _init(){// The first time an Interchange plugin is initialized, this.rules is converted from a string of "classes" to an object of rules
1715if(typeof this.rules==='string'){var rulesTree={};// Parse rules from "classes" pulled from data attribute
1716var rules=this.rules.split(' ');// Iterate through every rule found
1717for(var i=0;i<rules.length;i++){var rule=rules[i].split('-');var ruleSize=rule.length>1?rule[0]:'small';var rulePlugin=rule.length>1?rule[1]:rule[0];if(MenuPlugins[rulePlugin]!==null){rulesTree[ruleSize]=MenuPlugins[rulePlugin];}}this.rules=rulesTree;}if(!$.isEmptyObject(this.rules)){this._checkMediaQueries();}// Add data-mutate since children may need it.
1718this.$element.attr('data-mutate',this.$element.attr('data-mutate')||Foundation.GetYoDigits(6,'responsive-menu'));}/**
1719   * Initializes events for the Menu.
1720   * @function
1721   * @private
1722   */},{key:'_events',value:function _events(){var _this=this;$(window).on('changed.zf.mediaquery',function(){_this._checkMediaQueries();});// $(window).on('resize.zf.ResponsiveMenu', function() {
1723//   _this._checkMediaQueries();
1724// });
1725}/**
1726   * Checks the current screen width against available media queries. If the media query has changed, and the plugin needed has changed, the plugins will swap out.
1727   * @function
1728   * @private
1729   */},{key:'_checkMediaQueries',value:function _checkMediaQueries(){var matchedMq,_this=this;// Iterate through each rule and find the last matching rule
1730$.each(this.rules,function(key){if(Foundation.MediaQuery.atLeast(key)){matchedMq=key;}});// No match? No dice
1731if(!matchedMq)return;// Plugin already initialized? We good
1732if(this.currentPlugin instanceof this.rules[matchedMq].plugin)return;// Remove existing plugin-specific CSS classes
1733$.each(MenuPlugins,function(key,value){_this.$element.removeClass(value.cssClass);});// Add the CSS class for the new plugin
1734this.$element.addClass(this.rules[matchedMq].cssClass);// Create an instance of the new plugin
1735if(this.currentPlugin)this.currentPlugin.destroy();this.currentPlugin=new this.rules[matchedMq].plugin(this.$element,{});}/**
1736   * Destroys the instance of the current plugin on this element, as well as the window resize handler that switches the plugins out.
1737   * @function
1738   */},{key:'destroy',value:function destroy(){this.currentPlugin.destroy();$(window).off('.zf.ResponsiveMenu');Foundation.unregisterPlugin(this);}}]);return ResponsiveMenu;}();ResponsiveMenu.defaults={};// The plugin matches the plugin classes with these plugin instances.
1739var MenuPlugins={dropdown:{cssClass:'dropdown',plugin:Foundation._plugins['dropdown-menu']||null},drilldown:{cssClass:'drilldown',plugin:Foundation._plugins['drilldown']||null},accordion:{cssClass:'accordion-menu',plugin:Foundation._plugins['accordion-menu']||null}};// Window exports
1740Foundation.plugin(ResponsiveMenu,'ResponsiveMenu');}(jQuery);
1741'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1742 * ResponsiveToggle module.
1743 * @module foundation.responsiveToggle
1744 * @requires foundation.util.mediaQuery
1745 */var ResponsiveToggle=function(){/**
1746   * Creates a new instance of Tab Bar.
1747   * @class
1748   * @fires ResponsiveToggle#init
1749   * @param {jQuery} element - jQuery object to attach tab bar functionality to.
1750   * @param {Object} options - Overrides to the default plugin settings.
1751   */function ResponsiveToggle(element,options){_classCallCheck(this,ResponsiveToggle);this.$element=$(element);this.options=$.extend({},ResponsiveToggle.defaults,this.$element.data(),options);this._init();this._events();Foundation.registerPlugin(this,'ResponsiveToggle');}/**
1752   * Initializes the tab bar by finding the target element, toggling element, and running update().
1753   * @function
1754   * @private
1755   */_createClass(ResponsiveToggle,[{key:'_init',value:function _init(){var targetID=this.$element.data('responsive-toggle');
1755if(!targetID){console.error('Your tab bar needs an ID of a Menu as the value of data-tab-bar.');}this.$targetMenu=$('#'+targetID);this.$toggler=this.$element.find('[data-toggle]');this.options=$.extend({},this.options,this.$targetMenu.data());// If they were set, parse the animation classes
1756if(this.options.animate){var input=this.options.animate.split(' ');this.animationIn=input[0];this.animationOut=input[1]||null;}this._update();}/**
1757   * Adds necessary event handlers for the tab bar to work.
1758   * @function
1759   * @private
1760   */},{key:'_events',value:function _events(){var _this=this;this._updateMqHandler=this._update.bind(this);$(window).on('changed.zf.mediaquery',this._updateMqHandler);this.$toggler.on('click.zf.responsiveToggle',this.toggleMenu.bind(this));}/**
1761   * Checks the current media query to determine if the tab bar should be visible or hidden.
1762   * @function
1763   * @private
1764   */},{key:'_update',value:function _update(){// Mobile
1765if(!Foundation.MediaQuery.atLeast(this.options.hideFor)){this.$element.show();this.$targetMenu.hide();}// Desktop
1766else{this.$element.hide();this.$targetMenu.show();}}/**
1767   * Toggles the element attached to the tab bar. The toggle only happens if the screen is small enough to allow it.
1768   * @function
1769   * @fires ResponsiveToggle#toggled
1770   */},{key:'toggleMenu',value:function toggleMenu(){var _this2=this;if(!Foundation.MediaQuery.atLeast(this.options.hideFor)){if(this.options.animate){if(this.$targetMenu.is(':hidden')){Foundation.Motion.animateIn(this.$targetMenu,this.animationIn,function(){/**
1771             * Fires when the element attached to the tab bar toggles.
1772             * @event ResponsiveToggle#toggled
1773             */_this2.$element.trigger('toggled.zf.responsiveToggle');_this2.$targetMenu.find('[data-mutate]').triggerHandler('mutateme.zf.trigger');});}else{Foundation.Motion.animateOut(this.$targetMenu,this.animationOut,function(){/**
1774             * Fires when the element attached to the tab bar toggles.
1775             * @event ResponsiveToggle#toggled
1776             */_this2.$element.trigger('toggled.zf.responsiveToggle');});}}else{this.$targetMenu.toggle(0);this.$targetMenu.find('[data-mutate]').trigger('mutateme.zf.trigger');/**
1777         * Fires when the element attached to the tab bar toggles.
1778         * @event ResponsiveToggle#toggled
1779         */this.$element.trigger('toggled.zf.responsiveToggle');}}}},{key:'destroy',value:function destroy(){this.$element.off('.zf.responsiveToggle');this.$toggler.off('.zf.responsiveToggle');$(window).off('changed.zf.mediaquery',this._updateMqHandler);Foundation.unregisterPlugin(this);}}]);return ResponsiveToggle;}();ResponsiveToggle.defaults={/**
1780   * The breakpoint after which the menu is always shown, and the tab bar is hidden.
1781   * @option
1782   * @example 'medium'
1783   */hideFor:'medium',/**
1784   * To decide if the toggle should be animated or not.
1785   * @option
1786   * @example false
1787   */animate:false};// Window exports
1788Foundation.plugin(ResponsiveToggle,'ResponsiveToggle');}(jQuery);
1789'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1790 * Reveal module.
1791 * @module foundation.reveal
1792 * @requires foundation.util.keyboard
1793 * @requires foundation.util.box
1794 * @requires foundation.util.triggers
1795 * @requires foundation.util.mediaQuery
1796 * @requires foundation.util.motion if using animations
1797 */var Reveal=function(){/**
1798   * Creates a new instance of Reveal.
1799   * @class
1800   * @param {jQuery} element - jQuery object to use for the modal.
1801   * @param {Object} options - optional parameters.
1802   */function Reveal(element,options){_classCallCheck(this,Reveal);this.$element=element;this.options=$.extend({},Reveal.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Reveal');Foundation.Keyboard.register('Reveal',{'ENTER':'open','SPACE':'open','ESCAPE':'close'});}/**
1803   * Initializes the modal by adding the overlay and close buttons, (if selected).
1804   * @private
1805   */_createClass(Reveal,[{key:'_init',value:function _init(){this.id=this.$element.attr('id');this.isActive=false;this.cached={mq:Foundation.MediaQuery.current};this.isMobile=mobileSniff();this.$anchor=$('[data-open="'+this.id+'"]').length?$('[data-open="'+this.id+'"]'):$('[data-toggle="'+this.id+'"]');this.$anchor.attr({'aria-controls':this.id,'aria-haspopup':true,'tabindex':0});if(this.options.fullScreen||this.$element.hasClass('full')){this.options.fullScreen=true;this.options.overlay=false;}if(this.options.overlay&&!this.$overlay){this.$overlay=this._makeOverlay(this.id);}this.$element.attr({'role':'dialog','aria-hidden':true,'data-yeti-box':this.id,'data-resize':this.id});if(this.$overlay){this.$element.detach().appendTo(this.$overlay);}else{this.$element.detach().appendTo($(this.options.appendTo));this.$element.addClass('without-overlay');}this._events();
1805if(this.options.deepLink&&window.location.hash==='#'+this.id){$(window).one('load.zf.reveal',this.open.bind(this));}}/**
1806   * Creates an overlay div to display behind the modal.
1807   * @private
1808   */},{key:'_makeOverlay',value:function _makeOverlay(){return $('<div></div>').addClass('reveal-overlay').appendTo(this.options.appendTo);}/**
1809   * Updates position of modal
1810   * TODO:  Figure out if we actually need to cache these values or if it doesn't matter
1811   * @private
1812   */},{key:'_updatePosition',value:function _updatePosition(){var width=this.$element.outerWidth();var outerWidth=$(window).width();var height=this.$element.outerHeight();var outerHeight=$(window).height();var left,top;if(this.options.hOffset==='auto'){left=parseInt((outerWidth-width)/2,10);}else{left=parseInt(this.options.hOffset,10);}if(this.options.vOffset==='auto'){if(height>outerHeight){top=parseInt(Math.min(100,outerHeight/10),10);}else{top=parseInt((outerHeight-height)/4,10);}}else{top=parseInt(this.options.vOffset,10);}this.$element.css({top:top+'px'});
1812// only worry about left if we don't have an overlay or we havea  horizontal offset,
1813// otherwise we're perfectly in the middle
1814if(!this.$overlay||this.options.hOffset!=='auto'){this.$element.css({left:left+'px'});this.$element.css({margin:'0px'});}}/**
1815   * Adds event handlers for the modal.
1816   * @private
1817   */},{key:'_events',value:function _events(){var _this2=this;var _this=this;this.$element.on({'open.zf.trigger':this.open.bind(this),'close.zf.trigger':function closeZfTrigger(event,$element){if(event.target===_this.$element[0]||$(event.target).parents('[data-closable]')[0]===$element){// only close reveal when it's explicitly called
1818return _this2.close.apply(_this2);}},'toggle.zf.trigger':this.toggle.bind(this),'resizeme.zf.trigger':function resizemeZfTrigger(){_this._updatePosition();}});if(this.$anchor.length){this.$anchor.on('keydown.zf.reveal',function(e){if(e.which===13||e.which===32){e.stopPropagation();e.preventDefault();_this.open();}});}if(this.options.closeOnClick&&this.options.overlay){this.$overlay.off('.zf.reveal').on('click.zf.reveal',function(e){if(e.target===_this.$element[0]||$.contains(_this.$element[0],e.target)||!$.contains(document,e.target)){return;}_this.close();});}if(this.options.deepLink){$(window).on('popstate.zf.reveal:'+this.id,this._handleState.bind(this));}}/**
1819   * Handles modal methods on back/forward button clicks or any other event that triggers popstate.
1820   * @private
1821   */},{key:'_handleState',value:function _handleState(e){if(window.location.hash==='#'+this.id&&!this.isActive){this.open();}else{this.close();}}/**
1822   * Opens the modal controlled by `this.$anchor`, and closes all others by default.
1823   * @function
1824   * @fires Reveal#closeme
1825   * @fires Reveal#open
1826   */},{key:'open',value:function open(){var _this3=this;if(this.options.deepLink){var hash='#'+this.id;if(window.history.pushState){window.history.pushState(null,null,hash);}else{window.location.hash=hash;}}this.isActive=true;// Make elements invisible, but remove display: none so we can get size and positioning
1827this.$element.css({'visibility':'hidden'}).show().scrollTop(0);if(this.options.overlay){this.$overlay.css({'visibility':'hidden'}).show();}this._updatePosition();this.$element.hide().css({'visibility':''});if(this.$overlay){this.$overlay.css({'visibility':''}).hide();if(this.$element.hasClass('fast')){this.$overlay.addClass('fast');}else if(this.$element.hasClass('slow')){this.$overlay.addClass('slow');}}if(!this.options.multipleOpened){/**
1828       * Fires immediately before the modal opens.
1829       * Closes any other modals that are currently open
1830       * @event Reveal#closeme
1831       */this.$element.trigger('closeme.zf.reveal',this.id);}var _this=this;function addRevealOpenClasses(){if(_this.isMobile){if(!_this.originalScrollPos){_this.originalScrollPos=window.pageYOffset;}$('html, body').addClass('is-reveal-open');}else{$('body').addClass('is-reveal-open');}}// Motion UI method of reveal
1832if(this.options.animationIn){(function(){var afterAnimation=function afterAnimation(){_this.$element.attr({'aria-hidden':false,'tabindex':-1}).focus();addRevealOpenClasses();Foundation.Keyboard.trapFocus(_this.$element);};if(_this3.options.overlay){Foundation.Motion.animateIn(_this3.$overlay,'fade-in');}Foundation.Motion.animateIn(_this3.$element,_this3.options.animationIn,function(){if(_this3.$element){// protect against object having been removed
1833_this3.focusableElements=Foundation.Keyboard.findFocusable(_this3.$element);afterAnimation();}});})();}// jQuery method of reveal
1834else{if(this.options.overlay){this.$overlay.show(0);}this.$element.show(this.options.showDelay);}// handle accessibility
1835this.$element.attr({'aria-hidden':false,'tabindex':-1}).focus();Foundation.Keyboard.trapFocus(this.$element);/**
1836     * Fires when the modal has successfully opened.
1837     * @event Reveal#open
1838     */this.$element.trigger('open.zf.reveal');addRevealOpenClasses();setTimeout(function(){_this3._extraHandlers();},0);}/**
1839   * Adds extra event handlers for the body and window if necessary.
1840   * @private
1841   */},{key:'_extraHandlers',value:function _extraHandlers(){var _this=this;if(!this.$element){return;}// If we're in the middle of cleanup, don't freak out
1842this.focusableElements=Foundation.Keyboard.findFocusable(this.$element);if(!this.options.overlay&&this.options.closeOnClick&&!this.options.fullScreen){$('body').on('click.zf.reveal',function(e){if(e.target===_this.$element[0]||$.contains(_this.$element[0],e.target)||!$.contains(document,e.target)){return;}_this.close();});}if(this.options.closeOnEsc){$(window).on('keydown.zf.reveal',function(e){Foundation.Keyboard.handleKey(e,'Reveal',{close:function close(){if(_this.options.closeOnEsc){_this.close();_this.$anchor.focus();}}});});}// lock focus within modal while tabbing
1843this.$element.on('keydown.zf.reveal',function(e){var $target=$(this);// handle keyboard event with keyboard util
1844Foundation.Keyboard.handleKey(e,'Reveal',{open:function open(){if(_this.$element.find(':focus').is(_this.$element.find('[data-close]'))){setTimeout(function(){// set focus back to anchor if close button has been activated
1845_this.$anchor.focus();},1);}else if($target.is(_this.focusableElements)){// dont't trigger if acual element has focus (i.e. inputs, links, ...)
1846_this.open();}},close:function close(){if(_this.options.closeOnEsc){_this.close();_this.$anchor.focus();}},handled:function handled(preventDefault){if(preventDefault){e.preventDefault();}}});});}/**
1847   * Closes the modal.
1848   * @function
1849   * @fires Reveal#closed
1850   */},{key:'close',value:function close(){if(!this.isActive||!this.$element.is(':visible')){return false;}var _this=this;// Motion UI method of hiding
1851if(this.options.animationOut){if(this.options.overlay){Foundation.Motion.animateOut(this.$overlay,'fade-out',finishUp);}else{finishUp();}Foundation.Motion.animateOut(this.$element,this.options.animationOut);}// jQuery method of hiding
1852else{if(this.options.overlay){this.$overlay.hide(0,finishUp);}else{finishUp();}this.$element.hide(this.options.hideDelay);}// Conditionals to remove extra event listeners added on open
1853if(this.options.closeOnEsc){$(window).off('keydown.zf.reveal');}if(!this.options.overlay&&this.options.closeOnClick){$('body').off('click.zf.reveal');}this.$element.off('keydown.zf.reveal');function finishUp(){if(_this.isMobile){$('html, body').removeClass('is-reveal-open');if(_this.originalScrollPos){$('body').scrollTop(_this.originalScrollPos);_this.originalScrollPos=null;}}else{$('body').removeClass('is-reveal-open');}Foundation.Keyboard.releaseFocus(_this.$element);_this.$element.attr('aria-hidden',true);/**
1854      * Fires when the modal is done closing.
1855      * @event Reveal#closed
1856      */_this.$element.trigger('closed.zf.reveal');}/**
1857    * Resets the modal content
1858    * This prevents a running video to keep going in the background
1859    */if(this.options.resetOnClose){this.$element.html(this.$element.html());}this.isActive=false;if(_this.options.deepLink){if(window.history.replaceState){window.history.replaceState('',document.title,window.location.href.replace('#'+this.id,''));}else{window.location.hash='';}}}/**
1860   * Toggles the open/closed state of a modal.
1861   * @function
1862   */}
1862,{key:'toggle',value:function toggle(){if(this.isActive){this.close();}else{this.open();}}},{key:'destroy',/**
1863   * Destroys an instance of a modal.
1864   * @function
1865   */value:function destroy(){if(this.options.overlay){this.$element.appendTo($(this.options.appendTo));// move $element outside of $overlay to prevent error unregisterPlugin()
1866this.$overlay.hide().off().remove();}this.$element.hide().off();this.$anchor.off('.zf');$(window).off('.zf.reveal:'+this.id);Foundation.unregisterPlugin(this);}}]);return Reveal;}();Reveal.defaults={/**
1867   * Motion-UI class to use for animated elements. If none used, defaults to simple show/hide.
1868   * @option
1869   * @example 'slide-in-left'
1870   */animationIn:'',/**
1871   * Motion-UI class to use for animated elements. If none used, defaults to simple show/hide.
1872   * @option
1873   * @example 'slide-out-right'
1874   */animationOut:'',/**
1875   * Time, in ms, to delay the opening of a modal after a click if no animation used.
1876   * @option
1877   * @example 10
1878   */showDelay:0,/**
1879   * Time, in ms, to delay the closing of a modal after a click if no animation used.
1880   * @option
1881   * @example 10
1882   */hideDelay:0,/**
1883   * Allows a click on the body/overlay to close the modal.
1884   * @option
1885   * @example true
1886   */closeOnClick:true,/**
1887   * Allows the modal to close if the user presses the `ESCAPE` key.
1888   * @option
1889   * @example true
1890   */closeOnEsc:true,/**
1891   * If true, allows multiple modals to be displayed at once.
1892   * @option
1893   * @example false
1894   */multipleOpened:false,/**
1895   * Distance, in pixels, the modal should push down from the top of the screen.
1896   * @option
1897   * @example auto
1898   */vOffset:'auto',/**
1899   * Distance, in pixels, the modal should push in from the side of the screen.
1900   * @option
1901   * @example auto
1902   */hOffset:'auto',/**
1903   * Allows the modal to be fullscreen, completely blocking out the rest of the view. JS checks for this as well.
1904   * @option
1905   * @example false
1906   */fullScreen:false,/**
1907   * Percentage of screen height the modal should push up from the bottom of the view.
1908   * @option
1909   * @example 10
1910   */btmOffsetPct:10,/**
1911   * Allows the modal to generate an overlay div, which will cover the view when modal opens.
1912   * @option
1913   * @example true
1914   */overlay:true,/**
1915   * Allows the modal to remove and reinject markup on close. Should be true if using video elements w/o using provider's api, otherwise, videos will continue to play in the background.
1916   * @option
1917   * @example false
1918   */resetOnClose:false,/**
1919   * Allows the modal to alter the url on open/close, and allows the use of the `back` button to close modals. ALSO, allows a modal to auto-maniacally open on page load IF the hash === the modal's user-set id.
1920   * @option
1921   * @example false
1922   */deepLink:false,/**
1923   * Allows the modal to append to custom div.
1924   * @option
1925   * @example false
1926   */appendTo:"body"};// Window exports
1927Foundation.plugin(Reveal,'Reveal');function iPhoneSniff(){return /iP(ad|hone|od).*OS/.test(window.navigator.userAgent);}function androidSniff(){return /Android/.test(window.navigator.userAgent);}function mobileSniff(){return iPhoneSniff()||androidSniff();}}(jQuery);
1928'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
1929 * Slider module.
1930 * @module foundation.slider
1931 * @requires foundation.util.motion
1932 * @requires foundation.util.triggers
1933 * @requires foundation.util.keyboard
1934 * @requires foundation.util.touch
1935 */var Slider=function(){/**
1936   * Creates a new instance of a slider control.
1937   * @class
1938   * @param {jQuery} element - jQuery object to make into a slider control.
1939   * @param {Object} options - Overrides to the default plugin settings.
1940   */function Slider(element,options){_classCallCheck(this,Slider);this.$element=element;this.options=$.extend({},Slider.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Slider');Foundation.Keyboard.register('Slider',{'ltr':{'ARROW_RIGHT':'increase','ARROW_UP':'increase','ARROW_DOWN':'decrease','ARROW_LEFT':'decrease','SHIFT_ARROW_RIGHT':'increase_fast','SHIFT_ARROW_UP':'increase_fast','SHIFT_ARROW_DOWN':'decrease_fast','SHIFT_ARROW_LEFT':'decrease_fast'},'rtl':{'ARROW_LEFT':'increase','ARROW_RIGHT':'decrease','SHIFT_ARROW_LEFT':'increase_fast','SHIFT_ARROW_RIGHT':'decrease_fast'}});}/**
1941   * Initilizes the plugin by reading/setting attributes, creating collections and setting the initial position of the handle(s).
1942   * @function
1943   * @private
1944   */_createClass(Slider,[{key:'_init',value:function _init(){this.inputs=this.$element.find('input');
vendor: 4,251 bytes, lines 1944-1976
1944this.handles=this.$element.find('[data-slider-handle]');this.$handle=this.handles.eq(0);this.$input=this.inputs.length?this.inputs.eq(0):$('#'+this.$handle.attr('aria-controls'));this.$fill=this.$element.find('[data-slider-fill]').css(this.options.vertical?'height':'width',0);var isDbl=false,_this=this;if(this.options.disabled||this.$element.hasClass(this.options.disabledClass)){this.options.disabled=true;this.$element.addClass(this.options.disabledClass);}if(!this.inputs.length){this.inputs=$().add(this.$input);this.options.binding=true;}this._setInitAttr(0);if(this.handles[1]){this.options.doubleSided=true;this.$handle2=this.handles.eq(1);this.$input2=this.inputs.length>1?this.inputs.eq(1):$('#'+this.$handle2.attr('aria-controls'));if(!this.inputs[1]){this.inputs=this.inputs.add(this.$input2);}isDbl=true;// this.$handle.triggerHandler('click.zf.slider');
1945this._setInitAttr(1);}// Set handle positions
1946this.setHandles();this._events();}},{key:'setHandles',value:function setHandles(){var _this2=this;if(this.handles[1]){this._setHandlePos(this.$handle,this.inputs.eq(0).val(),true,function(){_this2._setHandlePos(_this2.$handle2,_this2.inputs.eq(1).val(),true);});}else{this._setHandlePos(this.$handle,this.inputs.eq(0).val(),true);}}},{key:'_reflow',value:function _reflow(){this.setHandles();}/**
1947  * @function
1948  * @private
1949  * @param {Number} value - floating point (the value) to be transformed using to a relative position on the slider (the inverse of _value)
1950  */},{key:'_pctOfBar',value:function _pctOfBar(value){var pctOfBar=percent(value-this.options.start,this.options.end-this.options.start);switch(this.options.positionValueFunction){case"pow":pctOfBar=this._logTransform(pctOfBar);break;case"log":pctOfBar=this._powTransform(pctOfBar);break;}return pctOfBar.toFixed(2);}/**
1951  * @function
1952  * @private
1953  * @param {Number} pctOfBar - floating point, the relative position of the slider (typically between 0-1) to be transformed to a value
1954  */},{key:'_value',value:function _value(pctOfBar){switch(this.options.positionValueFunction){case"pow":pctOfBar=this._powTransform(pctOfBar);break;case"log":pctOfBar=this._logTransform(pctOfBar);break;}var value=(this.options.end-this.options.start)*pctOfBar+this.options.start;return value;}/**
1955  * @function
1956  * @private
1957  * @param {Number} value - floating point (typically between 0-1) to be transformed using the log function
1958  */},{key:'_logTransform',value:function _logTransform(value){return baseLog(this.options.nonLinearBase,value*(this.options.nonLinearBase-1)+1);}/**
1959  * @function
1960  * @private
1961  * @param {Number} value - floating point (typically between 0-1) to be transformed using the power function
1962  */},{key:'_powTransform',value:function _powTransform(value){return(Math.pow(this.options.nonLinearBase,value)-1)/(this.options.nonLinearBase-1);}/**
1963   * Sets the position of the selected handle and fill bar.
1964   * @function
1965   * @private
1966   * @param {jQuery} $hndl - the selected handle to move.
1967   * @param {Number} location - floating point between the start and end values of the slider bar.
1968   * @param {Function} cb - callback function to fire on completion.
1969   * @fires Slider#moved
1970   * @fires Slider#changed
1971   */},{key:'_setHandlePos',value:function _setHandlePos($hndl,location,noInvert,cb){// don't move if the slider has been disabled since its initialization
1972if(this.$element.hasClass(this.options.disabledClass)){return;}//might need to alter that slightly for bars that will have odd number selections.
1973location=parseFloat(location);//on input change events, convert string to number...grumble.
1974// prevent slider from running out of bounds, if value exceeds the limits set through options, override the value to min/max
1975if(location<this.options.start){location=this.options.start;}else if(location>this.options.end){location=this.options.end;}var isDbl=this.options.doubleSided;if(isDbl){//this block is to prevent 2 handles from crossing eachother. Could/should be improved.
1976if(this.handles.index($hndl)===0){var h2Val=parseFloat(this.$handle2.attr('aria-valuenow'));location=location>=h2Val?h2Val-this.options.step:location;}else{var h1Val=parseFloat(this.$handle.attr('aria-valuenow'));location=location<=h1Val?h1Val+this.options.step:location;}}
vendor: 5,808 bytes, lines 1976-2030
1976//this is for single-handled vertical sliders, it adjusts the value to account for the slider being "upside-down"
1977//for click and drag events, it's weird due to the scale(-1, 1) css property
1978if(this.options.vertical&&!noInvert){location=this.options.end-location;}var _this=this,vert=this.options.vertical,hOrW=vert?'height':'width',lOrT=vert?'top':'left',handleDim=$hndl[0].getBoundingClientRect()[hOrW],elemDim=this.$element[0].getBoundingClientRect()[hOrW],//percentage of bar min/max value based on click or drag point
1979pctOfBar=this._pctOfBar(location),//number of actual pixels to shift the handle, based on the percentage obtained above
1980pxToMove=(elemDim-handleDim)*pctOfBar,//percentage of bar to shift the handle
1981movement=(percent(pxToMove,elemDim)*100).toFixed(this.options.decimal);//fixing the decimal value for the location number, is passed to other methods as a fixed floating-point value
1982location=parseFloat(location.toFixed(this.options.decimal));// declare empty object for css adjustments, only used with 2 handled-sliders
1983var css={};this._setValues($hndl,location);// TODO update to calculate based on values set to respective inputs??
1984if(isDbl){var isLeftHndl=this.handles.index($hndl)===0,//empty variable, will be used for min-height/width for fill bar
1985dim,//percentage w/h of the handle compared to the slider bar
1986handlePct=~~(percent(handleDim,elemDim)*100);//if left handle, the math is slightly different than if it's the right handle, and the left/top property needs to be changed for the fill bar
1987if(isLeftHndl){//left or top percentage value to apply to the fill bar.
1988css[lOrT]=movement+'%';//calculate the new min-height/width for the fill bar.
1989dim=parseFloat(this.$handle2[0].style[lOrT])-movement+handlePct;//this callback is necessary to prevent errors and allow the proper placement and initialization of a 2-handled slider
1990//plus, it means we don't care if 'dim' isNaN on init, it won't be in the future.
1991if(cb&&typeof cb==='function'){cb();}//this is only needed for the initialization of 2 handled sliders
1992}else{//just caching the value of the left/bottom handle's left/top property
1993var handlePos=parseFloat(this.$handle[0].style[lOrT]);//calculate the new min-height/width for the fill bar. Use isNaN to prevent false positives for numbers <= 0
1994//based on the percentage of movement of the handle being manipulated, less the opposing handle's left/top position, plus the percentage w/h of the handle itself
1995dim=movement-(isNaN(handlePos)?(this.options.initialStart-this.options.start)/((this.options.end-this.options.start)/100):handlePos)+handlePct;}// assign the min-height/width to our css object
1996css['min-'+hOrW]=dim+'%';}this.$element.one('finished.zf.animate',function(){/**
1997                     * Fires when the handle is done moving.
1998                     * @event Slider#moved
1999                     */_this.$element.trigger('moved.zf.slider',[$hndl]);});//because we don't know exactly how the handle will be moved, check the amount of time it should take to move.
2000var moveTime=this.$element.data('dragging')?1000/60:this.options.moveTime;Foundation.Move(moveTime,$hndl,function(){// adjusting the left/top property of the handle, based on the percentage calculated above
2001// if movement isNaN, that is because the slider is hidden and we cannot determine handle width,
2002// fall back to next best guess.
2003if(isNaN(movement)){$hndl.css(lOrT,pctOfBar*100+'%');}else{$hndl.css(lOrT,movement+'%');}if(!_this.options.doubleSided){//if single-handled, a simple method to expand the fill bar
2004_this.$fill.css(hOrW,pctOfBar*100+'%');}else{//otherwise, use the css object we created above
2005_this.$fill.css(css);}});/**
2006     * Fires when the value has not been change for a given time.
2007     * @event Slider#changed
2008     */clearTimeout(_this.timeout);_this.timeout=setTimeout(function(){_this.$element.trigger('changed.zf.slider',[$hndl]);},_this.options.changedDelay);}/**
2009   * Sets the initial attribute for the slider element.
2010   * @function
2011   * @private
2012   * @param {Number} idx - index of the current handle/input to use.
2013   */},{key:'_setInitAttr',value:function _setInitAttr(idx){var initVal=idx===0?this.options.initialStart:this.options.initialEnd;var id=this.inputs.eq(idx).attr('id')||Foundation.GetYoDigits(6,'slider');this.inputs.eq(idx).attr({'id':id,'max':this.options.end,'min':this.options.start,'step':this.options.step});this.inputs.eq(idx).val(initVal);this.handles.eq(idx).attr({'role':'slider','aria-controls':id,'aria-valuemax':this.options.end,'aria-valuemin':this.options.start,'aria-valuenow':initVal,'aria-orientation':this.options.vertical?'vertical':'horizontal','tabindex':0});}/**
2014   * Sets the input and `aria-valuenow` values for the slider element.
2015   * @function
2016   * @private
2017   * @param {jQuery} $handle - the currently selected handle.
2018   * @param {Number} val - floating point of the new value.
2019   */},{key:'_setValues',value:function _setValues($handle,val){var idx=this.options.doubleSided?this.handles.index($handle):0;this.inputs.eq(idx).val(val);$handle.attr('aria-valuenow',val);}/**
2020   * Handles events on the slider element.
2021   * Calculates the new location of the current handle.
2022   * If there are two handles and the bar was clicked, it determines which handle to move.
2023   * @function
2024   * @private
2025   * @param {Object} e - the `event` object passed from the listener.
2026   * @param {jQuery} $handle - the current handle to calculate for, if selected.
2027   * @param {Number} val - floating point number for the new value of the slider.
2028   * TODO clean this up, there's a lot of repeated code between this and the _setHandlePos fn.
2029   */},{key:'_handleEvent',value:function _handleEvent(e,$handle,val){var value,hasVal;if(!val){//click or drag events
2030e.preventDefault();var _this=this,vertical=this.options.vertical,param=vertical?'he
vendor: 4,091 bytes, lines 2030-2054
2030ight':'width',direction=vertical?'top':'left',eventOffset=vertical?e.pageY:e.pageX,halfOfHandle=this.$handle[0].getBoundingClientRect()[param]/2,barDim=this.$element[0].getBoundingClientRect()[param],windowScroll=vertical?$(window).scrollTop():$(window).scrollLeft();var elemOffset=this.$element.offset()[direction];// touch events emulated by the touch util give position relative to screen, add window.scroll to event coordinates...
2031// best way to guess this is simulated is if clientY == pageY
2032if(e.clientY===e.pageY){eventOffset=eventOffset+windowScroll;}var eventFromBar=eventOffset-elemOffset;var barXY;if(eventFromBar<0){barXY=0;}else if(eventFromBar>barDim){barXY=barDim;}else{barXY=eventFromBar;}var offsetPct=percent(barXY,barDim);value=this._value(offsetPct);// turn everything around for RTL, yay math!
2033if(Foundation.rtl()&&!this.options.vertical){value=this.options.end-value;}value=_this._adjustValue(null,value);//boolean flag for the setHandlePos fn, specifically for vertical sliders
2034hasVal=false;if(!$handle){//figure out which handle it is, pass it to the next function.
2035var firstHndlPos=absPosition(this.$handle,direction,barXY,param),secndHndlPos=absPosition(this.$handle2,direction,barXY,param);$handle=firstHndlPos<=secndHndlPos?this.$handle:this.$handle2;}}else{//change event on input
2036value=this._adjustValue(null,val);hasVal=true;}this._setHandlePos($handle,value,hasVal);}/**
2037   * Adjustes value for handle in regard to step value. returns adjusted value
2038   * @function
2039   * @private
2040   * @param {jQuery} $handle - the selected handle.
2041   * @param {Number} value - value to adjust. used if $handle is falsy
2042   */},{key:'_adjustValue',value:function _adjustValue($handle,value){var val,step=this.options.step,div=parseFloat(step/2),left,prev_val,next_val;if(!!$handle){val=parseFloat($handle.attr('aria-valuenow'));}else{val=value;}left=val%step;prev_val=val-left;next_val=prev_val+step;if(left===0){return val;}val=val>=prev_val+div?next_val:prev_val;return val;}/**
2043   * Adds event listeners to the slider elements.
2044   * @function
2045   * @private
2046   */},{key:'_events',value:function _events(){this._eventsForHandle(this.$handle);if(this.handles[1]){this._eventsForHandle(this.$handle2);}}/**
2047   * Adds event listeners a particular handle
2048   * @function
2049   * @private
2050   * @param {jQuery} $handle - the current handle to apply listeners to.
2051   */},{key:'_eventsForHandle',value:function _eventsForHandle($handle){var _this=this,curHandle,timer;this.inputs.off('change.zf.slider').on('change.zf.slider',function(e){var idx=_this.inputs.index($(this));_this._handleEvent(e,_this.handles.eq(idx),$(this).val());});if(this.options.clickSelect){this.$element.off('click.zf.slider').on('click.zf.slider',function(e){if(_this.$element.data('dragging')){return false;}if(!$(e.target).is('[data-slider-handle]')){if(_this.options.doubleSided){_this._handleEvent(e);}else{_this._handleEvent(e,_this.$handle);}}});}if(this.options.draggable){this.handles.addTouch();var $body=$('body');$handle.off('mousedown.zf.slider').on('mousedown.zf.slider',function(e){$handle.addClass('is-dragging');_this.$fill.addClass('is-dragging');//
2052_this.$element.data('dragging',true);curHandle=$(e.currentTarget);$body.on('mousemove.zf.slider',function(e){e.preventDefault();_this._handleEvent(e,curHandle);}).on('mouseup.zf.slider',function(e){_this._handleEvent(e,curHandle);$handle.removeClass('is-dragging');_this.$fill.removeClass('is-dragging');_this.$element.data('dragging',false);$body.off('mousemove.zf.slider mouseup.zf.slider');});})// prevent events triggered by touch
2053.on('selectstart.zf.slider touchmove.zf.slider',function(e){e.preventDefault();});}$handle.off('keydown.zf.slider').on('keydown.zf.slider',function(e){var _$handle=$(this),idx=_this.options.doubleSided?_this.handles.index(_$handle):0,oldValue=parseFloat(_this.inputs.eq(idx).val()),newValue;// handle keyboard event with keyboard util
2054Foundation.Keyboard.handleKey(e,'Slider',{decrease:function decrease(){newValue=oldValue-_this.options.step;},increase:function increase(){newValue=oldValue+_this.options.step;}
2054,decrease_fast:function decrease_fast(){newValue=oldValue-_this.options.step*10;},increase_fast:function increase_fast(){newValue=oldValue+_this.options.step*10;},handled:function handled(){// only set handle pos when event was handled specially
2055e.preventDefault();_this._setHandlePos(_$handle,newValue,true);}});/*if (newValue) { // if pressed key has special function, update value
2056        e.preventDefault();
2057        _this._setHandlePos(_$handle, newValue);
2058      }*/});}/**
2059   * Destroys the slider plugin.
2060   */},{key:'destroy',value:function destroy(){this.handles.off('.zf.slider');this.inputs.off('.zf.slider');this.$element.off('.zf.slider');clearTimeout(this.timeout);Foundation.unregisterPlugin(this);}}]);return Slider;}();Slider.defaults={/**
2061   * Minimum value for the slider scale.
2062   * @option
2063   * @example 0
2064   */start:0,/**
2065   * Maximum value for the slider scale.
2066   * @option
2067   * @example 100
2068   */end:100,/**
2069   * Minimum value change per change event.
2070   * @option
2071   * @example 1
2072   */step:1,/**
2073   * Value at which the handle/input *(left handle/first input)* should be set to on initialization.
2074   * @option
2075   * @example 0
2076   */initialStart:0,/**
2077   * Value at which the right handle/second input should be set to on initialization.
2078   * @option
2079   * @example 100
2080   */initialEnd:100,/**
2081   * Allows the input to be located outside the container and visible. Set to by the JS
2082   * @option
2083   * @example false
2084   */binding:false,/**
2085   * Allows the user to click/tap on the slider bar to select a value.
2086   * @option
2087   * @example true
2088   */clickSelect:true,/**
2089   * Set to true and use the `vertical` class to change alignment to vertical.
2090   * @option
2091   * @example false
2092   */vertical:false,/**
2093   * Allows the user to drag the slider handle(s) to select a value.
2094   * @option
2095   * @example true
2096   */draggable:true,/**
2097   * Disables the slider and prevents event listeners from being applied. Double checked by JS with `disabledClass`.
2098   * @option
2099   * @example false
2100   */disabled:false,/**
2101   * Allows the use of two handles. Double checked by the JS. Changes some logic handling.
2102   * @option
2103   * @example false
2104   */doubleSided:false,/**
2105   * Potential future feature.
2106   */// steps: 100,
2107/**
2108   * Number of decimal places the plugin should go to for floating point precision.
2109   * @option
2110   * @example 2
2111   */decimal:2,/**
2112   * Time delay for dragged elements.
2113   */// dragDelay: 0,
2114/**
2115   * Time, in ms, to animate the movement of a slider handle if user clicks/taps on the bar. Needs to be manually set if updating the transition time in the Sass settings.
2116   * @option
2117   * @example 200
2118   */moveTime:200,//update this if changing the transition time in the sass
2119/**
2120   * Class applied to disabled sliders.
2121   * @option
2122   * @example 'disabled'
2123   */disabledClass:'disabled',/**
2124   * Will invert the default layout for a vertical<span data-tooltip title="who would do this???"> </span>slider.
2125   * @option
2126   * @example false
2127   */invertVertical:false,/**
2128   * Milliseconds before the `changed.zf-slider` event is triggered after value change.
2129   * @option
2130   * @example 500
2131   */changedDelay:500,/**
2132  * Basevalue for non-linear sliders
2133  * @option
2134  * @example 5
2135  */nonLinearBase:5,/**
2136  * Basevalue for non-linear sliders, possible values are: 'linear', 'pow' & 'log'. Pow and Log use the nonLinearBase setting.
2137  * @option
2138  * @example 'linear'
2139  */positionValueFunction:'linear'};function percent(frac,num){return frac/num;}function absPosition($handle,dir,clickPos,param){return Math.abs($handle.position()[dir]+$handle[param]()/2-clickPos);}function baseLog(base,value){return Math.log(value)/Math.log(base);}// Window exports
2140Foundation.plugin(Slider,'Slider');}(jQuery);
2141'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
2142 * Sticky module.
2143 * @module foundation.sticky
2144 * @requires foundation.util.triggers
2145 * @requires foundation.util.mediaQuery
2146 */var Sticky=function(){/**
2147   * Creates a new instance of a sticky thing.
2148   * @class
2149   * @param {jQuery} element - jQuery object to make sticky.
2150   * @param {Object} options - options object passed when creating the element programmatically.
2151   */function Sticky(element,options){_classCallCheck(this,Sticky);this.$element=element;this.options=$.extend({},Sticky.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Sticky');}/**
2152   * Initializes the sticky element by adding classes, getting/setting dimensions, breakpoints and attributes
2153   * @function
2154   * @private
2155   */_createClass(Sticky,[{key:'_init',value:function _init(){var $parent=this.$element.parent('[data-sticky-container]'),id=this.$element[0].id||Foundation.GetYoDigits(6,'sticky'),_this=this;if(!$parent.length){this.wasWrapped=true;}this.$container=$parent.length?$parent:$(this.options.container).wrapInner(this.$element);this.$container.addClass(this.options.containerClass);this.$element.addClass(this.options.stickyClass).attr({'data-resize':id});this.scrollCount=this.options.checkEvery;this.isStuck=false;$(window).one('load.zf.sticky',function(){//We calculate the container height to have correct values for anchor points offset calculation.
2156_this.containerHeight=_this.$element.css("display")=="none"?0:_this.$element[0].getBoundingClientRect().height;_this.$container.css('height',_this.containerHeight);_this.elemHeight=_this.containerHeight;if(_this.options.anchor!==''){_this.$anchor=$('#'+_this.options.anchor);}else{_this._parsePoints();}_this._setSizes(function(){var scroll=window.pageYOffset;_this._calc(false,scroll);//Unstick the element will ensure that proper classes are set.
2157if(!_this.isStuck){_this._removeSticky(scroll>=_this.topPoint?false:true);}});_this._events(id.split('-').reverse().join('-'));});}/**
2158   * If using multiple elements as anchors, calculates the top and bottom pixel values the sticky thing should stick and unstick on.
2159   * @function
2160   * @private
2161   */},{key:'_parsePoints',value:function _parsePoints(){var top=this.options.topAnchor==""?1:this.options.topAnchor,btm=this.options.btmAnchor==""?document.documentElement.scrollHeight:this.options.btmAnchor,pts=[top,btm],breaks={};for(var i=0,len=pts.length;i<len&&pts[i];i++){var pt;if(typeof pts[i]==='number'){pt=pts[i];}else{var place=pts[i].split(':'),anchor=$('#'+place[0]);pt=anchor.offset().top;if(place[1]&&place[1].toLowerCase()==='bottom'){pt+=anchor[0].getBoundingClientRect().height;}}breaks[i]=pt;}this.points=breaks;return;}/**
2162   * Adds event handlers for the scrolling element.
2163   * @private
2164   * @param {String} id - psuedo-random id for unique scroll event listener.
2165   */},{key:'_events',value:function _events(id){var _this=this,scrollListener=this.scrollListener='scroll.zf.'+id;if(this.isOn){return;}if(this.canStick){this.isOn=true;$(window).off(scrollListener).on(scrollListener,function(e){if(_this.scrollCount===0){_this.scrollCount=_this.options.checkEvery;_this._setSizes(function(){_this._calc(false,window.pageYOffset);});}else{_this.scrollCount--;_this._calc(false,window.pageYOffset);}});}this.$element.off('resizeme.zf.trigger').on('resizeme.zf.trigger',function(e,el){_this._setSizes(function(){_this._calc(false);
2165if(_this.canStick){if(!_this.isOn){_this._events(id);}}else if(_this.isOn){_this._pauseListeners(scrollListener);}});});}/**
2166   * Removes event handlers for scroll and change events on anchor.
2167   * @fires Sticky#pause
2168   * @param {String} scrollListener - unique, namespaced scroll listener attached to `window`
2169   */},{key:'_pauseListeners',value:function _pauseListeners(scrollListener){this.isOn=false;$(window).off(scrollListener);/**
2170     * Fires when the plugin is paused due to resize event shrinking the view.
2171     * @event Sticky#pause
2172     * @private
2173     */this.$element.trigger('pause.zf.sticky');}/**
2174   * Called on every `scroll` event and on `_init`
2175   * fires functions based on booleans and cached values
2176   * @param {Boolean} checkSizes - true if plugin should recalculate sizes and breakpoints.
2177   * @param {Number} scroll - current scroll position passed from scroll event cb function. If not passed, defaults to `window.pageYOffset`.
2178   */},{key:'_calc',value:function _calc(checkSizes,scroll){if(checkSizes){this._setSizes();}if(!this.canStick){if(this.isStuck){this._removeSticky(true);}return false;}if(!scroll){scroll=window.pageYOffset;}if(scroll>=this.topPoint){if(scroll<=this.bottomPoint){if(!this.isStuck){this._setSticky();}}else{if(this.isStuck){this._removeSticky(false);}}}else{if(this.isStuck){this._removeSticky(true);}}}/**
2179   * Causes the $element to become stuck.
2180   * Adds `position: fixed;`, and helper classes.
2181   * @fires Sticky#stuckto
2182   * @function
2183   * @private
2184   */},{key:'_setSticky',value:function _setSticky(){var _this=this,stickTo=this.options.stickTo,mrgn=stickTo==='top'?'marginTop':'marginBottom',notStuckTo=stickTo==='top'?'bottom':'top',css={};css[mrgn]=this.options[mrgn]+'em';css[stickTo]=0;css[notStuckTo]='auto';this.isStuck=true;this.$element.removeClass('is-anchored is-at-'+notStuckTo).addClass('is-stuck is-at-'+stickTo).css(css)/**
2185                  * Fires when the $element has become `position: fixed;`
2186                  * Namespaced to `top` or `bottom`, e.g. `sticky.zf.stuckto:top`
2187                  * @event Sticky#stuckto
2188                  */.trigger('sticky.zf.stuckto:'+stickTo);this.$element.on("transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd",function(){_this._setSizes();});}/**
2189   * Causes the $element to become unstuck.
2190   * Removes `position: fixed;`, and helper classes.
2191   * Adds other helper classes.
2192   * @param {Boolean} isTop - tells the function if the $element should anchor to the top or bottom of its $anchor element.
2193   * @fires Sticky#unstuckfrom
2194   * @private
2195   */},{key:'_removeSticky',value:function _removeSticky(isTop){var stickTo=this.options.stickTo,stickToTop=stickTo==='top',css={},anchorPt=(this.points?this.points[1]-this.points[0]:this.anchorHeight)-this.elemHeight,mrgn=stickToTop?'marginTop':'marginBottom',notStuckTo=stickToTop?'bottom':'top',topOrBottom=isTop?'top':'bottom';css[mrgn]=0;css['bottom']='auto';if(isTop){css['top']=0;}else{css['top']=anchorPt;}this.isStuck=false;this.$element.removeClass('is-stuck is-at-'+stickTo).addClass('is-anchored is-at-'+topOrBottom).css(css)/**
2196                  * Fires when the $element has become anchored.
2197                  * Namespaced to `top` or `bottom`, e.g. `sticky.zf.unstuckfrom:bottom`
2198                  * @event Sticky#unstuckfrom
2199                  */.trigger('sticky.zf.unstuckfrom:'+topOrBottom);}/**
2200   * Sets the $element and $container sizes for plugin.
2201   * Calls `_setBreakPoints`.
2202   * @param {Function} cb - optional callback function to fire on completion of `_setBreakPoints`.
2203   * @private
2204   */},{key:'_setSizes',value:function _setSizes(cb){this.canStick=Foundation.MediaQuery.is(this.options.stickyOn);if(!this.canStick){if(cb&&typeof cb==='function'){cb();}}var _this=this,newElemWidth=this.$container[0].getBoundingClientRect().width,comp=window.getComputedStyle(this.$container[0]),pdngl=parseInt(comp['padding-left'],10),pdngr=parseInt(comp['padding-right'],10);if(this.$anchor&&this.$anchor.length){this.anchorHeight=this.$anchor[0].getBoundingClientRect().height;}else{this._parsePoints();}this.$element.css({'max-width':newElemWidth-pdngl-pdngr+'px'});var newContainerHeight=this.$element[0].getBoundingClientRect().height||this.containerHeight;if(this.$element.css("display")=="none"){newContainerHeight=0;}this.containerHeight=newContainerHeight;this.$container.css({height:newContainerHeight});this.elemHeight=newContainerHeight;if(!this.isStuck){if(this.$element.hasClass('is-at-bottom')){var anchorPt=(this.points?this.points[1]-this.$container.offset().top:this.anchorHeight)-this.elemHeight;this.$element.css('top',anchorPt);}}this._setBreakPoints(newContainerHeight,function(){if(cb&&typeof cb==='function'){cb();}});}/**
2205   * Sets the upper and lower breakpoints for the element to become sticky/unsticky.
2206   * @param {Number} elemHeight - px value for sticky.$element height, calculated by `_setSizes`.
2207   * @param {Function} cb - optional callback function to be called on completion.
2208   * @private
2209   */},{key:'_setBreakPoints',value:function _setBreakPoints(elemHeight,cb){if(!this.canStick){if(cb&&typeof cb==='function'){cb();}else{return false;}}var mTop=emCalc(this.options.marginTop),mBtm=emCalc(this.options.marginBottom),topPoint=this.points?this.points[0]:this.$anchor.offset().top,bottomPoint=this.points?this.points[1]:topPoint+this.anchorHeight,// topPoint = this.$anchor.offset().top || this.points[0],
2210// bottomPoint = topPoint + this.anchorHeight || this.points[1],
2211winHeight=window.innerHeight;if(this.options.stickTo==='top'){topPoint-=mTop;bottomPoint-=elemHeight+mTop;}else if(this.options.stickTo==='bottom'){topPoint-=winHeight-(elemHeight+mBtm);bottomPoint-=winHeight-mBtm;}else{//this would be the stickTo: both option... tricky
2212}this.topPoint=topPoint;this.bottomPoint=bottomPoint;if(cb&&typeof cb==='function'){cb();}}/**
2213   * Destroys the current sticky element.
2214   * Resets the element to the top position first.
2215   * Removes event listeners, JS-added css properties and classes, and unwraps the $element if the JS added the $container.
2216   * @function
2217   */},{key:'destroy',value:function destroy(){this._removeSticky(true);this.$element.removeClass(this.options.stickyClass+' is-anchored is-at-top').css({height:'',top:'',bottom:'','max-width':''}).off('resizeme.zf.trigger');if(this.$anchor&&this.$anchor.length){this.$anchor.off('change.zf.sticky');}$(window).off(this.scrollListener);if(this.wasWrapped){this.$element.unwrap();}else{this.$container.removeClass(this.options.containerClass).css({height:''});}Foundation.unregisterPlugin(this);}}]);return Sticky;}();Sticky.defaults={/**
2218   * Customizable container template. Add your own classes for styling and sizing.
2219   * @option
2220   * @example '&lt;div data-sticky-container class="small-6 columns"&gt;&lt;/div&gt;'
2221   */container:'<div data-sticky-container></div>',/**
2222   * Location in the view the element sticks to.
2223   * @option
2224   * @example 'top'
2225   */stickTo:'top',/**
2226   * If anchored to a single element, the id of that element.
2227   * @option
2228   * @example 'exampleId'
2229   */anchor:'',/**
2230   * If using more than one element as anchor points, the id of the top anchor.
2231   * @option
2232   * @example 'exampleId:top'
2233   */topAnchor:'',/**
2234   * If using more than one element as anchor points, the id of the bottom anch
2234or.
2235   * @option
2236   * @example 'exampleId:bottom'
2237   */btmAnchor:'',/**
2238   * Margin, in `em`'s to apply to the top of the element when it becomes sticky.
2239   * @option
2240   * @example 1
2241   */marginTop:1,/**
2242   * Margin, in `em`'s to apply to the bottom of the element when it becomes sticky.
2243   * @option
2244   * @example 1
2245   */marginBottom:1,/**
2246   * Breakpoint string that is the minimum screen size an element should become sticky.
2247   * @option
2248   * @example 'medium'
2249   */stickyOn:'medium',/**
2250   * Class applied to sticky element, and removed on destruction. Foundation defaults to `sticky`.
2251   * @option
2252   * @example 'sticky'
2253   */stickyClass:'sticky',/**
2254   * Class applied to sticky container. Foundation defaults to `sticky-container`.
2255   * @option
2256   * @example 'sticky-container'
2257   */containerClass:'sticky-container',/**
2258   * Number of scroll events between the plugin's recalculating sticky points. Setting it to `0` will cause it to recalc every scroll event, setting it to `-1` will prevent recalc on scroll.
2259   * @option
2260   * @example 50
2261   */checkEvery:-1};/**
2262 * Helper function to calculate em values
2263 * @param Number {em} - number of em's to calculate into pixels
2264 */function emCalc(em){return parseInt(window.getComputedStyle(document.body,null).fontSize,10)*em;}// Window exports
2265Foundation.plugin(Sticky,'Sticky');}(jQuery);
2266'use strict';var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj;}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
2267 * Tabs module.
2268 * @module foundation.tabs
2269 * @requires foundation.util.keyboard
2270 * @requires foundation.util.timerAndImageLoader if tabs contain images
2271 */var Tabs=function(){/**
2272   * Creates a new instance of tabs.
2273   * @class
2274   * @fires Tabs#init
2275   * @param {jQuery} element - jQuery object to make into tabs.
2276   * @param {Object} options - Overrides to the default plugin settings.
2277   */function Tabs(element,options){_classCallCheck(this,Tabs);this.$element=element;this.options=$.extend({},Tabs.defaults,this.$element.data(),options);this._init();Foundation.registerPlugin(this,'Tabs');Foundation.Keyboard.register('Tabs',{'ENTER':'open','SPACE':'open','ARROW_RIGHT':'next','ARROW_UP':'previous','ARROW_DOWN':'next','ARROW_LEFT':'previous'// 'TAB': 'next',
2278// 'SHIFT_TAB': 'previous'
2279});}/**
2280   * Initializes the tabs by showing and focusing (if autoFocus=true) the preset active tab.
2281   * @private
2282   */_createClass(Tabs,[{key:'_init',value:function _init(){var _this=this;this.$element.attr({'role':'tablist'});this.$tabTitles=this.$element.find('.'+this.options.linkClass);this.$tabContent=$('[data-tabs-content="'+this.$element[0].id+'"]');this.$tabTitles.each(function(){var $elem=$(this),$link=$elem.find('a'),isActive=$elem.hasClass(''+_this.options.linkActiveClass),hash=$link[0].hash.slice(1),linkId=$link[0].id?$link[0].id:hash+'-label',$tabContent=$('#'+hash);$elem.attr({'role':'presentation'});$link.attr({'role':'tab','aria-controls':hash,'aria-selected':isActive,'id':linkId});$tabContent.attr({'role':'tabpanel','aria-hidden':!isActive,'aria-labelledby':linkId});if(isActive&&_this.options.autoFocus){$(window).load(function(){$('html, body').animate({scrollTop:$elem.offset().top},_this.options.deepLinkSmudgeDelay,function(){$link.focus();});});}//use browser to open a tab, if it exists in this tabset
2283if(_this.options.deepLink){var anchor=window.location.hash;//need a hash and a relevant anchor in this tabset
2284if(anchor.length){var $link=$elem.find('[href="'+anchor+'"]');
2284if($link.length){_this.selectTab($(anchor));//roll up a little to show the titles
2285if(_this.options.deepLinkSmudge){$(window).load(function(){var offset=$elem.offset();$('html, body').animate({scrollTop:offset.top},_this.options.deepLinkSmudgeDelay);});}/**
2286              * Fires when the zplugin has deeplinked at pageload
2287              * @event Tabs#deeplink
2288              */$elem.trigger('deeplink.zf.tabs',[$link,$(anchor)]);}}}});if(this.options.matchHeight){var $images=this.$tabContent.find('img');if($images.length){Foundation.onImagesLoaded($images,this._setHeight.bind(this));}else{this._setHeight();}}this._events();}/**
2289   * Adds event handlers for items within the tabs.
2290   * @private
2291   */},{key:'_events',value:function _events(){this._addKeyHandler();this._addClickHandler();this._setHeightMqHandler=null;if(this.options.matchHeight){this._setHeightMqHandler=this._setHeight.bind(this);$(window).on('changed.zf.mediaquery',this._setHeightMqHandler);}}/**
2292   * Adds click handlers for items within the tabs.
2293   * @private
2294   */},{key:'_addClickHandler',value:function _addClickHandler(){var _this=this;this.$element.off('click.zf.tabs').on('click.zf.tabs','.'+this.options.linkClass,function(e){e.preventDefault();e.stopPropagation();_this._handleTabChange($(this));});}/**
2295   * Adds keyboard event handlers for items within the tabs.
2296   * @private
2297   */},{key:'_addKeyHandler',value:function _addKeyHandler(){var _this=this;this.$tabTitles.off('keydown.zf.tabs').on('keydown.zf.tabs',function(e){if(e.which===9)return;var $element=$(this),$elements=$element.parent('ul').children('li'),$prevElement,$nextElement;$elements.each(function(i){if($(this).is($element)){if(_this.options.wrapOnKeys){$prevElement=i===0?$elements.last():$elements.eq(i-1);$nextElement=i===$elements.length-1?$elements.first():$elements.eq(i+1);}else{$prevElement=$elements.eq(Math.max(0,i-1));$nextElement=$elements.eq(Math.min(i+1,$elements.length-1));}return;}});// handle keyboard event with keyboard util
2298Foundation.Keyboard.handleKey(e,'Tabs',{open:function open(){$element.find('[role="tab"]').focus();_this._handleTabChange($element);},previous:function previous(){$prevElement.find('[role="tab"]').focus();_this._handleTabChange($prevElement);},next:function next(){$nextElement.find('[role="tab"]').focus();_this._handleTabChange($nextElement);},handled:function handled(){e.stopPropagation();e.preventDefault();}});});}/**
2299   * Opens the tab `$targetContent` defined by `$target`. Collapses active tab.
2300   * @param {jQuery} $target - Tab to open.
2301   * @fires Tabs#change
2302   * @function
2303   */},{key:'_handleTabChange',value:function _handleTabChange($target){/**
2304     * Check for active class on target. Collapse if exists.
2305     */if($target.hasClass(''+this.options.linkActiveClass)){if(this.options.activeCollapse){this._collapseTab($target);/**
2306            * Fires when the zplugin has successfully collapsed tabs.
2307            * @event Tabs#collapse
2308            */this.$element.trigger('collapse.zf.tabs',[$target]);}return;}var $oldTab=this.$element.find('.'+this.options.linkClass+'.'+this.options.linkActiveClass),$tabLink=$target.find('[role="tab"]'),hash=$tabLink[0].hash,$targetContent=this.$tabContent.find(hash);//close old tab
2309this._collapseTab($oldTab);//open new tab
2310this._openTab($target);//either replace or update browser history
2311if(this.options.deepLink){var anchor=$target.find('a').attr('href');if(this.options.updateHistory){history.pushState({},'',anchor);}else{history.replaceState({},'',anchor);}}/**
2312     * Fires when the plugin has successfully changed tabs.
2313     * @event Tabs#change
2314     */this.$element.trigger('change.zf.tabs',[$target,$targetContent]);//fire to children a mutation event
2315$targetContent.find("[data-mutate]").trigger("mutateme.zf.trigger");}/**
2316   * Opens the tab `$targetContent` defined by `$target`.
2317   * @param {jQuery} $target - Tab to Open.
2318   * @function
2319   */},{key:'_openTab',value:function _openTab($target){var $tabLink=$target.find('[role="tab"]'),hash=$tabLink[0].hash,$targetContent=this.$tabContent.find(hash);$target.addClass(''+this.options.linkActiveClass);$tabLink.attr({'aria-selected':'true'});$targetContent.addClass(''+this.options.panelActiveClass).attr({'aria-hidden':'false'});}/**
2320   * Collapses `$targetContent` defined by `$target`.
2321   * @param {jQuery} $target - Tab to Open.
2322   * @function
2323   */},{key:'_collapseTab',value:function _collapseTab($target){var $target_anchor=$target.removeClass(''+this.options.linkActiveClass).find('[role="tab"]').attr({'aria-selected':'false'});$('#'+$target_anchor.attr('aria-controls')).removeClass(''+this.options.panelActiveClass).attr({'aria-hidden':'true'});}/**
2324   * Public method for selecting a content pane to display.
2325   * @param {jQuery | String} elem - jQuery object or string of the id of the pane to display.
2326   * @function
2327   */},{key:'selectTab',value:function selectTab(elem){var idStr;if((typeof elem==='undefined'?'undefined':_typeof(elem))==='object'){idStr=elem[0].id;}else{idStr=elem;}if(idStr.indexOf('#')<0){idStr='#'+idStr;}var $target=this.$tabTitles.find('[href="'+idStr+'"]').parent('.'+this.options.linkClass);this._handleTabChange($target);}},{key:'_setHeight',/**
2328   * Sets the height of each panel to the height of the tallest panel.
2329   * If enabled in options, gets called on media query change.
2330   * If loading content via external source, can be called directly or with _reflow.
2331   * @function
2332   * @private
2333   */value:function _setHeight(){var max=0;this.$tabContent.find('.'+this.options.panelClass).css('height','').each(function(){var panel=$(this),isActive=panel.hasClass(''+this.options.panelActiveClass);if(!isActive){panel.css({'visibility':'hidden','display':'block'});}var temp=this.getBoundingClientRect().height;if(!isActive){panel.css({'visibility':'','display':''});}max=temp>max?temp:max;}).css('height',max+'px');}/**
2334   * Destroys an instance of an tabs.
2335   * @fires Tabs#destroyed
2336   */},{key:'destroy',value:function destroy(){this.$element.find('.'+this.options.linkClass).off('.zf.tabs').hide().end().find('.'+this.options.panelClass).hide();if(this.options.matchHeight){if(this._setHeightMqHandler!=null){$(window).off('changed.zf.mediaquery',this._setHeightMqHandler);}}Foundation.unregisterPlugin(this);}}]);return Tabs;}();Tabs.defaults={/**
2337   * Allows the window to scroll to content of pane specified by hash anchor
2338   * @option
2339   * @example false
2340   */deepLink:false,/**
2341   * Adjust the deep link scroll to make sure the top of the tab panel is visible
2342   * @option
2343   * @example false
2344   */deepLinkSmudge:false,/**
2345   * Animation time (ms) for the deep link adjustment
2346   * @option
2347   * @example 300
2348   */deepLinkSmudgeDelay:300,/**
2349   * Update the browser history with the open tab
2350   * @option
2351   * @example false
2352   */updateHistory:false,/**
2353   * Allows the window to scroll to content of active pane on load if set to true.
2354   * Not recommended if more than one tab panel per page.
2355   * @option
2356   * @example false
2357   */autoFocus:false,/**
2358   * Allows keyboard input to 'wrap' around the tab links.
2359   * @option
2360   * @example true
2361   */wrapOnKeys:true,/**
2362   * Allows the tab content panes to match heights if set to true.
2363   * @option
2364   * @example false
2365   */matchHeight:false,/**
2366   * Allows active tabs to collapse when clicked.
2367   * @option
2368   * @example false
2369   */activeCollapse:false,/**
2370   * Class applied to `li`'s in tab link list.
2371   * @option
2372   * @example 'tabs-title'
2373   */linkClass:'tabs-title',/**
2374   * Class applied to the active `li` in tab link list.
2375   * @option
2376   * @example 'is-active'
2377   */linkActiveClass:'is-active',/**
2378   * Class applied to the content containers.
2379   * @option
2380   * @example 'tabs-panel'
2381   */panelClass:'tabs-panel',/**
2382   * Class applied to the active content container.
2383   * @option
2384   * @example 'is-active'
2385   */panelActiveClass:'is-active'};// Window exports
2386Foundation.plugin(Tabs,'Tabs');}(jQuery);
2387'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
2388 * Toggler module.
2389 * @module foundation.toggler
2390 * @requires foundation.util.motion
2391 * @requires foundation.util.triggers
2392 */var Toggler=function(){/**
2393   * Creates a new instance of Toggler.
2394   * @class
2395   * @fires Toggler#init
2396   * @param {Object} element - jQuery object to add the trigger to.
2397   * @param {Object} options - Overrides to the default plugin settings.
2398   */function Toggler(element,options){_classCallCheck(this,Toggler);this.$element=element;this.options=$.extend({},Toggler.defaults,element.data(),options);this.className='';this._init();this._events();Foundation.registerPlugin(this,'Toggler');}/**
2399   * Initializes the Toggler plugin by parsing the toggle class from data-toggler, or animation classes from data-animate.
2400   * @function
2401   * @private
2402   */_createClass(Toggler,[{key:'_init',value:function _init(){var input;// Parse animation classes if they were set
2403if(this.options.animate){input=this.options.animate.split(' ');this.animationIn=input[0];this.animationOut=input[1]||null;}// Otherwise, parse toggle class
2404else{input=this.$element.data('toggler');// Allow for a . at the beginning of the string
2405this.className=input[0]==='.'?input.slice(1):input;}// Add ARIA attributes to triggers
2406var id=this.$element[0].id;$('[data-open="'+id+'"], [data-close="'+id+'"], [data-toggle="'+id+'"]').attr('aria-controls',id);// If the target is hidden, add aria-hidden
2407this.$element.attr('aria-expanded',this.$element.is(':hidden')?false:true);}/**
2408   * Initializes events for the toggle trigger.
2409   * @function
2410   * @private
2411   */},{key:'_events',value:function _events(){this.$element.off('toggle.zf.trigger').on('toggle.zf.trigger',this.toggle.bind(this));}/**
2412   * Toggles the target class on the target element. An event is fired from the original trigger depending on if the resultant state was "on" or "off".
2413   * @function
2414   * @fires Toggler#on
2415   * @fires Toggler#off
2416   */},{key:'toggle',value:function toggle(){this[this.options.animate?'_toggleAnimate':'_toggleClass']();}},{key:'_toggleClass',value:function _toggleClass(){this.$element.toggleClass(this.className);var isOn=this.$element.hasClass(this.className);if(isOn){/**
2417       * Fires if the target element has the class after a toggle.
2418       * @event Toggler#on
2419       */this.$element.trigger('on.zf.toggler');}else{/**
2420       * Fires if the target element does not have the class after a toggle.
2421       * @event Toggler#off
2422       */this.$element.trigger('off.zf.toggler');}this._updateARIA(isOn);this.$element.find('[data-mutate]').trigger('mutateme.zf.trigger');}},{key:'_toggleAnimate',value:function _toggleAnimate(){var _this=this;if(this.$element.is(':hidden')){Foundation.Motion.animateIn(this.$element,this.animationIn,function(){_this._updateARIA(true);this.trigger('on.zf.toggler');this.find('[data-mutate]').trigger('mutateme.zf.trigger');});}else{Foundation.Motion.animateOut(this.$element,this.animationOut,function(){_this._updateARIA(false);this.trigger('off.zf.toggler');this.find('[data-mutate]').trigger('mutateme.zf.trigger');});}}},{key:'_updateARIA',value:function _updateARIA(isOn){this.$element.attr('aria-expanded',isOn?true:false);}/**
2423   * Destroys the instance of Toggler on the element.
2424   * @function
2425   */},{key:'destroy',value:function destroy(){this.$element.off('.zf.toggler');Foundation.unregisterPlugin(this);}}]);return Toggler;}();Toggler.defaults={/**
2426   * Tells the plugin if the element should animated when toggled.
2427   * @option
2428   * @example false
2429   */animate:false};// Window exports
2430Foundation.plugin(Toggler,'Toggler');}(jQuery);
2431'use strict';var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}!function($){/**
2432 * Tooltip module.
2433 * @module foundation.tooltip
2434 * @requires foundation.util.box
2435 * @requires foundation.util.mediaQuery
2436 * @requires foundation.util.triggers
2437 */var Tooltip=function(){/**
2438   * Creates a new instance of a Tooltip.
2439   * @class
2440   * @fires Tooltip#init
2441   * @param {jQuery} element - jQuery object to attach a tooltip to.
2442   * @param {Object} options - object to extend the default configuration.
2443   */function Tooltip(element,options){_classCallCheck(this,Tooltip);this.$element=element;this.options=$.extend({},Tooltip.defaults,this.$element.data(),options);this.isActive=false;this.isClick=false;this._init();Foundation.registerPlugin(this,'Tooltip');}/**
2444   * Initializes the tooltip by setting the creating the tip element, adding it's text, setting private variables and setting attributes on the anch
2444or.
2445   * @private
2446   */_createClass(Tooltip,[{key:'_init',value:function _init(){var elemId=this.$element.attr('aria-describedby')||Foundation.GetYoDigits(6,'tooltip');this.options.positionClass=this.options.positionClass||this._getPositionClass(this.$element);this.options.tipText=this.options.tipText||this.$element.attr('title');this.template=this.options.template?$(this.options.template):this._buildTemplate(elemId);if(this.options.allowHtml){this.template.appendTo(document.body).html(this.options.tipText).hide();}else{this.template.appendTo(document.body).text(this.options.tipText).hide();}this.$element.attr({'title':'','aria-describedby':elemId,'data-yeti-box':elemId,'data-toggle':elemId,'data-resize':elemId}).addClass(this.options.triggerClass);//helper variables to track movement on collisions
2447this.usedPositions=[];this.counter=4;this.classChanged=false;this._events();}/**
2448   * Grabs the current positioning class, if present, and returns the value or an empty string.
2449   * @private
2450   */},{key:'_getPositionClass',value:function _getPositionClass(element){if(!element){return'';}// var position = element.attr('class').match(/top|left|right/g);
2451var position=element[0].className.match(/\b(top|left|right)\b/g);position=position?position[0]:'';return position;}},{key:'_buildTemplate',/**
2452   * builds the tooltip element, adds attributes, and returns the template.
2453   * @private
2454   */value:function _buildTemplate(id){var templateClasses=(this.options.tooltipClass+' '+this.options.positionClass+' '+this.options.templateClasses).trim();var $template=$('<div></div>').addClass(templateClasses).attr({'role':'tooltip','aria-hidden':true,'data-is-active':false,'data-is-focus':false,'id':id});return $template;}/**
2455   * Function that gets called if a collision event is detected.
2456   * @param {String} position - positioning class to try
2457   * @private
2458   */},{key:'_reposition',value:function _reposition(position){this.usedPositions.push(position?position:'bottom');//default, try switching to opposite side
2459if(!position&&this.usedPositions.indexOf('top')<0){this.template.addClass('top');}else if(position==='top'&&this.usedPositions.indexOf('bottom')<0){this.template.removeClass(position);}else if(position==='left'&&this.usedPositions.indexOf('right')<0){this.template.removeClass(position).addClass('right');}else if(position==='right'&&this.usedPositions.indexOf('left')<0){this.template.removeClass(position).addClass('left');}//if default change didn't work, try bottom or left first
2460else if(!position&&this.usedPositions.indexOf('top')>-1&&this.usedPositions.indexOf('left')<0){this.template.addClass('left');}else if(position==='top'&&this.usedPositions.indexOf('bottom')>-1&&this.usedPositions.indexOf('left')<0){this.template.removeClass(position).addClass('left');}else if(position==='left'&&this.usedPositions.indexOf('right')>-1&&this.usedPositions.indexOf('bottom')<0){this.template.removeClass(position);}else if(position==='right'&&this.usedPositions.indexOf('left')>-1&&this.usedPositions.indexOf('bottom')<0){this.template.removeClass(position);}//if nothing cleared, set to bottom
2461else{this.template.removeClass(position);}this.classChanged=true;this.counter--;}/**
2462   * sets the position class of an element and recursively calls itself until there are no more possible positions to attempt, or the tooltip element is no longer colliding.
2463   * if the tooltip is larger than the screen width, default to full width - any user selected margin
2464   * @private
2465   */},{key:'_setPosition',value:function _setPosition(){var position=this._getPositionClass(this.template),$tipDims=Foundation.Box.GetDimensions(this.template),$anchorDims=Foundation.Box.GetDimensions(this.$element),direction=position==='left'?'left':position==='right'?'left':'top',param=direction==='top'?'height':'width',offset=param==='height'?this.options.vOffset:this.options.hOffset,_this=this;if($tipDims.width>=$tipDims.windowDims.width||!this.counter&&!Foundation.Box.ImNotTouchingYou(this.template)){this.template.offset(Foundation.Box.GetOffsets(this.template,this.$element,'center bottom',this.options.vOffset,this.options.hOffset,true)).css({// this.$element.offset(Foundation.GetOffsets(this.template, this.$element, 'center bottom', this.options.vOffset, this.options.hOffset, true)).css({
2466'width':$anchorDims.windowDims.width-this.options.hOffset*2,'height':'auto'});return false;}this.template.offset(Foundation.Box.GetOffsets(this.template,this.$element,'center '+(position||'bottom'),this.options.vOffset,this.options.hOffset));while(!Foundation.Box.ImNotTouchingYou(this.template)&&this.counter){this._reposition(position);this._setPosition();}}/**
2467   * reveals the tooltip, and fires an event to close any other open tooltips on the page
2468   * @fires Tooltip#closeme
2469   * @fires Tooltip#show
2470   * @function
2471   */},{key:'show',value:function show(){if(this.options.showOn!=='all'&&!Foundation.MediaQuery.is(this.options.showOn)){// console.error('The screen is too small to display this tooltip');
2472return false;}var _this=this;this.template.css('visibility','hidden').show();this._setPosition();/**
2473     * Fires to close all other open tooltips on the page
2474     * @event Closeme#tooltip
2475     */this.$element.trigger('closeme.zf.tooltip',this.template.attr('id'));this.template.attr({'data-is-active':true,'aria-hidden':false});_this.isActive=true;// console.log(this.template);
2476this.template.stop().hide().css('visibility','').fadeIn(this.options.fadeInDuration,function(){//maybe do stuff?
2477});/**
2478     * Fires when the tooltip is shown
2479     * @event Tooltip#show
2480     */this.$element.trigger('show.zf.tooltip');}/**
2481   * Hides the current tooltip, and resets the positioning class if it was changed due to collision
2482   * @fires Tooltip#hide
2483   * @function
2484   */},{key:'hide',value:function hide(){// console.log('hiding', this.$element.data('yeti-box'));
2485var _this=this;this.template.stop().attr({'aria-hidden':true,'data-is-active':false}).fadeOut(this.options.fadeOutDuration,function(){_this.isActive=false;_this.isClick=false;if(_this.classChanged){_this.template.removeClass(_this._getPositionClass(_this.template)).addClass(_this.options.positionClass);_this.usedPositions=[];_this.counter=4;_this.classChanged=false;}});/**
2486     * fires when the tooltip is hidden
2487     * @event Tooltip#hide
2488     */this.$element.trigger('hide.zf.tooltip');}/**
2489   * adds event listeners for the tooltip and its anchor
2490   * TODO combine some of the listeners like focus and mouseenter, etc.
2491   * @private
2492   */},{key:'_events',value:function _events(){var _this=this;var $template=this.template;var isFocus=false;if(!this.options.disableHover){this.$element.on('mouseenter.zf.tooltip',function(e){if(!_this.isActive){_this.timeout=setTimeout(function(){_this.show();},_this.options.hoverDelay);}}).on('mouseleave.zf.tooltip',function(e){clearTimeout(_this.timeout);if(!isFocus||_this.isClick&&!_this.options.clickOpen){_this.hide();}});}if(this.options.clickOpen){this.$element.on('mousedown.zf.tooltip',function(e){e.stopImmediatePropagation();if(_this.isClick){//_this.hide();
2493// _this.isClick = false;
2494}else{_this.isClick=true;if((_this.options.disableHover||!_this.$element.attr('tabindex'))&&!_this.isActive){_this.show();}}});}else{this.$element.on('mousedown.zf.tooltip',function(e){e.stopImmediatePropagation();_this.isClick=true;});}if(!this.options.disableForTouch){this.$element.on('tap.zf.tooltip touchend.zf.tooltip',function(e){_this.isActive?_this.hide():_this.show();});}this.$element.on({// 'toggle.zf.trigger': this.toggle.bind(this),
2495// 'close.zf.trigger': this.hide.bind(this)
2496'close.zf.trigger':this.hide.bind(this)});this.$element.on('focus.zf.tooltip',function(e){isFocus=true;if(_this.isClick){// If we're not showing open on clicks, we need to pretend a click-launched focus isn't
2497// a real focus, otherwise on hover and come back we get bad behavior
2498if(!_this.options.clickOpen){isFocus=false;}return false;}else{_this.show();}}).on('focusout.zf.tooltip',function(e){isFocus=false;_this.isClick=false;_this.hide();}).on('resizeme.zf.trigger',function(){if(_this.isActive){_this._setPosition();}});}/**
2499   * adds a toggle method, in addition to the static show() & hide() functions
2500   * @function
2501   */},{key:'toggle',value:function toggle(){if(this.isActive){this.hide();}else{this.show();}}/**
2502   * Destroys an instance of tooltip, removes template element from the view.
2503   * @function
2504   */},{key:'destroy',value:function destroy(){this.$element.attr('title',this.template.text()).off('.zf.trigger .zf.tooltip').removeClass('has-tip top right left').removeAttr('aria-describedby aria-haspopup data-disable-hover data-resize data-toggle data-tooltip data-yeti-box');this.template.remove();Foundation.unregisterPlugin(this);}}]);return Tooltip;}();Tooltip.defaults={disableForTouch:false,/**
2505   * Time, in ms, before a tooltip should open on hover.
2506   * @option
2507   * @example 200
2508   */hoverDelay:200,/**
2509   * Time, in ms, a tooltip should take to fade into view.
2510   * @option
2511   * @example 150
2512   */fadeInDuration:150,/**
2513   * Time, in ms, a tooltip should take to fade out of view.
2514   * @option
2515   * @example 150
2516   */fadeOutDuration:150,/**
2517   * Disables hover events from opening the tooltip if set to true
2518   * @option
2519   * @example false
2520   */disableHover:false,/**
2521   * Optional addtional classes to apply to the tooltip template on init.
2522   * @option
2523   * @example 'my-cool-tip-class'
2524   */templateClasses:'',/**
2525   * Non-optional class added to tooltip templates. Foundation default is 'tooltip'.
2526   * @option
2527   * @example 'tooltip'
2528   */tooltipClass:'tooltip',/**
2529   * Class applied to the tooltip anchor element.
2530   * @option
2531   * @example 'has-tip'
2532   */triggerClass:'has-tip',/**
2533   * Minimum breakpoint size at which to open the tooltip.
2534   * @option
2535   * @example 'small'
2536   */showOn:'small',/**
2537   * Custom template to be used to generate markup for tooltip.
2538   * @option
2539   * @example '&lt;div class="tooltip"&gt;&lt;/div&gt;'
2540   */template:'',/**
2541   * Text displayed in the tooltip template on open.
2542   * @option
2543   * @example 'Some cool space fact here.'
2544   */tipText:'',touchCloseText:'Tap to close.',/**
2545   * Allows the tooltip to remain open if triggered with a click or touch event.
2546   * @option
2547   * @example true
2548   */clickOpen:true,/**
2549   * Additional positioning classes, set by the JS
2550   * @option
2551   * @example 'top'
2552   */positionClass:'',/**
2553   * Distance, in pixels, the template should push away from the anch
2553or on the Y axis.
2554   * @option
2555   * @example 10
2556   */vOffset:10,/**
2557   * Distance, in pixels, the template should push away from the anchor on the X axis, if aligned to a side.
2558   * @option
2559   * @example 12
2560   */hOffset:12,/**
2561   * Allow HTML in tooltip. Warning: If you are loading user-generated content into tooltips,
2562   * allowing HTML may open yourself up to XSS attacks.
2563   * @option
2564   * @example false
2565   */allowHtml:false};/**
2566 * TODO utilize resize event trigger
2567 */// Window exports
2568Foundation.plugin(Tooltip,'Tooltip');}(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.