1(function webpackUniversalModuleDefinition(root, factory) { 2 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("jquery"));else if (typeof define === 'function' && define.amd) define(["jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.core"] = factory(root["jQuery"]); 3})(self, function (__WEBPACK_EXTERNAL_MODULE_jquery__) { 4 return /******/function () { 5 // webpackBootstrap 6 /******/ 7 "use strict"; 8 9 /******/ 10 var __webpack_modules__ = { 11
vendor: 27,000 bytes, lines 11-601
11/***/"./js/foundation.core.js": ( 12 /*!*******************************!*\ 13 !*** ./js/foundation.core.js ***! 14 \*******************************/ 15 /***/ 16 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 17 __webpack_require__.r(__webpack_exports__); 18 /* harmony export */ 19 __webpack_require__.d(__webpack_exports__, { 20 /* harmony export */Foundation: function () { 21 return /* binding */Foundation; 22 } 23 /* harmony export */ 24 }); 25 /* harmony import */ 26 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 27 /* harmony import */ 28 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 29 /* harmony import */ 30 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./js/foundation.core.utils.js"); 31 /* harmony import */ 32 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./js/foundation.util.mediaQuery.js"); 33 function _typeof(o) { 34 "@babel/helpers - typeof"; 35 36 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 37 return typeof o; 38 } : function (o) { 39 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 40 }, _typeof(o); 41 } 42 var FOUNDATION_VERSION = '6.9.0'; 43 44 // Global Foundation object 45 // This is attached to the window, or used as a module for AMD/Browserify 46 var Foundation = { 47 version: FOUNDATION_VERSION, 48 /** 49 * Stores initialized plugins. 50 */ 51 _plugins: {}, 52 /** 53 * Stores generated unique ids for plugin instances 54 */ 55 _uuids: [], 56 /** 57 * Defines a Foundation plugin, adding it to the `Foundation` namespace and the list of plugins to initialize when reflowing. 58 * @param {Object} plugin - The constructor of the plugin. 59 */ 60 plugin: function plugin(_plugin, name) { 61 // Object key to use when adding to global Foundation object 62 // Examples: Foundation.Reveal, Foundation.OffCanvas 63 var className = name || functionName(_plugin); 64 // Object key to use when storing the plugin, also used to create the identifying data attribute for the plugin 65 // Examples: data-reveal, data-off-canvas 66 var attrName = hyphenate(className); 67 68 // Add to the Foundation object and the plugins list (for reflowing) 69 this._plugins[attrName] = this[className] = _plugin; 70 }, 71 /** 72 * @function 73 * Populates the _uuids array with pointers to each individual plugin instance. 74 * Adds the `zfPlugin` data-attribute to programmatically created plugins to allow use of $(selector).foundation(method) calls. 75 * Also fires the initialization event for each plugin, consolidating repetitive code. 76 * @param {Object} plugin - an instance of a plugin, usually `this` in context. 77 * @param {String} name - the name of the plugin, passed as a camelCased string. 78 * @fires Plugin#init 79 */ 80 registerPlugin: function registerPlugin(plugin, name) { 81 var pluginName = name ? hyphenate(name) : functionName(plugin.constructor).toLowerCase(); 82 plugin.uuid = (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.GetYoDigits)(6, pluginName); 83 if (!plugin.$element.attr("data-".concat(pluginName))) { 84 plugin.$element.attr("data-".concat(pluginName), plugin.uuid); 85 } 86 if (!plugin.$element.data('zfPlugin')) { 87 plugin.$element.data('zfPlugin', plugin); 88 } 89 /** 90 * Fires when the plugin has initialized. 91 * @event Plugin#init 92 */ 93 plugin.$element.trigger("init.zf.".concat(pluginName)); 94 this._uuids.push(plugin.uuid); 95 return; 96 }, 97 /** 98 * @function 99 * Removes the plugins uuid from the _uuids array. 100 * Removes the zfPlugin data attribute, as well as the data-plugin-name attribute. 101 * Also fires the destroyed event for the plugin, consolidating repetitive code. 102 * @param {Object} plugin - an instance of a plugin, usually `this` in context. 103 * @fires Plugin#destroyed 104 */ 105 unregisterPlugin: function unregisterPlugin(plugin) { 106 var pluginName = hyphenate(functionName(plugin.$element.data('zfPlugin').constructor)); 107 this._uuids.splice(this._uuids.indexOf(plugin.uuid), 1); 108 plugin.$element.removeAttr("data-".concat(pluginName)).removeData('zfPlugin') 109 /** 110 * Fires when the plugin has been destroyed. 111 * @event Plugin#destroyed 112 */.trigger("destroyed.zf.".concat(pluginName)); 113 for (var prop in plugin) { 114 if (typeof plugin[prop] === 'function') { 115 plugin[prop] = null; //clean up script to prep for garbage collection. 116 } 117 } 118 return; 119 }, 120 /** 121 * @function 122 * Causes one or more active plugins to re-initialize, resetting event listeners, recalculating positions, etc. 123 * @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'` 124 * @default If no argument is passed, reflow all currently active plugins. 125 */ 126 reInit: function reInit(plugins) { 127 var isJQ = plugins instanceof jquery__WEBPACK_IMPORTED_MODULE_0___default(); 128 try { 129 if (isJQ) { 130 plugins.each(function () { 131 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('zfPlugin')._init(); 132 }); 133 } else { 134 var type = _typeof(plugins), 135 _this = this, 136 fns = { 137 'object': function object(plgs) { 138 plgs.forEach(function (p) { 139 p = hyphenate(p); 140 jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-' + p + ']').foundation('_init'); 141 }); 142 }, 143 'string': function string() { 144 plugins = hyphenate(plugins); 145 jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-' + plugins + ']').foundation('_init'); 146 }, 147 'undefined': function undefined() { 148 this.object(Object.keys(_this._plugins)); 149 } 150 }; 151 fns[type](plugins); 152 } 153 } catch (err) { 154 console.error(err); 155 } finally { 156 return plugins; 157 } 158 }, 159 /** 160 * Initialize plugins on any elements within `elem` (and `elem` itself) that aren't already initialized. 161 * @param {Object} elem - jQuery object containing the element to check inside. Also checks the element itself, unless it's the `document` object. 162 * @param {String|Array} plugins - A list of plugins to initialize. Leave this out to initialize everything. 163 */ 164 reflow: function reflow(elem, plugins) { 165 // If plugins is undefined, just grab everything 166 if (typeof plugins === 'undefined') { 167 plugins = Object.keys(this._plugins); 168 } 169 // If plugins is a string, convert it to an array with one item 170 else if (typeof plugins === 'string') { 171 plugins = [plugins]; 172 } 173 var _this = this; 174 175 // Iterate through each plugin 176 jquery__WEBPACK_IMPORTED_MODULE_0___default().each(plugins, function (i, name) { 177 // Get the current plugin 178 var plugin = _this._plugins[name]; 179 180 // Localize the search to all elements inside elem, as well as elem itself, unless elem === document 181 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elem).find('[data-' + name + ']').addBack('[data-' + name + ']').filter(function () { 182 return typeof jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data("zfPlugin") === 'undefined'; 183 }); 184 185 // For each plugin found, initialize it 186 $elem.each(function () { 187 var $el = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 188 opts = { 189 reflow: true 190 }; 191 if ($el.attr('data-options')) { 192 $el.attr('data-options').split(';').forEach(function (option) { 193 var opt = option.split(':').map(function (el) { 194 return el.trim(); 195 }); 196 if (opt[0]) opts[opt[0]] = parseValue(opt[1]); 197 }); 198 } 199 try { 200 $el.data('zfPlugin', new plugin(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), opts)); 201 } catch (er) { 202 console.error(er); 203 } finally { 204 return; 205 } 206 }); 207 }); 208 }, 209 getFnName: functionName, 210 addToJquery: function addToJquery() { 211 // TODO: consider not making this a jQuery function 212 // TODO: need way to reflow vs. re-initialize 213 /** 214 * The Foundation jQuery method. 215 * @param {String|Array} method - An action to perform on the current jQuery object. 216 */ 217 var foundation = function foundation(method) { 218 var type = _typeof(method), 219 $noJS = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.no-js'); 220 if ($noJS.length) { 221 $noJS.removeClass('no-js'); 222 } 223 if (type === 'undefined') { 224 //needs to initialize the Foundation object, or an individual plugin. 225 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__.MediaQuery._init(); 226 Foundation.reflow(this); 227 } else if (type === 'string') { 228 //an individual method to invoke on a plugin or group of plugins 229 var args = Array.prototype.slice.call(arguments, 1); //collect all the arguments, if necessary 230 var plugClass = this.data('zfPlugin'); //determine the class of plugin 231 232 if (typeof plugClass !== 'undefined' && typeof plugClass[method] !== 'undefined') { 233 //make sure both the class and method exist 234 if (this.length === 1) { 235 //if there's only one, call it directly. 236 plugClass[method].apply(plugClass, args); 237 } else { 238 this.each(function (i, el) { 239 //otherwise loop through the jQuery collection and invoke the method on each 240 plugClass[method].apply(jquery__WEBPACK_IMPORTED_MODULE_0___default()(el).data('zfPlugin'), args); 241 }); 242 } 243 } else { 244 //error for no class or no method 245 throw new ReferenceError("We're sorry, '" + method + "' is not an available method for " + (plugClass ? functionName(plugClass) : 'this element') + '.'); 246 } 247 } else { 248 //error for invalid argument type 249 throw new TypeError("We're sorry, ".concat(type, " is not a valid parameter. You must use a string representing the method you wish to invoke.")); 250 } 251 return this; 252 }; 253 jquery__WEBPACK_IMPORTED_MODULE_0___default().fn.foundation = foundation; 254 return jquery__WEBPACK_IMPORTED_MODULE_0___default(); 255 } 256 }; 257 Foundation.util = { 258 /** 259 * Function for applying a debounce effect to a function call. 260 * @function 261 * @param {Function} func - Function to be called at end of timeout. 262 * @param {Number} delay - Time in ms to delay the call of `func`. 263 * @returns function 264 */ 265 throttle: function throttle(func, delay) { 266 var timer = null; 267 return function () { 268 var context = this, 269 args = arguments; 270 if (timer === null) { 271 timer = setTimeout(function () { 272 func.apply(context, args); 273 timer = null; 274 }, delay); 275 } 276 }; 277 } 278 }; 279 window.Foundation = Foundation; 280 281 // Polyfill for requestAnimationFrame 282 (function () { 283 if (!Date.now || !window.Date.now) window.Date.now = Date.now = function () { 284 return new Date().getTime(); 285 }; 286 var vendors = ['webkit', 'moz']; 287 for (var i = 0; i < vendors.length && !window.requestAnimationFrame; ++i) { 288 var vp = vendors[i]; 289 window.requestAnimationFrame = window[vp + 'RequestAnimationFrame']; 290 window.cancelAnimationFrame = window[vp + 'CancelAnimationFrame'] || window[vp + 'CancelRequestAnimationFrame']; 291 } 292 if (/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent) || !window.requestAnimationFrame || !window.cancelAnimationFrame) { 293 var lastTime = 0; 294 window.requestAnimationFrame = function (callback) { 295 var now = Date.now(); 296 var nextTime = Math.max(lastTime + 16, now); 297 return setTimeout(function () { 298 callback(lastTime = nextTime); 299 }, nextTime - now); 300 }; 301 window.cancelAnimationFrame = clearTimeout; 302 } 303 /** 304 * Polyfill for performance.now, required by rAF 305 */ 306 if (!window.performance || !window.performance.now) { 307 window.performance = { 308 start: Date.now(), 309 now: function now() { 310 return Date.now() - this.start; 311 } 312 }; 313 } 314 })(); 315 if (!Function.prototype.bind) { 316 /* eslint-disable no-extend-native */ 317 Function.prototype.bind = function (oThis) { 318 if (typeof this !== 'function') { 319 // closest thing possible to the ECMAScript 5 320 // internal IsCallable function 321 throw new TypeError('Function.prototype.bind - what is trying to be bound is not callable'); 322 } 323 var aArgs = Array.prototype.slice.call(arguments, 1), 324 fToBind = this, 325 fNOP = function fNOP() {}, 326 fBound = function fBound() { 327 return fToBind.apply(this instanceof fNOP ? this : oThis, aArgs.concat(Array.prototype.slice.call(arguments))); 328 }; 329 if (this.prototype) { 330 // native functions don't have a prototype 331 fNOP.prototype = this.prototype; 332 } 333 fBound.prototype = new fNOP(); 334 return fBound; 335 }; 336 } 337 // Polyfill to get the name of a function in IE9 338 function functionName(fn) { 339 if (typeof Function.prototype.name === 'undefined') { 340 var funcNameRegex = /function\s([^(]{1,})\(/; 341 var results = funcNameRegex.exec(fn.toString()); 342 return results && results.length > 1 ? results[1].trim() : ""; 343 } else if (typeof fn.prototype === 'undefined') { 344 return fn.constructor.name; 345 } else { 346 return fn.prototype.constructor.name; 347 } 348 } 349 function parseValue(str) { 350 if ('true' === str) return true;else if ('false' === str) return false;else if (!isNaN(str * 1)) return parseFloat(str); 351 return str; 352 } 353 // Convert PascalCase to kebab-case 354 // Thank you: http://stackoverflow.com/a/8955580 355 function hyphenate(str) { 356 return str.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase(); 357 } 358 359 /***/ 360 }), 361 /***/"./js/foundation.core.plugin.js": ( 362 /*!**************************************!*\ 363 !*** ./js/foundation.core.plugin.js ***! 364 \**************************************/ 365 /***/ 366 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 367 __webpack_require__.r(__webpack_exports__); 368 /* harmony export */ 369 __webpack_require__.d(__webpack_exports__, { 370 /* harmony export */Plugin: function () { 371 return /* binding */Plugin; 372 } 373 /* harmony export */ 374 }); 375 /* harmony import */ 376 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core.utils */"./js/foundation.core.utils.js"); 377 function _typeof(o) { 378 "@babel/helpers - typeof"; 379 380 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 381 return typeof o; 382 } : function (o) { 383 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 384 }, _typeof(o); 385 } 386 function _classCallCheck(a, n) { 387 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 388 } 389 function _defineProperties(e, r) { 390 for (var t = 0; t < r.length; t++) { 391 var o = r[t]; 392 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 393 } 394 } 395 function _createClass(e, r, t) { 396 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 397 writable: !1 398 }), e; 399 } 400 function _toPropertyKey(t) { 401 var i = _toPrimitive(t, "string"); 402 return "symbol" == _typeof(i) ? i : i + ""; 403 } 404 function _toPrimitive(t, r) { 405 if ("object" != _typeof(t) || !t) return t; 406 var e = t[Symbol.toPrimitive]; 407 if (void 0 !== e) { 408 var i = e.call(t, r || "default"); 409 if ("object" != _typeof(i)) return i; 410 throw new TypeError("@@toPrimitive must return a primitive value."); 411 } 412 return ("string" === r ? String : Number)(t); 413 } 414 415 // Abstract class for providing lifecycle hooks. Expect plugins to define AT LEAST 416 // {function} _setup (replaces previous constructor), 417 // {function} _destroy (replaces previous destroy) 418 var Plugin = /*#__PURE__*/function () { 419 function Plugin(element, options) { 420 _classCallCheck(this, Plugin); 421 this._setup(element, options); 422 var pluginName = getPluginName(this); 423 this.uuid = (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_0__.GetYoDigits)(6, pluginName); 424 if (!this.$element.attr("data-".concat(pluginName))) { 425 this.$element.attr("data-".concat(pluginName), this.uuid); 426 } 427 if (!this.$element.data('zfPlugin')) { 428 this.$element.data('zfPlugin', this); 429 } 430 /** 431 * Fires when the plugin has initialized. 432 * @event Plugin#init 433 */ 434 this.$element.trigger("init.zf.".concat(pluginName)); 435 } 436 return _createClass(Plugin, [{ 437 key: "destroy", 438 value: function destroy() { 439 this._destroy(); 440 var pluginName = getPluginName(this); 441 this.$element.removeAttr("data-".concat(pluginName)).removeData('zfPlugin') 442 /** 443 * Fires when the plugin has been destroyed. 444 * @event Plugin#destroyed 445 */.trigger("destroyed.zf.".concat(pluginName)); 446 for (var prop in this) { 447 if (this.hasOwnProperty(prop)) { 448 this[prop] = null; //clean up script to prep for garbage collection. 449 } 450 } 451 } 452 }]); 453 }(); // Convert PascalCase to kebab-case 454 // Thank you: http://stackoverflow.com/a/8955580 455 function hyphenate(str) { 456 return str.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase(); 457 } 458 function getPluginName(obj) { 459 return hyphenate(obj.className); 460 } 461 462 /***/ 463 }), 464 /***/"./js/foundation.core.utils.js": ( 465 /*!*************************************!*\ 466 !*** ./js/foundation.core.utils.js ***! 467 \*************************************/ 468 /***/ 469 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 470 __webpack_require__.r(__webpack_exports__); 471 /* harmony export */ 472 __webpack_require__.d(__webpack_exports__, { 473 /* harmony export */GetYoDigits: function () { 474 return /* binding */GetYoDigits; 475 }, 476 /* harmony export */RegExpEscape: function () { 477 return /* binding */RegExpEscape; 478 }, 479 /* harmony export */ignoreMousedisappear: function () { 480 return /* binding */ignoreMousedisappear; 481 }, 482 /* harmony export */onLoad: function () { 483 return /* binding */onLoad; 484 }, 485 /* harmony export */rtl: function () { 486 return /* binding */rtl; 487 }, 488 /* harmony export */transitionend: function () { 489 return /* binding */transitionend; 490 } 491 /* harmony export */ 492 }); 493 /* harmony import */ 494 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 495 /* harmony import */ 496 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 497 498 // Core Foundation Utilities, utilized in a number of places. 499 500 /** 501 * Returns a boolean for RTL support 502 */ 503 function rtl() { 504 return jquery__WEBPACK_IMPORTED_MODULE_0___default()('html').attr('dir') === 'rtl'; 505 } 506 507 /** 508 * returns a random base-36 uid with namespacing 509 * @function 510 * @param {Number} length - number of random base-36 digits desired. Increase for more random strings. 511 * @param {String} namespace - name of plugin to be incorporated in uid, optional. 512 * @default {String} '' - if no plugin name is provided, nothing is appended to the uid. 513 * @returns {String} - unique id 514 */ 515 function GetYoDigits() { 516 var length = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 6; 517 var namespace = arguments.length > 1 ? arguments[1] : undefined; 518 var str = ''; 519 var chars = '0123456789abcdefghijklmnopqrstuvwxyz'; 520 var charsLength = chars.length; 521 for (var i = 0; i < length; i++) { 522 str += chars[Math.floor(Math.random() * charsLength)]; 523 } 524 return namespace ? "".concat(str, "-").concat(namespace) : str; 525 } 526 527 /** 528 * Escape a string so it can be used as a regexp pattern 529 * @function 530 * @see https://stackoverflow.com/a/9310752/4317384 531 * 532 * @param {String} str - string to escape. 533 * @returns {String} - escaped string 534 */ 535 function RegExpEscape(str) { 536 return str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&'); 537 } 538 function transitionend($elem) { 539 var transitions = { 540 'transition': 'transitionend', 541 'WebkitTransition': 'webkitTransitionEnd', 542 'MozTransition': 'transitionend', 543 'OTransition': 'otransitionend' 544 }; 545 var elem = document.createElement('div'), 546 end; 547 for (var transition in transitions) { 548 if (typeof elem.style[transition] !== 'undefined') { 549 end = transitions[transition]; 550 } 551 } 552 if (end) { 553 return end; 554 } else { 555 setTimeout(function () { 556 $elem.triggerHandler('transitionend', [$elem]); 557 }, 1); 558 return 'transitionend'; 559 } 560 } 561 562 /** 563 * Return an event type to listen for window load. 564 * 565 * If `$elem` is passed, an event will be triggered on `$elem`. If window is already loaded, the event will still be triggered. 566 * If `handler` is passed, attach it to the event on `$elem`. 567 * Calling `onLoad` without handler allows you to get the event type that will be triggered before attaching the handler by yourself. 568 * @function 569 * 570 * @param {Object} [] $elem - jQuery element on which the event will be triggered if passed. 571 * @param {Function} [] handler - function to attach to the event. 572 * @returns {String} - event type that should or will be triggered. 573 */ 574 function onLoad($elem, handler) { 575 var didLoad = document.readyState === 'complete'; 576 var eventType = (didLoad ? '_didLoad' : 'load') + '.zf.util.onLoad'; 577 var cb = function cb() { 578 return $elem.triggerHandler(eventType); 579 }; 580 if ($elem) { 581 if (handler) $elem.one(eventType, handler); 582 if (didLoad) setTimeout(cb);else jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).one('load', cb); 583 } 584 return eventType; 585 } 586 587 /** 588 * Retuns an handler for the `mouseleave` that ignore disappeared mouses. 589 * 590 * If the mouse "disappeared" from the document (like when going on a browser UI element, See https://git.io/zf-11410), 591 * the event is ignored. 592 * - If the `ignoreLeaveWindow` is `true`, the event is ignored when the user actually left the window 593 * (like by switching to an other window with [Alt]+[Tab]). 594 * - If the `ignoreReappear` is `true`, the event will be ignored when the mouse will reappear later on the document 595 * outside of the element it left. 596 * 597 * @function 598 * 599 * @param {Function} [] handler - handler for the filtered `mouseleave` event to watch. 600 * @param {Object} [] options - object of options: 601 * - {Boolean}
601 [false] ignoreLeaveWindow - also ignore when the user switched windows. 602 * - {Boolean} [false] ignoreReappear - also ignore when the mouse reappeared outside of the element it left. 603 * @returns {Function} - filtered handler to use to listen on the `mouseleave` event. 604 */ 605 function ignoreMousedisappear(handler) { 606 var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, 607 _ref$ignoreLeaveWindo = _ref.ignoreLeaveWindow, 608 ignoreLeaveWindow = _ref$ignoreLeaveWindo === void 0 ? false : _ref$ignoreLeaveWindo, 609 _ref$ignoreReappear = _ref.ignoreReappear, 610 ignoreReappear = _ref$ignoreReappear === void 0 ? false : _ref$ignoreReappear; 611 return function leaveEventHandler(eLeave) { 612 for (var _len = arguments.length, rest = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { 613 rest[_key - 1] = arguments[_key]; 614 } 615 var callback = handler.bind.apply(handler, [this, eLeave].concat(rest)); 616 617 // The mouse left: call the given callback if the mouse entered elsewhere 618 if (eLeave.relatedTarget !== null) { 619 return callback(); 620 } 621 622 // Otherwise, check if the mouse actually left the window. 623 // In firefox if the user switched between windows, the window sill have the focus by the time 624 // the event is triggered. We have to debounce the event to test this case. 625 setTimeout(function leaveEventDebouncer() { 626 if (!ignoreLeaveWindow && document.hasFocus && !document.hasFocus()) { 627 return callback(); 628 } 629 630 // Otherwise, wait for the mouse to reeapear outside of the element, 631 if (!ignoreReappear) { 632 jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).one('mouseenter', function reenterEventHandler(eReenter) { 633 if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()(eLeave.currentTarget).has(eReenter.target).length) { 634 // Fill where the mouse finally entered. 635 eLeave.relatedTarget = eReenter.target; 636 callback(); 637 } 638 }); 639 } 640 }, 0); 641 }; 642 } 643 644 /***/ 645 }), 646
vendor: 7,062 bytes, lines 646-808
646/***/"./js/foundation.util.mediaQuery.js": ( 647 /*!******************************************!*\ 648 !*** ./js/foundation.util.mediaQuery.js ***! 649 \******************************************/ 650 /***/ 651 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 652 __webpack_require__.r(__webpack_exports__); 653 /* harmony export */ 654 __webpack_require__.d(__webpack_exports__, { 655 /* harmony export */MediaQuery: function () { 656 return /* binding */MediaQuery; 657 } 658 /* harmony export */ 659 }); 660 /* harmony import */ 661 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 662 /* harmony import */ 663 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 664 function _typeof(o) { 665 "@babel/helpers - typeof"; 666 667 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 668 return typeof o; 669 } : function (o) { 670 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 671 }, _typeof(o); 672 } 673 function _slicedToArray(r, e) { 674 return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); 675 } 676 function _nonIterableRest() { 677 throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); 678 } 679 function _unsupportedIterableToArray(r, a) { 680 if (r) { 681 if ("string" == typeof r) return _arrayLikeToArray(r, a); 682 var t = {}.toString.call(r).slice(8, -1); 683 return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; 684 } 685 } 686 function _arrayLikeToArray(r, a) { 687 (null == a || a > r.length) && (a = r.length); 688 for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; 689 return n; 690 } 691 function _iterableToArrayLimit(r, l) { 692 var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; 693 if (null != t) { 694 var e, 695 n, 696 i, 697 u, 698 a = [], 699 f = !0, 700 o = !1; 701 try { 702 if (i = (t = t.call(r)).next, 0 === l) { 703 if (Object(t) !== t) return; 704 f = !1; 705 } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); 706 } catch (r) { 707 o = !0, n = r; 708 } finally { 709 try { 710 if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; 711 } finally { 712 if (o) throw n; 713 } 714 } 715 return a; 716 } 717 } 718 function _arrayWithHoles(r) { 719 if (Array.isArray(r)) return r; 720 } 721 722 // Default set of media queries 723 // const defaultQueries = { 724 // 'default' : 'only screen', 725 // landscape : 'only screen and (orientation: landscape)', 726 // portrait : 'only screen and (orientation: portrait)', 727 // retina : 'only screen and (-webkit-min-device-pixel-ratio: 2),' + 728 // 'only screen and (min--moz-device-pixel-ratio: 2),' + 729 // 'only screen and (-o-min-device-pixel-ratio: 2/1),' + 730 // 'only screen and (min-device-pixel-ratio: 2),' + 731 // 'only screen and (min-resolution: 192dpi),' + 732 // 'only screen and (min-resolution: 2dppx)' 733 // }; 734 735 // matchMedia() polyfill - Test a CSS media type/query in JS. 736 // Authors & copyright © 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. MIT license 737 /* eslint-disable */ 738 window.matchMedia || (window.matchMedia = function () { 739 "use strict"; 740 741 // For browsers that support matchMedium api such as IE 9 and webkit 742 var styleMedia = window.styleMedia || window.media; 743 744 // For those that don't support matchMedium 745 if (!styleMedia) { 746 var style = document.createElement('style'), 747 script = document.getElementsByTagName('script')[0], 748 info = null; 749 style.type = 'text/css'; 750 style.id = 'matchmediajs-test'; 751 if (!script) { 752 document.head.appendChild(style); 753 } else { 754 script.parentNode.insertBefore(style, script); 755 } 756 757 // 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers 758 info = 'getComputedStyle' in window && window.getComputedStyle(style, null) || style.currentStyle; 759 styleMedia = { 760 matchMedium: function matchMedium(media) { 761 var text = '@media ' + media + '{ #matchmediajs-test { width: 1px; } }'; 762 763 // 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers 764 if (style.styleSheet) { 765 style.styleSheet.cssText = text; 766 } else { 767 style.textContent = text; 768 } 769 770 // Test if media query is true or false 771 return info.width === '1px'; 772 } 773 }; 774 } 775 return function (media) { 776 return { 777 matches: styleMedia.matchMedium(media || 'all'), 778 media: media || 'all' 779 }; 780 }; 781 }()); 782 /* eslint-enable */ 783 784 var MediaQuery = { 785 queries: [], 786 current: '', 787 /** 788 * Initializes the media query helper, by extracting the breakpoint list from the CSS and activating the breakpoint watcher. 789 * @function 790 * @private 791 */ 792 _init: function _init() { 793 // make sure the initialization is only done once when calling _init() several times 794 if (this.isInitialized === true) { 795 return this; 796 } else { 797 this.isInitialized = true; 798 } 799 var self = this; 800 var $meta = jquery__WEBPACK_IMPORTED_MODULE_0___default()('meta.foundation-mq'); 801 if (!$meta.length) { 802 jquery__WEBPACK_IMPORTED_MODULE_0___default()('<meta class="foundation-mq" name="foundation-mq" content>').appendTo(document.head); 803 } 804 var extractedStyles = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.foundation-mq').css('font-family'); 805 var namedQueries; 806 namedQueries = parseStyleToObject(extractedStyles); 807 self.queries = []; // reset 808
vendor: 5,468 bytes, lines 809-937
809 for (var key in namedQueries) { 810 if (namedQueries.hasOwnProperty(key)) { 811 self.queries.push({ 812 name: key, 813 value: "only screen and (min-width: ".concat(namedQueries[key], ")") 814 }); 815 } 816 } 817 this.current = this._getCurrentSize(); 818 this._watcher(); 819 }, 820 /** 821 * Reinitializes the media query helper. 822 * Useful if your CSS breakpoint configuration has just been loaded or has changed since the initialization. 823 * @function 824 * @private 825 */ 826 _reInit: function _reInit() { 827 this.isInitialized = false; 828 this._init(); 829 }, 830 /** 831 * Checks if the screen is at least as wide as a breakpoint. 832 * @function 833 * @param {String} size - Name of the breakpoint to check. 834 * @returns {Boolean} `true` if the breakpoint matches, `false` if it's smaller. 835 */ 836 atLeast: function atLeast(size) { 837 var query = this.get(size); 838 if (query) { 839 return window.matchMedia(query).matches; 840 } 841 return false; 842 }, 843 /** 844 * Checks if the screen is within the given breakpoint. 845 * If smaller than the breakpoint of larger than its upper limit it returns false. 846 * @function 847 * @param {String} size - Name of the breakpoint to check. 848 * @returns {Boolean} `true` if the breakpoint matches, `false` otherwise. 849 */ 850 only: function only(size) { 851 return size === this._getCurrentSize(); 852 }, 853 /** 854 * Checks if the screen is within a breakpoint or smaller. 855 * @function 856 * @param {String} size - Name of the breakpoint to check. 857 * @returns {Boolean} `true` if the breakpoint matches, `false` if it's larger. 858 */ 859 upTo: function upTo(size) { 860 var nextSize = this.next(size); 861 862 // If the next breakpoint does not match, the screen is smaller than 863 // the upper limit of this breakpoint. 864 if (nextSize) { 865 return !this.atLeast(nextSize); 866 } 867 868 // If there is no next breakpoint, the "size" breakpoint does not have 869 // an upper limit and the screen will always be within it or smaller. 870 return true; 871 }, 872 /** 873 * Checks if the screen matches to a breakpoint. 874 * @function 875 * @param {String} size - Name of the breakpoint to check, either 'small only' or 'small'. Omitting 'only' falls back to using atLeast() method. 876 * @returns {Boolean} `true` if the breakpoint matches, `false` if it does not. 877 */ 878 is: function is(size) { 879 var parts = size.trim().split(' ').filter(function (p) { 880 return !!p.length; 881 }); 882 var _parts = _slicedToArray(parts, 2), 883 bpSize = _parts[0], 884 _parts$ = _parts[1], 885 bpModifier = _parts$ === void 0 ? '' : _parts$; 886 887 // Only the breakpont 888 if (bpModifier === 'only') { 889 return this.only(bpSize); 890 } 891 // At least the breakpoint (included) 892 if (!bpModifier || bpModifier === 'up') { 893 return this.atLeast(bpSize); 894 } 895 // Up to the breakpoint (included) 896 if (bpModifier === 'down') { 897 return this.upTo(bpSize); 898 } 899 throw new Error("\n Invalid breakpoint passed to MediaQuery.is().\n Expected a breakpoint name formatted like \"<size> <modifier>\", got \"".concat(size, "\".\n ")); 900 }, 901 /** 902 * Gets the media query of a breakpoint. 903 * @function 904 * @param {String} size - Name of the breakpoint to get. 905 * @returns {String|null} - The media query of the breakpoint, or `null` if the breakpoint doesn't exist. 906 */ 907 get: function get(size) { 908 for (var i in this.queries) { 909 if (this.queries.hasOwnProperty(i)) { 910 var query = this.queries[i]; 911 if (size === query.name) return query.value; 912 } 913 } 914 return null; 915 }, 916 /** 917 * Get the breakpoint following the given breakpoint. 918 * @function 919 * @param {String} size - Name of the breakpoint. 920 * @returns {String|null} - The name of the following breakpoint, or `null` if the passed breakpoint was the last one. 921 */ 922 next: function next(size) { 923 var _this = this; 924 var queryIndex = this.queries.findIndex(function (q) { 925 return _this._getQueryName(q) === size; 926 }); 927 if (queryIndex === -1) { 928 throw new Error("\n Unknown breakpoint \"".concat(size, "\" passed to MediaQuery.next().\n Ensure it is present in your Sass \"$breakpoints\" setting.\n ")); 929 } 930 var nextQuery = this.queries[queryIndex + 1]; 931 return nextQuery ? nextQuery.name : null; 932 }, 933 /** 934 * Returns the name of the breakpoint related to the given value. 935 * @function 936 * @private 937 * @param {String|Object}
vendor: 5,080 bytes, lines 937-1068
937 value - Breakpoint name or query object. 938 * @returns {String} Name of the breakpoint. 939 */ 940 _getQueryName: function _getQueryName(value) { 941 if (typeof value === 'string') return value; 942 if (_typeof(value) === 'object') return value.name; 943 throw new TypeError("\n Invalid value passed to MediaQuery._getQueryName().\n Expected a breakpoint name (String) or a breakpoint query (Object), got \"".concat(value, "\" (").concat(_typeof(value), ")\n ")); 944 }, 945 /** 946 * Gets the current breakpoint name by testing every breakpoint and returning the last one to match (the biggest one). 947 * @function 948 * @private 949 * @returns {String} Name of the current breakpoint. 950 */ 951 _getCurrentSize: function _getCurrentSize() { 952 var matched; 953 for (var i = 0; i < this.queries.length; i++) { 954 var query = this.queries[i]; 955 if (window.matchMedia(query.value).matches) { 956 matched = query; 957 } 958 } 959 return matched && this._getQueryName(matched); 960 }, 961 /** 962 * Activates the breakpoint watcher, which fires an event on the window whenever the breakpoint changes. 963 * @function 964 * @private 965 */ 966 _watcher: function _watcher() { 967 var _this2 = this; 968 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('resize.zf.trigger', function () { 969 var newSize = _this2._getCurrentSize(), 970 currentSize = _this2.current; 971 if (newSize !== currentSize) { 972 // Change the current media query 973 _this2.current = newSize; 974 975 // Broadcast the media query change on the window 976 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).trigger('changed.zf.mediaquery', [newSize, currentSize]); 977 } 978 }); 979 } 980 }; 981 982 // Thank you: https://github.com/sindresorhus/query-string 983 function parseStyleToObject(str) { 984 var styleObject = {}; 985 if (typeof str !== 'string') { 986 return styleObject; 987 } 988 str = str.trim().slice(1, -1); // browsers re-quote string style values 989 990 if (!str) { 991 return styleObject; 992 } 993 styleObject = str.split('&').reduce(function (ret, param) { 994 var parts = param.replace(/\+/g, ' ').split('='); 995 var key = parts[0]; 996 var val = parts[1]; 997 key = decodeURIComponent(key); 998 999 // missing `=` should be `null`: 1000 // http://w3.org/TR/2012/WD-url-20120524/#collect-url-parameters 1001 val = typeof val === 'undefined' ? null : decodeURIComponent(val); 1002 if (!ret.hasOwnProperty(key)) { 1003 ret[key] = val; 1004 } else if (Array.isArray(ret[key])) { 1005 ret[key].push(val); 1006 } else { 1007 ret[key] = [ret[key], val]; 1008 } 1009 return ret; 1010 }, {}); 1011 return styleObject; 1012 } 1013 1014 /***/ 1015 }), 1016 /***/"jquery": ( 1017 /*!********************************************************************************************!*\ 1018 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 1019 \********************************************************************************************/ 1020 /***/ 1021 function (module) { 1022 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 1023 1024 /***/ 1025 }) 1026 1027 /******/ 1028 }; 1029 /************************************************************************/ 1030 /******/ // The module cache 1031 /******/ 1032 var __webpack_module_cache__ = {}; 1033 /******/ 1034 /******/ // The require function 1035 /******/ 1036 function __webpack_require__(moduleId) { 1037 /******/ // Check if module is in cache 1038 /******/var cachedModule = __webpack_module_cache__[moduleId]; 1039 /******/ 1040 if (cachedModule !== undefined) { 1041 /******/return cachedModule.exports; 1042 /******/ 1043 } 1044 /******/ // Create a new module (and put it into the cache) 1045 /******/ 1046 var module = __webpack_module_cache__[moduleId] = { 1047 /******/ // no module.id needed 1048 /******/ // no module.loaded needed 1049 /******/exports: {} 1050 /******/ 1051 }; 1052 /******/ 1053 /******/ // Execute the module function 1054 /******/ 1055 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 1056 /******/ 1057 /******/ // Return the exports of the module 1058 /******/ 1059 return module.exports; 1060 /******/ 1061 } 1062 /******/ 1063 /************************************************************************/ 1064 /******/ /* webpack/runtime/compat get default export */ 1065 /******/ 1066 !function () { 1067 /******/ // getDefaultExport function for compatibility with non-harmony modules 1068 /******/__webpack_require__.n = function (module) {
vendor: 7,156 bytes, lines 1069-1219
1069 /******/var getter = module && module.__esModule ? /******/function () { 1070 return module['default']; 1071 } : /******/function () { 1072 return module; 1073 }; 1074 /******/ 1075 __webpack_require__.d(getter, { 1076 a: getter 1077 }); 1078 /******/ 1079 return getter; 1080 /******/ 1081 }; 1082 /******/ 1083 }(); 1084 /******/ 1085 /******/ /* webpack/runtime/define property getters */ 1086 /******/ 1087 !function () { 1088 /******/ // define getter functions for harmony exports 1089 /******/__webpack_require__.d = function (exports, definition) { 1090 /******/for (var key in definition) { 1091 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 1092 /******/Object.defineProperty(exports, key, { 1093 enumerable: true, 1094 get: definition[key] 1095 }); 1096 /******/ 1097 } 1098 /******/ 1099 } 1100 /******/ 1101 }; 1102 /******/ 1103 }(); 1104 /******/ 1105 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 1106 /******/ 1107 !function () { 1108 /******/__webpack_require__.o = function (obj, prop) { 1109 return Object.prototype.hasOwnProperty.call(obj, prop); 1110 }; 1111 /******/ 1112 }(); 1113 /******/ 1114 /******/ /* webpack/runtime/make namespace object */ 1115 /******/ 1116 !function () { 1117 /******/ // define __esModule on exports 1118 /******/__webpack_require__.r = function (exports) { 1119 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 1120 /******/Object.defineProperty(exports, Symbol.toStringTag, { 1121 value: 'Module' 1122 }); 1123 /******/ 1124 } 1125 /******/ 1126 Object.defineProperty(exports, '__esModule', { 1127 value: true 1128 }); 1129 /******/ 1130 }; 1131 /******/ 1132 }(); 1133 /******/ 1134 /************************************************************************/ 1135 var __webpack_exports__ = {}; 1136 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 1137 !function () { 1138 /*!***********************************************!*\ 1139 !*** ./js/entries/plugins/foundation.core.js ***! 1140 \***********************************************/ 1141 __webpack_require__.r(__webpack_exports__); 1142 /* harmony export */ 1143 __webpack_require__.d(__webpack_exports__, { 1144 /* harmony export */Foundation: function () { 1145 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation; 1146 }, 1147 /* harmony export */GetYoDigits: function () { 1148 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.GetYoDigits; 1149 }, 1150 /* harmony export */Plugin: function () { 1151 return /* reexport safe */_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__.Plugin; 1152 }, 1153 /* harmony export */RegExpEscape: function () { 1154 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.RegExpEscape; 1155 }, 1156 /* harmony export */ignoreMousedisappear: function () { 1157 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.ignoreMousedisappear; 1158 }, 1159 /* harmony export */onLoad: function () { 1160 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.onLoad; 1161 }, 1162 /* harmony export */rtl: function () { 1163 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.rtl; 1164 }, 1165 /* harmony export */transitionend: function () { 1166 return /* reexport safe */_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.transitionend; 1167 } 1168 /* harmony export */ 1169 }); 1170 /* harmony import */ 1171 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 1172 /* harmony import */ 1173 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 1174 /* harmony import */ 1175 var _foundation_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.core */"./js/foundation.core.js"); 1176 /* harmony import */ 1177 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../foundation.core.plugin */"./js/foundation.core.plugin.js"); 1178 /* harmony import */ 1179 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../foundation.core.utils */"./js/foundation.core.utils.js"); 1180 // --- Foundation Core API --- 1181 // Initialize Foundation and add some utilities to its public API for backward compatibility. 1182 // Please note that every utility do not have to be added to the core API. 1183 1184 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.addToJquery(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 1185 1186 // Every plugin depends on plugin now, we can include that on the core for the 1187 // script inclusion path. 1188 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.Plugin = _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__.Plugin; 1189 1190 // These are now separated out, but historically were a part of this module, 1191 // and since this is here for backwards compatibility we include them in 1192 // this entry. 1193 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.rtl = _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.rtl; 1194 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.GetYoDigits = _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.GetYoDigits; 1195 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.transitionend = _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.transitionend; 1196 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.RegExpEscape = _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.RegExpEscape; 1197 _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation.onLoad = _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.onLoad; 1198 window.Foundation = _foundation_core__WEBPACK_IMPORTED_MODULE_1__.Foundation; 1199 1200 // --- Foundation Core exports --- 1201 // Export "Plugin" and all core utilities, since the `foundation.core` entry plays the role of 1202 // all core source files. 1203 }(); 1204 /******/ 1205 return __webpack_exports__; 1206 /******/ 1207 }(); 1208}); 1209(function webpackUniversalModuleDefinition(root, factory) { 1210 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"));else if (typeof define === 'function' && define.amd) define(["./foundation.core"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.box"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"]); 1211})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__) { 1212 return /******/function () { 1213 // webpackBootstrap 1214 /******/ 1215 "use strict"; 1216 1217 /******/ 1218 var __webpack_modules__ = { 1219
vendor: 5,867 bytes, lines 1219-1342
1219/***/"./js/foundation.util.box.js": ( 1220 /*!***********************************!*\ 1221 !*** ./js/foundation.util.box.js ***! 1222 \***********************************/ 1223 /***/ 1224 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1225 __webpack_require__.r(__webpack_exports__); 1226 /* harmony export */ 1227 __webpack_require__.d(__webpack_exports__, { 1228 /* harmony export */Box: function () { 1229 return /* binding */Box; 1230 } 1231 /* harmony export */ 1232 }); 1233 var Box = { 1234 ImNotTouchingYou: ImNotTouchingYou, 1235 OverlapArea: OverlapArea, 1236 GetDimensions: GetDimensions, 1237 GetExplicitOffsets: GetExplicitOffsets 1238 }; 1239 1240 /** 1241 * Compares the dimensions of an element to a container and determines collision events with container. 1242 * @function 1243 * @param {jQuery} element - jQuery object to test for collisions. 1244 * @param {jQuery} parent - jQuery object to use as bounding container. 1245 * @param {Boolean} lrOnly - set to true to check left and right values only. 1246 * @param {Boolean} tbOnly - set to true to check top and bottom values only. 1247 * @default if no parent object passed, detects collisions with `window`. 1248 * @returns {Boolean} - true if collision free, false if a collision in any direction. 1249 */ 1250 function ImNotTouchingYou(element, parent, lrOnly, tbOnly, ignoreBottom) { 1251 return OverlapArea(element, parent, lrOnly, tbOnly, ignoreBottom) === 0; 1252 } 1253 function OverlapArea(element, parent, lrOnly, tbOnly, ignoreBottom) { 1254 var eleDims = GetDimensions(element), 1255 topOver, 1256 bottomOver, 1257 leftOver, 1258 rightOver; 1259 if (parent) { 1260 var parDims = GetDimensions(parent); 1261 bottomOver = parDims.height + parDims.offset.top - (eleDims.offset.top + eleDims.height); 1262 topOver = eleDims.offset.top - parDims.offset.top; 1263 leftOver = eleDims.offset.left - parDims.offset.left; 1264 rightOver = parDims.width + parDims.offset.left - (eleDims.offset.left + eleDims.width); 1265 } else { 1266 bottomOver = eleDims.windowDims.height + eleDims.windowDims.offset.top - (eleDims.offset.top + eleDims.height); 1267 topOver = eleDims.offset.top - eleDims.windowDims.offset.top; 1268 leftOver = eleDims.offset.left - eleDims.windowDims.offset.left; 1269 rightOver = eleDims.windowDims.width - (eleDims.offset.left + eleDims.width); 1270 } 1271 bottomOver = ignoreBottom ? 0 : Math.min(bottomOver, 0); 1272 topOver = Math.min(topOver, 0); 1273 leftOver = Math.min(leftOver, 0); 1274 rightOver = Math.min(rightOver, 0); 1275 if (lrOnly) { 1276 return leftOver + rightOver; 1277 } 1278 if (tbOnly) { 1279 return topOver + bottomOver; 1280 } 1281 1282 // use sum of squares b/c we care about overlap area. 1283 return Math.sqrt(topOver * topOver + bottomOver * bottomOver + leftOver * leftOver + rightOver * rightOver); 1284 } 1285 1286 /** 1287 * Uses native methods to return an object of dimension values. 1288 * @function 1289 * @param {jQuery || HTML} element - jQuery object or DOM element for which to get the dimensions. Can be any element other that document or window. 1290 * @returns {Object} - nested object of integer pixel values 1291 * TODO - if element is window, return only those values. 1292 */ 1293 function GetDimensions(elem) { 1294 elem = elem.length ? elem[0] : elem; 1295 if (elem === window || elem === document) { 1296 throw new Error("I'm sorry, Dave. I'm afraid I can't do that."); 1297 } 1298 var rect = elem.getBoundingClientRect(), 1299 parRect = elem.parentNode.getBoundingClientRect(), 1300 winRect = document.body.getBoundingClientRect(), 1301 winY = window.pageYOffset, 1302 winX = window.pageXOffset; 1303 return { 1304 width: rect.width, 1305 height: rect.height, 1306 offset: { 1307 top: rect.top + winY, 1308 left: rect.left + winX 1309 }, 1310 parentDims: { 1311 width: parRect.width, 1312 height: parRect.height, 1313 offset: { 1314 top: parRect.top + winY, 1315 left: parRect.left + winX 1316 } 1317 }, 1318 windowDims: { 1319 width: winRect.width, 1320 height: winRect.height, 1321 offset: { 1322 top: winY, 1323 left: winX 1324 } 1325 } 1326 }; 1327 } 1328 1329 /** 1330 * Returns an object of top and left integer pixel values for dynamically rendered elements, 1331 * such as: Tooltip, Reveal, and Dropdown. Maintained for backwards compatibility, and where 1332 * you don't know alignment, but generally from 1333 * 6.4 forward you should use GetExplicitOffsets, as GetOffsets conflates position and alignment. 1334 * @function 1335 * @param {jQuery} element - jQuery object for the element being positioned. 1336 * @param {jQuery} anchor - jQuery object for the element's anchor point. 1337 * @param {String} position - a string relating to the desired position of the element, relative to it's anchor 1338 * @param {Number} vOffset - integer pixel value of desired vertical separation between anchor and element. 1339 * @param {Number} hOffset - integer pixel value of desired horizontal separation between anchor and element. 1340 * @param {Boolean} isOverflow - if a collision event is detected, sets to true to default the element to full width - any desired offset. 1341 * TODO alter/rewrite to work with `em` values as well/instead of pixels 1342 */
vendor: 4,435 bytes, lines 1343-1456
1343 function GetExplicitOffsets(element, anchor, position, alignment, vOffset, hOffset, isOverflow) { 1344 var $eleDims = GetDimensions(element), 1345 $anchorDims = anchor ? GetDimensions(anchor) : null; 1346 var topVal, leftVal; 1347 if ($anchorDims !== null) { 1348 // set position related attribute 1349 switch (position) { 1350 case 'top': 1351 topVal = $anchorDims.offset.top - ($eleDims.height + vOffset); 1352 break; 1353 case 'bottom': 1354 topVal = $anchorDims.offset.top + $anchorDims.height + vOffset; 1355 break; 1356 case 'left': 1357 leftVal = $anchorDims.offset.left - ($eleDims.width + hOffset); 1358 break; 1359 case 'right': 1360 leftVal = $anchorDims.offset.left + $anchorDims.width + hOffset; 1361 break; 1362 } 1363 1364 // set alignment related attribute 1365 switch (position) { 1366 case 'top': 1367 case 'bottom': 1368 switch (alignment) { 1369 case 'left': 1370 leftVal = $anchorDims.offset.left + hOffset; 1371 break; 1372 case 'right': 1373 leftVal = $anchorDims.offset.left - $eleDims.width + $anchorDims.width - hOffset; 1374 break; 1375 case 'center': 1376 leftVal = isOverflow ? hOffset : $anchorDims.offset.left + $anchorDims.width / 2 - $eleDims.width / 2 + hOffset; 1377 break; 1378 } 1379 break; 1380 case 'right': 1381 case 'left': 1382 switch (alignment) { 1383 case 'bottom': 1384 topVal = $anchorDims.offset.top - vOffset + $anchorDims.height - $eleDims.height; 1385 break; 1386 case 'top': 1387 topVal = $anchorDims.offset.top + vOffset; 1388 break; 1389 case 'center': 1390 topVal = $anchorDims.offset.top + vOffset + $anchorDims.height / 2 - $eleDims.height / 2; 1391 break; 1392 } 1393 break; 1394 } 1395 } 1396 return { 1397 top: topVal, 1398 left: leftVal 1399 }; 1400 } 1401 1402 /***/ 1403 }), 1404 /***/"./foundation.core": ( 1405 /*!****************************************************************************************************************************************************************!*\ 1406 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 1407 \****************************************************************************************************************************************************************/ 1408 /***/ 1409 function (module) { 1410 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 1411 1412 /***/ 1413 }) 1414 1415 /******/ 1416 }; 1417 /************************************************************************/ 1418 /******/ // The module cache 1419 /******/ 1420 var __webpack_module_cache__ = {}; 1421 /******/ 1422 /******/ // The require function 1423 /******/ 1424 function __webpack_require__(moduleId) { 1425 /******/ // Check if module is in cache 1426 /******/var cachedModule = __webpack_module_cache__[moduleId]; 1427 /******/ 1428 if (cachedModule !== undefined) { 1429 /******/return cachedModule.exports; 1430 /******/ 1431 } 1432 /******/ // Create a new module (and put it into the cache) 1433 /******/ 1434 var module = __webpack_module_cache__[moduleId] = { 1435 /******/ // no module.id needed 1436 /******/ // no module.loaded needed 1437 /******/exports: {} 1438 /******/ 1439 }; 1440 /******/ 1441 /******/ // Execute the module function 1442 /******/ 1443 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 1444 /******/ 1445 /******/ // Return the exports of the module 1446 /******/ 1447 return module.exports; 1448 /******/ 1449 } 1450 /******/ 1451 /************************************************************************/ 1452 /******/ /* webpack/runtime/compat get default export */ 1453 /******/ 1454 !function () { 1455 /******/ // getDefaultExport function for compatibility with non-harmony modules 1456 /******/__webpack_require__.n = function (module) {
vendor: 13,819 bytes, lines 1457-1788
1457 /******/var getter = module && module.__esModule ? /******/function () { 1458 return module['default']; 1459 } : /******/function () { 1460 return module; 1461 }; 1462 /******/ 1463 __webpack_require__.d(getter, { 1464 a: getter 1465 }); 1466 /******/ 1467 return getter; 1468 /******/ 1469 }; 1470 /******/ 1471 }(); 1472 /******/ 1473 /******/ /* webpack/runtime/define property getters */ 1474 /******/ 1475 !function () { 1476 /******/ // define getter functions for harmony exports 1477 /******/__webpack_require__.d = function (exports, definition) { 1478 /******/for (var key in definition) { 1479 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 1480 /******/Object.defineProperty(exports, key, { 1481 enumerable: true, 1482 get: definition[key] 1483 }); 1484 /******/ 1485 } 1486 /******/ 1487 } 1488 /******/ 1489 }; 1490 /******/ 1491 }(); 1492 /******/ 1493 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 1494 /******/ 1495 !function () { 1496 /******/__webpack_require__.o = function (obj, prop) { 1497 return Object.prototype.hasOwnProperty.call(obj, prop); 1498 }; 1499 /******/ 1500 }(); 1501 /******/ 1502 /******/ /* webpack/runtime/make namespace object */ 1503 /******/ 1504 !function () { 1505 /******/ // define __esModule on exports 1506 /******/__webpack_require__.r = function (exports) { 1507 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 1508 /******/Object.defineProperty(exports, Symbol.toStringTag, { 1509 value: 'Module' 1510 }); 1511 /******/ 1512 } 1513 /******/ 1514 Object.defineProperty(exports, '__esModule', { 1515 value: true 1516 }); 1517 /******/ 1518 }; 1519 /******/ 1520 }(); 1521 /******/ 1522 /************************************************************************/ 1523 var __webpack_exports__ = {}; 1524 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 1525 !function () { 1526 /*!***************************************************!*\ 1527 !*** ./js/entries/plugins/foundation.util.box.js ***! 1528 \***************************************************/ 1529 __webpack_require__.r(__webpack_exports__); 1530 /* harmony export */ 1531 __webpack_require__.d(__webpack_exports__, { 1532 /* harmony export */Box: function () { 1533 return /* reexport safe */_foundation_util_box__WEBPACK_IMPORTED_MODULE_1__.Box; 1534 }, 1535 /* harmony export */Foundation: function () { 1536 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 1537 } 1538 /* harmony export */ 1539 }); 1540 /* harmony import */ 1541 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 1542 /* harmony import */ 1543 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 1544 /* harmony import */ 1545 var _foundation_util_box__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.box */"./js/foundation.util.box.js"); 1546 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Box = _foundation_util_box__WEBPACK_IMPORTED_MODULE_1__.Box; 1547 }(); 1548 /******/ 1549 return __webpack_exports__; 1550 /******/ 1551 }(); 1552}); 1553(function webpackUniversalModuleDefinition(root, factory) { 1554 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.imageLoader"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 1555})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 1556 return /******/function () { 1557 // webpackBootstrap 1558 /******/ 1559 "use strict"; 1560 1561 /******/ 1562 var __webpack_modules__ = { 1563 /***/"./js/foundation.util.imageLoader.js": ( 1564 /*!*******************************************!*\ 1565 !*** ./js/foundation.util.imageLoader.js ***! 1566 \*******************************************/ 1567 /***/ 1568 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1569 __webpack_require__.r(__webpack_exports__); 1570 /* harmony export */ 1571 __webpack_require__.d(__webpack_exports__, { 1572 /* harmony export */onImagesLoaded: function () { 1573 return /* binding */onImagesLoaded; 1574 } 1575 /* harmony export */ 1576 }); 1577 /* harmony import */ 1578 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 1579 /* harmony import */ 1580 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 1581 1582 /** 1583 * Runs a callback function when images are fully loaded. 1584 * @param {Object} images - Image(s) to check if loaded. 1585 * @param {Func} callback - Function to execute when image is fully loaded. 1586 */ 1587 function onImagesLoaded(images, callback) { 1588 var unloaded = images.length; 1589 if (unloaded === 0) { 1590 callback(); 1591 } 1592 images.each(function () { 1593 // Check if image is loaded 1594 if (this.complete && typeof this.naturalWidth !== 'undefined') { 1595 singleImageLoaded(); 1596 } else { 1597 // If the above check failed, simulate loading on detached element. 1598 var image = new Image(); 1599 // Still count image as loaded if it finalizes with an error. 1600 var events = "load.zf.images error.zf.images"; 1601 jquery__WEBPACK_IMPORTED_MODULE_0___default()(image).one(events, function me() { 1602 // Unbind the event listeners. We're using 'one' but only one of the two events will have fired. 1603 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).off(events, me); 1604 singleImageLoaded(); 1605 }); 1606 image.src = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('src'); 1607 } 1608 }); 1609 function singleImageLoaded() { 1610 unloaded--; 1611 if (unloaded === 0) { 1612 callback(); 1613 } 1614 } 1615 } 1616 1617 /***/ 1618 }), 1619 /***/"./foundation.core": ( 1620 /*!****************************************************************************************************************************************************************!*\ 1621 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 1622 \****************************************************************************************************************************************************************/ 1623 /***/ 1624 function (module) { 1625 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 1626 1627 /***/ 1628 }), 1629 /***/"jquery": ( 1630 /*!********************************************************************************************!*\ 1631 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 1632 \********************************************************************************************/ 1633 /***/ 1634 function (module) { 1635 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 1636 1637 /***/ 1638 }) 1639 1640 /******/ 1641 }; 1642 /************************************************************************/ 1643 /******/ // The module cache 1644 /******/ 1645 var __webpack_module_cache__ = {}; 1646 /******/ 1647 /******/ // The require function 1648 /******/ 1649 function __webpack_require__(moduleId) { 1650 /******/ // Check if module is in cache 1651 /******/var cachedModule = __webpack_module_cache__[moduleId]; 1652 /******/ 1653 if (cachedModule !== undefined) { 1654 /******/return cachedModule.exports; 1655 /******/ 1656 } 1657 /******/ // Create a new module (and put it into the cache) 1658 /******/ 1659 var module = __webpack_module_cache__[moduleId] = { 1660 /******/ // no module.id needed 1661 /******/ // no module.loaded needed 1662 /******/exports: {} 1663 /******/ 1664 }; 1665 /******/ 1666 /******/ // Execute the module function 1667 /******/ 1668 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 1669 /******/ 1670 /******/ // Return the exports of the module 1671 /******/ 1672 return module.exports; 1673 /******/ 1674 } 1675 /******/ 1676 /************************************************************************/ 1677 /******/ /* webpack/runtime/compat get default export */ 1678 /******/ 1679 !function () { 1680 /******/ // getDefaultExport function for compatibility with non-harmony modules 1681 /******/__webpack_require__.n = function (module) { 1682 /******/var getter = module && module.__esModule ? /******/function () { 1683 return module['default']; 1684 } : /******/function () { 1685 return module; 1686 }; 1687 /******/ 1688 __webpack_require__.d(getter, { 1689 a: getter 1690 }); 1691 /******/ 1692 return getter; 1693 /******/ 1694 }; 1695 /******/ 1696 }(); 1697 /******/ 1698 /******/ /* webpack/runtime/define property getters */ 1699 /******/ 1700 !function () { 1701 /******/ // define getter functions for harmony exports 1702 /******/__webpack_require__.d = function (exports, definition) { 1703 /******/for (var key in definition) { 1704 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 1705 /******/Object.defineProperty(exports, key, { 1706 enumerable: true, 1707 get: definition[key] 1708 }); 1709 /******/ 1710 } 1711 /******/ 1712 } 1713 /******/ 1714 }; 1715 /******/ 1716 }(); 1717 /******/ 1718 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 1719 /******/ 1720 !function () { 1721 /******/__webpack_require__.o = function (obj, prop) { 1722 return Object.prototype.hasOwnProperty.call(obj, prop); 1723 }; 1724 /******/ 1725 }(); 1726 /******/ 1727 /******/ /* webpack/runtime/make namespace object */ 1728 /******/ 1729 !function () { 1730 /******/ // define __esModule on exports 1731 /******/__webpack_require__.r = function (exports) { 1732 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 1733 /******/Object.defineProperty(exports, Symbol.toStringTag, { 1734 value: 'Module' 1735 }); 1736 /******/ 1737 } 1738 /******/ 1739 Object.defineProperty(exports, '__esModule', { 1740 value: true 1741 }); 1742 /******/ 1743 }; 1744 /******/ 1745 }(); 1746 /******/ 1747 /************************************************************************/ 1748 var __webpack_exports__ = {}; 1749 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 1750 !function () { 1751 /*!***********************************************************!*\ 1752 !*** ./js/entries/plugins/foundation.util.imageLoader.js ***! 1753 \***********************************************************/ 1754 __webpack_require__.r(__webpack_exports__); 1755 /* harmony export */ 1756 __webpack_require__.d(__webpack_exports__, { 1757 /* harmony export */Foundation: function () { 1758 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 1759 }, 1760 /* harmony export */onImagesLoaded: function () { 1761 return /* reexport safe */_foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_1__.onImagesLoaded; 1762 } 1763 /* harmony export */ 1764 }); 1765 /* harmony import */ 1766 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 1767 /* harmony import */ 1768 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 1769 /* harmony import */ 1770 var _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.imageLoader */"./js/foundation.util.imageLoader.js"); 1771 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.onImagesLoaded = _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_1__.onImagesLoaded; 1772 }(); 1773 /******/ 1774 return __webpack_exports__; 1775 /******/ 1776 }(); 1777}); 1778(function webpackUniversalModuleDefinition(root, factory) { 1779 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.keyboard"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 1780})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 1781 return /******/function () { 1782 // webpackBootstrap 1783 /******/ 1784 "use strict"; 1785 1786 /******/ 1787 var __webpack_modules__ = { 1788
vendor: 5,883 bytes, lines 1788-1912
1788/***/"./js/foundation.util.keyboard.js": ( 1789 /*!****************************************!*\ 1790 !*** ./js/foundation.util.keyboard.js ***! 1791 \****************************************/ 1792 /***/ 1793 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 1794 __webpack_require__.r(__webpack_exports__); 1795 /* harmony export */ 1796 __webpack_require__.d(__webpack_exports__, { 1797 /* harmony export */Keyboard: function () { 1798 return /* binding */Keyboard; 1799 } 1800 /* harmony export */ 1801 }); 1802 /* harmony import */ 1803 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 1804 /* harmony import */ 1805 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 1806 /* harmony import */ 1807 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 1808 /* harmony import */ 1809 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 1810 /******************************************* 1811 * * 1812 * This util was created by Marius Olbertz * 1813 * Please thank Marius on GitHub /owlbertz * 1814 * or the web http://www.mariusolbertz.de/ * 1815 * * 1816 ******************************************/ 1817 1818 var keyCodes = { 1819 9: 'TAB', 1820 13: 'ENTER', 1821 27: 'ESCAPE', 1822 32: 'SPACE', 1823 35: 'END', 1824 36: 'HOME', 1825 37: 'ARROW_LEFT', 1826 38: 'ARROW_UP', 1827 39: 'ARROW_RIGHT', 1828 40: 'ARROW_DOWN' 1829 }; 1830 var commands = {}; 1831 1832 // Functions pulled out to be referenceable from internals 1833 function findFocusable($element) { 1834 if (!$element) { 1835 return false; 1836 } 1837 return $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 () { 1838 if (!jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).is(':visible') || jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('tabindex') < 0) { 1839 return false; 1840 } //only have visible elements and those that have a tabindex greater or equal 0 1841 return true; 1842 }).sort(function (a, b) { 1843 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).attr('tabindex') === jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).attr('tabindex')) { 1844 return 0; 1845 } 1846 var aTabIndex = parseInt(jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).attr('tabindex'), 10), 1847 bTabIndex = parseInt(jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).attr('tabindex'), 10); 1848 // Undefined is treated the same as 0 1849 if (typeof jquery__WEBPACK_IMPORTED_MODULE_0___default()(a).attr('tabindex') === 'undefined' && bTabIndex > 0) { 1850 return 1; 1851 } 1852 if (typeof jquery__WEBPACK_IMPORTED_MODULE_0___default()(b).attr('tabindex') === 'undefined' && aTabIndex > 0) { 1853 return -1; 1854 } 1855 if (aTabIndex === 0 && bTabIndex > 0) { 1856 return 1; 1857 } 1858 if (bTabIndex === 0 && aTabIndex > 0) { 1859 return -1; 1860 } 1861 if (aTabIndex < bTabIndex) { 1862 return -1; 1863 } 1864 if (aTabIndex > bTabIndex) { 1865 return 1; 1866 } 1867 }); 1868 } 1869 function parseKey(event) { 1870 var key = keyCodes[event.which || event.keyCode] || String.fromCharCode(event.which).toUpperCase(); 1871 1872 // Remove un-printable characters, e.g. for `fromCharCode` calls for CTRL only events 1873 key = key.replace(/\W+/, ''); 1874 if (event.shiftKey) key = "SHIFT_".concat(key); 1875 if (event.ctrlKey) key = "CTRL_".concat(key); 1876 if (event.altKey) key = "ALT_".concat(key); 1877 1878 // Remove trailing underscore, in case only modifiers were used (e.g. only `CTRL_ALT`) 1879 key = key.replace(/_$/, ''); 1880 return key; 1881 } 1882 var Keyboard = { 1883 keys: getKeyCodes(keyCodes), 1884 /** 1885 * Parses the (keyboard) event and returns a String that represents its key 1886 * Can be used like Foundation.parseKey(event) === Foundation.keys.SPACE 1887 * @param {Event} event - the event generated by the event handler 1888 * @return String key - String that represents the key pressed 1889 */ 1890 parseKey: parseKey, 1891 /** 1892 * Handles the given (keyboard) event 1893 * @param {Event} event - the event generated by the event handler 1894 * @param {String} component - Foundation component's name, e.g. Slider or Reveal 1895 * @param {Objects} functions - collection of functions that are to be executed 1896 */ 1897 handleKey: function handleKey(event, component, functions) { 1898 var commandList = commands[component], 1899 keyCode = this.parseKey(event), 1900 cmds, 1901 command, 1902 fn; 1903 if (!commandList) return console.warn('Component not defined!'); 1904 1905 // Ignore the event if it was already handled 1906 if (event.zfIsKeyHandled === true) return; 1907 1908 // This component does not differentiate between ltr and rtl 1909 if (typeof commandList.ltr === 'undefined') { 1910 cmds = commandList; // use plain list 1911 } else { 1912 // merge ltr and rtl: if document is rtl, rtl over
vendor: 5,907 bytes, lines 1912-2055
1912writes ltr and vice versa 1913 if ((0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.rtl)()) cmds = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, commandList.ltr, commandList.rtl);else cmds = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, commandList.rtl, commandList.ltr); 1914 } 1915 command = cmds[keyCode]; 1916 fn = functions[command]; 1917 // Execute the handler if found 1918 if (fn && typeof fn === 'function') { 1919 var returnValue = fn.apply(); 1920 1921 // Mark the event as "handled" to prevent future handlings 1922 event.zfIsKeyHandled = true; 1923 1924 // Execute function when event was handled 1925 if (functions.handled || typeof functions.handled === 'function') { 1926 functions.handled(returnValue); 1927 } 1928 } else { 1929 // Execute function when event was not handled 1930 if (functions.unhandled || typeof functions.unhandled === 'function') { 1931 functions.unhandled(); 1932 } 1933 } 1934 }, 1935 /** 1936 * Finds all focusable elements within the given `$element` 1937 * @param {jQuery} $element - jQuery object to search within 1938 * @return {jQuery} $focusable - all focusable elements within `$element` 1939 */ 1940 1941 findFocusable: findFocusable, 1942 /** 1943 * Returns the component name name 1944 * @param {Object} component - Foundation component, e.g. Slider or Reveal 1945 * @return String componentName 1946 */ 1947 register: function register(componentName, cmds) { 1948 commands[componentName] = cmds; 1949 }, 1950 // TODO9438: These references to Keyboard need to not require global. Will 'this' work in this context? 1951 // 1952 /** 1953 * Traps the focus in the given element. 1954 * @param {jQuery} $element jQuery object to trap the foucs into. 1955 */ 1956 trapFocus: function trapFocus($element) { 1957 var $focusable = findFocusable($element), 1958 $firstFocusable = $focusable.eq(0), 1959 $lastFocusable = $focusable.eq(-1); 1960 $element.on('keydown.zf.trapfocus', function (event) { 1961 if (event.target === $lastFocusable[0] && parseKey(event) === 'TAB') { 1962 event.preventDefault(); 1963 $firstFocusable.focus(); 1964 } else if (event.target === $firstFocusable[0] && parseKey(event) === 'SHIFT_TAB') { 1965 event.preventDefault(); 1966 $lastFocusable.focus(); 1967 } 1968 }); 1969 }, 1970 /** 1971 * Releases the trapped focus from the given element. 1972 * @param {jQuery} $element jQuery object to release the focus for. 1973 */ 1974 releaseFocus: function releaseFocus($element) { 1975 $element.off('keydown.zf.trapfocus'); 1976 } 1977 }; 1978 1979 /* 1980 * Constants for easier comparing. 1981 * Can be used like Foundation.parseKey(event) === Foundation.keys.SPACE 1982 */ 1983 function getKeyCodes(kcs) { 1984 var k = {}; 1985 for (var kc in kcs) { 1986 if (kcs.hasOwnProperty(kc)) k[kcs[kc]] = kcs[kc]; 1987 } 1988 return k; 1989 } 1990 1991 /***/ 1992 }), 1993 /***/"./foundation.core": ( 1994 /*!****************************************************************************************************************************************************************!*\ 1995 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 1996 \****************************************************************************************************************************************************************/ 1997 /***/ 1998 function (module) { 1999 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 2000 2001 /***/ 2002 }), 2003 /***/"jquery": ( 2004 /*!********************************************************************************************!*\ 2005 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 2006 \********************************************************************************************/ 2007 /***/ 2008 function (module) { 2009 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 2010 2011 /***/ 2012 }) 2013 2014 /******/ 2015 }; 2016 /************************************************************************/ 2017 /******/ // The module cache 2018 /******/ 2019 var __webpack_module_cache__ = {}; 2020 /******/ 2021 /******/ // The require function 2022 /******/ 2023 function __webpack_require__(moduleId) { 2024 /******/ // Check if module is in cache 2025 /******/var cachedModule = __webpack_module_cache__[moduleId]; 2026 /******/ 2027 if (cachedModule !== undefined) { 2028 /******/return cachedModule.exports; 2029 /******/ 2030 } 2031 /******/ // Create a new module (and put it into the cache) 2032 /******/ 2033 var module = __webpack_module_cache__[moduleId] = { 2034 /******/ // no module.id needed 2035 /******/ // no module.loaded needed 2036 /******/exports: {} 2037 /******/ 2038 }; 2039 /******/ 2040 /******/ // Execute the module function 2041 /******/ 2042 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 2043 /******/ 2044 /******/ // Return the exports of the module 2045 /******/ 2046 return module.exports; 2047 /******/ 2048 } 2049 /******/ 2050 /************************************************************************/ 2051 /******/ /* webpack/runtime/compat get default export */ 2052 /******/ 2053 !function () { 2054 /******/ // getDefaultExport function for compatibility with non-harmony modules 2055 /******/__webpack_require__.n = function (module) {
vendor: 4,427 bytes, lines 2056-2162
2056 /******/var getter = module && module.__esModule ? /******/function () { 2057 return module['default']; 2058 } : /******/function () { 2059 return module; 2060 }; 2061 /******/ 2062 __webpack_require__.d(getter, { 2063 a: getter 2064 }); 2065 /******/ 2066 return getter; 2067 /******/ 2068 }; 2069 /******/ 2070 }(); 2071 /******/ 2072 /******/ /* webpack/runtime/define property getters */ 2073 /******/ 2074 !function () { 2075 /******/ // define getter functions for harmony exports 2076 /******/__webpack_require__.d = function (exports, definition) { 2077 /******/for (var key in definition) { 2078 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 2079 /******/Object.defineProperty(exports, key, { 2080 enumerable: true, 2081 get: definition[key] 2082 }); 2083 /******/ 2084 } 2085 /******/ 2086 } 2087 /******/ 2088 }; 2089 /******/ 2090 }(); 2091 /******/ 2092 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 2093 /******/ 2094 !function () { 2095 /******/__webpack_require__.o = function (obj, prop) { 2096 return Object.prototype.hasOwnProperty.call(obj, prop); 2097 }; 2098 /******/ 2099 }(); 2100 /******/ 2101 /******/ /* webpack/runtime/make namespace object */ 2102 /******/ 2103 !function () { 2104 /******/ // define __esModule on exports 2105 /******/__webpack_require__.r = function (exports) { 2106 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 2107 /******/Object.defineProperty(exports, Symbol.toStringTag, { 2108 value: 'Module' 2109 }); 2110 /******/ 2111 } 2112 /******/ 2113 Object.defineProperty(exports, '__esModule', { 2114 value: true 2115 }); 2116 /******/ 2117 }; 2118 /******/ 2119 }(); 2120 /******/ 2121 /************************************************************************/ 2122 var __webpack_exports__ = {}; 2123 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 2124 !function () { 2125 /*!********************************************************!*\ 2126 !*** ./js/entries/plugins/foundation.util.keyboard.js ***! 2127 \********************************************************/ 2128 __webpack_require__.r(__webpack_exports__); 2129 /* harmony export */ 2130 __webpack_require__.d(__webpack_exports__, { 2131 /* harmony export */Foundation: function () { 2132 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 2133 }, 2134 /* harmony export */Keyboard: function () { 2135 return /* reexport safe */_foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_1__.Keyboard; 2136 } 2137 /* harmony export */ 2138 }); 2139 /* harmony import */ 2140 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 2141 /* harmony import */ 2142 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 2143 /* harmony import */ 2144 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.keyboard */"./js/foundation.util.keyboard.js"); 2145 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Keyboard = _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_1__.Keyboard; 2146 }(); 2147 /******/ 2148 return __webpack_exports__; 2149 /******/ 2150 }(); 2151}); 2152(function webpackUniversalModuleDefinition(root, factory) { 2153 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 2154})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 2155 return /******/function () { 2156 // webpackBootstrap 2157 /******/ 2158 "use strict"; 2159 2160 /******/ 2161 var __webpack_modules__ = { 2162
vendor: 7,062 bytes, lines 2162-2324
2162/***/"./js/foundation.util.mediaQuery.js": ( 2163 /*!******************************************!*\ 2164 !*** ./js/foundation.util.mediaQuery.js ***! 2165 \******************************************/ 2166 /***/ 2167 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 2168 __webpack_require__.r(__webpack_exports__); 2169 /* harmony export */ 2170 __webpack_require__.d(__webpack_exports__, { 2171 /* harmony export */MediaQuery: function () { 2172 return /* binding */MediaQuery; 2173 } 2174 /* harmony export */ 2175 }); 2176 /* harmony import */ 2177 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 2178 /* harmony import */ 2179 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 2180 function _typeof(o) { 2181 "@babel/helpers - typeof"; 2182 2183 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 2184 return typeof o; 2185 } : function (o) { 2186 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 2187 }, _typeof(o); 2188 } 2189 function _slicedToArray(r, e) { 2190 return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); 2191 } 2192 function _nonIterableRest() { 2193 throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); 2194 } 2195 function _unsupportedIterableToArray(r, a) { 2196 if (r) { 2197 if ("string" == typeof r) return _arrayLikeToArray(r, a); 2198 var t = {}.toString.call(r).slice(8, -1); 2199 return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; 2200 } 2201 } 2202 function _arrayLikeToArray(r, a) { 2203 (null == a || a > r.length) && (a = r.length); 2204 for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; 2205 return n; 2206 } 2207 function _iterableToArrayLimit(r, l) { 2208 var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; 2209 if (null != t) { 2210 var e, 2211 n, 2212 i, 2213 u, 2214 a = [], 2215 f = !0, 2216 o = !1; 2217 try { 2218 if (i = (t = t.call(r)).next, 0 === l) { 2219 if (Object(t) !== t) return; 2220 f = !1; 2221 } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); 2222 } catch (r) { 2223 o = !0, n = r; 2224 } finally { 2225 try { 2226 if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; 2227 } finally { 2228 if (o) throw n; 2229 } 2230 } 2231 return a; 2232 } 2233 } 2234 function _arrayWithHoles(r) { 2235 if (Array.isArray(r)) return r; 2236 } 2237 2238 // Default set of media queries 2239 // const defaultQueries = { 2240 // 'default' : 'only screen', 2241 // landscape : 'only screen and (orientation: landscape)', 2242 // portrait : 'only screen and (orientation: portrait)', 2243 // retina : 'only screen and (-webkit-min-device-pixel-ratio: 2),' + 2244 // 'only screen and (min--moz-device-pixel-ratio: 2),' + 2245 // 'only screen and (-o-min-device-pixel-ratio: 2/1),' + 2246 // 'only screen and (min-device-pixel-ratio: 2),' + 2247 // 'only screen and (min-resolution: 192dpi),' + 2248 // 'only screen and (min-resolution: 2dppx)' 2249 // }; 2250 2251 // matchMedia() polyfill - Test a CSS media type/query in JS. 2252 // Authors & copyright © 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. MIT license 2253 /* eslint-disable */ 2254 window.matchMedia || (window.matchMedia = function () { 2255 "use strict"; 2256 2257 // For browsers that support matchMedium api such as IE 9 and webkit 2258 var styleMedia = window.styleMedia || window.media; 2259 2260 // For those that don't support matchMedium 2261 if (!styleMedia) { 2262 var style = document.createElement('style'), 2263 script = document.getElementsByTagName('script')[0], 2264 info = null; 2265 style.type = 'text/css'; 2266 style.id = 'matchmediajs-test'; 2267 if (!script) { 2268 document.head.appendChild(style); 2269 } else { 2270 script.parentNode.insertBefore(style, script); 2271 } 2272 2273 // 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers 2274 info = 'getComputedStyle' in window && window.getComputedStyle(style, null) || style.currentStyle; 2275 styleMedia = { 2276 matchMedium: function matchMedium(media) { 2277 var text = '@media ' + media + '{ #matchmediajs-test { width: 1px; } }'; 2278 2279 // 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers 2280 if (style.styleSheet) { 2281 style.styleSheet.cssText = text; 2282 } else { 2283 style.textContent = text; 2284 } 2285 2286 // Test if media query is true or false 2287 return info.width === '1px'; 2288 } 2289 }; 2290 } 2291 return function (media) { 2292 return { 2293 matches: styleMedia.matchMedium(media || 'all'), 2294 media: media || 'all' 2295 }; 2296 }; 2297 }()); 2298 /* eslint-enable */ 2299 2300 var MediaQuery = { 2301 queries: [], 2302 current: '', 2303 /** 2304 * Initializes the media query helper, by extracting the breakpoint list from the CSS and activating the breakpoint watcher. 2305 * @function 2306 * @private 2307 */ 2308 _init: function _init() { 2309 // make sure the initialization is only done once when calling _init() several times 2310 if (this.isInitialized === true) { 2311 return this; 2312 } else { 2313 this.isInitialized = true; 2314 } 2315 var self = this; 2316 var $meta = jquery__WEBPACK_IMPORTED_MODULE_0___default()('meta.foundation-mq'); 2317 if (!$meta.length) { 2318 jquery__WEBPACK_IMPORTED_MODULE_0___default()('<meta class="foundation-mq" name="foundation-mq" content>').appendTo(document.head); 2319 } 2320 var extractedStyles = jquery__WEBPACK_IMPORTED_MODULE_0___default()('.foundation-mq').css('font-family'); 2321 var namedQueries; 2322 namedQueries = parseStyleToObject(extractedStyles); 2323 self.queries = []; // reset 2324
vendor: 5,468 bytes, lines 2325-2453
2325 for (var key in namedQueries) { 2326 if (namedQueries.hasOwnProperty(key)) { 2327 self.queries.push({ 2328 name: key, 2329 value: "only screen and (min-width: ".concat(namedQueries[key], ")") 2330 }); 2331 } 2332 } 2333 this.current = this._getCurrentSize(); 2334 this._watcher(); 2335 }, 2336 /** 2337 * Reinitializes the media query helper. 2338 * Useful if your CSS breakpoint configuration has just been loaded or has changed since the initialization. 2339 * @function 2340 * @private 2341 */ 2342 _reInit: function _reInit() { 2343 this.isInitialized = false; 2344 this._init(); 2345 }, 2346 /** 2347 * Checks if the screen is at least as wide as a breakpoint. 2348 * @function 2349 * @param {String} size - Name of the breakpoint to check. 2350 * @returns {Boolean} `true` if the breakpoint matches, `false` if it's smaller. 2351 */ 2352 atLeast: function atLeast(size) { 2353 var query = this.get(size); 2354 if (query) { 2355 return window.matchMedia(query).matches; 2356 } 2357 return false; 2358 }, 2359 /** 2360 * Checks if the screen is within the given breakpoint. 2361 * If smaller than the breakpoint of larger than its upper limit it returns false. 2362 * @function 2363 * @param {String} size - Name of the breakpoint to check. 2364 * @returns {Boolean} `true` if the breakpoint matches, `false` otherwise. 2365 */ 2366 only: function only(size) { 2367 return size === this._getCurrentSize(); 2368 }, 2369 /** 2370 * Checks if the screen is within a breakpoint or smaller. 2371 * @function 2372 * @param {String} size - Name of the breakpoint to check. 2373 * @returns {Boolean} `true` if the breakpoint matches, `false` if it's larger. 2374 */ 2375 upTo: function upTo(size) { 2376 var nextSize = this.next(size); 2377 2378 // If the next breakpoint does not match, the screen is smaller than 2379 // the upper limit of this breakpoint. 2380 if (nextSize) { 2381 return !this.atLeast(nextSize); 2382 } 2383 2384 // If there is no next breakpoint, the "size" breakpoint does not have 2385 // an upper limit and the screen will always be within it or smaller. 2386 return true; 2387 }, 2388 /** 2389 * Checks if the screen matches to a breakpoint. 2390 * @function 2391 * @param {String} size - Name of the breakpoint to check, either 'small only' or 'small'. Omitting 'only' falls back to using atLeast() method. 2392 * @returns {Boolean} `true` if the breakpoint matches, `false` if it does not. 2393 */ 2394 is: function is(size) { 2395 var parts = size.trim().split(' ').filter(function (p) { 2396 return !!p.length; 2397 }); 2398 var _parts = _slicedToArray(parts, 2), 2399 bpSize = _parts[0], 2400 _parts$ = _parts[1], 2401 bpModifier = _parts$ === void 0 ? '' : _parts$; 2402 2403 // Only the breakpont 2404 if (bpModifier === 'only') { 2405 return this.only(bpSize); 2406 } 2407 // At least the breakpoint (included) 2408 if (!bpModifier || bpModifier === 'up') { 2409 return this.atLeast(bpSize); 2410 } 2411 // Up to the breakpoint (included) 2412 if (bpModifier === 'down') { 2413 return this.upTo(bpSize); 2414 } 2415 throw new Error("\n Invalid breakpoint passed to MediaQuery.is().\n Expected a breakpoint name formatted like \"<size> <modifier>\", got \"".concat(size, "\".\n ")); 2416 }, 2417 /** 2418 * Gets the media query of a breakpoint. 2419 * @function 2420 * @param {String} size - Name of the breakpoint to get. 2421 * @returns {String|null} - The media query of the breakpoint, or `null` if the breakpoint doesn't exist. 2422 */ 2423 get: function get(size) { 2424 for (var i in this.queries) { 2425 if (this.queries.hasOwnProperty(i)) { 2426 var query = this.queries[i]; 2427 if (size === query.name) return query.value; 2428 } 2429 } 2430 return null; 2431 }, 2432 /** 2433 * Get the breakpoint following the given breakpoint. 2434 * @function 2435 * @param {String} size - Name of the breakpoint. 2436 * @returns {String|null} - The name of the following breakpoint, or `null` if the passed breakpoint was the last one. 2437 */ 2438 next: function next(size) { 2439 var _this = this; 2440 var queryIndex = this.queries.findIndex(function (q) { 2441 return _this._getQueryName(q) === size; 2442 }); 2443 if (queryIndex === -1) { 2444 throw new Error("\n Unknown breakpoint \"".concat(size, "\" passed to MediaQuery.next().\n Ensure it is present in your Sass \"$breakpoints\" setting.\n ")); 2445 } 2446 var nextQuery = this.queries[queryIndex + 1]; 2447 return nextQuery ? nextQuery.name : null; 2448 }, 2449 /** 2450 * Returns the name of the breakpoint related to the given value. 2451 * @function 2452 * @private 2453 * @param {String|Object}
vendor: 10,293 bytes, lines 2453-2702
2453 value - Breakpoint name or query object. 2454 * @returns {String} Name of the breakpoint. 2455 */ 2456 _getQueryName: function _getQueryName(value) { 2457 if (typeof value === 'string') return value; 2458 if (_typeof(value) === 'object') return value.name; 2459 throw new TypeError("\n Invalid value passed to MediaQuery._getQueryName().\n Expected a breakpoint name (String) or a breakpoint query (Object), got \"".concat(value, "\" (").concat(_typeof(value), ")\n ")); 2460 }, 2461 /** 2462 * Gets the current breakpoint name by testing every breakpoint and returning the last one to match (the biggest one). 2463 * @function 2464 * @private 2465 * @returns {String} Name of the current breakpoint. 2466 */ 2467 _getCurrentSize: function _getCurrentSize() { 2468 var matched; 2469 for (var i = 0; i < this.queries.length; i++) { 2470 var query = this.queries[i]; 2471 if (window.matchMedia(query.value).matches) { 2472 matched = query; 2473 } 2474 } 2475 return matched && this._getQueryName(matched); 2476 }, 2477 /** 2478 * Activates the breakpoint watcher, which fires an event on the window whenever the breakpoint changes. 2479 * @function 2480 * @private 2481 */ 2482 _watcher: function _watcher() { 2483 var _this2 = this; 2484 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('resize.zf.trigger', function () { 2485 var newSize = _this2._getCurrentSize(), 2486 currentSize = _this2.current; 2487 if (newSize !== currentSize) { 2488 // Change the current media query 2489 _this2.current = newSize; 2490 2491 // Broadcast the media query change on the window 2492 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).trigger('changed.zf.mediaquery', [newSize, currentSize]); 2493 } 2494 }); 2495 } 2496 }; 2497 2498 // Thank you: https://github.com/sindresorhus/query-string 2499 function parseStyleToObject(str) { 2500 var styleObject = {}; 2501 if (typeof str !== 'string') { 2502 return styleObject; 2503 } 2504 str = str.trim().slice(1, -1); // browsers re-quote string style values 2505 2506 if (!str) { 2507 return styleObject; 2508 } 2509 styleObject = str.split('&').reduce(function (ret, param) { 2510 var parts = param.replace(/\+/g, ' ').split('='); 2511 var key = parts[0]; 2512 var val = parts[1]; 2513 key = decodeURIComponent(key); 2514 2515 // missing `=` should be `null`: 2516 // http://w3.org/TR/2012/WD-url-20120524/#collect-url-parameters 2517 val = typeof val === 'undefined' ? null : decodeURIComponent(val); 2518 if (!ret.hasOwnProperty(key)) { 2519 ret[key] = val; 2520 } else if (Array.isArray(ret[key])) { 2521 ret[key].push(val); 2522 } else { 2523 ret[key] = [ret[key], val]; 2524 } 2525 return ret; 2526 }, {}); 2527 return styleObject; 2528 } 2529 2530 /***/ 2531 }), 2532 /***/"./foundation.core": ( 2533 /*!****************************************************************************************************************************************************************!*\ 2534 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 2535 \****************************************************************************************************************************************************************/ 2536 /***/ 2537 function (module) { 2538 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 2539 2540 /***/ 2541 }), 2542 /***/"jquery": ( 2543 /*!********************************************************************************************!*\ 2544 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 2545 \********************************************************************************************/ 2546 /***/ 2547 function (module) { 2548 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 2549 2550 /***/ 2551 }) 2552 2553 /******/ 2554 }; 2555 /************************************************************************/ 2556 /******/ // The module cache 2557 /******/ 2558 var __webpack_module_cache__ = {}; 2559 /******/ 2560 /******/ // The require function 2561 /******/ 2562 function __webpack_require__(moduleId) { 2563 /******/ // Check if module is in cache 2564 /******/var cachedModule = __webpack_module_cache__[moduleId]; 2565 /******/ 2566 if (cachedModule !== undefined) { 2567 /******/return cachedModule.exports; 2568 /******/ 2569 } 2570 /******/ // Create a new module (and put it into the cache) 2571 /******/ 2572 var module = __webpack_module_cache__[moduleId] = { 2573 /******/ // no module.id needed 2574 /******/ // no module.loaded needed 2575 /******/exports: {} 2576 /******/ 2577 }; 2578 /******/ 2579 /******/ // Execute the module function 2580 /******/ 2581 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 2582 /******/ 2583 /******/ // Return the exports of the module 2584 /******/ 2585 return module.exports; 2586 /******/ 2587 } 2588 /******/ 2589 /************************************************************************/ 2590 /******/ /* webpack/runtime/compat get default export */ 2591 /******/ 2592 !function () { 2593 /******/ // getDefaultExport function for compatibility with non-harmony modules 2594 /******/__webpack_require__.n = function (module) { 2595 /******/var getter = module && module.__esModule ? /******/function () { 2596 return module['default']; 2597 } : /******/function () { 2598 return module; 2599 }; 2600 /******/ 2601 __webpack_require__.d(getter, { 2602 a: getter 2603 }); 2604 /******/ 2605 return getter; 2606 /******/ 2607 }; 2608 /******/ 2609 }(); 2610 /******/ 2611 /******/ /* webpack/runtime/define property getters */ 2612 /******/ 2613 !function () { 2614 /******/ // define getter functions for harmony exports 2615 /******/__webpack_require__.d = function (exports, definition) { 2616 /******/for (var key in definition) { 2617 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 2618 /******/Object.defineProperty(exports, key, { 2619 enumerable: true, 2620 get: definition[key] 2621 }); 2622 /******/ 2623 } 2624 /******/ 2625 } 2626 /******/ 2627 }; 2628 /******/ 2629 }(); 2630 /******/ 2631 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 2632 /******/ 2633 !function () { 2634 /******/__webpack_require__.o = function (obj, prop) { 2635 return Object.prototype.hasOwnProperty.call(obj, prop); 2636 }; 2637 /******/ 2638 }(); 2639 /******/ 2640 /******/ /* webpack/runtime/make namespace object */ 2641 /******/ 2642 !function () { 2643 /******/ // define __esModule on exports 2644 /******/__webpack_require__.r = function (exports) { 2645 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 2646 /******/Object.defineProperty(exports, Symbol.toStringTag, { 2647 value: 'Module' 2648 }); 2649 /******/ 2650 } 2651 /******/ 2652 Object.defineProperty(exports, '__esModule', { 2653 value: true 2654 }); 2655 /******/ 2656 }; 2657 /******/ 2658 }(); 2659 /******/ 2660 /************************************************************************/ 2661 var __webpack_exports__ = {}; 2662 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 2663 !function () { 2664 /*!**********************************************************!*\ 2665 !*** ./js/entries/plugins/foundation.util.mediaQuery.js ***! 2666 \**********************************************************/ 2667 __webpack_require__.r(__webpack_exports__); 2668 /* harmony export */ 2669 __webpack_require__.d(__webpack_exports__, { 2670 /* harmony export */Foundation: function () { 2671 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 2672 }, 2673 /* harmony export */MediaQuery: function () { 2674 return /* reexport safe */_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery; 2675 } 2676 /* harmony export */ 2677 }); 2678 /* harmony import */ 2679 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 2680 /* harmony import */ 2681 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 2682 /* harmony import */ 2683 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.mediaQuery */"./js/foundation.util.mediaQuery.js"); 2684 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.MediaQuery = _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery; 2685 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.MediaQuery._init(); 2686 }(); 2687 /******/ 2688 return __webpack_exports__; 2689 /******/ 2690 }(); 2691}); 2692(function webpackUniversalModuleDefinition(root, factory) { 2693 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.motion"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 2694})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 2695 return /******/function () { 2696 // webpackBootstrap 2697 /******/ 2698 "use strict"; 2699 2700 /******/ 2701 var __webpack_modules__ = { 2702
vendor: 7,285 bytes, lines 2702-2879
2702/***/"./js/foundation.util.motion.js": ( 2703 /*!**************************************!*\ 2704 !*** ./js/foundation.util.motion.js ***! 2705 \**************************************/ 2706 /***/ 2707 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 2708 __webpack_require__.r(__webpack_exports__); 2709 /* harmony export */ 2710 __webpack_require__.d(__webpack_exports__, { 2711 /* harmony export */Motion: function () { 2712 return /* binding */Motion; 2713 }, 2714 /* harmony export */Move: function () { 2715 return /* binding */Move; 2716 } 2717 /* harmony export */ 2718 }); 2719 /* harmony import */ 2720 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 2721 /* harmony import */ 2722 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 2723 /* harmony import */ 2724 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 2725 /* harmony import */ 2726 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 2727 2728 /** 2729 * Motion module. 2730 * @module foundation.motion 2731 */ 2732 2733 var initClasses = ['mui-enter', 'mui-leave']; 2734 var activeClasses = ['mui-enter-active', 'mui-leave-active']; 2735 var Motion = { 2736 animateIn: function animateIn(element, animation, cb) { 2737 animate(true, element, animation, cb); 2738 }, 2739 animateOut: function animateOut(element, animation, cb) { 2740 animate(false, element, animation, cb); 2741 } 2742 }; 2743 function Move(duration, elem, fn) { 2744 var anim, 2745 prog, 2746 start = null; 2747 if (duration === 0) { 2748 fn.apply(elem); 2749 elem.trigger('finished.zf.animate', [elem]).triggerHandler('finished.zf.animate', [elem]); 2750 return; 2751 } 2752 function move(ts) { 2753 if (!start) start = ts; 2754 prog = ts - start; 2755 fn.apply(elem); 2756 if (prog < duration) { 2757 anim = window.requestAnimationFrame(move, elem); 2758 } else { 2759 window.cancelAnimationFrame(anim); 2760 elem.trigger('finished.zf.animate', [elem]).triggerHandler('finished.zf.animate', [elem]); 2761 } 2762 } 2763 anim = window.requestAnimationFrame(move); 2764 } 2765 2766 /** 2767 * Animates an element in or out using a CSS transition class. 2768 * @function 2769 * @private 2770 * @param {Boolean} isIn - Defines if the animation is in or out. 2771 * @param {Object} element - jQuery or HTML object to animate. 2772 * @param {String} animation - CSS class to use. 2773 * @param {Function} cb - Callback to run when animation is finished. 2774 */ 2775 function animate(isIn, element, animation, cb) { 2776 element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element).eq(0); 2777 if (!element.length) return; 2778 var initClass = isIn ? initClasses[0] : initClasses[1]; 2779 var activeClass = isIn ? activeClasses[0] : activeClasses[1]; 2780 2781 // Set up the animation 2782 reset(); 2783 element.addClass(animation).css('transition', 'none'); 2784 requestAnimationFrame(function () { 2785 element.addClass(initClass); 2786 if (isIn) element.show(); 2787 }); 2788 2789 // Start the animation 2790 requestAnimationFrame(function () { 2791 // will trigger the browser to synchronously calculate the style and layout 2792 // also called reflow or layout thrashing 2793 // see https://gist.github.com/paulirish/5d52fb081b3570c81e3a 2794 element[0].offsetWidth; 2795 element.css('transition', '').addClass(activeClass); 2796 }); 2797 2798 // Clean up the animation when it finishes 2799 element.one((0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.transitionend)(element), finish); 2800 2801 // Hides the element (for out animations), resets the element, and runs a callback 2802 function finish() { 2803 if (!isIn) element.hide(); 2804 reset(); 2805 if (cb) cb.apply(element); 2806 } 2807 2808 // Resets transitions and removes motion-specific classes 2809 function reset() { 2810 element[0].style.transitionDuration = 0; 2811 element.removeClass("".concat(initClass, " ").concat(activeClass, " ").concat(animation)); 2812 } 2813 } 2814 2815 /***/ 2816 }), 2817 /***/"./foundation.core": ( 2818 /*!****************************************************************************************************************************************************************!*\ 2819 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 2820 \****************************************************************************************************************************************************************/ 2821 /***/ 2822 function (module) { 2823 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 2824 2825 /***/ 2826 }), 2827 /***/"jquery": ( 2828 /*!********************************************************************************************!*\ 2829 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 2830 \********************************************************************************************/ 2831 /***/ 2832 function (module) { 2833 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 2834 2835 /***/ 2836 }) 2837 2838 /******/ 2839 }; 2840 /************************************************************************/ 2841 /******/ // The module cache 2842 /******/ 2843 var __webpack_module_cache__ = {}; 2844 /******/ 2845 /******/ // The require function 2846 /******/ 2847 function __webpack_require__(moduleId) { 2848 /******/ // Check if module is in cache 2849 /******/var cachedModule = __webpack_module_cache__[moduleId]; 2850 /******/ 2851 if (cachedModule !== undefined) { 2852 /******/return cachedModule.exports; 2853 /******/ 2854 } 2855 /******/ // Create a new module (and put it into the cache) 2856 /******/ 2857 var module = __webpack_module_cache__[moduleId] = { 2858 /******/ // no module.id needed 2859 /******/ // no module.loaded needed 2860 /******/exports: {} 2861 /******/ 2862 }; 2863 /******/ 2864 /******/ // Execute the module function 2865 /******/ 2866 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 2867 /******/ 2868 /******/ // Return the exports of the module 2869 /******/ 2870 return module.exports; 2871 /******/ 2872 } 2873 /******/ 2874 /************************************************************************/ 2875 /******/ /* webpack/runtime/compat get default export */ 2876 /******/ 2877 !function () { 2878 /******/ // getDefaultExport function for compatibility with non-harmony modules 2879 /******/__webpack_require__.n = function (module) {
vendor: 4,680 bytes, lines 2880-2990
2880 /******/var getter = module && module.__esModule ? /******/function () { 2881 return module['default']; 2882 } : /******/function () { 2883 return module; 2884 }; 2885 /******/ 2886 __webpack_require__.d(getter, { 2887 a: getter 2888 }); 2889 /******/ 2890 return getter; 2891 /******/ 2892 }; 2893 /******/ 2894 }(); 2895 /******/ 2896 /******/ /* webpack/runtime/define property getters */ 2897 /******/ 2898 !function () { 2899 /******/ // define getter functions for harmony exports 2900 /******/__webpack_require__.d = function (exports, definition) { 2901 /******/for (var key in definition) { 2902 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 2903 /******/Object.defineProperty(exports, key, { 2904 enumerable: true, 2905 get: definition[key] 2906 }); 2907 /******/ 2908 } 2909 /******/ 2910 } 2911 /******/ 2912 }; 2913 /******/ 2914 }(); 2915 /******/ 2916 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 2917 /******/ 2918 !function () { 2919 /******/__webpack_require__.o = function (obj, prop) { 2920 return Object.prototype.hasOwnProperty.call(obj, prop); 2921 }; 2922 /******/ 2923 }(); 2924 /******/ 2925 /******/ /* webpack/runtime/make namespace object */ 2926 /******/ 2927 !function () { 2928 /******/ // define __esModule on exports 2929 /******/__webpack_require__.r = function (exports) { 2930 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 2931 /******/Object.defineProperty(exports, Symbol.toStringTag, { 2932 value: 'Module' 2933 }); 2934 /******/ 2935 } 2936 /******/ 2937 Object.defineProperty(exports, '__esModule', { 2938 value: true 2939 }); 2940 /******/ 2941 }; 2942 /******/ 2943 }(); 2944 /******/ 2945 /************************************************************************/ 2946 var __webpack_exports__ = {}; 2947 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 2948 !function () { 2949 /*!******************************************************!*\ 2950 !*** ./js/entries/plugins/foundation.util.motion.js ***! 2951 \******************************************************/ 2952 __webpack_require__.r(__webpack_exports__); 2953 /* harmony export */ 2954 __webpack_require__.d(__webpack_exports__, { 2955 /* harmony export */Foundation: function () { 2956 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 2957 }, 2958 /* harmony export */Motion: function () { 2959 return /* reexport safe */_foundation_util_motion__WEBPACK_IMPORTED_MODULE_1__.Motion; 2960 }, 2961 /* harmony export */Move: function () { 2962 return /* reexport safe */_foundation_util_motion__WEBPACK_IMPORTED_MODULE_1__.Move; 2963 } 2964 /* harmony export */ 2965 }); 2966 /* harmony import */ 2967 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 2968 /* harmony import */ 2969 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 2970 /* harmony import */ 2971 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.motion */"./js/foundation.util.motion.js"); 2972 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Motion = _foundation_util_motion__WEBPACK_IMPORTED_MODULE_1__.Motion; 2973 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Move = _foundation_util_motion__WEBPACK_IMPORTED_MODULE_1__.Move; 2974 }(); 2975 /******/ 2976 return __webpack_exports__; 2977 /******/ 2978 }(); 2979}); 2980(function webpackUniversalModuleDefinition(root, factory) { 2981 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.nest"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 2982})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 2983 return /******/function () { 2984 // webpackBootstrap 2985 /******/ 2986 "use strict"; 2987 2988 /******/ 2989 var __webpack_modules__ = { 2990
vendor: 6,167 bytes, lines 2990-3133
2990/***/"./js/foundation.util.nest.js": ( 2991 /*!************************************!*\ 2992 !*** ./js/foundation.util.nest.js ***! 2993 \************************************/ 2994 /***/ 2995 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 2996 __webpack_require__.r(__webpack_exports__); 2997 /* harmony export */ 2998 __webpack_require__.d(__webpack_exports__, { 2999 /* harmony export */Nest: function () { 3000 return /* binding */Nest; 3001 } 3002 /* harmony export */ 3003 }); 3004 /* harmony import */ 3005 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 3006 /* harmony import */ 3007 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 3008 var Nest = { 3009 Feather: function Feather(menu) { 3010 var type = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'zf'; 3011 menu.attr('role', 'menubar'); 3012 menu.find('a').attr({ 3013 'role': 'menuitem' 3014 }); 3015 var items = menu.find('li').attr({ 3016 'role': 'none' 3017 }), 3018 subMenuClass = "is-".concat(type, "-submenu"), 3019 subItemClass = "".concat(subMenuClass, "-item"), 3020 hasSubClass = "is-".concat(type, "-submenu-parent"), 3021 applyAria = type !== 'accordion'; // Accordions handle their own ARIA attriutes. 3022 3023 items.each(function () { 3024 var $item = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 3025 $sub = $item.children('ul'); 3026 if ($sub.length) { 3027 $item.addClass(hasSubClass); 3028 if (applyAria) { 3029 var firstItem = $item.children('a:first'); 3030 firstItem.attr({ 3031 'aria-haspopup': true, 3032 'aria-label': firstItem.attr('aria-label') || firstItem.text() 3033 }); 3034 // Note: Drilldowns behave differently in how they hide, and so need 3035 // additional attributes. We should look if this possibly over-generalized 3036 // utility (Nest) is appropriate when we rework menus in 6.4 3037 if (type === 'drilldown') { 3038 $item.attr({ 3039 'aria-expanded': false 3040 }); 3041 } 3042 } 3043 $sub.addClass("submenu ".concat(subMenuClass)).attr({ 3044 'data-submenu': '', 3045 'role': 'menubar' 3046 }); 3047 if (type === 'drilldown') { 3048 $sub.attr({ 3049 'aria-hidden': true 3050 }); 3051 } 3052 } 3053 if ($item.parent('[data-submenu]').length) { 3054 $item.addClass("is-submenu-item ".concat(subItemClass)); 3055 } 3056 }); 3057 return; 3058 }, 3059 Burn: function Burn(menu, type) { 3060 var 3061 //items = menu.find('li'), 3062 subMenuClass = "is-".concat(type, "-submenu"), 3063 subItemClass = "".concat(subMenuClass, "-item"), 3064 hasSubClass = "is-".concat(type, "-submenu-parent"); 3065 menu.find('>li, > li > ul, .menu, .menu > li, [data-submenu] > li').removeClass("".concat(subMenuClass, " ").concat(subItemClass, " ").concat(hasSubClass, " is-submenu-item submenu is-active")).removeAttr('data-submenu').css('display', ''); 3066 } 3067 }; 3068 3069 /***/ 3070 }), 3071 /***/"./foundation.core": ( 3072 /*!****************************************************************************************************************************************************************!*\ 3073 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 3074 \****************************************************************************************************************************************************************/ 3075 /***/ 3076 function (module) { 3077 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 3078 3079 /***/ 3080 }), 3081 /***/"jquery": ( 3082 /*!********************************************************************************************!*\ 3083 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 3084 \********************************************************************************************/ 3085 /***/ 3086 function (module) { 3087 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 3088 3089 /***/ 3090 }) 3091 3092 /******/ 3093 }; 3094 /************************************************************************/ 3095 /******/ // The module cache 3096 /******/ 3097 var __webpack_module_cache__ = {}; 3098 /******/ 3099 /******/ // The require function 3100 /******/ 3101 function __webpack_require__(moduleId) { 3102 /******/ // Check if module is in cache 3103 /******/var cachedModule = __webpack_module_cache__[moduleId]; 3104 /******/ 3105 if (cachedModule !== undefined) { 3106 /******/return cachedModule.exports; 3107 /******/ 3108 } 3109 /******/ // Create a new module (and put it into the cache) 3110 /******/ 3111 var module = __webpack_module_cache__[moduleId] = { 3112 /******/ // no module.id needed 3113 /******/ // no module.loaded needed 3114 /******/exports: {} 3115 /******/ 3116 }; 3117 /******/ 3118 /******/ // Execute the module function 3119 /******/ 3120 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 3121 /******/ 3122 /******/ // Return the exports of the module 3123 /******/ 3124 return module.exports; 3125 /******/ 3126 } 3127 /******/ 3128 /************************************************************************/ 3129 /******/ /* webpack/runtime/compat get default export */ 3130 /******/ 3131 !function () { 3132 /******/ // getDefaultExport function for compatibility with non-harmony modules 3133 /******/__webpack_require__.n = function (module) {
vendor: 4,274 bytes, lines 3134-3240
3134 /******/var getter = module && module.__esModule ? /******/function () { 3135 return module['default']; 3136 } : /******/function () { 3137 return module; 3138 }; 3139 /******/ 3140 __webpack_require__.d(getter, { 3141 a: getter 3142 }); 3143 /******/ 3144 return getter; 3145 /******/ 3146 }; 3147 /******/ 3148 }(); 3149 /******/ 3150 /******/ /* webpack/runtime/define property getters */ 3151 /******/ 3152 !function () { 3153 /******/ // define getter functions for harmony exports 3154 /******/__webpack_require__.d = function (exports, definition) { 3155 /******/for (var key in definition) { 3156 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 3157 /******/Object.defineProperty(exports, key, { 3158 enumerable: true, 3159 get: definition[key] 3160 }); 3161 /******/ 3162 } 3163 /******/ 3164 } 3165 /******/ 3166 }; 3167 /******/ 3168 }(); 3169 /******/ 3170 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 3171 /******/ 3172 !function () { 3173 /******/__webpack_require__.o = function (obj, prop) { 3174 return Object.prototype.hasOwnProperty.call(obj, prop); 3175 }; 3176 /******/ 3177 }(); 3178 /******/ 3179 /******/ /* webpack/runtime/make namespace object */ 3180 /******/ 3181 !function () { 3182 /******/ // define __esModule on exports 3183 /******/__webpack_require__.r = function (exports) { 3184 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 3185 /******/Object.defineProperty(exports, Symbol.toStringTag, { 3186 value: 'Module' 3187 }); 3188 /******/ 3189 } 3190 /******/ 3191 Object.defineProperty(exports, '__esModule', { 3192 value: true 3193 }); 3194 /******/ 3195 }; 3196 /******/ 3197 }(); 3198 /******/ 3199 /************************************************************************/ 3200 var __webpack_exports__ = {}; 3201 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 3202 !function () { 3203 /*!****************************************************!*\ 3204 !*** ./js/entries/plugins/foundation.util.nest.js ***! 3205 \****************************************************/ 3206 __webpack_require__.r(__webpack_exports__); 3207 /* harmony export */ 3208 __webpack_require__.d(__webpack_exports__, { 3209 /* harmony export */Foundation: function () { 3210 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 3211 }, 3212 /* harmony export */Nest: function () { 3213 return /* reexport safe */_foundation_util_nest__WEBPACK_IMPORTED_MODULE_1__.Nest; 3214 } 3215 /* harmony export */ 3216 }); 3217 /* harmony import */ 3218 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 3219 /* harmony import */ 3220 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 3221 /* harmony import */ 3222 var _foundation_util_nest__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.nest */"./js/foundation.util.nest.js"); 3223 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Nest = _foundation_util_nest__WEBPACK_IMPORTED_MODULE_1__.Nest; 3224 }(); 3225 /******/ 3226 return __webpack_exports__; 3227 /******/ 3228 }(); 3229}); 3230(function webpackUniversalModuleDefinition(root, factory) { 3231 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"));else if (typeof define === 'function' && define.amd) define(["./foundation.core"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.timer"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"]); 3232})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__) { 3233 return /******/function () { 3234 // webpackBootstrap 3235 /******/ 3236 "use strict"; 3237 3238 /******/ 3239 var __webpack_modules__ = { 3240
vendor: 4,291 bytes, lines 3240-3350
3240/***/"./js/foundation.util.timer.js": ( 3241 /*!*************************************!*\ 3242 !*** ./js/foundation.util.timer.js ***! 3243 \*************************************/ 3244 /***/ 3245 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 3246 __webpack_require__.r(__webpack_exports__); 3247 /* harmony export */ 3248 __webpack_require__.d(__webpack_exports__, { 3249 /* harmony export */Timer: function () { 3250 return /* binding */Timer; 3251 } 3252 /* harmony export */ 3253 }); 3254 function Timer(elem, options, cb) { 3255 var _this = this, 3256 duration = options.duration, 3257 //options is an object for easily adding features later. 3258 nameSpace = Object.keys(elem.data())[0] || 'timer', 3259 remain = -1, 3260 start, 3261 timer; 3262 this.isPaused = false; 3263 this.restart = function () { 3264 remain = -1; 3265 clearTimeout(timer); 3266 this.start(); 3267 }; 3268 this.start = function () { 3269 this.isPaused = false; 3270 // if(!elem.data('paused')){ return false; }//maybe implement this sanity check if used for other things. 3271 clearTimeout(timer); 3272 remain = remain <= 0 ? duration : remain; 3273 elem.data('paused', false); 3274 start = Date.now(); 3275 timer = setTimeout(function () { 3276 if (options.infinite) { 3277 _this.restart(); //rerun the timer. 3278 } 3279 if (cb && typeof cb === 'function') { 3280 cb(); 3281 } 3282 }, remain); 3283 elem.trigger("timerstart.zf.".concat(nameSpace)); 3284 }; 3285 this.pause = function () { 3286 this.isPaused = true; 3287 //if(elem.data('paused')){ return false; }//maybe implement this sanity check if used for other things. 3288 clearTimeout(timer); 3289 elem.data('paused', true); 3290 var end = Date.now(); 3291 remain = remain - (end - start); 3292 elem.trigger("timerpaused.zf.".concat(nameSpace)); 3293 }; 3294 } 3295 3296 /***/ 3297 }), 3298 /***/"./foundation.core": ( 3299 /*!****************************************************************************************************************************************************************!*\ 3300 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 3301 \****************************************************************************************************************************************************************/ 3302 /***/ 3303 function (module) { 3304 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 3305 3306 /***/ 3307 }) 3308 3309 /******/ 3310 }; 3311 /************************************************************************/ 3312 /******/ // The module cache 3313 /******/ 3314 var __webpack_module_cache__ = {}; 3315 /******/ 3316 /******/ // The require function 3317 /******/ 3318 function __webpack_require__(moduleId) { 3319 /******/ // Check if module is in cache 3320 /******/var cachedModule = __webpack_module_cache__[moduleId]; 3321 /******/ 3322 if (cachedModule !== undefined) { 3323 /******/return cachedModule.exports; 3324 /******/ 3325 } 3326 /******/ // Create a new module (and put it into the cache) 3327 /******/ 3328 var module = __webpack_module_cache__[moduleId] = { 3329 /******/ // no module.id needed 3330 /******/ // no module.loaded needed 3331 /******/exports: {} 3332 /******/ 3333 }; 3334 /******/ 3335 /******/ // Execute the module function 3336 /******/ 3337 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 3338 /******/ 3339 /******/ // Return the exports of the module 3340 /******/ 3341 return module.exports; 3342 /******/ 3343 } 3344 /******/ 3345 /************************************************************************/ 3346 /******/ /* webpack/runtime/compat get default export */ 3347 /******/ 3348 !function () { 3349 /******/ // getDefaultExport function for compatibility with non-harmony modules 3350 /******/__webpack_require__.n = function (module) {
vendor: 4,386 bytes, lines 3351-3457
3351 /******/var getter = module && module.__esModule ? /******/function () { 3352 return module['default']; 3353 } : /******/function () { 3354 return module; 3355 }; 3356 /******/ 3357 __webpack_require__.d(getter, { 3358 a: getter 3359 }); 3360 /******/ 3361 return getter; 3362 /******/ 3363 }; 3364 /******/ 3365 }(); 3366 /******/ 3367 /******/ /* webpack/runtime/define property getters */ 3368 /******/ 3369 !function () { 3370 /******/ // define getter functions for harmony exports 3371 /******/__webpack_require__.d = function (exports, definition) { 3372 /******/for (var key in definition) { 3373 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 3374 /******/Object.defineProperty(exports, key, { 3375 enumerable: true, 3376 get: definition[key] 3377 }); 3378 /******/ 3379 } 3380 /******/ 3381 } 3382 /******/ 3383 }; 3384 /******/ 3385 }(); 3386 /******/ 3387 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 3388 /******/ 3389 !function () { 3390 /******/__webpack_require__.o = function (obj, prop) { 3391 return Object.prototype.hasOwnProperty.call(obj, prop); 3392 }; 3393 /******/ 3394 }(); 3395 /******/ 3396 /******/ /* webpack/runtime/make namespace object */ 3397 /******/ 3398 !function () { 3399 /******/ // define __esModule on exports 3400 /******/__webpack_require__.r = function (exports) { 3401 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 3402 /******/Object.defineProperty(exports, Symbol.toStringTag, { 3403 value: 'Module' 3404 }); 3405 /******/ 3406 } 3407 /******/ 3408 Object.defineProperty(exports, '__esModule', { 3409 value: true 3410 }); 3411 /******/ 3412 }; 3413 /******/ 3414 }(); 3415 /******/ 3416 /************************************************************************/ 3417 var __webpack_exports__ = {}; 3418 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 3419 !function () { 3420 /*!*****************************************************!*\ 3421 !*** ./js/entries/plugins/foundation.util.timer.js ***! 3422 \*****************************************************/ 3423 __webpack_require__.r(__webpack_exports__); 3424 /* harmony export */ 3425 __webpack_require__.d(__webpack_exports__, { 3426 /* harmony export */Foundation: function () { 3427 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 3428 }, 3429 /* harmony export */Timer: function () { 3430 return /* reexport safe */_foundation_util_timer__WEBPACK_IMPORTED_MODULE_1__.Timer; 3431 } 3432 /* harmony export */ 3433 }); 3434 /* harmony import */ 3435 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 3436 /* harmony import */ 3437 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 3438 /* harmony import */ 3439 var _foundation_util_timer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.timer */"./js/foundation.util.timer.js"); 3440 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.Timer = _foundation_util_timer__WEBPACK_IMPORTED_MODULE_1__.Timer; 3441 }(); 3442 /******/ 3443 return __webpack_exports__; 3444 /******/ 3445 }(); 3446}); 3447(function webpackUniversalModuleDefinition(root, factory) { 3448 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("jquery"), require("./foundation.core"));else if (typeof define === 'function' && define.amd) define(["jquery", "./foundation.core"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("jquery"), require("./foundation.core"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.touch"] = factory(root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.core"]); 3449})(self, function (__WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_core__) { 3450 return /******/function () { 3451 // webpackBootstrap 3452 /******/ 3453 "use strict"; 3454 3455 /******/ 3456 var __webpack_modules__ = { 3457
vendor: 4,934 bytes, lines 3457-3567
3457/***/"./js/foundation.util.touch.js": ( 3458 /*!*************************************!*\ 3459 !*** ./js/foundation.util.touch.js ***! 3460 \*************************************/ 3461 /***/ 3462 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 3463 __webpack_require__.r(__webpack_exports__); 3464 /* harmony export */ 3465 __webpack_require__.d(__webpack_exports__, { 3466 /* harmony export */Touch: function () { 3467 return /* binding */Touch; 3468 } 3469 /* harmony export */ 3470 }); 3471 /* harmony import */ 3472 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 3473 /* harmony import */ 3474 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 3475 function _typeof(o) { 3476 "@babel/helpers - typeof"; 3477 3478 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 3479 return typeof o; 3480 } : function (o) { 3481 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 3482 }, _typeof(o); 3483 } 3484 function _classCallCheck(a, n) { 3485 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 3486 } 3487 function _defineProperties(e, r) { 3488 for (var t = 0; t < r.length; t++) { 3489 var o = r[t]; 3490 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 3491 } 3492 } 3493 function _createClass(e, r, t) { 3494 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 3495 writable: !1 3496 }), e; 3497 } 3498 function _toPropertyKey(t) { 3499 var i = _toPrimitive(t, "string"); 3500 return "symbol" == _typeof(i) ? i : i + ""; 3501 } 3502 function _toPrimitive(t, r) { 3503 if ("object" != _typeof(t) || !t) return t; 3504 var e = t[Symbol.toPrimitive]; 3505 if (void 0 !== e) { 3506 var i = e.call(t, r || "default"); 3507 if ("object" != _typeof(i)) return i; 3508 throw new TypeError("@@toPrimitive must return a primitive value."); 3509 } 3510 return ("string" === r ? String : Number)(t); 3511 } 3512 //************************************************** 3513 //**Work inspired by multiple jquery swipe plugins** 3514 //**Done by Yohai Ararat *************************** 3515 //************************************************** 3516 3517 var Touch = {}; 3518 var startPosX, 3519 startTime, 3520 elapsedTime, 3521 startEvent, 3522 isMoving = false, 3523 didMoved = false; 3524 function onTouchEnd(e) { 3525 this.removeEventListener('touchmove', onTouchMove); 3526 this.removeEventListener('touchend', onTouchEnd); 3527 3528 // If the touch did not move, consider it as a "tap" 3529 if (!didMoved) { 3530 var tapEvent = jquery__WEBPACK_IMPORTED_MODULE_0___default().Event('tap', startEvent || e); 3531 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger(tapEvent); 3532 } 3533 startEvent = null; 3534 isMoving = false; 3535 didMoved = false; 3536 } 3537 function onTouchMove(e) { 3538 if (true === jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe.preventDefault) { 3539 e.preventDefault(); 3540 } 3541 if (isMoving) { 3542 var x = e.touches[0].pageX; 3543 // var y = e.touches[0].pageY; 3544 var dx = startPosX - x; 3545 // var dy = startPosY - y; 3546 var dir; 3547 didMoved = true; 3548 elapsedTime = new Date().getTime() - startTime; 3549 if (Math.abs(dx) >= jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe.moveThreshold && elapsedTime <= jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe.timeThreshold) { 3550 dir = dx > 0 ? 'left' : 'right'; 3551 } 3552 // else if(Math.abs(dy) >= $.spotSwipe.moveThreshold && elapsedTime <= $.spotSwipe.timeThreshold) { 3553 // dir = dy > 0 ? 'down' : 'up'; 3554 // } 3555 if (dir) { 3556 e.preventDefault(); 3557 onTouchEnd.apply(this, arguments); 3558 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger(jquery__WEBPACK_IMPORTED_MODULE_0___default().Event('swipe', Object.assign({}, e)), dir).trigger(jquery__WEBPACK_IMPORTED_MODULE_0___default().Event("swipe".concat(dir), Object.assign({}, e))); 3559 } 3560 } 3561 } 3562 function onTouchStart(e) { 3563 if (e.touches.length === 1) { 3564 startPosX = e.touches[0].pageX; 3565 startEvent = e; 3566 isMoving = true; 3567 didMoved = false;
vendor: 7,245 bytes, lines 3568-3733
3568 startTime = new Date().getTime(); 3569 this.addEventListener('touchmove', onTouchMove, { 3570 passive: true === jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe.preventDefault 3571 }); 3572 this.addEventListener('touchend', onTouchEnd, false); 3573 } 3574 } 3575 function init() { 3576 this.addEventListener && this.addEventListener('touchstart', onTouchStart, { 3577 passive: true 3578 }); 3579 } 3580 3581 // function teardown() { 3582 // this.removeEventListener('touchstart', onTouchStart); 3583 // } 3584 var SpotSwipe = /*#__PURE__*/function () { 3585 function SpotSwipe() { 3586 _classCallCheck(this, SpotSwipe); 3587 this.version = '1.0.0'; 3588 this.enabled = 'ontouchstart' in document.documentElement; 3589 this.preventDefault = false; 3590 this.moveThreshold = 75; 3591 this.timeThreshold = 200; 3592 this._init(); 3593 } 3594 return _createClass(SpotSwipe, [{ 3595 key: "_init", 3596 value: function _init() { 3597 jquery__WEBPACK_IMPORTED_MODULE_0___default().event.special.swipe = { 3598 setup: init 3599 }; 3600 jquery__WEBPACK_IMPORTED_MODULE_0___default().event.special.tap = { 3601 setup: init 3602 }; 3603 jquery__WEBPACK_IMPORTED_MODULE_0___default().each(['left', 'up', 'down', 'right'], function () { 3604 jquery__WEBPACK_IMPORTED_MODULE_0___default().event.special["swipe".concat(this)] = { 3605 setup: function setup() { 3606 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).on('swipe', jquery__WEBPACK_IMPORTED_MODULE_0___default().noop); 3607 } 3608 }; 3609 }); 3610 } 3611 }]); 3612 }(); 3613 /**************************************************** 3614 * As far as I can tell, both setupSpotSwipe and * 3615 * setupTouchHandler should be idempotent, * 3616 * because they directly replace functions & * 3617 * values, and do not add event handlers directly. * 3618 ****************************************************/ 3619 Touch.setupSpotSwipe = function () { 3620 jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe = new SpotSwipe(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 3621 }; 3622 3623 /**************************************************** 3624 * Method for adding pseudo drag events to elements * 3625 ***************************************************/ 3626 Touch.setupTouchHandler = function () { 3627 jquery__WEBPACK_IMPORTED_MODULE_0___default().fn.addTouch = function () { 3628 this.each(function (i, el) { 3629 jquery__WEBPACK_IMPORTED_MODULE_0___default()(el).bind('touchstart touchmove touchend touchcancel', function (event) { 3630 //we pass the original event object because the jQuery event 3631 //object is normalized to w3c specs and does not provide the TouchList 3632 handleTouch(event); 3633 }); 3634 }); 3635 var handleTouch = function handleTouch(event) { 3636 var touches = event.changedTouches, 3637 first = touches[0], 3638 eventTypes = { 3639 touchstart: 'mousedown', 3640 touchmove: 'mousemove', 3641 touchend: 'mouseup' 3642 }, 3643 type = eventTypes[event.type], 3644 simulatedEvent; 3645 if ('MouseEvent' in window && typeof window.MouseEvent === 'function') { 3646 simulatedEvent = new window.MouseEvent(type, { 3647 'bubbles': true, 3648 'cancelable': true, 3649 'screenX': first.screenX, 3650 'screenY': first.screenY, 3651 'clientX': first.clientX, 3652 'clientY': first.clientY 3653 }); 3654 } else { 3655 simulatedEvent = document.createEvent('MouseEvent'); 3656 simulatedEvent.initMouseEvent(type, true, true, window, 1, first.screenX, first.screenY, first.clientX, first.clientY, false, false, false, false, 0 /*left*/, null); 3657 } 3658 first.target.dispatchEvent(simulatedEvent); 3659 }; 3660 }; 3661 }; 3662 Touch.init = function () { 3663 if (typeof jquery__WEBPACK_IMPORTED_MODULE_0___default().spotSwipe === 'undefined') { 3664 Touch.setupSpotSwipe(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 3665 Touch.setupTouchHandler(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 3666 } 3667 }; 3668 3669 /***/ 3670 }), 3671 /***/"./foundation.core": ( 3672 /*!****************************************************************************************************************************************************************!*\ 3673 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 3674 \****************************************************************************************************************************************************************/ 3675 /***/ 3676 function (module) { 3677 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 3678 3679 /***/ 3680 }), 3681 /***/"jquery": ( 3682 /*!********************************************************************************************!*\ 3683 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 3684 \********************************************************************************************/ 3685 /***/ 3686 function (module) { 3687 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 3688 3689 /***/ 3690 }) 3691 3692 /******/ 3693 }; 3694 /************************************************************************/ 3695 /******/ // The module cache 3696 /******/ 3697 var __webpack_module_cache__ = {}; 3698 /******/ 3699 /******/ // The require function 3700 /******/ 3701 function __webpack_require__(moduleId) { 3702 /******/ // Check if module is in cache 3703 /******/var cachedModule = __webpack_module_cache__[moduleId]; 3704 /******/ 3705 if (cachedModule !== undefined) { 3706 /******/return cachedModule.exports; 3707 /******/ 3708 } 3709 /******/ // Create a new module (and put it into the cache) 3710 /******/ 3711 var module = __webpack_module_cache__[moduleId] = { 3712 /******/ // no module.id needed 3713 /******/ // no module.loaded needed 3714 /******/exports: {} 3715 /******/ 3716 }; 3717 /******/ 3718 /******/ // Execute the module function 3719 /******/ 3720 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 3721 /******/ 3722 /******/ // Return the exports of the module 3723 /******/ 3724 return module.exports; 3725 /******/ 3726 } 3727 /******/ 3728 /************************************************************************/ 3729 /******/ /* webpack/runtime/compat get default export */ 3730 /******/ 3731 !function () { 3732 /******/ // getDefaultExport function for compatibility with non-harmony modules 3733 /******/__webpack_require__.n = function (module) {
vendor: 4,956 bytes, lines 3734-3845
3734 /******/var getter = module && module.__esModule ? /******/function () { 3735 return module['default']; 3736 } : /******/function () { 3737 return module; 3738 }; 3739 /******/ 3740 __webpack_require__.d(getter, { 3741 a: getter 3742 }); 3743 /******/ 3744 return getter; 3745 /******/ 3746 }; 3747 /******/ 3748 }(); 3749 /******/ 3750 /******/ /* webpack/runtime/define property getters */ 3751 /******/ 3752 !function () { 3753 /******/ // define getter functions for harmony exports 3754 /******/__webpack_require__.d = function (exports, definition) { 3755 /******/for (var key in definition) { 3756 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 3757 /******/Object.defineProperty(exports, key, { 3758 enumerable: true, 3759 get: definition[key] 3760 }); 3761 /******/ 3762 } 3763 /******/ 3764 } 3765 /******/ 3766 }; 3767 /******/ 3768 }(); 3769 /******/ 3770 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 3771 /******/ 3772 !function () { 3773 /******/__webpack_require__.o = function (obj, prop) { 3774 return Object.prototype.hasOwnProperty.call(obj, prop); 3775 }; 3776 /******/ 3777 }(); 3778 /******/ 3779 /******/ /* webpack/runtime/make namespace object */ 3780 /******/ 3781 !function () { 3782 /******/ // define __esModule on exports 3783 /******/__webpack_require__.r = function (exports) { 3784 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 3785 /******/Object.defineProperty(exports, Symbol.toStringTag, { 3786 value: 'Module' 3787 }); 3788 /******/ 3789 } 3790 /******/ 3791 Object.defineProperty(exports, '__esModule', { 3792 value: true 3793 }); 3794 /******/ 3795 }; 3796 /******/ 3797 }(); 3798 /******/ 3799 /************************************************************************/ 3800 var __webpack_exports__ = {}; 3801 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 3802 !function () { 3803 /*!*****************************************************!*\ 3804 !*** ./js/entries/plugins/foundation.util.touch.js ***! 3805 \*****************************************************/ 3806 __webpack_require__.r(__webpack_exports__); 3807 /* harmony export */ 3808 __webpack_require__.d(__webpack_exports__, { 3809 /* harmony export */Foundation: function () { 3810 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_2__.Foundation; 3811 }, 3812 /* harmony export */Touch: function () { 3813 return /* reexport safe */_foundation_util_touch__WEBPACK_IMPORTED_MODULE_1__.Touch; 3814 } 3815 /* harmony export */ 3816 }); 3817 /* harmony import */ 3818 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 3819 /* harmony import */ 3820 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 3821 /* harmony import */ 3822 var _foundation_util_touch__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.util.touch */"./js/foundation.util.touch.js"); 3823 /* harmony import */ 3824 var _foundation_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 3825 /* harmony import */ 3826 var _foundation_core__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_2__); 3827 _foundation_util_touch__WEBPACK_IMPORTED_MODULE_1__.Touch.init(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 3828 window.Foundation.Touch = _foundation_util_touch__WEBPACK_IMPORTED_MODULE_1__.Touch; 3829 }(); 3830 /******/ 3831 return __webpack_exports__; 3832 /******/ 3833 }(); 3834}); 3835(function webpackUniversalModuleDefinition(root, factory) { 3836 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.motion"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.motion"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.motion"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.util.triggers"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.motion"]); 3837})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__) { 3838 return /******/function () { 3839 // webpackBootstrap 3840 /******/ 3841 "use strict"; 3842 3843 /******/ 3844 var __webpack_modules__ = { 3845
vendor: 13,889 bytes, lines 3845-4111
3845/***/"./js/foundation.util.triggers.js": ( 3846 /*!****************************************!*\ 3847 !*** ./js/foundation.util.triggers.js ***! 3848 \****************************************/ 3849 /***/ 3850 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 3851 __webpack_require__.r(__webpack_exports__); 3852 /* harmony export */ 3853 __webpack_require__.d(__webpack_exports__, { 3854 /* harmony export */Triggers: function () { 3855 return /* binding */Triggers; 3856 } 3857 /* harmony export */ 3858 }); 3859 /* harmony import */ 3860 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 3861 /* harmony import */ 3862 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 3863 /* harmony import */ 3864 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 3865 /* harmony import */ 3866 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 3867 /* harmony import */ 3868 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.motion */"./foundation.util.motion"); 3869 /* harmony import */ 3870 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__); 3871 function _typeof(o) { 3872 "@babel/helpers - typeof"; 3873 3874 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 3875 return typeof o; 3876 } : function (o) { 3877 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 3878 }, _typeof(o); 3879 } 3880 var MutationObserver = function () { 3881 var prefixes = ['WebKit', 'Moz', 'O', 'Ms', '']; 3882 for (var i = 0; i < prefixes.length; i++) { 3883 if ("".concat(prefixes[i], "MutationObserver") in window) { 3884 return window["".concat(prefixes[i], "MutationObserver")]; 3885 } 3886 } 3887 return false; 3888 }(); 3889 var triggers = function triggers(el, type) { 3890 el.data(type).split(' ').forEach(function (id) { 3891 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id))[type === 'close' ? 'trigger' : 'triggerHandler']("".concat(type, ".zf.trigger"), [el]); 3892 }); 3893 }; 3894 var Triggers = { 3895 Listeners: { 3896 Basic: {}, 3897 Global: {} 3898 }, 3899 Initializers: {} 3900 }; 3901 Triggers.Listeners.Basic = { 3902 openListener: function openListener() { 3903 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'open'); 3904 }, 3905 closeListener: function closeListener() { 3906 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('close'); 3907 if (id) { 3908 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'close'); 3909 } else { 3910 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('close.zf.trigger'); 3911 } 3912 }, 3913 toggleListener: function toggleListener() { 3914 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle'); 3915 if (id) { 3916 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'toggle'); 3917 } else { 3918 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('toggle.zf.trigger'); 3919 } 3920 }, 3921 closeableListener: function closeableListener(e) { 3922 var animation = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('closable'); 3923 3924 // Only close the first closable element. See https://git.io/zf-7833 3925 e.stopPropagation(); 3926 if (animation !== '') { 3927 _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__.Motion.animateOut(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), animation, function () { 3928 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('closed.zf'); 3929 }); 3930 } else { 3931 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).fadeOut().trigger('closed.zf'); 3932 } 3933 }, 3934 toggleFocusListener: function toggleFocusListener() { 3935 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle-focus'); 3936 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id)).triggerHandler('toggle.zf.trigger', [jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)]); 3937 } 3938 }; 3939 3940 // Elements with [data-open] will reveal a plugin that supports it when clicked. 3941 Triggers.Initializers.addOpenListener = function ($elem) { 3942 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.openListener); 3943 $elem.on('click.zf.trigger', '[data-open]', Triggers.Listeners.Basic.openListener); 3944 }; 3945 3946 // Elements with [data-close] will close a plugin that supports it when clicked. 3947 // If used without a value on [data-close], the event will bubble, allowing it to close a parent component. 3948 Triggers.Initializers.addCloseListener = function ($elem) { 3949 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.closeListener); 3950 $elem.on('click.zf.trigger', '[data-close]', Triggers.Listeners.Basic.closeListener); 3951 }; 3952 3953 // Elements with [data-toggle] will toggle a plugin that supports it when clicked. 3954 Triggers.Initializers.addToggleListener = function ($elem) { 3955 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.toggleListener); 3956 $elem.on('click.zf.trigger', '[data-toggle]', Triggers.Listeners.Basic.toggleListener); 3957 }; 3958 3959 // Elements with [data-closable] will respond to close.zf.trigger events. 3960 Triggers.Initializers.addCloseableListener = function ($elem) { 3961 $elem.off('close.zf.trigger', Triggers.Listeners.Basic.closeableListener); 3962 $elem.on('close.zf.trigger', '[data-closeable], [data-closable]', Triggers.Listeners.Basic.closeableListener); 3963 }; 3964 3965 // Elements with [data-toggle-focus] will respond to coming in and out of focus 3966 Triggers.Initializers.addToggleFocusListener = function ($elem) { 3967 $elem.off('focus.zf.trigger blur.zf.trigger', Triggers.Listeners.Basic.toggleFocusListener); 3968 $elem.on('focus.zf.trigger blur.zf.trigger', '[data-toggle-focus]', Triggers.Listeners.Basic.toggleFocusListener); 3969 }; 3970 3971 // More Global/complex listeners and triggers 3972 Triggers.Listeners.Global = { 3973 resizeListener: function resizeListener($nodes) { 3974 if (!MutationObserver) { 3975 //fallback for IE 9 3976 $nodes.each(function () { 3977 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('resizeme.zf.trigger'); 3978 }); 3979 } 3980 //trigger all listening elements and signal a resize event 3981 $nodes.attr('data-events', "resize"); 3982 }, 3983 scrollListener: function scrollListener($nodes) { 3984 if (!MutationObserver) { 3985 //fallback for IE 9 3986 $nodes.each(function () { 3987 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('scrollme.zf.trigger'); 3988 }); 3989 } 3990 //trigger all listening elements and signal a scroll event 3991 $nodes.attr('data-events', "scroll"); 3992 }, 3993 closeMeListener: function closeMeListener(e, pluginId) { 3994 var plugin = e.namespace.split('.')[0]; 3995 var plugins = jquery__WEBPACK_IMPORTED_MODULE_0___default()("[data-".concat(plugin, "]")).not("[data-yeti-box=\"".concat(pluginId, "\"]")); 3996 plugins.each(function () { 3997 var _this = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this); 3998 _this.triggerHandler('close.zf.trigger', [_this]); 3999 }); 4000 } 4001 }; 4002 4003 // Global, parses whole document. 4004 Triggers.Initializers.addClosemeListener = function (pluginName) { 4005 var yetiBoxes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-yeti-box]'), 4006 plugNames = ['dropdown', 'tooltip', 'reveal']; 4007 if (pluginName) { 4008 if (typeof pluginName === 'string') { 4009 plugNames.push(pluginName); 4010 } else if (_typeof(pluginName) === 'object' && typeof pluginName[0] === 'string') { 4011 plugNames = plugNames.concat(pluginName); 4012 } else { 4013 console.error('Plugin names must be strings'); 4014 } 4015 } 4016 if (yetiBoxes.length) { 4017 var listeners = plugNames.map(function (name) { 4018 return "closeme.zf.".concat(name); 4019 }).join(' '); 4020 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(listeners).on(listeners, Triggers.Listeners.Global.closeMeListener); 4021 } 4022 }; 4023 function debounceGlobalListener(debounce, trigger, listener) { 4024 var timer, 4025 args = Array.prototype.slice.call(arguments, 3); 4026 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on(trigger, function () { 4027 if (timer) { 4028 clearTimeout(timer); 4029 } 4030 timer = setTimeout(function () { 4031 listener.apply(null, args); 4032 }, debounce || 10); //default time to emit scroll event 4033 }); 4034 } 4035 Triggers.Initializers.addResizeListener = function (debounce) { 4036 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-resize]'); 4037 if ($nodes.length) { 4038 debounceGlobalListener(debounce, 'resize.zf.trigger', Triggers.Listeners.Global.resizeListener, $nodes); 4039 } 4040 }; 4041 Triggers.Initializers.addScrollListener = function (debounce) { 4042 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-scroll]'); 4043 if ($nodes.length) { 4044 debounceGlobalListener(debounce, 'scroll.zf.trigger', Triggers.Listeners.Global.scrollListener, $nodes); 4045 } 4046 }; 4047 Triggers.Initializers.addMutationEventsListener = function ($elem) { 4048 if (!MutationObserver) { 4049 return false; 4050 } 4051 var $nodes = $elem.find('[data-resize], [data-scroll], [data-mutate]'); 4052 4053 //element callback 4054 var listeningElementsMutation = function listeningElementsMutation(mutationRecordsList) { 4055 var $target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(mutationRecordsList[0].target); 4056 4057 //trigger the event handler for the element depending on type 4058 switch (mutationRecordsList[0].type) { 4059 case "attributes": 4060 if ($target.attr("data-events") === "scroll" && mutationRecordsList[0].attributeName === "data-events") { 4061 $target.triggerHandler('scrollme.zf.trigger', [$target, window.pageYOffset]); 4062 } 4063 if ($target.attr("data-events") === "resize" && mutationRecordsList[0].attributeName === "data-events") { 4064 $target.triggerHandler('resizeme.zf.trigger', [$target]); 4065 } 4066 if (mutationRecordsList[0].attributeName === "style") { 4067 $target.closest("[data-mutate]").attr("data-events", "mutate"); 4068 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 4069 } 4070 break; 4071 case "childList": 4072 $target.closest("[data-mutate]").attr("data-events", "mutate"); 4073 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 4074 break; 4075 default: 4076 return false; 4077 //nothing 4078 } 4079 }; 4080 if ($nodes.length) { 4081 //for each element that needs to listen for resizing, scrolling, or mutation add a single observer 4082 for (var i = 0; i <= $nodes.length - 1; i++) { 4083 var elementObserver = new MutationObserver(listeningElementsMutation); 4084 elementObserver.observe($nodes[i], { 4085 attributes: true, 4086 childList: true, 4087 characterData: false, 4088 subtree: true, 4089 attributeFilter: ["data-events", "style"] 4090 }); 4091 } 4092 } 4093 }; 4094 Triggers.Initializers.addSimpleListeners = function () { 4095 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 4096 Triggers.Initializers.addOpenListener($document); 4097 Triggers.Initializers.addCloseListener($document); 4098 Triggers.Initializers.addToggleListener($document); 4099 Triggers.Initializers.addCloseableListener($document); 4100 Triggers.Initializers.addToggleFocusListener($document); 4101 }; 4102 Triggers.Initializers.addGlobalListeners = function () { 4103 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 4104 Triggers.Initializers.addMutationEventsListener($document); 4105 Triggers.Initializers.addResizeListener(250); 4106 Triggers.Initializers.addScrollListener(); 4107 Triggers.Initializers.addClosemeListener(); 4108 }; 4109 Triggers.init = function (__, Foundation) { 4110 (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 4111 if (jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized !== true) {
vendor: 8,581 bytes, lines 4112-4309
4112 Triggers.Initializers.addSimpleListeners(); 4113 Triggers.Initializers.addGlobalListeners(); 4114 jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized = true; 4115 } 4116 }); 4117 if (Foundation) { 4118 Foundation.Triggers = Triggers; 4119 // Legacy included to be backwards compatible for now. 4120 Foundation.IHearYou = Triggers.Initializers.addGlobalListeners; 4121 } 4122 }; 4123 4124 /***/ 4125 }), 4126 /***/"./foundation.core": ( 4127 /*!****************************************************************************************************************************************************************!*\ 4128 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 4129 \****************************************************************************************************************************************************************/ 4130 /***/ 4131 function (module) { 4132 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 4133 4134 /***/ 4135 }), 4136 /***/"./foundation.util.motion": ( 4137 /*!********************************************************************************************************************************************************************************************!*\ 4138 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.motion"],"amd":"./foundation.util.motion","commonjs":"./foundation.util.motion","commonjs2":"./foundation.util.motion"} ***! 4139 \********************************************************************************************************************************************************************************************/ 4140 /***/ 4141 function (module) { 4142 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__; 4143 4144 /***/ 4145 }), 4146 /***/"jquery": ( 4147 /*!********************************************************************************************!*\ 4148 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 4149 \********************************************************************************************/ 4150 /***/ 4151 function (module) { 4152 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 4153 4154 /***/ 4155 }) 4156 4157 /******/ 4158 }; 4159 /************************************************************************/ 4160 /******/ // The module cache 4161 /******/ 4162 var __webpack_module_cache__ = {}; 4163 /******/ 4164 /******/ // The require function 4165 /******/ 4166 function __webpack_require__(moduleId) { 4167 /******/ // Check if module is in cache 4168 /******/var cachedModule = __webpack_module_cache__[moduleId]; 4169 /******/ 4170 if (cachedModule !== undefined) { 4171 /******/return cachedModule.exports; 4172 /******/ 4173 } 4174 /******/ // Create a new module (and put it into the cache) 4175 /******/ 4176 var module = __webpack_module_cache__[moduleId] = { 4177 /******/ // no module.id needed 4178 /******/ // no module.loaded needed 4179 /******/exports: {} 4180 /******/ 4181 }; 4182 /******/ 4183 /******/ // Execute the module function 4184 /******/ 4185 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 4186 /******/ 4187 /******/ // Return the exports of the module 4188 /******/ 4189 return module.exports; 4190 /******/ 4191 } 4192 /******/ 4193 /************************************************************************/ 4194 /******/ /* webpack/runtime/compat get default export */ 4195 /******/ 4196 !function () { 4197 /******/ // getDefaultExport function for compatibility with non-harmony modules 4198 /******/__webpack_require__.n = function (module) { 4199 /******/var getter = module && module.__esModule ? /******/function () { 4200 return module['default']; 4201 } : /******/function () { 4202 return module; 4203 }; 4204 /******/ 4205 __webpack_require__.d(getter, { 4206 a: getter 4207 }); 4208 /******/ 4209 return getter; 4210 /******/ 4211 }; 4212 /******/ 4213 }(); 4214 /******/ 4215 /******/ /* webpack/runtime/define property getters */ 4216 /******/ 4217 !function () { 4218 /******/ // define getter functions for harmony exports 4219 /******/__webpack_require__.d = function (exports, definition) { 4220 /******/for (var key in definition) { 4221 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 4222 /******/Object.defineProperty(exports, key, { 4223 enumerable: true, 4224 get: definition[key] 4225 }); 4226 /******/ 4227 } 4228 /******/ 4229 } 4230 /******/ 4231 }; 4232 /******/ 4233 }(); 4234 /******/ 4235 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 4236 /******/ 4237 !function () { 4238 /******/__webpack_require__.o = function (obj, prop) { 4239 return Object.prototype.hasOwnProperty.call(obj, prop); 4240 }; 4241 /******/ 4242 }(); 4243 /******/ 4244 /******/ /* webpack/runtime/make namespace object */ 4245 /******/ 4246 !function () { 4247 /******/ // define __esModule on exports 4248 /******/__webpack_require__.r = function (exports) { 4249 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 4250 /******/Object.defineProperty(exports, Symbol.toStringTag, { 4251 value: 'Module' 4252 }); 4253 /******/ 4254 } 4255 /******/ 4256 Object.defineProperty(exports, '__esModule', { 4257 value: true 4258 }); 4259 /******/ 4260 }; 4261 /******/ 4262 }(); 4263 /******/ 4264 /************************************************************************/ 4265 var __webpack_exports__ = {}; 4266 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 4267 !function () { 4268 /*!********************************************************!*\ 4269 !*** ./js/entries/plugins/foundation.util.triggers.js ***! 4270 \********************************************************/ 4271 __webpack_require__.r(__webpack_exports__); 4272 /* harmony export */ 4273 __webpack_require__.d(__webpack_exports__, { 4274 /* harmony export */Foundation: function () { 4275 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 4276 }, 4277 /* harmony export */Triggers: function () { 4278 return /* reexport safe */_foundation_util_triggers__WEBPACK_IMPORTED_MODULE_2__.Triggers; 4279 } 4280 /* harmony export */ 4281 }); 4282 /* harmony import */ 4283 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 4284 /* harmony import */ 4285 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 4286 /* harmony import */ 4287 var jquery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! jquery */"jquery"); 4288 /* harmony import */ 4289 var jquery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_1__); 4290 /* harmony import */ 4291 var _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../foundation.util.triggers */"./js/foundation.util.triggers.js"); 4292 _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_2__.Triggers.init(jquery__WEBPACK_IMPORTED_MODULE_1___default(), _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation); 4293 }(); 4294 /******/ 4295 return __webpack_exports__; 4296 /******/ 4297 }(); 4298}); 4299(function webpackUniversalModuleDefinition(root, factory) { 4300 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.abide"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"]); 4301})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__) { 4302 return /******/function () { 4303 // webpackBootstrap 4304 /******/ 4305 "use strict"; 4306 4307 /******/ 4308 var __webpack_modules__ = { 4309
vendor: 9,624 bytes, lines 4309-4526
4309/***/"./js/foundation.abide.js": ( 4310 /*!********************************!*\ 4311 !*** ./js/foundation.abide.js ***! 4312 \********************************/ 4313 /***/ 4314 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 4315 __webpack_require__.r(__webpack_exports__); 4316 /* harmony export */ 4317 __webpack_require__.d(__webpack_exports__, { 4318 /* harmony export */Abide: function () { 4319 return /* binding */Abide; 4320 } 4321 /* harmony export */ 4322 }); 4323 /* harmony import */ 4324 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 4325 /* harmony import */ 4326 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 4327 /* harmony import */ 4328 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 4329 /* harmony import */ 4330 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 4331 function _typeof(o) { 4332 "@babel/helpers - typeof"; 4333 4334 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 4335 return typeof o; 4336 } : function (o) { 4337 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 4338 }, _typeof(o); 4339 } 4340 function _classCallCheck(a, n) { 4341 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 4342 } 4343 function _defineProperties(e, r) { 4344 for (var t = 0; t < r.length; t++) { 4345 var o = r[t]; 4346 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 4347 } 4348 } 4349 function _createClass(e, r, t) { 4350 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 4351 writable: !1 4352 }), e; 4353 } 4354 function _toPropertyKey(t) { 4355 var i = _toPrimitive(t, "string"); 4356 return "symbol" == _typeof(i) ? i : i + ""; 4357 } 4358 function _toPrimitive(t, r) { 4359 if ("object" != _typeof(t) || !t) return t; 4360 var e = t[Symbol.toPrimitive]; 4361 if (void 0 !== e) { 4362 var i = e.call(t, r || "default"); 4363 if ("object" != _typeof(i)) return i; 4364 throw new TypeError("@@toPrimitive must return a primitive value."); 4365 } 4366 return ("string" === r ? String : Number)(t); 4367 } 4368 function _callSuper(t, o, e) { 4369 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 4370 } 4371 function _possibleConstructorReturn(t, e) { 4372 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 4373 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 4374 return _assertThisInitialized(t); 4375 } 4376 function _assertThisInitialized(e) { 4377 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 4378 return e; 4379 } 4380 function _isNativeReflectConstruct() { 4381 try { 4382 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 4383 } catch (t) {} 4384 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 4385 return !!t; 4386 })(); 4387 } 4388 function _getPrototypeOf(t) { 4389 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 4390 return t.__proto__ || Object.getPrototypeOf(t); 4391 }, _getPrototypeOf(t); 4392 } 4393 function _inherits(t, e) { 4394 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 4395 t.prototype = Object.create(e && e.prototype, { 4396 constructor: { 4397 value: t, 4398 writable: !0, 4399 configurable: !0 4400 } 4401 }), Object.defineProperty(t, "prototype", { 4402 writable: !1 4403 }), e && _setPrototypeOf(t, e); 4404 } 4405 function _setPrototypeOf(t, e) { 4406 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 4407 return t.__proto__ = e, t; 4408 }, _setPrototypeOf(t, e); 4409 } 4410 4411 /** 4412 * Abide module. 4413 * @module foundation.abide 4414 */ 4415 var Abide = /*#__PURE__*/function (_Plugin) { 4416 function Abide() { 4417 _classCallCheck(this, Abide); 4418 return _callSuper(this, Abide, arguments); 4419 } 4420 _inherits(Abide, _Plugin); 4421 return _createClass(Abide, [{ 4422 key: "_setup", 4423 value: 4424 /** 4425 * Creates a new instance of Abide. 4426 * @class 4427 * @name Abide 4428 * @fires Abide#init 4429 * @param {Object} element - jQuery object to add the trigger to. 4430 * @param {Object} options - Overrides to the default plugin settings. 4431 */ 4432 function _setup(element) { 4433 var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; 4434 this.$element = element; 4435 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(true, {}, Abide.defaults, this.$element.data(), options); 4436 this.isEnabled = true; 4437 this.formnovalidate = null; 4438 this.className = 'Abide'; // ie9 back compat 4439 this._init(); 4440 } 4441 4442 /** 4443 * Initializes the Abide plugin and calls functions to get Abide functioning on load. 4444 * @private 4445 */ 4446 }, { 4447 key: "_init", 4448 value: function _init() { 4449 var _this2 = this; 4450 this.$inputs = jquery__WEBPACK_IMPORTED_MODULE_0___default().merge( 4451 // Consider as input to validate: 4452 this.$element.find('input').not('[type="submit"]'), 4453 // * all input fields expect submit 4454 this.$element.find('textarea, select') // * all textareas and select fields 4455 ); 4456 this.$submits = this.$element.find('[type="submit"]'); 4457 var $globalErrors = this.$element.find('[data-abide-error]'); 4458 4459 // Add a11y attributes to all fields 4460 if (this.options.a11yAttributes) { 4461 this.$inputs.each(function (i, input) { 4462 return _this2.addA11yAttributes(jquery__WEBPACK_IMPORTED_MODULE_0___default()(input)); 4463 }); 4464 $globalErrors.each(function (i, error) { 4465 return _this2.addGlobalErrorA11yAttributes(jquery__WEBPACK_IMPORTED_MODULE_0___default()(error)); 4466 }); 4467 } 4468 this._events(); 4469 } 4470 4471 /** 4472 * Initializes events for Abide. 4473 * @private 4474 */ 4475 }, { 4476 key: "_events", 4477 value: function _events() { 4478 var _this3 = this; 4479 this.$element.off('.abide').on('reset.zf.abide', function () { 4480 _this3.resetForm(); 4481 }).on('submit.zf.abide', function () { 4482 return _this3.validateForm(); 4483 }); 4484 this.$submits.off('click.zf.abide keydown.zf.abide').on('click.zf.abide keydown.zf.abide', function (e) { 4485 if (!e.key || e.key === ' ' || e.key === 'Enter') { 4486 e.preventDefault(); 4487 _this3.formnovalidate = e.target.getAttribute('formnovalidate') !== null; 4488 _this3.$element.submit(); 4489 } 4490 }); 4491 if (this.options.validateOn === 'fieldChange') { 4492 this.$inputs.off('change.zf.abide').on('change.zf.abide', function (e) { 4493 _this3.validateInput(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target)); 4494 }); 4495 } 4496 if (this.options.liveValidate) { 4497 this.$inputs.off('input.zf.abide').on('input.zf.abide', function (e) { 4498 _this3.validateInput(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target)); 4499 }); 4500 } 4501 if (this.options.validateOnBlur) { 4502 this.$inputs.off('blur.zf.abide').on('blur.zf.abide', function (e) { 4503 _this3.validateInput(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target)); 4504 }); 4505 } 4506 } 4507 4508 /** 4509 * Calls necessary functions to update Abide upon DOM change 4510 * @private 4511 */ 4512 }, { 4513 key: "_reflow", 4514 value: function _reflow() { 4515 this._init(); 4516 } 4517 4518 /** 4519 * Checks whether the submitted form should be validated or not, consodering formnovalidate and isEnabled 4520 * @returns {Boolean} 4521 * @private 4522 */ 4523 }, { 4524 key: "_validationIsDisabled", 4525 value: function _validationIsDisabled() { 4526 if (this.isEnabled === false) {
vendor: 4,925 bytes, lines 4527-4643
4527 // whole validation disabled 4528 return true; 4529 } else if (typeof this.formnovalidate === 'boolean') { 4530 // triggered by $submit 4531 return this.formnovalidate; 4532 } 4533 // triggered by Enter in non-submit input 4534 return this.$submits.length ? this.$submits[0].getAttribute('formnovalidate') !== null : false; 4535 } 4536 4537 /** 4538 * Enables the whole validation 4539 */ 4540 }, { 4541 key: "enableValidation", 4542 value: function enableValidation() { 4543 this.isEnabled = true; 4544 } 4545 4546 /** 4547 * Disables the whole validation 4548 */ 4549 }, { 4550 key: "disableValidation", 4551 value: function disableValidation() { 4552 this.isEnabled = false; 4553 } 4554 4555 /** 4556 * Checks whether or not a form element has the required attribute and if it's checked or not 4557 * @param {Object} element - jQuery object to check for required attribute 4558 * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty 4559 */ 4560 }, { 4561 key: "requiredCheck", 4562 value: function requiredCheck($el) { 4563 if (!$el.attr('required')) return true; 4564 var isGood = true; 4565 switch ($el[0].type) { 4566 case 'checkbox': 4567 isGood = $el[0].checked; 4568 break; 4569 case 'select': 4570 case 'select-one': 4571 case 'select-multiple': 4572 var opt = $el.find('option:selected'); 4573 if (!opt.length || !opt.val()) isGood = false; 4574 break; 4575 default: 4576 if (!$el.val() || !$el.val().length) isGood = false; 4577 } 4578 return isGood; 4579 } 4580 4581 /** 4582 * Get: 4583 * - Based on $el, the first element(s) corresponding to `formErrorSelector` in this order: 4584 * 1. The element's direct sibling('s). 4585 * 2. The element's parent's children. 4586 * - Element(s) with the attribute `[data-form-error-for]` set with the element's id. 4587 * 4588 * This allows for multiple form errors per input, though if none are found, no form errors will be shown. 4589 * 4590 * @param {Object} $el - jQuery object to use as reference to find the form error selector. 4591 * @param {String[]} [failedValidators] - List of failed validators. 4592 * @returns {Object} jQuery object with the selector. 4593 */ 4594 }, { 4595 key: "findFormError", 4596 value: function findFormError($el, failedValidators) { 4597 var _this4 = this; 4598 var id = $el.length ? $el[0].id : ''; 4599 var $error = $el.siblings(this.options.formErrorSelector); 4600 if (!$error.length) { 4601 $error = $el.parent().find(this.options.formErrorSelector); 4602 } 4603 if (id) { 4604 $error = $error.add(this.$element.find("[data-form-error-for=\"".concat(id, "\"]"))); 4605 } 4606 if (!!failedValidators) { 4607 $error = $error.not('[data-form-error-on]'); 4608 failedValidators.forEach(function (v) { 4609 $error = $error.add($el.siblings("[data-form-error-on=\"".concat(v, "\"]"))); 4610 $error = $error.add(_this4.$element.find("[data-form-error-for=\"".concat(id, "\"][data-form-error-on=\"").concat(v, "\"]"))); 4611 }); 4612 } 4613 return $error; 4614 } 4615 4616 /** 4617 * Get the first element in this order: 4618 * 2. The <label> with the attribute `[for="someInputId"]` 4619 * 3. The `.closest()` <label> 4620 * 4621 * @param {Object} $el - jQuery object to check for required attribute 4622 * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty 4623 */ 4624 }, { 4625 key: "findLabel", 4626 value: function findLabel($el) { 4627 var id = $el[0].id; 4628 var $label = this.$element.find("label[for=\"".concat(id, "\"]")); 4629 if (!$label.length) { 4630 return $el.closest('label'); 4631 } 4632 return $label; 4633 } 4634 4635 /** 4636 * Get the set of labels associated with a set of radio els in this order 4637 * 2. The <label> with the attribute `[for="someInputId"]` 4638 * 3. The `.closest()` <label> 4639 * 4640 * @param {Object} $el - jQuery object to check for required attribute 4641 * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty 4642 */ 4643 }, {
vendor: 28,507 bytes, lines 4644-5246
4644 key: "findRadioLabels", 4645 value: function findRadioLabels($els) { 4646 var _this5 = this; 4647 var labels = $els.map(function (i, el) { 4648 var id = el.id; 4649 var $label = _this5.$element.find("label[for=\"".concat(id, "\"]")); 4650 if (!$label.length) { 4651 $label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(el).closest('label'); 4652 } 4653 return $label[0]; 4654 }); 4655 return jquery__WEBPACK_IMPORTED_MODULE_0___default()(labels); 4656 } 4657 4658 /** 4659 * Get the set of labels associated with a set of checkbox els in this order 4660 * 2. The <label> with the attribute `[for="someInputId"]` 4661 * 3. The `.closest()` <label> 4662 * 4663 * @param {Object} $el - jQuery object to check for required attribute 4664 * @returns {Boolean} Boolean value depends on whether or not attribute is checked or empty 4665 */ 4666 }, { 4667 key: "findCheckboxLabels", 4668 value: function findCheckboxLabels($els) { 4669 var _this6 = this; 4670 var labels = $els.map(function (i, el) { 4671 var id = el.id; 4672 var $label = _this6.$element.find("label[for=\"".concat(id, "\"]")); 4673 if (!$label.length) { 4674 $label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(el).closest('label'); 4675 } 4676 return $label[0]; 4677 }); 4678 return jquery__WEBPACK_IMPORTED_MODULE_0___default()(labels); 4679 } 4680 4681 /** 4682 * Adds the CSS error class as specified by the Abide settings to the label, input, and the form 4683 * @param {Object} $el - jQuery object to add the class to 4684 * @param {String[]} [failedValidators] - List of failed validators. 4685 */ 4686 }, { 4687 key: "addErrorClasses", 4688 value: function addErrorClasses($el, failedValidators) { 4689 var $label = this.findLabel($el); 4690 var $formError = this.findFormError($el, failedValidators); 4691 if ($label.length) { 4692 $label.addClass(this.options.labelErrorClass); 4693 } 4694 if ($formError.length) { 4695 $formError.addClass(this.options.formErrorClass); 4696 } 4697 $el.addClass(this.options.inputErrorClass).attr({ 4698 'data-invalid': '', 4699 'aria-invalid': true 4700 }); 4701 if ($formError.filter(':visible').length) { 4702 this.addA11yErrorDescribe($el, $formError); 4703 } 4704 } 4705 4706 /** 4707 * Adds [for] and [role=alert] attributes to all form error targetting $el, 4708 * and [aria-describedby] attribute to $el toward the first form error. 4709 * @param {Object} $el - jQuery object 4710 */ 4711 }, { 4712 key: "addA11yAttributes", 4713 value: function addA11yAttributes($el) { 4714 var $errors = this.findFormError($el); 4715 var $labels = $errors.filter('label'); 4716 if (!$errors.length) return; 4717 var $error = $errors.filter(':visible').first(); 4718 if ($error.length) { 4719 this.addA11yErrorDescribe($el, $error); 4720 } 4721 if ($labels.filter('[for]').length < $labels.length) { 4722 // Get the input ID or create one 4723 var elemId = $el.attr('id'); 4724 if (typeof elemId === 'undefined') { 4725 elemId = (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.GetYoDigits)(6, 'abide-input'); 4726 $el.attr('id', elemId); 4727 } 4728 4729 // For each label targeting $el, set [for] if it is not set. 4730 $labels.each(function (i, label) { 4731 var $label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(label); 4732 if (typeof $label.attr('for') === 'undefined') $label.attr('for', elemId); 4733 }); 4734 } 4735 4736 // For each error targeting $el, set [role=alert] if it is not set. 4737 $errors.each(function (i, label) { 4738 var $label = jquery__WEBPACK_IMPORTED_MODULE_0___default()(label); 4739 if (typeof $label.attr('role') === 'undefined') $label.attr('role', 'alert'); 4740 }).end(); 4741 } 4742 }, { 4743 key: "addA11yErrorDescribe", 4744 value: function addA11yErrorDescribe($el, $error) { 4745 if ($el.attr('type') === 'hidden') return; 4746 if (typeof $el.attr('aria-describedby') !== 'undefined') return; 4747 4748 // Set [aria-describedby] on the input toward the first form error if it is not set 4749 // Get the first error ID or create one 4750 var errorId = $error.attr('id'); 4751 if (typeof errorId === 'undefined') { 4752 errorId = (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.GetYoDigits)(6, 'abide-error'); 4753 $error.attr('id', errorId); 4754 } 4755 $el.attr('aria-describedby', errorId).data('abide-describedby', true); 4756 } 4757 4758 /** 4759 * Adds [aria-live] attribute to the given global form error $el. 4760 * @param {Object} $el - jQuery object to add the attribute to 4761 */ 4762 }, { 4763 key: "addGlobalErrorA11yAttributes", 4764 value: function addGlobalErrorA11yAttributes($el) { 4765 if (typeof $el.attr('aria-live') === 'undefined') $el.attr('aria-live', this.options.a11yErrorLevel); 4766 } 4767 4768 /** 4769 * Remove CSS error classes etc from an entire radio button group 4770 * @param {String} groupName - A string that specifies the name of a radio button group 4771 * 4772 */ 4773 }, { 4774 key: "removeRadioErrorClasses", 4775 value: function removeRadioErrorClasses(groupName) { 4776 var $els = this.$element.find(":radio[name=\"".concat(groupName, "\"]")); 4777 var $labels = this.findRadioLabels($els); 4778 var $formErrors = this.findFormError($els); 4779 if ($labels.length) { 4780 $labels.removeClass(this.options.labelErrorClass); 4781 } 4782 if ($formErrors.length) { 4783 $formErrors.removeClass(this.options.formErrorClass); 4784 } 4785 $els.removeClass(this.options.inputErrorClass).attr({ 4786 'data-invalid': null, 4787 'aria-invalid': null 4788 }); 4789 } 4790 4791 /** 4792 * Remove CSS error classes etc from an entire checkbox group 4793 * @param {String} groupName - A string that specifies the name of a checkbox group 4794 * 4795 */ 4796 }, { 4797 key: "removeCheckboxErrorClasses", 4798 value: function removeCheckboxErrorClasses(groupName) { 4799 var $els = this.$element.find(":checkbox[name=\"".concat(groupName, "\"]")); 4800 var $labels = this.findCheckboxLabels($els); 4801 var $formErrors = this.findFormError($els); 4802 if ($labels.length) { 4803 $labels.removeClass(this.options.labelErrorClass); 4804 } 4805 if ($formErrors.length) { 4806 $formErrors.removeClass(this.options.formErrorClass); 4807 } 4808 $els.removeClass(this.options.inputErrorClass).attr({ 4809 'data-invalid': null, 4810 'aria-invalid': null 4811 }); 4812 } 4813 4814 /** 4815 * Removes CSS error class as specified by the Abide settings from the label, input, and the form 4816 * @param {Object} $el - jQuery object to remove the class from 4817 */ 4818 }, { 4819 key: "removeErrorClasses", 4820 value: function removeErrorClasses($el) { 4821 // radios need to clear all of the els 4822 if ($el[0].type === 'radio') { 4823 return this.removeRadioErrorClasses($el.attr('name')); 4824 } 4825 // checkboxes need to clear all of the els 4826 else if ($el[0].type === 'checkbox') { 4827 return this.removeCheckboxErrorClasses($el.attr('name')); 4828 } 4829 var $label = this.findLabel($el); 4830 var $formError = this.findFormError($el); 4831 if ($label.length) { 4832 $label.removeClass(this.options.labelErrorClass); 4833 } 4834 if ($formError.length) { 4835 $formError.removeClass(this.options.formErrorClass); 4836 } 4837 $el.removeClass(this.options.inputErrorClass).attr({ 4838 'data-invalid': null, 4839 'aria-invalid': null 4840 }); 4841 if ($el.data('abide-describedby')) { 4842 $el.removeAttr('aria-describedby').removeData('abide-describedby'); 4843 } 4844 } 4845 4846 /** 4847 * Goes through a form to find inputs and proceeds to validate them in ways specific to their type. 4848 * Ignores inputs with data-abide-ignore, type="hidden" or disabled attributes set 4849 * @fires Abide#invalid 4850 * @fires Abide#valid 4851 * @param {Object} element - jQuery object to validate, should be an HTML input 4852 * @returns {Boolean} goodToGo - If the input is valid or not. 4853 */ 4854 }, { 4855 key: "validateInput", 4856 value: function validateInput($el) { 4857 var _this7 = this; 4858 var clearRequire = this.requiredCheck($el), 4859 validator = $el.attr('data-validator'), 4860 failedValidators = [], 4861 manageErrorClasses = true; 4862 4863 // skip validation if disabled 4864 if (this._validationIsDisabled()) { 4865 return true; 4866 } 4867 4868 // don't validate ignored inputs or hidden inputs or disabled inputs 4869 if ($el.is('[data-abide-ignore]') || $el.is('[type="hidden"]') || $el.is('[disabled]')) { 4870 return true; 4871 } 4872 switch ($el[0].type) { 4873 case 'radio': 4874 this.validateRadio($el.attr('name')) || failedValidators.push('required'); 4875 break; 4876 case 'checkbox': 4877 this.validateCheckbox($el.attr('name')) || failedValidators.push('required'); 4878 // validateCheckbox() adds/removes error classes 4879 manageErrorClasses = false; 4880 break; 4881 case 'select': 4882 case 'select-one': 4883 case 'select-multiple': 4884 clearRequire || failedValidators.push('required'); 4885 break; 4886 default: 4887 clearRequire || failedValidators.push('required'); 4888 this.validateText($el) || failedValidators.push('pattern'); 4889 } 4890 if (validator) { 4891 var required = $el.attr('required') ? true : false; 4892 validator.split(' ').forEach(function (v) { 4893 _this7.options.validators[v]($el, required, $el.parent()) || failedValidators.push(v); 4894 }); 4895 } 4896 if ($el.attr('data-equalto')) { 4897 this.options.validators.equalTo($el) || failedValidators.push('equalTo'); 4898 } 4899 var goodToGo = failedValidators.length === 0; 4900 var message = (goodToGo ? 'valid' : 'invalid') + '.zf.abide'; 4901 if (goodToGo) { 4902 // Re-validate inputs that depend on this one with equalto 4903 var dependentElements = this.$element.find("[data-equalto=\"".concat($el.attr('id'), "\"]")); 4904 if (dependentElements.length) { 4905 var _this = this; 4906 dependentElements.each(function () { 4907 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).val()) { 4908 _this.validateInput(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)); 4909 } 4910 }); 4911 } 4912 } 4913 if (manageErrorClasses) { 4914 this.removeErrorClasses($el); 4915 if (!goodToGo) { 4916 this.addErrorClasses($el, failedValidators); 4917 } 4918 } 4919 4920 /** 4921 * Fires when the input is done checking for validation. Event trigger is either `valid.zf.abide` or `invalid.zf.abide` 4922 * Trigger includes the DOM element of the input. 4923 * @event Abide#valid 4924 * @event Abide#invalid 4925 */ 4926 $el.trigger(message, [$el]); 4927 return goodToGo; 4928 } 4929 4930 /** 4931 * Goes through a form and if there are any invalid inputs, it will display the form error element 4932 * @returns {Boolean} noError - true if no errors were detected... 4933 * @fires Abide#formvalid 4934 * @fires Abide#forminvalid 4935 */ 4936 }, { 4937 key: "validateForm", 4938 value: function validateForm() { 4939 var _this8 = this; 4940 var acc = []; 4941 var _this = this; 4942 var checkboxGroupName; 4943 4944 // Remember first form submission to prevent specific checkbox validation (more than one required) until form got initially submitted 4945 if (!this.initialized) { 4946 this.initialized = true; 4947 } 4948 4949 // skip validation if disabled 4950 if (this._validationIsDisabled()) { 4951 this.formnovalidate = null; 4952 return true; 4953 } 4954 this.$inputs.each(function () { 4955 // Only use one checkbox per group since validateCheckbox() iterates over all associated checkboxes 4956 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)[0].type === 'checkbox') { 4957 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('name') === checkboxGroupName) return true; 4958 checkboxGroupName = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).attr('name'); 4959 } 4960 acc.push(_this.validateInput(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this))); 4961 }); 4962 var noError = acc.indexOf(false) === -1; 4963 this.$element.find('[data-abide-error]').each(function (i, elem) { 4964 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(elem); 4965 // Ensure a11y attributes are set 4966 if (_this8.options.a11yAttributes) _this8.addGlobalErrorA11yAttributes($elem); 4967 // Show or hide the error 4968 $elem.css('display', noError ? 'none' : 'block'); 4969 }); 4970 4971 /** 4972 * Fires when the form is finished validating. Event trigger is either `formvalid.zf.abide` or `forminvalid.zf.abide`. 4973 * Trigger includes the element of the form. 4974 * @event Abide#formvalid 4975 * @event Abide#forminvalid 4976 */ 4977 this.$element.trigger((noError ? 'formvalid' : 'forminvalid') + '.zf.abide', [this.$element]); 4978 return noError; 4979 } 4980 4981 /** 4982 * 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. 4983 * @param {Object} $el - jQuery object to validate, should be a text input HTML element 4984 * @param {String} pattern - string value of one of the RegEx patterns in Abide.options.patterns 4985 * @returns {Boolean} Boolean value depends on whether or not the input value matches the pattern specified 4986 */ 4987 }, { 4988 key: "validateText", 4989 value: function validateText($el, pattern) { 4990 // A pattern can be passed to this function, or it will be infered from the input's "pattern" attribute, or it's "type" attribute 4991 pattern = pattern || $el.attr('data-pattern') || $el.attr('pattern') || $el.attr('type'); 4992 var inputText = $el.val(); 4993 var valid = true; 4994 if (inputText.length) { 4995 // If the pattern attribute on the element is in Abide's list of patterns, then test that regexp 4996 if (this.options.patterns.hasOwnProperty(pattern)) { 4997 valid = this.options.patterns[pattern].test(inputText); 4998 } 4999 // If the pattern name isn't also the type attribute of the field, then test it as a regexp 5000 else if (pattern !== $el.attr('type')) { 5001 valid = new RegExp(pattern).test(inputText); 5002 } 5003 } 5004 return valid; 5005 } 5006 5007 /** 5008 * 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. 5009 * @param {String} groupName - A string that specifies the name of a radio button group 5010 * @returns {Boolean} Boolean value depends on whether or not at least one radio input has been selected (if it's required) 5011 */ 5012 }, { 5013 key: "validateRadio", 5014 value: function validateRadio(groupName) { 5015 // If at least one radio in the group has the `required` attribute, the group is considered required 5016 // Per W3C spec, all radio buttons in a group should have `required`, but we're being nice 5017 var $group = this.$element.find(":radio[name=\"".concat(groupName, "\"]")); 5018 var valid = false, 5019 required = false; 5020 5021 // For the group to be required, at least one radio needs to be required 5022 $group.each(function (i, e) { 5023 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).attr('required')) { 5024 required = true; 5025 } 5026 }); 5027 if (!required) valid = true; 5028 if (!valid) { 5029 // For the group to be valid, at least one radio needs to be checked 5030 $group.each(function (i, e) { 5031 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).prop('checked')) { 5032 valid = true; 5033 } 5034 }); 5035 } 5036 return valid; 5037 } 5038 5039 /** 5040 * Determines whether or a not a checkbox input is valid based on whether or not it is required and checked. Although the function targets a single `<input>`, it validates by checking the `required` and `checked` properties of all checkboxes in its group. 5041 * @param {String} groupName - A string that specifies the name of a checkbox group 5042 * @returns {Boolean} Boolean value depends on whether or not at least one checkbox input has been checked (if it's required) 5043 */ 5044 }, { 5045 key: "validateCheckbox", 5046 value: function validateCheckbox(groupName) { 5047 var _this9 = this; 5048 // If at least one checkbox in the group has the `required` attribute, the group is considered required 5049 // Per W3C spec, all checkboxes in a group should have `required`, but we're being nice 5050 var $group = this.$element.find(":checkbox[name=\"".concat(groupName, "\"]")); 5051 var valid = false, 5052 required = false, 5053 minRequired = 1, 5054 checked = 0; 5055 5056 // For the group to be required, at least one checkbox needs to be required 5057 $group.each(function (i, e) { 5058 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).attr('required')) { 5059 required = true; 5060 } 5061 }); 5062 if (!required) valid = true; 5063 if (!valid) { 5064 // Count checked checkboxes within the group 5065 // Use data-min-required if available (default: 1) 5066 $group.each(function (i, e) { 5067 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).prop('checked')) { 5068 checked++; 5069 } 5070 if (typeof jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).attr('data-min-required') !== 'undefined') { 5071 minRequired = parseInt(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e).attr('data-min-required'), 10); 5072 } 5073 }); 5074 5075 // For the group to be valid, the minRequired amount of checkboxes have to be checked 5076 if (checked >= minRequired) { 5077 valid = true; 5078 } 5079 } 5080 5081 // Skip validation if more than 1 checkbox have to be checked AND if the form hasn't got submitted yet (otherwise it will already show an error during the first fill in) 5082 if (this.initialized !== true && minRequired > 1) { 5083 return true; 5084 } 5085 5086 // Refresh error class for all input 5087 $group.each(function (i, e) { 5088 if (!valid) { 5089 _this9.addErrorClasses(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e), ['required']); 5090 } else { 5091 _this9.removeErrorClasses(jquery__WEBPACK_IMPORTED_MODULE_0___default()(e)); 5092 } 5093 }); 5094 return valid; 5095 } 5096 5097 /** 5098 * 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. 5099 * @param {Object} $el - jQuery input element. 5100 * @param {String} validators - a string of function names matching functions in the Abide.options.validators object. 5101 * @param {Boolean} required - self explanatory? 5102 * @returns {Boolean} - true if validations passed. 5103 */ 5104 }, { 5105 key: "matchValidation", 5106 value: function matchValidation($el, validators, required) { 5107 var _this10 = this; 5108 required = required ? true : false; 5109 var clear = validators.split(' ').map(function (v) { 5110 return _this10.options.validators[v]($el, required, $el.parent()); 5111 }); 5112 return clear.indexOf(false) === -1; 5113 } 5114 5115 /** 5116 * Resets form inputs and styles 5117 * @fires Abide#formreset 5118 */ 5119 }, { 5120 key: "resetForm", 5121 value: function resetForm() { 5122 var $form = this.$element, 5123 opts = this.options; 5124 jquery__WEBPACK_IMPORTED_MODULE_0___default()(".".concat(opts.labelErrorClass), $form).not('small').removeClass(opts.labelErrorClass); 5125 jquery__WEBPACK_IMPORTED_MODULE_0___default()(".".concat(opts.inputErrorClass), $form).not('small').removeClass(opts.inputErrorClass); 5126 jquery__WEBPACK_IMPORTED_MODULE_0___default()("".concat(opts.formErrorSelector, ".").concat(opts.formErrorClass)).removeClass(opts.formErrorClass); 5127 $form.find('[data-abide-error]').css('display', 'none'); 5128 jquery__WEBPACK_IMPORTED_MODULE_0___default()(':input', $form).not(':button, :submit, :reset, :hidden, :radio, :checkbox, [data-abide-ignore]').val('').attr({ 5129 'data-invalid': null, 5130 'aria-invalid': null 5131 }); 5132 jquery__WEBPACK_IMPORTED_MODULE_0___default()(':input:radio', $form).not('[data-abide-ignore]').prop('checked', false).attr({ 5133 'data-invalid': null, 5134 'aria-invalid': null 5135 }); 5136 jquery__WEBPACK_IMPORTED_MODULE_0___default()(':input:checkbox', $form).not('[data-abide-ignore]').prop('checked', false).attr({ 5137 'data-invalid': null, 5138 'aria-invalid': null 5139 }); 5140 /** 5141 * Fires when the form has been reset. 5142 * @event Abide#formreset 5143 */ 5144 $form.trigger('formreset.zf.abide', [$form]); 5145 } 5146 5147 /** 5148 * Destroys an instance of Abide. 5149 * Removes error styles and classes from elements, without resetting their values. 5150 */ 5151 }, { 5152 key: "_destroy", 5153 value: function _destroy() { 5154 var _this = this; 5155 this.$element.off('.abide').find('[data-abide-error]').css('display', 'none'); 5156 this.$inputs.off('.abide').each(function () { 5157 _this.removeErrorClasses(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)); 5158 }); 5159 this.$submits.off('.abide'); 5160 } 5161 }]); 5162 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 5163 /** 5164 * Default settings for plugin 5165 */ 5166 Abide.defaults = { 5167 /** 5168 * The default event to validate inputs. Checkboxes and radios validate immediately. 5169 * Remove or change this value for manual validation. 5170 * @option 5171 * @type {?string} 5172 * @default 'fieldChange' 5173 */ 5174 validateOn: 'fieldChange', 5175 /** 5176 * Class to be applied to input labels on failed validation. 5177 * @option 5178 * @type {string} 5179 * @default 'is-invalid-label' 5180 */ 5181 labelErrorClass: 'is-invalid-label', 5182 /** 5183 * Class to be applied to inputs on failed validation. 5184 * @option 5185 * @type {string} 5186 * @default 'is-invalid-input' 5187 */ 5188 inputErrorClass: 'is-invalid-input', 5189 /** 5190 * Class selector to use to target Form Errors for show/hide. 5191 * @option 5192 * @type {string} 5193 * @default '.form-error' 5194 */ 5195 formErrorSelector: '.form-error', 5196 /** 5197 * Class added to Form Errors on failed validation. 5198 * @option 5199 * @type {string} 5200 * @default 'is-visible' 5201 */ 5202 formErrorClass: 'is-visible', 5203 /** 5204 * If true, automatically insert when possible: 5205 * - `[aria-describedby]` on fields 5206 * - `[role=alert]` on form errors and `[for]` on form error labels 5207 * - `[aria-live]` on global errors `[data-abide-error]` (see option `a11yErrorLevel`). 5208 * @option 5209 * @type {boolean} 5210 * @default true 5211 */ 5212 a11yAttributes: true, 5213 /** 5214 * [aria-live] attribute value to be applied on global errors `[data-abide-error]`. 5215 * Options are: 'assertive', 'polite' and 'off'/null 5216 * @option 5217 * @see https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Live_Regions 5218 * @type {string} 5219 * @default 'assertive' 5220 */ 5221 a11yErrorLevel: 'assertive', 5222 /** 5223 * Set to true to validate text inputs on any value change. 5224 * @option 5225 * @type {boolean} 5226 * @default false 5227 */ 5228 liveValidate: false, 5229 /** 5230 * Set to true to validate inputs on blur. 5231 * @option 5232 * @type {boolean} 5233 * @default false 5234 */ 5235 validateOnBlur: false, 5236 patterns: { 5237 alpha: /^[a-zA-Z]+$/, 5238 // eslint-disable-next-line camelcase 5239 alpha_numeric: /^[a-zA-Z0-9]+$/, 5240 integer: /^[-+]?\d+$/, 5241 number: /^[-+]?\d*(?:[\.\,]\d+)?$/, 5242 // amex, visa, diners 5243 card: /^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|(?:222[1-9]|2[3-6][0-9]{2}|27[0-1][0-9]|2720)[0-9]{12}|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})$/, 5244 cvv: /^([0-9]){3,4}$/, 5245 // http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#valid-e-mail-address 5246 email: /^[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])?)+$/,
vendor: 4,923 bytes, lines 5247-5351
5247 // From CommonRegexJS (@talyssonoc) 5248 // https://github.com/talyssonoc/CommonRegexJS/blob/e2901b9f57222bc14069dc8f0598d5f412555411/lib/commonregex.js#L76 5249 // For more restrictive URL Regexs, see https://mathiasbynens.be/demo/url-regex. 5250 url: /^((?:(https?|ftps?|file|ssh|sftp):\/\/|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\((?:[^\s()<>]+|(?:\([^\s()<>]+\)))*\))+(?:\((?:[^\s()<>]+|(?:\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:\'".,<>?\xab\xbb\u201c\u201d\u2018\u2019]))$/, 5251 // abc.de 5252 domain: /^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,8}$/, 5253 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))$/, 5254 // YYYY-MM-DD 5255 date: /(?: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))$/, 5256 // HH:MM:SS 5257 time: /^(0[0-9]|1[0-9]|2[0-3])(:[0-5][0-9]){2}$/, 5258 dateISO: /^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/, 5259 // MM/DD/YYYY 5260 // eslint-disable-next-line camelcase 5261 month_day_year: /^(0[1-9]|1[012])[- \/.](0[1-9]|[12][0-9]|3[01])[- \/.]\d{4}$/, 5262 // DD/MM/YYYY 5263 // eslint-disable-next-line camelcase 5264 day_month_year: /^(0[1-9]|[12][0-9]|3[01])[- \/.](0[1-9]|1[012])[- \/.]\d{4}$/, 5265 // #FFF or #FFFFFF 5266 color: /^#?([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/, 5267 // Domain || URL 5268 website: { 5269 test: function test(text) { 5270 return Abide.defaults.patterns.domain.test(text) || Abide.defaults.patterns.url.test(text); 5271 } 5272 } 5273 }, 5274 /** 5275 * Optional validation functions to be used. `equalTo` being the only default included function. 5276 * Functions should return only a boolean if the input is valid or not. Functions are given the following arguments: 5277 * el : The jQuery element to validate. 5278 * @option 5279 */ 5280 validators: { 5281 equalTo: function equalTo(el) { 5282 return jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(el.attr('data-equalto'))).val() === el.val(); 5283 } 5284 } 5285 }; 5286 5287 /***/ 5288 }), 5289 /***/"./foundation.core": ( 5290 /*!****************************************************************************************************************************************************************!*\ 5291 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 5292 \****************************************************************************************************************************************************************/ 5293 /***/ 5294 function (module) { 5295 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 5296 5297 /***/ 5298 }), 5299 /***/"jquery": ( 5300 /*!********************************************************************************************!*\ 5301 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 5302 \********************************************************************************************/ 5303 /***/ 5304 function (module) { 5305 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 5306 5307 /***/ 5308 }) 5309 5310 /******/ 5311 }; 5312 /************************************************************************/ 5313 /******/ // The module cache 5314 /******/ 5315 var __webpack_module_cache__ = {}; 5316 /******/ 5317 /******/ // The require function 5318 /******/ 5319 function __webpack_require__(moduleId) { 5320 /******/ // Check if module is in cache 5321 /******/var cachedModule = __webpack_module_cache__[moduleId]; 5322 /******/ 5323 if (cachedModule !== undefined) { 5324 /******/return cachedModule.exports; 5325 /******/ 5326 } 5327 /******/ // Create a new module (and put it into the cache) 5328 /******/ 5329 var module = __webpack_module_cache__[moduleId] = { 5330 /******/ // no module.id needed 5331 /******/ // no module.loaded needed 5332 /******/exports: {} 5333 /******/ 5334 }; 5335 /******/ 5336 /******/ // Execute the module function 5337 /******/ 5338 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 5339 /******/ 5340 /******/ // Return the exports of the module 5341 /******/ 5342 return module.exports; 5343 /******/ 5344 } 5345 /******/ 5346 /************************************************************************/ 5347 /******/ /* webpack/runtime/compat get default export */ 5348 /******/ 5349 !function () { 5350 /******/ // getDefaultExport function for compatibility with non-harmony modules 5351 /******/__webpack_require__.n = function (module) {
vendor: 4,578 bytes, lines 5352-5458
5352 /******/var getter = module && module.__esModule ? /******/function () { 5353 return module['default']; 5354 } : /******/function () { 5355 return module; 5356 }; 5357 /******/ 5358 __webpack_require__.d(getter, { 5359 a: getter 5360 }); 5361 /******/ 5362 return getter; 5363 /******/ 5364 }; 5365 /******/ 5366 }(); 5367 /******/ 5368 /******/ /* webpack/runtime/define property getters */ 5369 /******/ 5370 !function () { 5371 /******/ // define getter functions for harmony exports 5372 /******/__webpack_require__.d = function (exports, definition) { 5373 /******/for (var key in definition) { 5374 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 5375 /******/Object.defineProperty(exports, key, { 5376 enumerable: true, 5377 get: definition[key] 5378 }); 5379 /******/ 5380 } 5381 /******/ 5382 } 5383 /******/ 5384 }; 5385 /******/ 5386 }(); 5387 /******/ 5388 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 5389 /******/ 5390 !function () { 5391 /******/__webpack_require__.o = function (obj, prop) { 5392 return Object.prototype.hasOwnProperty.call(obj, prop); 5393 }; 5394 /******/ 5395 }(); 5396 /******/ 5397 /******/ /* webpack/runtime/make namespace object */ 5398 /******/ 5399 !function () { 5400 /******/ // define __esModule on exports 5401 /******/__webpack_require__.r = function (exports) { 5402 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 5403 /******/Object.defineProperty(exports, Symbol.toStringTag, { 5404 value: 'Module' 5405 }); 5406 /******/ 5407 } 5408 /******/ 5409 Object.defineProperty(exports, '__esModule', { 5410 value: true 5411 }); 5412 /******/ 5413 }; 5414 /******/ 5415 }(); 5416 /******/ 5417 /************************************************************************/ 5418 var __webpack_exports__ = {}; 5419 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 5420 !function () { 5421 /*!************************************************!*\ 5422 !*** ./js/entries/plugins/foundation.abide.js ***! 5423 \************************************************/ 5424 __webpack_require__.r(__webpack_exports__); 5425 /* harmony export */ 5426 __webpack_require__.d(__webpack_exports__, { 5427 /* harmony export */Abide: function () { 5428 return /* reexport safe */_foundation_abide__WEBPACK_IMPORTED_MODULE_1__.Abide; 5429 }, 5430 /* harmony export */Foundation: function () { 5431 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 5432 } 5433 /* harmony export */ 5434 }); 5435 /* harmony import */ 5436 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 5437 /* harmony import */ 5438 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 5439 /* harmony import */ 5440 var _foundation_abide__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.abide */"./js/foundation.abide.js"); 5441 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_abide__WEBPACK_IMPORTED_MODULE_1__.Abide, 'Abide'); 5442 }(); 5443 /******/ 5444 return __webpack_exports__; 5445 /******/ 5446 }(); 5447}); 5448(function webpackUniversalModuleDefinition(root, factory) { 5449 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.keyboard"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.accordion"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.keyboard"]); 5450})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__) { 5451 return /******/function () { 5452 // webpackBootstrap 5453 /******/ 5454 "use strict"; 5455 5456 /******/ 5457 var __webpack_modules__ = { 5458
vendor: 19,686 bytes, lines 5458-5906
5458/***/"./js/foundation.accordion.js": ( 5459 /*!************************************!*\ 5460 !*** ./js/foundation.accordion.js ***! 5461 \************************************/ 5462 /***/ 5463 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 5464 __webpack_require__.r(__webpack_exports__); 5465 /* harmony export */ 5466 __webpack_require__.d(__webpack_exports__, { 5467 /* harmony export */Accordion: function () { 5468 return /* binding */Accordion; 5469 } 5470 /* harmony export */ 5471 }); 5472 /* harmony import */ 5473 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 5474 /* harmony import */ 5475 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 5476 /* harmony import */ 5477 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 5478 /* harmony import */ 5479 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 5480 /* harmony import */ 5481 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.keyboard */"./foundation.util.keyboard"); 5482 /* harmony import */ 5483 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__); 5484 function _typeof(o) { 5485 "@babel/helpers - typeof"; 5486 5487 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 5488 return typeof o; 5489 } : function (o) { 5490 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 5491 }, _typeof(o); 5492 } 5493 function _classCallCheck(a, n) { 5494 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 5495 } 5496 function _defineProperties(e, r) { 5497 for (var t = 0; t < r.length; t++) { 5498 var o = r[t]; 5499 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 5500 } 5501 } 5502 function _createClass(e, r, t) { 5503 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 5504 writable: !1 5505 }), e; 5506 } 5507 function _toPropertyKey(t) { 5508 var i = _toPrimitive(t, "string"); 5509 return "symbol" == _typeof(i) ? i : i + ""; 5510 } 5511 function _toPrimitive(t, r) { 5512 if ("object" != _typeof(t) || !t) return t; 5513 var e = t[Symbol.toPrimitive]; 5514 if (void 0 !== e) { 5515 var i = e.call(t, r || "default"); 5516 if ("object" != _typeof(i)) return i; 5517 throw new TypeError("@@toPrimitive must return a primitive value."); 5518 } 5519 return ("string" === r ? String : Number)(t); 5520 } 5521 function _callSuper(t, o, e) { 5522 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 5523 } 5524 function _possibleConstructorReturn(t, e) { 5525 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 5526 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 5527 return _assertThisInitialized(t); 5528 } 5529 function _assertThisInitialized(e) { 5530 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 5531 return e; 5532 } 5533 function _isNativeReflectConstruct() { 5534 try { 5535 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 5536 } catch (t) {} 5537 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 5538 return !!t; 5539 })(); 5540 } 5541 function _getPrototypeOf(t) { 5542 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 5543 return t.__proto__ || Object.getPrototypeOf(t); 5544 }, _getPrototypeOf(t); 5545 } 5546 function _inherits(t, e) { 5547 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 5548 t.prototype = Object.create(e && e.prototype, { 5549 constructor: { 5550 value: t, 5551 writable: !0, 5552 configurable: !0 5553 } 5554 }), Object.defineProperty(t, "prototype", { 5555 writable: !1 5556 }), e && _setPrototypeOf(t, e); 5557 } 5558 function _setPrototypeOf(t, e) { 5559 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 5560 return t.__proto__ = e, t; 5561 }, _setPrototypeOf(t, e); 5562 } 5563 5564 /** 5565 * Accordion module. 5566 * @module foundation.accordion 5567 * @requires foundation.util.keyboard 5568 */ 5569 var Accordion = /*#__PURE__*/function (_Plugin) { 5570 function Accordion() { 5571 _classCallCheck(this, Accordion); 5572 return _callSuper(this, Accordion, arguments); 5573 } 5574 _inherits(Accordion, _Plugin); 5575 return _createClass(Accordion, [{ 5576 key: "_setup", 5577 value: 5578 /** 5579 * Creates a new instance of an accordion. 5580 * @class 5581 * @name Accordion 5582 * @fires Accordion#init 5583 * @param {jQuery} element - jQuery object to make into an accordion. 5584 * @param {Object} options - a plain object with settings to override the default options. 5585 */ 5586 function _setup(element, options) { 5587 this.$element = element; 5588 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, Accordion.defaults, this.$element.data(), options); 5589 this.className = 'Accordion'; // ie9 back compat 5590 this._init(); 5591 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.register('Accordion', { 5592 'ENTER': 'toggle', 5593 'SPACE': 'toggle', 5594 'ARROW_DOWN': 'next', 5595 'ARROW_UP': 'previous', 5596 'HOME': 'first', 5597 'END': 'last' 5598 }); 5599 } 5600 5601 /** 5602 * Initializes the accordion by animating the preset active pane(s). 5603 * @private 5604 */ 5605 }, { 5606 key: "_init", 5607 value: function _init() { 5608 var _this2 = this; 5609 this._isInitializing = true; 5610 this.$tabs = this.$element.children('[data-accordion-item]'); 5611 this.$tabs.each(function (idx, el) { 5612 var $el = jquery__WEBPACK_IMPORTED_MODULE_0___default()(el), 5613 $content = $el.children('[data-tab-content]'), 5614 id = $content[0].id || (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.GetYoDigits)(6, 'accordion'), 5615 linkId = el.id ? "".concat(el.id, "-label") : "".concat(id, "-label"); 5616 $el.find('a:first').attr({ 5617 'aria-controls': id, 5618 'id': linkId, 5619 'aria-expanded': false 5620 }); 5621 $content.attr({ 5622 'role': 'region', 5623 'aria-labelledby': linkId, 5624 'aria-hidden': true, 5625 'id': id 5626 }); 5627 }); 5628 var $initActive = this.$element.find('.is-active').children('[data-tab-content]'); 5629 if ($initActive.length) { 5630 // Save up the initial hash to return to it later when going back in history 5631 this._initialAnchor = $initActive.prev('a').attr('href'); 5632 this._openSingleTab($initActive); 5633 } 5634 this._checkDeepLink = function () { 5635 var anchor = window.location.hash; 5636 if (!anchor.length) { 5637 // If we are still initializing and there is no anchor, then there is nothing to do 5638 if (_this2._isInitializing) return; 5639 // Otherwise, move to the initial anchor 5640 if (_this2._initialAnchor) anchor = _this2._initialAnchor; 5641 } 5642 var $anchor = anchor && jquery__WEBPACK_IMPORTED_MODULE_0___default()(anchor); 5643 var $link = anchor && _this2.$element.find("[href$=\"".concat(anchor, "\"]")); 5644 // Whether the anchor element that has been found is part of this element 5645 var isOwnAnchor = !!($anchor.length && $link.length); 5646 if (isOwnAnchor) { 5647 // If there is an anchor for the hash, open it (if not already active) 5648 if ($anchor && $link && $link.length) { 5649 if (!$link.parent('[data-accordion-item]').hasClass('is-active')) { 5650 _this2._openSingleTab($anchor); 5651 } 5652 } 5653 // Otherwise, close everything 5654 else { 5655 _this2._closeAllTabs(); 5656 } 5657 5658 // Roll up a little to show the titles 5659 if (_this2.options.deepLinkSmudge) { 5660 (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 5661 var offset = _this2.$element.offset(); 5662 jquery__WEBPACK_IMPORTED_MODULE_0___default()('html, body').animate({ 5663 scrollTop: offset.top - _this2.options.deepLinkSmudgeOffset 5664 }, _this2.options.deepLinkSmudgeDelay); 5665 }); 5666 } 5667 5668 /** 5669 * Fires when the plugin has deeplinked at pageload 5670 * @event Accordion#deeplink 5671 */ 5672 _this2.$element.trigger('deeplink.zf.accordion', [$link, $anchor]); 5673 } 5674 }; 5675 5676 //use browser to open a tab, if it exists in this tabset 5677 if (this.options.deepLink) { 5678 this._checkDeepLink(); 5679 } 5680 this._events(); 5681 this._isInitializing = false; 5682 } 5683 5684 /** 5685 * Adds event handlers for items within the accordion. 5686 * @private 5687 */ 5688 }, { 5689 key: "_events", 5690 value: function _events() { 5691 var _this = this; 5692 this.$tabs.each(function () { 5693 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this); 5694 var $tabContent = $elem.children('[data-tab-content]'); 5695 if ($tabContent.length) { 5696 $elem.children('a').off('click.zf.accordion keydown.zf.accordion').on('click.zf.accordion', function (e) { 5697 e.preventDefault(); 5698 _this.toggle($tabContent); 5699 }).on('keydown.zf.accordion', function (e) { 5700 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.handleKey(e, 'Accordion', { 5701 toggle: function toggle() { 5702 _this.toggle($tabContent); 5703 }, 5704 next: function next() { 5705 var $a = $elem.next().find('a').focus(); 5706 if (!_this.options.multiExpand) { 5707 $a.trigger('click.zf.accordion'); 5708 } 5709 }, 5710 previous: function previous() { 5711 var $a = $elem.prev().find('a').focus(); 5712 if (!_this.options.multiExpand) { 5713 $a.trigger('click.zf.accordion'); 5714 } 5715 }, 5716 first: function first() { 5717 var $a = _this.$tabs.first().find('.accordion-title').focus(); 5718 if (!_this.options.multiExpand) { 5719 $a.trigger('click.zf.accordion'); 5720 } 5721 }, 5722 last: function last() { 5723 var $a = _this.$tabs.last().find('.accordion-title').focus(); 5724 if (!_this.options.multiExpand) { 5725 $a.trigger('click.zf.accordion'); 5726 } 5727 }, 5728 handled: function handled() { 5729 e.preventDefault(); 5730 } 5731 }); 5732 }); 5733 } 5734 }); 5735 if (this.options.deepLink) { 5736 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('hashchange', this._checkDeepLink); 5737 } 5738 } 5739 5740 /** 5741 * Toggles the selected content pane's open/close state. 5742 * @param {jQuery} $target - jQuery object of the pane to toggle (`.accordion-content`). 5743 * @function 5744 */ 5745 }, { 5746 key: "toggle", 5747 value: function toggle($target) { 5748 if ($target.closest('[data-accordion]').is('[disabled]')) { 5749 console.info('Cannot toggle an accordion that is disabled.'); 5750 return; 5751 } 5752 if ($target.parent().hasClass('is-active')) { 5753 this.up($target); 5754 } else { 5755 this.down($target); 5756 } 5757 //either replace or update browser history 5758 if (this.options.deepLink) { 5759 var anchor = $target.prev('a').attr('href'); 5760 if (this.options.updateHistory) { 5761 history.pushState({}, '', anchor); 5762 } else { 5763 history.replaceState({}, '', anchor); 5764 } 5765 } 5766 } 5767 5768 /** 5769 * Opens the accordion tab defined by `$target`. 5770 * @param {jQuery} $target - Accordion pane to open (`.accordion-content`). 5771 * @fires Accordion#down 5772 * @function 5773 */ 5774 }, { 5775 key: "down", 5776 value: function down($target) { 5777 if ($target.closest('[data-accordion]').is('[disabled]')) { 5778 console.info('Cannot call down on an accordion that is disabled.'); 5779 return; 5780 } 5781 if (this.options.multiExpand) this._openTab($target);else this._openSingleTab($target); 5782 } 5783 5784 /** 5785 * Closes the tab defined by `$target`. 5786 * It may be ignored if the Accordion options don't allow it. 5787 * 5788 * @param {jQuery} $target - Accordion tab to close (`.accordion-content`). 5789 * @fires Accordion#up 5790 * @function 5791 */ 5792 }, { 5793 key: "up", 5794 value: function up($target) { 5795 if (this.$element.is('[disabled]')) { 5796 console.info('Cannot call up on an accordion that is disabled.'); 5797 return; 5798 } 5799 5800 // Don't close the item if it is already closed 5801 var $targetItem = $target.parent(); 5802 if (!$targetItem.hasClass('is-active')) return; 5803 5804 // Don't close the item if there is no other active item (unless with `allowAllClosed`) 5805 var $othersItems = $targetItem.siblings(); 5806 if (!this.options.allowAllClosed && !$othersItems.hasClass('is-active')) return; 5807 this._closeTab($target); 5808 } 5809 5810 /** 5811 * Make the tab defined by `$target` the only opened tab, closing all others tabs. 5812 * @param {jQuery} $target - Accordion tab to open (`.accordion-content`). 5813 * @function 5814 * @private 5815 */ 5816 }, { 5817 key: "_openSingleTab", 5818 value: function _openSingleTab($target) { 5819 // Close all the others active tabs. 5820 var $activeContents = this.$element.children('.is-active').children('[data-tab-content]'); 5821 if ($activeContents.length) { 5822 this._closeTab($activeContents.not($target)); 5823 } 5824 5825 // Then open the target. 5826 this._openTab($target); 5827 } 5828 5829 /** 5830 * Opens the tab defined by `$target`. 5831 * @param {jQuery} $target - Accordion tab to open (`.accordion-content`). 5832 * @fires Accordion#down 5833 * @function 5834 * @private 5835 */ 5836 }, { 5837 key: "_openTab", 5838 value: function _openTab($target) { 5839 var _this3 = this; 5840 var $targetItem = $target.parent(); 5841 var targetContentId = $target.attr('aria-labelledby'); 5842 $target.attr('aria-hidden', false); 5843 $targetItem.addClass('is-active'); 5844 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(targetContentId)).attr({ 5845 'aria-expanded': true 5846 }); 5847 $target.finish().slideDown(this.options.slideSpeed, function () { 5848 /** 5849 * Fires when the tab is done opening. 5850 * @event Accordion#down 5851 */ 5852 _this3.$element.trigger('down.zf.accordion', [$target]); 5853 }); 5854 } 5855 5856 /** 5857 * Closes the tab defined by `$target`. 5858 * @param {jQuery} $target - Accordion tab to close (`.accordion-content`). 5859 * @fires Accordion#up 5860 * @function 5861 * @private 5862 */ 5863 }, { 5864 key: "_closeTab", 5865 value: function _closeTab($target) { 5866 var _this4 = this; 5867 var $targetItem = $target.parent(); 5868 var targetContentId = $target.attr('aria-labelledby'); 5869 $target.attr('aria-hidden', true); 5870 $targetItem.removeClass('is-active'); 5871 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(targetContentId)).attr({ 5872 'aria-expanded': false 5873 }); 5874 $target.finish().slideUp(this.options.slideSpeed, function () { 5875 /** 5876 * Fires when the tab is done collapsing up. 5877 * @event Accordion#up 5878 */ 5879 _this4.$element.trigger('up.zf.accordion', [$target]); 5880 }); 5881 } 5882 5883 /** 5884 * Closes all active tabs 5885 * @fires Accordion#up 5886 * @function 5887 * @private 5888 */ 5889 }, { 5890 key: "_closeAllTabs", 5891 value: function _closeAllTabs() { 5892 var $activeTabs = this.$element.children('.is-active').children('[data-tab-content]'); 5893 if ($activeTabs.length) { 5894 this._closeTab($activeTabs); 5895 } 5896 } 5897 5898 /** 5899 * Destroys an instance of an accordion. 5900 * @fires Accordion#destroyed 5901 * @function 5902 */ 5903 }, { 5904 key: "_destroy", 5905 value: function _destroy() { 5906 this.$element.find('[data-tab-content]').stop(true).slide
vendor: 5,713 bytes, lines 5906-6048
5906Up(0).css('display', ''); 5907 this.$element.find('a').off('.zf.accordion'); 5908 if (this.options.deepLink) { 5909 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off('hashchange', this._checkDeepLink); 5910 } 5911 } 5912 }]); 5913 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 5914 Accordion.defaults = { 5915 /** 5916 * Amount of time to animate the opening of an accordion pane. 5917 * @option 5918 * @type {number} 5919 * @default 250 5920 */ 5921 slideSpeed: 250, 5922 /** 5923 * Allow the accordion to have multiple open panes. 5924 * @option 5925 * @type {boolean} 5926 * @default false 5927 */ 5928 multiExpand: false, 5929 /** 5930 * Allow the accordion to close all panes. 5931 * @option 5932 * @type {boolean} 5933 * @default false 5934 */ 5935 allowAllClosed: false, 5936 /** 5937 * Link the location hash to the open pane. 5938 * Set the location hash when the opened pane changes, and open and scroll to the corresponding pane when the location changes. 5939 * @option 5940 * @type {boolean} 5941 * @default false 5942 */ 5943 deepLink: false, 5944 /** 5945 * If `deepLink` is enabled, adjust the deep link scroll to make sure the top of the accordion panel is visible 5946 * @option 5947 * @type {boolean} 5948 * @default false 5949 */ 5950 deepLinkSmudge: false, 5951 /** 5952 * If `deepLinkSmudge` is enabled, animation time (ms) for the deep link adjustment 5953 * @option 5954 * @type {number} 5955 * @default 300 5956 */ 5957 deepLinkSmudgeDelay: 300, 5958 /** 5959 * If `deepLinkSmudge` is enabled, the offset for scrollToTtop to prevent overlap by a sticky element at the top of the page 5960 * @option 5961 * @type {number} 5962 * @default 0 5963 */ 5964 deepLinkSmudgeOffset: 0, 5965 /** 5966 * If `deepLink` is enabled, update the browser history with the open accordion 5967 * @option 5968 * @type {boolean} 5969 * @default false 5970 */ 5971 updateHistory: false 5972 }; 5973 5974 /***/ 5975 }), 5976 /***/"./foundation.core": ( 5977 /*!****************************************************************************************************************************************************************!*\ 5978 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 5979 \****************************************************************************************************************************************************************/ 5980 /***/ 5981 function (module) { 5982 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 5983 5984 /***/ 5985 }), 5986 /***/"./foundation.util.keyboard": ( 5987 /*!****************************************************************************************************************************************************************************************************!*\ 5988 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.keyboard"],"amd":"./foundation.util.keyboard","commonjs":"./foundation.util.keyboard","commonjs2":"./foundation.util.keyboard"} ***! 5989 \****************************************************************************************************************************************************************************************************/ 5990 /***/ 5991 function (module) { 5992 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__; 5993 5994 /***/ 5995 }), 5996 /***/"jquery": ( 5997 /*!********************************************************************************************!*\ 5998 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 5999 \********************************************************************************************/ 6000 /***/ 6001 function (module) { 6002 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 6003 6004 /***/ 6005 }) 6006 6007 /******/ 6008 }; 6009 /************************************************************************/ 6010 /******/ // The module cache 6011 /******/ 6012 var __webpack_module_cache__ = {}; 6013 /******/ 6014 /******/ // The require function 6015 /******/ 6016 function __webpack_require__(moduleId) { 6017 /******/ // Check if module is in cache 6018 /******/var cachedModule = __webpack_module_cache__[moduleId]; 6019 /******/ 6020 if (cachedModule !== undefined) { 6021 /******/return cachedModule.exports; 6022 /******/ 6023 } 6024 /******/ // Create a new module (and put it into the cache) 6025 /******/ 6026 var module = __webpack_module_cache__[moduleId] = { 6027 /******/ // no module.id needed 6028 /******/ // no module.loaded needed 6029 /******/exports: {} 6030 /******/ 6031 }; 6032 /******/ 6033 /******/ // Execute the module function 6034 /******/ 6035 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 6036 /******/ 6037 /******/ // Return the exports of the module 6038 /******/ 6039 return module.exports; 6040 /******/ 6041 } 6042 /******/ 6043 /************************************************************************/ 6044 /******/ /* webpack/runtime/compat get default export */ 6045 /******/ 6046 !function () { 6047 /******/ // getDefaultExport function for compatibility with non-harmony modules 6048 /******/__webpack_require__.n = function (module) {
vendor: 5,241 bytes, lines 6049-6155
6049 /******/var getter = module && module.__esModule ? /******/function () { 6050 return module['default']; 6051 } : /******/function () { 6052 return module; 6053 }; 6054 /******/ 6055 __webpack_require__.d(getter, { 6056 a: getter 6057 }); 6058 /******/ 6059 return getter; 6060 /******/ 6061 }; 6062 /******/ 6063 }(); 6064 /******/ 6065 /******/ /* webpack/runtime/define property getters */ 6066 /******/ 6067 !function () { 6068 /******/ // define getter functions for harmony exports 6069 /******/__webpack_require__.d = function (exports, definition) { 6070 /******/for (var key in definition) { 6071 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 6072 /******/Object.defineProperty(exports, key, { 6073 enumerable: true, 6074 get: definition[key] 6075 }); 6076 /******/ 6077 } 6078 /******/ 6079 } 6080 /******/ 6081 }; 6082 /******/ 6083 }(); 6084 /******/ 6085 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 6086 /******/ 6087 !function () { 6088 /******/__webpack_require__.o = function (obj, prop) { 6089 return Object.prototype.hasOwnProperty.call(obj, prop); 6090 }; 6091 /******/ 6092 }(); 6093 /******/ 6094 /******/ /* webpack/runtime/make namespace object */ 6095 /******/ 6096 !function () { 6097 /******/ // define __esModule on exports 6098 /******/__webpack_require__.r = function (exports) { 6099 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 6100 /******/Object.defineProperty(exports, Symbol.toStringTag, { 6101 value: 'Module' 6102 }); 6103 /******/ 6104 } 6105 /******/ 6106 Object.defineProperty(exports, '__esModule', { 6107 value: true 6108 }); 6109 /******/ 6110 }; 6111 /******/ 6112 }(); 6113 /******/ 6114 /************************************************************************/ 6115 var __webpack_exports__ = {}; 6116 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 6117 !function () { 6118 /*!****************************************************!*\ 6119 !*** ./js/entries/plugins/foundation.accordion.js ***! 6120 \****************************************************/ 6121 __webpack_require__.r(__webpack_exports__); 6122 /* harmony export */ 6123 __webpack_require__.d(__webpack_exports__, { 6124 /* harmony export */Accordion: function () { 6125 return /* reexport safe */_foundation_accordion__WEBPACK_IMPORTED_MODULE_1__.Accordion; 6126 }, 6127 /* harmony export */Foundation: function () { 6128 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 6129 } 6130 /* harmony export */ 6131 }); 6132 /* harmony import */ 6133 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 6134 /* harmony import */ 6135 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 6136 /* harmony import */ 6137 var _foundation_accordion__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.accordion */"./js/foundation.accordion.js"); 6138 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_accordion__WEBPACK_IMPORTED_MODULE_1__.Accordion, 'Accordion'); 6139 }(); 6140 /******/ 6141 return __webpack_exports__; 6142 /******/ 6143 }(); 6144}); 6145(function webpackUniversalModuleDefinition(root, factory) { 6146 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.nest"), require("./foundation.util.box"), require("./foundation.util.touch"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.keyboard", "./foundation.util.nest", "./foundation.util.box", "./foundation.util.touch"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.nest"), require("./foundation.util.box"), require("./foundation.util.touch"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.dropdownMenu"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.keyboard"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.nest"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.box"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.touch"]); 6147})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__, __WEBPACK_EXTERNAL_MODULE__foundation_util_nest__, __WEBPACK_EXTERNAL_MODULE__foundation_util_box__, __WEBPACK_EXTERNAL_MODULE__foundation_util_touch__) { 6148 return /******/function () { 6149 // webpackBootstrap 6150 /******/ 6151 "use strict"; 6152 6153 /******/ 6154 var __webpack_modules__ = { 6155
6155/***/"./js/foundation.dropdownMenu.js": ( 6156 /*!***************************************!*\ 6157 !*** ./js/foundation.dropdownMenu.js ***! 6158 \***************************************/ 6159 /***/ 6160 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 6161 __webpack_require__.r(__webpack_exports__); 6162 /* harmony export */ 6163 __webpack_require__.d(__webpack_exports__, { 6164 /* harmony export */DropdownMenu: function () { 6165 return /* binding */DropdownMenu; 6166 } 6167 /* harmony export */ 6168 }); 6169 /* harmony import */ 6170 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 6171 /* harmony import */ 6172 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 6173 /* harmony import */ 6174 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 6175 /* harmony import */ 6176 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 6177 /* harmony import */ 6178 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.keyboard */"./foundation.util.keyboard"); 6179 /* harmony import */ 6180 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__); 6181 /* harmony import */ 6182 var _foundation_util_nest__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.util.nest */"./foundation.util.nest"); 6183 /* harmony import */ 6184 var _foundation_util_nest__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_nest__WEBPACK_IMPORTED_MODULE_3__); 6185 /* harmony import */ 6186 var _foundation_util_box__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./foundation.util.box */"./foundation.util.box"); 6187 /* harmony import */ 6188 var _foundation_util_box__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_box__WEBPACK_IMPORTED_MODULE_4__); 6189 /* harmony import */ 6190 var _foundation_util_touch__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./foundation.util.touch */"./foundation.util.touch"); 6191 /* harmony import */ 6192 var _foundation_util_touch__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_touch__WEBPACK_IMPORTED_MODULE_5__); 6193 function _typeof(o) { 6194 "@babel/helpers - typeof"; 6195 6196 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 6197 return typeof o; 6198 } : function (o) { 6199 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 6200 }, _typeof(o); 6201 } 6202 function _classCallCheck(a, n) { 6203 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 6204 } 6205 function _defineProperties(e, r) { 6206 for (var t = 0; t < r.length; t++) { 6207 var o = r[t]; 6208 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 6209 } 6210 } 6211 function _createClass(e, r, t) { 6212 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 6213 writable: !1 6214 }), e; 6215 } 6216 function _toPropertyKey(t) { 6217 var i = _toPrimitive(t, "string"); 6218 return "symbol" == _typeof(i) ? i : i + ""; 6219 } 6220 function _toPrimitive(t, r) { 6221 if ("object" != _typeof(t) || !t) return t; 6222 var e = t[Symbol.toPrimitive]; 6223 if (void 0 !== e) { 6224 var i = e.call(t, r || "default"); 6225 if ("object" != _typeof(i)) return i; 6226 throw new TypeError("@@toPrimitive must return a primitive value."); 6227 } 6228 return ("string" === r ? String : Number)(t); 6229 } 6230 function _callSuper(t, o, e) {
vendor: 15,473 bytes, lines 6231-6574
6231 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 6232 } 6233 function _possibleConstructorReturn(t, e) { 6234 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 6235 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 6236 return _assertThisInitialized(t); 6237 } 6238 function _assertThisInitialized(e) { 6239 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 6240 return e; 6241 } 6242 function _isNativeReflectConstruct() { 6243 try { 6244 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 6245 } catch (t) {} 6246 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 6247 return !!t; 6248 })(); 6249 } 6250 function _getPrototypeOf(t) { 6251 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 6252 return t.__proto__ || Object.getPrototypeOf(t); 6253 }, _getPrototypeOf(t); 6254 } 6255 function _inherits(t, e) { 6256 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 6257 t.prototype = Object.create(e && e.prototype, { 6258 constructor: { 6259 value: t, 6260 writable: !0, 6261 configurable: !0 6262 } 6263 }), Object.defineProperty(t, "prototype", { 6264 writable: !1 6265 }), e && _setPrototypeOf(t, e); 6266 } 6267 function _setPrototypeOf(t, e) { 6268 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 6269 return t.__proto__ = e, t; 6270 }, _setPrototypeOf(t, e); 6271 } 6272 6273 /** 6274 * DropdownMenu module. 6275 * @module foundation.dropdownMenu 6276 * @requires foundation.util.keyboard 6277 * @requires foundation.util.box 6278 * @requires foundation.util.nest 6279 * @requires foundation.util.touch 6280 */ 6281 var DropdownMenu = /*#__PURE__*/function (_Plugin) { 6282 function DropdownMenu() { 6283 _classCallCheck(this, DropdownMenu); 6284 return _callSuper(this, DropdownMenu, arguments); 6285 } 6286 _inherits(DropdownMenu, _Plugin); 6287 return _createClass(DropdownMenu, [{ 6288 key: "_setup", 6289 value: 6290 /** 6291 * Creates a new instance of DropdownMenu. 6292 * @class 6293 * @name DropdownMenu 6294 * @fires DropdownMenu#init 6295 * @param {jQuery} element - jQuery object to make into a dropdown menu. 6296 * @param {Object} options - Overrides to the default plugin settings. 6297 */ 6298 function _setup(element, options) { 6299 this.$element = element; 6300 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, DropdownMenu.defaults, this.$element.data(), options); 6301 this.className = 'DropdownMenu'; // ie9 back compat 6302 6303 _foundation_util_touch__WEBPACK_IMPORTED_MODULE_5__.Touch.init(jquery__WEBPACK_IMPORTED_MODULE_0___default()); // Touch init is idempotent, we just need to make sure it's initialied. 6304 6305 this._init(); 6306 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.register('DropdownMenu', { 6307 'ENTER': 'open', 6308 'SPACE': 'open', 6309 'ARROW_RIGHT': 'next', 6310 'ARROW_UP': 'up', 6311 'ARROW_DOWN': 'down', 6312 'ARROW_LEFT': 'previous', 6313 'ESCAPE': 'close' 6314 }); 6315 } 6316 6317 /** 6318 * Initializes the plugin, and calls _prepareMenu 6319 * @private 6320 * @function 6321 */ 6322 }, { 6323 key: "_init", 6324 value: function _init() { 6325 _foundation_util_nest__WEBPACK_IMPORTED_MODULE_3__.Nest.Feather(this.$element, 'dropdown'); 6326 var subs = this.$element.find('li.is-dropdown-submenu-parent'); 6327 this.$element.children('.is-dropdown-submenu-parent').children('.is-dropdown-submenu').addClass('first-sub'); 6328 this.$menuItems = this.$element.find('li[role="none"]'); 6329 this.$tabs = this.$element.children('li[role="none"]'); 6330 this.$tabs.find('ul.is-dropdown-submenu').addClass(this.options.verticalClass); 6331 if (this.options.alignment === 'auto') { 6332 if (this.$element.hasClass(this.options.rightClass) || (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.rtl)() || this.$element.parents('.top-bar-right').is('*')) { 6333 this.options.alignment = 'right'; 6334 subs.addClass('opens-left'); 6335 } else { 6336 this.options.alignment = 'left'; 6337 subs.addClass('opens-right'); 6338 } 6339 } else { 6340 if (this.options.alignment === 'right') { 6341 subs.addClass('opens-left'); 6342 } else { 6343 subs.addClass('opens-right'); 6344 } 6345 } 6346 this.changed = false; 6347 this._events(); 6348 } 6349 }, { 6350 key: "_isVertical", 6351 value: function _isVertical() { 6352 return this.$tabs.css('display') === 'block' || this.$element.css('flex-direction') === 'column'; 6353 } 6354 }, { 6355 key: "_isRtl", 6356 value: function _isRtl() { 6357 return this.$element.hasClass('align-right') || (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.rtl)() && !this.$element.hasClass('align-left'); 6358 } 6359 6360 /** 6361 * Adds event listeners to elements within the menu 6362 * @private 6363 * @function 6364 */ 6365 }, { 6366 key: "_events", 6367 value: function _events() { 6368 var _this = this, 6369 hasTouch = 'ontouchstart' in window || typeof window.ontouchstart !== 'undefined', 6370 parClass = 'is-dropdown-submenu-parent'; 6371 6372 // used for onClick and in the keyboard handlers 6373 var handleClickFn = function handleClickFn(e) { 6374 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target).parentsUntil('ul', ".".concat(parClass)), 6375 hasSub = $elem.hasClass(parClass), 6376 hasClicked = $elem.attr('data-is-click') === 'true', 6377 $sub = $elem.children('.is-dropdown-submenu'); 6378 if (hasSub) { 6379 if (hasClicked) { 6380 if (!_this.options.closeOnClick || !_this.options.clickOpen && !hasTouch || _this.options.forceFollow && hasTouch) { 6381 return; 6382 } 6383 e.stopImmediatePropagation(); 6384 e.preventDefault(); 6385 _this._hide($elem); 6386 } else { 6387 e.stopImmediatePropagation(); 6388 e.preventDefault(); 6389 _this._show($sub); 6390 $elem.add($elem.parentsUntil(_this.$element, ".".concat(parClass))).attr('data-is-click', true); 6391 } 6392 } 6393 }; 6394 if (this.options.clickOpen || hasTouch) { 6395 this.$menuItems.on('click.zf.dropdownMenu touchstart.zf.dropdownMenu', handleClickFn); 6396 } 6397 6398 // Handle Leaf element Clicks 6399 if (_this.options.closeOnClickInside) { 6400 this.$menuItems.on('click.zf.dropdownMenu', function () { 6401 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 6402 hasSub = $elem.hasClass(parClass); 6403 if (!hasSub) { 6404 _this._hide(); 6405 } 6406 }); 6407 } 6408 if (hasTouch && this.options.disableHoverOnTouch) this.options.disableHover = true; 6409 if (!this.options.disableHover) { 6410 this.$menuItems.on('mouseenter.zf.dropdownMenu', function () { 6411 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 6412 hasSub = $elem.hasClass(parClass); 6413 if (hasSub) { 6414 clearTimeout($elem.data('_delay')); 6415 $elem.data('_delay', setTimeout(function () { 6416 _this._show($elem.children('.is-dropdown-submenu')); 6417 }, _this.options.hoverDelay)); 6418 } 6419 }).on('mouseleave.zf.dropdownMenu', (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.ignoreMousedisappear)(function () { 6420 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 6421 hasSub = $elem.hasClass(parClass); 6422 if (hasSub && _this.options.autoclose) { 6423 if ($elem.attr('data-is-click') === 'true' && _this.options.clickOpen) { 6424 return false; 6425 } 6426 clearTimeout($elem.data('_delay')); 6427 $elem.data('_delay', setTimeout(function () { 6428 _this._hide($elem); 6429 }, _this.options.closingTime)); 6430 } 6431 })); 6432 } 6433 this.$menuItems.on('keydown.zf.dropdownMenu', function (e) { 6434 var $element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target).parentsUntil('ul', '[role="none"]'), 6435 isTab = _this.$tabs.index($element) > -1, 6436 $elements = isTab ? _this.$tabs : $element.siblings('li').add($element), 6437 $prevElement, 6438 $nextElement; 6439 $elements.each(function (i) { 6440 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).is($element)) { 6441 $prevElement = $elements.eq(i - 1); 6442 $nextElement = $elements.eq(i + 1); 6443 return; 6444 } 6445 }); 6446 var nextSibling = function nextSibling() { 6447 $nextElement.children('a:first').focus(); 6448 e.preventDefault(); 6449 }, 6450 prevSibling = function prevSibling() { 6451 $prevElement.children('a:first').focus(); 6452 e.preventDefault(); 6453 }, 6454 openSub = function openSub() { 6455 var $sub = $element.children('ul.is-dropdown-submenu'); 6456 if ($sub.length) { 6457 _this._show($sub); 6458 $element.find('li > a:first').focus(); 6459 e.preventDefault(); 6460 } else { 6461 return; 6462 } 6463 }, 6464 closeSub = function closeSub() { 6465 //if ($element.is(':first-child')) { 6466 var close = $element.parent('ul').parent('li'); 6467 close.children('a:first').focus(); 6468 _this._hide(close); 6469 e.preventDefault(); 6470 //} 6471 }; 6472 var functions = { 6473 open: openSub, 6474 close: function close() { 6475 _this._hide(_this.$element); 6476 _this.$menuItems.eq(0).children('a').focus(); // focus to first element 6477 e.preventDefault(); 6478 } 6479 }; 6480 if (isTab) { 6481 if (_this._isVertical()) { 6482 // vertical menu 6483 if (_this._isRtl()) { 6484 // right aligned 6485 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6486 down: nextSibling, 6487 up: prevSibling, 6488 next: closeSub, 6489 previous: openSub 6490 }); 6491 } else { 6492 // left aligned 6493 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6494 down: nextSibling, 6495 up: prevSibling, 6496 next: openSub, 6497 previous: closeSub 6498 }); 6499 } 6500 } else { 6501 // horizontal menu 6502 if (_this._isRtl()) { 6503 // right aligned 6504 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6505 next: prevSibling, 6506 previous: nextSibling, 6507 down: openSub, 6508 up: closeSub 6509 }); 6510 } else { 6511 // left aligned 6512 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6513 next: nextSibling, 6514 previous: prevSibling, 6515 down: openSub, 6516 up: closeSub 6517 }); 6518 } 6519 } 6520 } else { 6521 // not tabs -> one sub 6522 if (_this._isRtl()) { 6523 // right aligned 6524 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6525 next: closeSub, 6526 previous: openSub, 6527 down: nextSibling, 6528 up: prevSibling 6529 }); 6530 } else { 6531 // left aligned 6532 jquery__WEBPACK_IMPORTED_MODULE_0___default().extend(functions, { 6533 next: openSub, 6534 previous: closeSub, 6535 down: nextSibling, 6536 up: prevSibling 6537 }); 6538 } 6539 } 6540 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.handleKey(e, 'DropdownMenu', functions); 6541 }); 6542 } 6543 6544 /** 6545 * Adds an event handler to the body to close any dropdowns on a click. 6546 * @function 6547 * @private 6548 */ 6549 }, { 6550 key: "_addBodyHandler", 6551 value: function _addBodyHandler() { 6552 var _this2 = this; 6553 var $body = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document.body); 6554 this._removeBodyHandler(); 6555 $body.on('click.zf.dropdownMenu tap.zf.dropdownMenu', function (e) { 6556 var isItself = !!jquery__WEBPACK_IMPORTED_MODULE_0___default()(e.target).closest(_this2.$element).length; 6557 if (isItself) return; 6558 _this2._hide(); 6559 _this2._removeBodyHandler(); 6560 }); 6561 } 6562 6563 /** 6564 * Remove the body event handler. See `_addBodyHandler`. 6565 * @function 6566 * @private 6567 */ 6568 }, { 6569 key: "_removeBodyHandler", 6570 value: function _removeBodyHandler() { 6571 jquery__WEBPACK_IMPORTED_MODULE_0___default()(document.body).off('click.zf.dropdownMenu tap.zf.dropdownMenu'); 6572 } 6573 6574 /**
vendor: 13,137 bytes, lines 6575-6864
6575 * Opens a dropdown pane, and checks for collisions first. 6576 * @param {jQuery} $sub - ul element that is a submenu to show 6577 * @function 6578 * @private 6579 * @fires DropdownMenu#show 6580 */ 6581 }, { 6582 key: "_show", 6583 value: function _show($sub) { 6584 var idx = this.$tabs.index(this.$tabs.filter(function (i, el) { 6585 return jquery__WEBPACK_IMPORTED_MODULE_0___default()(el).find($sub).length > 0; 6586 })); 6587 var $sibs = $sub.parent('li.is-dropdown-submenu-parent').siblings('li.is-dropdown-submenu-parent'); 6588 this._hide($sibs, idx); 6589 $sub.css('visibility', 'hidden').addClass('js-dropdown-active').parent('li.is-dropdown-submenu-parent').addClass('is-active'); 6590 var clear = _foundation_util_box__WEBPACK_IMPORTED_MODULE_4__.Box.ImNotTouchingYou($sub, null, true); 6591 if (!clear) { 6592 var oldClass = this.options.alignment === 'left' ? '-right' : '-left', 6593 $parentLi = $sub.parent('.is-dropdown-submenu-parent'); 6594 $parentLi.removeClass("opens".concat(oldClass)).addClass("opens-".concat(this.options.alignment)); 6595 clear = _foundation_util_box__WEBPACK_IMPORTED_MODULE_4__.Box.ImNotTouchingYou($sub, null, true); 6596 if (!clear) { 6597 $parentLi.removeClass("opens-".concat(this.options.alignment)).addClass('opens-inner'); 6598 } 6599 this.changed = true; 6600 } 6601 $sub.css('visibility', ''); 6602 if (this.options.closeOnClick) { 6603 this._addBodyHandler(); 6604 } 6605 /** 6606 * Fires when the new dropdown pane is visible. 6607 * @event DropdownMenu#show 6608 */ 6609 this.$element.trigger('show.zf.dropdownMenu', [$sub]); 6610 } 6611 6612 /** 6613 * Hides a single, currently open dropdown pane, if passed a parameter, otherwise, hides everything. 6614 * @function 6615 * @param {jQuery} $elem - element with a submenu to hide 6616 * @param {Number} idx - index of the $tabs collection to hide 6617 * @fires DropdownMenu#hide 6618 * @private 6619 */ 6620 }, { 6621 key: "_hide", 6622 value: function _hide($elem, idx) { 6623 var $toClose; 6624 if ($elem && $elem.length) { 6625 $toClose = $elem; 6626 } else if (typeof idx !== 'undefined') { 6627 $toClose = this.$tabs.not(function (i) { 6628 return i === idx; 6629 }); 6630 } else { 6631 $toClose = this.$element; 6632 } 6633 var somethingToClose = $toClose.hasClass('is-active') || $toClose.find('.is-active').length > 0; 6634 if (somethingToClose) { 6635 var $activeItem = $toClose.find('li.is-active'); 6636 $activeItem.add($toClose).attr({ 6637 'data-is-click': false 6638 }).removeClass('is-active'); 6639 $toClose.find('ul.js-dropdown-active').removeClass('js-dropdown-active'); 6640 if (this.changed || $toClose.find('opens-inner').length) { 6641 var oldClass = this.options.alignment === 'left' ? 'right' : 'left'; 6642 $toClose.find('li.is-dropdown-submenu-parent').add($toClose).removeClass("opens-inner opens-".concat(this.options.alignment)).addClass("opens-".concat(oldClass)); 6643 this.changed = false; 6644 } 6645 clearTimeout($activeItem.data('_delay')); 6646 this._removeBodyHandler(); 6647 6648 /** 6649 * Fires when the open menus are closed. 6650 * @event DropdownMenu#hide 6651 */ 6652 this.$element.trigger('hide.zf.dropdownMenu', [$toClose]); 6653 } 6654 } 6655 6656 /** 6657 * Destroys the plugin. 6658 * @function 6659 */ 6660 }, { 6661 key: "_destroy", 6662 value: function _destroy() { 6663 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'); 6664 jquery__WEBPACK_IMPORTED_MODULE_0___default()(document.body).off('.zf.dropdownMenu'); 6665 _foundation_util_nest__WEBPACK_IMPORTED_MODULE_3__.Nest.Burn(this.$element, 'dropdown'); 6666 } 6667 }]); 6668 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 6669 /** 6670 * Default settings for plugin 6671 */ 6672 DropdownMenu.defaults = { 6673 /** 6674 * Disallows hover events from opening submenus 6675 * @option 6676 * @type {boolean} 6677 * @default false 6678 */ 6679 disableHover: false, 6680 /** 6681 * Disallows hover on touch devices 6682 * @option 6683 * @type {boolean} 6684 * @default true 6685 */ 6686 disableHoverOnTouch: true, 6687 /** 6688 * Allow a submenu to automatically close on a mouseleave event, if not clicked open. 6689 * @option 6690 * @type {boolean} 6691 * @default true 6692 */ 6693 autoclose: true, 6694 /** 6695 * Amount of time to delay opening a submenu on hover event. 6696 * @option 6697 * @type {number} 6698 * @default 50 6699 */ 6700 hoverDelay: 50, 6701 /** 6702 * Allow a submenu to open/remain open on parent click event. Allows cursor to move away from menu. 6703 * @option 6704 * @type {boolean} 6705 * @default false 6706 */ 6707 clickOpen: false, 6708 /** 6709 * Amount of time to delay closing a submenu on a mouseleave event. 6710 * @option 6711 * @type {number} 6712 * @default 500 6713 */ 6714 6715 closingTime: 500, 6716 /** 6717 * Position of the menu relative to what direction the submenus should open. Handled by JS. Can be `'auto'`, `'left'` or `'right'`. 6718 * @option 6719 * @type {string} 6720 * @default 'auto' 6721 */ 6722 alignment: 'auto', 6723 /** 6724 * Allow clicks on the body to close any open submenus. 6725 * @option 6726 * @type {boolean} 6727 * @default true 6728 */ 6729 closeOnClick: true, 6730 /** 6731 * Allow clicks on leaf anchor links to close any open submenus. 6732 * @option 6733 * @type {boolean} 6734 * @default true 6735 */ 6736 closeOnClickInside: true, 6737 /** 6738 * Class applied to vertical oriented menus, Foundation default is `vertical`. Update this if using your own class. 6739 * @option 6740 * @type {string} 6741 * @default 'vertical' 6742 */ 6743 verticalClass: 'vertical', 6744 /** 6745 * Class applied to right-side oriented menus, Foundation default is `align-right`. Update this if using your own class. 6746 * @option 6747 * @type {string} 6748 * @default 'align-right' 6749 */ 6750 rightClass: 'align-right', 6751 /** 6752 * Boolean to force overide the clicking of links to perform default action, on second touch event for mobile. 6753 * @option 6754 * @type {boolean} 6755 * @default true 6756 */ 6757 forceFollow: true 6758 }; 6759 6760 /***/ 6761 }), 6762 /***/"./foundation.core": ( 6763 /*!****************************************************************************************************************************************************************!*\ 6764 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 6765 \****************************************************************************************************************************************************************/ 6766 /***/ 6767 function (module) { 6768 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 6769 6770 /***/ 6771 }), 6772 /***/"./foundation.util.box": ( 6773 /*!********************************************************************************************************************************************************************************!*\ 6774 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.box"],"amd":"./foundation.util.box","commonjs":"./foundation.util.box","commonjs2":"./foundation.util.box"} ***! 6775 \********************************************************************************************************************************************************************************/ 6776 /***/ 6777 function (module) { 6778 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_box__; 6779 6780 /***/ 6781 }), 6782 /***/"./foundation.util.keyboard": ( 6783 /*!****************************************************************************************************************************************************************************************************!*\ 6784 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.keyboard"],"amd":"./foundation.util.keyboard","commonjs":"./foundation.util.keyboard","commonjs2":"./foundation.util.keyboard"} ***! 6785 \****************************************************************************************************************************************************************************************************/ 6786 /***/ 6787 function (module) { 6788 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__; 6789 6790 /***/ 6791 }), 6792 /***/"./foundation.util.nest": ( 6793 /*!************************************************************************************************************************************************************************************!*\ 6794 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.nest"],"amd":"./foundation.util.nest","commonjs":"./foundation.util.nest","commonjs2":"./foundation.util.nest"} ***! 6795 \************************************************************************************************************************************************************************************/ 6796 /***/ 6797 function (module) { 6798 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_nest__; 6799 6800 /***/ 6801 }), 6802 /***/"./foundation.util.touch": ( 6803 /*!****************************************************************************************************************************************************************************************!*\ 6804 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.touch"],"amd":"./foundation.util.touch","commonjs":"./foundation.util.touch","commonjs2":"./foundation.util.touch"} ***! 6805 \****************************************************************************************************************************************************************************************/ 6806 /***/ 6807 function (module) { 6808 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_touch__; 6809 6810 /***/ 6811 }), 6812 /***/"jquery": ( 6813 /*!********************************************************************************************!*\ 6814 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 6815 \********************************************************************************************/ 6816 /***/ 6817 function (module) { 6818 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 6819 6820 /***/ 6821 }) 6822 6823 /******/ 6824 }; 6825 /************************************************************************/ 6826 /******/ // The module cache 6827 /******/ 6828 var __webpack_module_cache__ = {}; 6829 /******/ 6830 /******/ // The require function 6831 /******/ 6832 function __webpack_require__(moduleId) { 6833 /******/ // Check if module is in cache 6834 /******/var cachedModule = __webpack_module_cache__[moduleId]; 6835 /******/ 6836 if (cachedModule !== undefined) { 6837 /******/return cachedModule.exports; 6838 /******/ 6839 } 6840 /******/ // Create a new module (and put it into the cache) 6841 /******/ 6842 var module = __webpack_module_cache__[moduleId] = { 6843 /******/ // no module.id needed 6844 /******/ // no module.loaded needed 6845 /******/exports: {} 6846 /******/ 6847 }; 6848 /******/ 6849 /******/ // Execute the module function 6850 /******/ 6851 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 6852 /******/ 6853 /******/ // Return the exports of the module 6854 /******/ 6855 return module.exports; 6856 /******/ 6857 } 6858 /******/ 6859 /************************************************************************/ 6860 /******/ /* webpack/runtime/compat get default export */ 6861 /******/ 6862 !function () { 6863 /******/ // getDefaultExport function for compatibility with non-harmony modules 6864 /******/__webpack_require__.n = function (module) {
vendor: 4,911 bytes, lines 6865-6971
6865 /******/var getter = module && module.__esModule ? /******/function () { 6866 return module['default']; 6867 } : /******/function () { 6868 return module; 6869 }; 6870 /******/ 6871 __webpack_require__.d(getter, { 6872 a: getter 6873 }); 6874 /******/ 6875 return getter; 6876 /******/ 6877 }; 6878 /******/ 6879 }(); 6880 /******/ 6881 /******/ /* webpack/runtime/define property getters */ 6882 /******/ 6883 !function () { 6884 /******/ // define getter functions for harmony exports 6885 /******/__webpack_require__.d = function (exports, definition) { 6886 /******/for (var key in definition) { 6887 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 6888 /******/Object.defineProperty(exports, key, { 6889 enumerable: true, 6890 get: definition[key] 6891 }); 6892 /******/ 6893 } 6894 /******/ 6895 } 6896 /******/ 6897 }; 6898 /******/ 6899 }(); 6900 /******/ 6901 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 6902 /******/ 6903 !function () { 6904 /******/__webpack_require__.o = function (obj, prop) { 6905 return Object.prototype.hasOwnProperty.call(obj, prop); 6906 }; 6907 /******/ 6908 }(); 6909 /******/ 6910 /******/ /* webpack/runtime/make namespace object */ 6911 /******/ 6912 !function () { 6913 /******/ // define __esModule on exports 6914 /******/__webpack_require__.r = function (exports) { 6915 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 6916 /******/Object.defineProperty(exports, Symbol.toStringTag, { 6917 value: 'Module' 6918 }); 6919 /******/ 6920 } 6921 /******/ 6922 Object.defineProperty(exports, '__esModule', { 6923 value: true 6924 }); 6925 /******/ 6926 }; 6927 /******/ 6928 }(); 6929 /******/ 6930 /************************************************************************/ 6931 var __webpack_exports__ = {}; 6932 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 6933 !function () { 6934 /*!*******************************************************!*\ 6935 !*** ./js/entries/plugins/foundation.dropdownMenu.js ***! 6936 \*******************************************************/ 6937 __webpack_require__.r(__webpack_exports__); 6938 /* harmony export */ 6939 __webpack_require__.d(__webpack_exports__, { 6940 /* harmony export */DropdownMenu: function () { 6941 return /* reexport safe */_foundation_dropdownMenu__WEBPACK_IMPORTED_MODULE_1__.DropdownMenu; 6942 }, 6943 /* harmony export */Foundation: function () { 6944 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 6945 } 6946 /* harmony export */ 6947 }); 6948 /* harmony import */ 6949 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 6950 /* harmony import */ 6951 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 6952 /* harmony import */ 6953 var _foundation_dropdownMenu__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.dropdownMenu */"./js/foundation.dropdownMenu.js"); 6954 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_dropdownMenu__WEBPACK_IMPORTED_MODULE_1__.DropdownMenu, 'DropdownMenu'); 6955 }(); 6956 /******/ 6957 return __webpack_exports__; 6958 /******/ 6959 }(); 6960}); 6961(function webpackUniversalModuleDefinition(root, factory) { 6962 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.imageLoader"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.mediaQuery", "./foundation.util.imageLoader"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.imageLoader"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.equalizer"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.imageLoader"]); 6963})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_imageLoader__) { 6964 return /******/function () { 6965 // webpackBootstrap 6966 /******/ 6967 "use strict"; 6968 6969 /******/ 6970 var __webpack_modules__ = { 6971
vendor: 16,827 bytes, lines 6971-7354
6971/***/"./js/foundation.equalizer.js": ( 6972 /*!************************************!*\ 6973 !*** ./js/foundation.equalizer.js ***! 6974 \************************************/ 6975 /***/ 6976 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 6977 __webpack_require__.r(__webpack_exports__); 6978 /* harmony export */ 6979 __webpack_require__.d(__webpack_exports__, { 6980 /* harmony export */Equalizer: function () { 6981 return /* binding */Equalizer; 6982 } 6983 /* harmony export */ 6984 }); 6985 /* harmony import */ 6986 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 6987 /* harmony import */ 6988 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 6989 /* harmony import */ 6990 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./foundation.util.mediaQuery"); 6991 /* harmony import */ 6992 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__); 6993 /* harmony import */ 6994 var _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.imageLoader */"./foundation.util.imageLoader"); 6995 /* harmony import */ 6996 var _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_2__); 6997 /* harmony import */ 6998 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.core.plugin */"./foundation.core"); 6999 /* harmony import */ 7000 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__); 7001 function _typeof(o) { 7002 "@babel/helpers - typeof"; 7003 7004 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 7005 return typeof o; 7006 } : function (o) { 7007 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 7008 }, _typeof(o); 7009 } 7010 function _classCallCheck(a, n) { 7011 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 7012 } 7013 function _defineProperties(e, r) { 7014 for (var t = 0; t < r.length; t++) { 7015 var o = r[t]; 7016 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 7017 } 7018 } 7019 function _createClass(e, r, t) { 7020 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 7021 writable: !1 7022 }), e; 7023 } 7024 function _toPropertyKey(t) { 7025 var i = _toPrimitive(t, "string"); 7026 return "symbol" == _typeof(i) ? i : i + ""; 7027 } 7028 function _toPrimitive(t, r) { 7029 if ("object" != _typeof(t) || !t) return t; 7030 var e = t[Symbol.toPrimitive]; 7031 if (void 0 !== e) { 7032 var i = e.call(t, r || "default"); 7033 if ("object" != _typeof(i)) return i; 7034 throw new TypeError("@@toPrimitive must return a primitive value."); 7035 } 7036 return ("string" === r ? String : Number)(t); 7037 } 7038 function _callSuper(t, o, e) { 7039 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 7040 } 7041 function _possibleConstructorReturn(t, e) { 7042 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 7043 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 7044 return _assertThisInitialized(t); 7045 } 7046 function _assertThisInitialized(e) { 7047 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 7048 return e; 7049 } 7050 function _isNativeReflectConstruct() { 7051 try { 7052 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 7053 } catch (t) {} 7054 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 7055 return !!t; 7056 })(); 7057 } 7058 function _getPrototypeOf(t) { 7059 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 7060 return t.__proto__ || Object.getPrototypeOf(t); 7061 }, _getPrototypeOf(t); 7062 } 7063 function _inherits(t, e) { 7064 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 7065 t.prototype = Object.create(e && e.prototype, { 7066 constructor: { 7067 value: t, 7068 writable: !0, 7069 configurable: !0 7070 } 7071 }), Object.defineProperty(t, "prototype", { 7072 writable: !1 7073 }), e && _setPrototypeOf(t, e); 7074 } 7075 function _setPrototypeOf(t, e) { 7076 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 7077 return t.__proto__ = e, t; 7078 }, _setPrototypeOf(t, e); 7079 } 7080 7081 /** 7082 * Equalizer module. 7083 * @module foundation.equalizer 7084 * @requires foundation.util.mediaQuery 7085 * @requires foundation.util.imageLoader if equalizer contains images 7086 */ 7087 var Equalizer = /*#__PURE__*/function (_Plugin) { 7088 function Equalizer() { 7089 _classCallCheck(this, Equalizer); 7090 return _callSuper(this, Equalizer, arguments); 7091 } 7092 _inherits(Equalizer, _Plugin); 7093 return _createClass(Equalizer, [{ 7094 key: "_setup", 7095 value: 7096 /** 7097 * Creates a new instance of Equalizer. 7098 * @class 7099 * @name Equalizer 7100 * @fires Equalizer#init 7101 * @param {Object} element - jQuery object to add the trigger to. 7102 * @param {Object} options - Overrides to the default plugin settings. 7103 */ 7104 function _setup(element, options) { 7105 this.$element = element; 7106 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, Equalizer.defaults, this.$element.data(), options); 7107 this.className = 'Equalizer'; // ie9 back compat 7108 7109 this._init(); 7110 } 7111 7112 /** 7113 * Initializes the Equalizer plugin and calls functions to get equalizer functioning on load. 7114 * @private 7115 */ 7116 }, { 7117 key: "_init", 7118 value: function _init() { 7119 var eqId = this.$element.attr('data-equalizer') || ''; 7120 var $watched = this.$element.find("[data-equalizer-watch=\"".concat(eqId, "\"]")); 7121 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery._init(); 7122 this.$watched = $watched.length ? $watched : this.$element.find('[data-equalizer-watch]'); 7123 this.$element.attr('data-resize', eqId || (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.GetYoDigits)(6, 'eq')); 7124 this.$element.attr('data-mutate', eqId || (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.GetYoDigits)(6, 'eq')); 7125 this.hasNested = this.$element.find('[data-equalizer]').length > 0; 7126 this.isNested = this.$element.parentsUntil(document.body, '[data-equalizer]').length > 0; 7127 this.isOn = false; 7128 this._bindHandler = { 7129 onResizeMeBound: this._onResizeMe.bind(this), 7130 onPostEqualizedBound: this._onPostEqualized.bind(this) 7131 }; 7132 var imgs = this.$element.find('img'); 7133 var tooSmall; 7134 if (this.options.equalizeOn) { 7135 tooSmall = this._checkMQ(); 7136 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('changed.zf.mediaquery', this._checkMQ.bind(this)); 7137 } else { 7138 this._events(); 7139 } 7140 if (typeof tooSmall !== 'undefined' && tooSmall === false || typeof tooSmall === 'undefined') { 7141 if (imgs.length) { 7142 (0, _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_2__.onImagesLoaded)(imgs, this._reflow.bind(this)); 7143 } else { 7144 this._reflow(); 7145 } 7146 } 7147 } 7148 7149 /** 7150 * Removes event listeners if the breakpoint is too small. 7151 * @private 7152 */ 7153 }, { 7154 key: "_pauseEvents", 7155 value: function _pauseEvents() { 7156 this.isOn = false; 7157 this.$element.off({ 7158 '.zf.equalizer': this._bindHandler.onPostEqualizedBound, 7159 'resizeme.zf.trigger': this._bindHandler.onResizeMeBound, 7160 'mutateme.zf.trigger': this._bindHandler.onResizeMeBound 7161 }); 7162 } 7163 7164 /** 7165 * function to handle $elements resizeme.zf.trigger, with bound this on _bindHandler.onResizeMeBound 7166 * @private 7167 */ 7168 }, { 7169 key: "_onResizeMe", 7170 value: function _onResizeMe() { 7171 this._reflow(); 7172 } 7173 7174 /** 7175 * function to handle $elements postequalized.zf.equalizer, with bound this on _bindHandler.onPostEqualizedBound 7176 * @private 7177 */ 7178 }, { 7179 key: "_onPostEqualized", 7180 value: function _onPostEqualized(e) { 7181 if (e.target !== this.$element[0]) { 7182 this._reflow(); 7183 } 7184 } 7185 7186 /** 7187 * Initializes events for Equalizer. 7188 * @private 7189 */ 7190 }, { 7191 key: "_events", 7192 value: function _events() { 7193 this._pauseEvents(); 7194 if (this.hasNested) { 7195 this.$element.on('postequalized.zf.equalizer', this._bindHandler.onPostEqualizedBound); 7196 } else { 7197 this.$element.on('resizeme.zf.trigger', this._bindHandler.onResizeMeBound); 7198 this.$element.on('mutateme.zf.trigger', this._bindHandler.onResizeMeBound); 7199 } 7200 this.isOn = true; 7201 } 7202 7203 /** 7204 * Checks the current breakpoint to the minimum required size. 7205 * @private 7206 */ 7207 }, { 7208 key: "_checkMQ", 7209 value: function _checkMQ() { 7210 var tooSmall = !_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery.is(this.options.equalizeOn); 7211 if (tooSmall) { 7212 if (this.isOn) { 7213 this._pauseEvents(); 7214 this.$watched.css('height', 'auto'); 7215 } 7216 } else { 7217 if (!this.isOn) { 7218 this._events(); 7219 } 7220 } 7221 return tooSmall; 7222 } 7223 7224 /** 7225 * A noop version for the plugin 7226 * @private 7227 */ 7228 }, { 7229 key: "_killswitch", 7230 value: function _killswitch() { 7231 return; 7232 } 7233 7234 /** 7235 * Calls necessary functions to update Equalizer upon DOM change 7236 * @private 7237 */ 7238 }, { 7239 key: "_reflow", 7240 value: function _reflow() { 7241 if (!this.options.equalizeOnStack) { 7242 if (this._isStacked()) { 7243 this.$watched.css('height', 'auto'); 7244 return false; 7245 } 7246 } 7247 if (this.options.equalizeByRow) { 7248 this.getHeightsByRow(this.applyHeightByRow.bind(this)); 7249 } else { 7250 this.getHeights(this.applyHeight.bind(this)); 7251 } 7252 } 7253 7254 /** 7255 * Manually determines if the first 2 elements are *NOT* stacked. 7256 * @private 7257 */ 7258 }, { 7259 key: "_isStacked", 7260 value: function _isStacked() { 7261 if (!this.$watched[0] || !this.$watched[1]) { 7262 return true; 7263 } 7264 return this.$watched[0].getBoundingClientRect().top !== this.$watched[1].getBoundingClientRect().top; 7265 } 7266 7267 /** 7268 * Finds the outer heights of children contained within an Equalizer parent and returns them in an array 7269 * @param {Function} cb - A non-optional callback to return the heights array to. 7270 * @returns {Array} heights - An array of heights of children within Equalizer container 7271 */ 7272 }, { 7273 key: "getHeights", 7274 value: function getHeights(cb) { 7275 var heights = []; 7276 for (var i = 0, len = this.$watched.length; i < len; i++) { 7277 this.$watched[i].style.height = 'auto'; 7278 heights.push(this.$watched[i].offsetHeight); 7279 } 7280 cb(heights); 7281 } 7282 7283 /** 7284 * Finds the outer heights of children contained within an Equalizer parent and returns them in an array 7285 * @param {Function} cb - A non-optional callback to return the heights array to. 7286 * @returns {Array} groups - An array of heights of children within Equalizer container grouped by row with element,height and max as last child 7287 */ 7288 }, { 7289 key: "getHeightsByRow", 7290 value: function getHeightsByRow(cb) { 7291 var lastElTopOffset = this.$watched.length ? this.$watched.first().offset().top : 0, 7292 groups = [], 7293 group = 0; 7294 //group by Row 7295 groups[group] = []; 7296 for (var i = 0, len = this.$watched.length; i < len; i++) { 7297 this.$watched[i].style.height = 'auto'; 7298 //maybe could use this.$watched[i].offsetTop 7299 var elOffsetTop = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.$watched[i]).offset().top; 7300 if (elOffsetTop !== lastElTopOffset) { 7301 group++; 7302 groups[group] = []; 7303 lastElTopOffset = elOffsetTop; 7304 } 7305 groups[group].push([this.$watched[i], this.$watched[i].offsetHeight]); 7306 } 7307 for (var j = 0, ln = groups.length; j < ln; j++) { 7308 var heights = jquery__WEBPACK_IMPORTED_MODULE_0___default()(groups[j]).map(function () { 7309 return this[1]; 7310 }).get(); 7311 var max = Math.max.apply(null, heights); 7312 groups[j].push(max); 7313 } 7314 cb(groups); 7315 } 7316 7317 /** 7318 * Changes the CSS height property of each child in an Equalizer parent to match the tallest 7319 * @param {array} heights - An array of heights of children within Equalizer container 7320 * @fires Equalizer#preequalized 7321 * @fires Equalizer#postequalized 7322 */ 7323 }, { 7324 key: "applyHeight", 7325 value: function applyHeight(heights) { 7326 var max = Math.max.apply(null, heights); 7327 /** 7328 * Fires before the heights are applied 7329 * @event Equalizer#preequalized 7330 */ 7331 this.$element.trigger('preequalized.zf.equalizer'); 7332 this.$watched.css('height', max); 7333 7334 /** 7335 * Fires when the heights have been applied 7336 * @event Equalizer#postequalized 7337 */ 7338 this.$element.trigger('postequalized.zf.equalizer'); 7339 } 7340 7341 /** 7342 * Changes the CSS height property of each child in an Equalizer parent to match the tallest by row 7343 * @param {array} groups - An array of heights of children within Equalizer container grouped by row with element,height and max as last child 7344 * @fires Equalizer#preequalized 7345 * @fires Equalizer#preequalizedrow 7346 * @fires Equalizer#postequalizedrow 7347 * @fires Equalizer#postequalized 7348 */ 7349 }, { 7350 key: "applyHeightByRow", 7351 value: function applyHeightByRow(groups) { 7352 /** 7353 * Fires before the heights are applied 7354 */
vendor: 6,766 bytes, lines 7355-7510
7355 this.$element.trigger('preequalized.zf.equalizer'); 7356 for (var i = 0, len = groups.length; i < len; i++) { 7357 var groupsILength = groups[i].length, 7358 max = groups[i][groupsILength - 1]; 7359 if (groupsILength <= 2) { 7360 jquery__WEBPACK_IMPORTED_MODULE_0___default()(groups[i][0][0]).css({ 7361 'height': 'auto' 7362 }); 7363 continue; 7364 } 7365 /** 7366 * Fires before the heights per row are applied 7367 * @event Equalizer#preequalizedrow 7368 */ 7369 this.$element.trigger('preequalizedrow.zf.equalizer'); 7370 for (var j = 0, lenJ = groupsILength - 1; j < lenJ; j++) { 7371 jquery__WEBPACK_IMPORTED_MODULE_0___default()(groups[i][j][0]).css({ 7372 'height': max 7373 }); 7374 } 7375 /** 7376 * Fires when the heights per row have been applied 7377 * @event Equalizer#postequalizedrow 7378 */ 7379 this.$element.trigger('postequalizedrow.zf.equalizer'); 7380 } 7381 /** 7382 * Fires when the heights have been applied 7383 */ 7384 this.$element.trigger('postequalized.zf.equalizer'); 7385 } 7386 7387 /** 7388 * Destroys an instance of Equalizer. 7389 * @function 7390 */ 7391 }, { 7392 key: "_destroy", 7393 value: function _destroy() { 7394 this._pauseEvents(); 7395 this.$watched.css('height', 'auto'); 7396 } 7397 }]); 7398 }(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_3__.Plugin); 7399 /** 7400 * Default settings for plugin 7401 */ 7402 Equalizer.defaults = { 7403 /** 7404 * Enable height equalization when stacked on smaller screens. 7405 * @option 7406 * @type {boolean} 7407 * @default false 7408 */ 7409 equalizeOnStack: false, 7410 /** 7411 * Enable height equalization row by row. 7412 * @option 7413 * @type {boolean} 7414 * @default false 7415 */ 7416 equalizeByRow: false, 7417 /** 7418 * String representing the minimum breakpoint size the plugin should equalize heights on. 7419 * @option 7420 * @type {string} 7421 * @default '' 7422 */ 7423 equalizeOn: '' 7424 }; 7425 7426 /***/ 7427 }), 7428 /***/"./foundation.core": ( 7429 /*!****************************************************************************************************************************************************************!*\ 7430 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 7431 \****************************************************************************************************************************************************************/ 7432 /***/ 7433 function (module) { 7434 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 7435 7436 /***/ 7437 }), 7438 /***/"./foundation.util.imageLoader": ( 7439 /*!****************************************************************************************************************************************************************************************************************!*\ 7440 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.imageLoader"],"amd":"./foundation.util.imageLoader","commonjs":"./foundation.util.imageLoader","commonjs2":"./foundation.util.imageLoader"} ***! 7441 \****************************************************************************************************************************************************************************************************************/ 7442 /***/ 7443 function (module) { 7444 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_imageLoader__; 7445 7446 /***/ 7447 }), 7448 /***/"./foundation.util.mediaQuery": ( 7449 /*!************************************************************************************************************************************************************************************************************!*\ 7450 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.mediaQuery"],"amd":"./foundation.util.mediaQuery","commonjs":"./foundation.util.mediaQuery","commonjs2":"./foundation.util.mediaQuery"} ***! 7451 \************************************************************************************************************************************************************************************************************/ 7452 /***/ 7453 function (module) { 7454 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__; 7455 7456 /***/ 7457 }), 7458 /***/"jquery": ( 7459 /*!********************************************************************************************!*\ 7460 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 7461 \********************************************************************************************/ 7462 /***/ 7463 function (module) { 7464 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 7465 7466 /***/ 7467 }) 7468 7469 /******/ 7470 }; 7471 /************************************************************************/ 7472 /******/ // The module cache 7473 /******/ 7474 var __webpack_module_cache__ = {}; 7475 /******/ 7476 /******/ // The require function 7477 /******/ 7478 function __webpack_require__(moduleId) { 7479 /******/ // Check if module is in cache 7480 /******/var cachedModule = __webpack_module_cache__[moduleId]; 7481 /******/ 7482 if (cachedModule !== undefined) { 7483 /******/return cachedModule.exports; 7484 /******/ 7485 } 7486 /******/ // Create a new module (and put it into the cache) 7487 /******/ 7488 var module = __webpack_module_cache__[moduleId] = { 7489 /******/ // no module.id needed 7490 /******/ // no module.loaded needed 7491 /******/exports: {} 7492 /******/ 7493 }; 7494 /******/ 7495 /******/ // Execute the module function 7496 /******/ 7497 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 7498 /******/ 7499 /******/ // Return the exports of the module 7500 /******/ 7501 return module.exports; 7502 /******/ 7503 } 7504 /******/ 7505 /************************************************************************/ 7506 /******/ /* webpack/runtime/compat get default export */ 7507 /******/ 7508 !function () { 7509 /******/ // getDefaultExport function for compatibility with non-harmony modules 7510 /******/__webpack_require__.n = function (module) {
vendor: 4,852 bytes, lines 7511-7617
7511 /******/var getter = module && module.__esModule ? /******/function () { 7512 return module['default']; 7513 } : /******/function () { 7514 return module; 7515 }; 7516 /******/ 7517 __webpack_require__.d(getter, { 7518 a: getter 7519 }); 7520 /******/ 7521 return getter; 7522 /******/ 7523 }; 7524 /******/ 7525 }(); 7526 /******/ 7527 /******/ /* webpack/runtime/define property getters */ 7528 /******/ 7529 !function () { 7530 /******/ // define getter functions for harmony exports 7531 /******/__webpack_require__.d = function (exports, definition) { 7532 /******/for (var key in definition) { 7533 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 7534 /******/Object.defineProperty(exports, key, { 7535 enumerable: true, 7536 get: definition[key] 7537 }); 7538 /******/ 7539 } 7540 /******/ 7541 } 7542 /******/ 7543 }; 7544 /******/ 7545 }(); 7546 /******/ 7547 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 7548 /******/ 7549 !function () { 7550 /******/__webpack_require__.o = function (obj, prop) { 7551 return Object.prototype.hasOwnProperty.call(obj, prop); 7552 }; 7553 /******/ 7554 }(); 7555 /******/ 7556 /******/ /* webpack/runtime/make namespace object */ 7557 /******/ 7558 !function () { 7559 /******/ // define __esModule on exports 7560 /******/__webpack_require__.r = function (exports) { 7561 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 7562 /******/Object.defineProperty(exports, Symbol.toStringTag, { 7563 value: 'Module' 7564 }); 7565 /******/ 7566 } 7567 /******/ 7568 Object.defineProperty(exports, '__esModule', { 7569 value: true 7570 }); 7571 /******/ 7572 }; 7573 /******/ 7574 }(); 7575 /******/ 7576 /************************************************************************/ 7577 var __webpack_exports__ = {}; 7578 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 7579 !function () { 7580 /*!****************************************************!*\ 7581 !*** ./js/entries/plugins/foundation.equalizer.js ***! 7582 \****************************************************/ 7583 __webpack_require__.r(__webpack_exports__); 7584 /* harmony export */ 7585 __webpack_require__.d(__webpack_exports__, { 7586 /* harmony export */Equalizer: function () { 7587 return /* reexport safe */_foundation_equalizer__WEBPACK_IMPORTED_MODULE_1__.Equalizer; 7588 }, 7589 /* harmony export */Foundation: function () { 7590 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 7591 } 7592 /* harmony export */ 7593 }); 7594 /* harmony import */ 7595 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 7596 /* harmony import */ 7597 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 7598 /* harmony import */ 7599 var _foundation_equalizer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.equalizer */"./js/foundation.equalizer.js"); 7600 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_equalizer__WEBPACK_IMPORTED_MODULE_1__.Equalizer, 'Equalizer'); 7601 }(); 7602 /******/ 7603 return __webpack_exports__; 7604 /******/ 7605 }(); 7606}); 7607(function webpackUniversalModuleDefinition(root, factory) { 7608 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.mediaQuery", "./foundation.util.motion"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.interchange"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.motion"]); 7609})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__) { 7610 return /******/function () { 7611 // webpackBootstrap 7612 /******/ 7613 "use strict"; 7614 7615 /******/ 7616 var __webpack_modules__ = { 7617
vendor: 12,382 bytes, lines 7617-7898
7617/***/"./js/foundation.interchange.js": ( 7618 /*!**************************************!*\ 7619 !*** ./js/foundation.interchange.js ***! 7620 \**************************************/ 7621 /***/ 7622 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 7623 __webpack_require__.r(__webpack_exports__); 7624 /* harmony export */ 7625 __webpack_require__.d(__webpack_exports__, { 7626 /* harmony export */Interchange: function () { 7627 return /* binding */Interchange; 7628 } 7629 /* harmony export */ 7630 }); 7631 /* harmony import */ 7632 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 7633 /* harmony import */ 7634 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 7635 /* harmony import */ 7636 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./foundation.util.mediaQuery"); 7637 /* harmony import */ 7638 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__); 7639 /* harmony import */ 7640 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 7641 /* harmony import */ 7642 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__); 7643 /* harmony import */ 7644 var _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.util.triggers */"./js/foundation.util.triggers.js"); 7645 function _typeof(o) { 7646 "@babel/helpers - typeof"; 7647 7648 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 7649 return typeof o; 7650 } : function (o) { 7651 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 7652 }, _typeof(o); 7653 } 7654 function _classCallCheck(a, n) { 7655 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 7656 } 7657 function _defineProperties(e, r) { 7658 for (var t = 0; t < r.length; t++) { 7659 var o = r[t]; 7660 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 7661 } 7662 } 7663 function _createClass(e, r, t) { 7664 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 7665 writable: !1 7666 }), e; 7667 } 7668 function _toPropertyKey(t) { 7669 var i = _toPrimitive(t, "string"); 7670 return "symbol" == _typeof(i) ? i : i + ""; 7671 } 7672 function _toPrimitive(t, r) { 7673 if ("object" != _typeof(t) || !t) return t; 7674 var e = t[Symbol.toPrimitive]; 7675 if (void 0 !== e) { 7676 var i = e.call(t, r || "default"); 7677 if ("object" != _typeof(i)) return i; 7678 throw new TypeError("@@toPrimitive must return a primitive value."); 7679 } 7680 return ("string" === r ? String : Number)(t); 7681 } 7682 function _callSuper(t, o, e) { 7683 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 7684 } 7685 function _possibleConstructorReturn(t, e) { 7686 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 7687 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 7688 return _assertThisInitialized(t); 7689 } 7690 function _assertThisInitialized(e) { 7691 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 7692 return e; 7693 } 7694 function _isNativeReflectConstruct() { 7695 try { 7696 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 7697 } catch (t) {} 7698 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 7699 return !!t; 7700 })(); 7701 } 7702 function _getPrototypeOf(t) { 7703 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 7704 return t.__proto__ || Object.getPrototypeOf(t); 7705 }, _getPrototypeOf(t); 7706 } 7707 function _inherits(t, e) { 7708 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 7709 t.prototype = Object.create(e && e.prototype, { 7710 constructor: { 7711 value: t, 7712 writable: !0, 7713 configurable: !0 7714 } 7715 }), Object.defineProperty(t, "prototype", { 7716 writable: !1 7717 }), e && _setPrototypeOf(t, e); 7718 } 7719 function _setPrototypeOf(t, e) { 7720 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 7721 return t.__proto__ = e, t; 7722 }, _setPrototypeOf(t, e); 7723 } 7724 7725 /** 7726 * Interchange module. 7727 * @module foundation.interchange 7728 * @requires foundation.util.mediaQuery 7729 */ 7730 var Interchange = /*#__PURE__*/function (_Plugin) { 7731 function Interchange() { 7732 _classCallCheck(this, Interchange); 7733 return _callSuper(this, Interchange, arguments); 7734 } 7735 _inherits(Interchange, _Plugin); 7736 return _createClass(Interchange, [{ 7737 key: "_setup", 7738 value: 7739 /** 7740 * Creates a new instance of Interchange. 7741 * @class 7742 * @name Interchange 7743 * @fires Interchange#init 7744 * @param {Object} element - jQuery object to add the trigger to. 7745 * @param {Object} options - Overrides to the default plugin settings. 7746 */ 7747 function _setup(element, options) { 7748 this.$element = element; 7749 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, Interchange.defaults, this.$element.data(), options); 7750 this.rules = []; 7751 this.currentPath = ''; 7752 this.className = 'Interchange'; // ie9 back compat 7753 7754 // Triggers init is idempotent, just need to make sure it is initialized 7755 _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_3__.Triggers.init(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 7756 this._init(); 7757 this._events(); 7758 } 7759 7760 /** 7761 * Initializes the Interchange plugin and calls functions to get interchange functioning on load. 7762 * @function 7763 * @private 7764 */ 7765 }, { 7766 key: "_init", 7767 value: function _init() { 7768 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery._init(); 7769 var id = this.$element[0].id || (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__.GetYoDigits)(6, 'interchange'); 7770 this.$element.attr({ 7771 'data-resize': id, 7772 'id': id 7773 }); 7774 this._parseOptions(); 7775 this._addBreakpoints(); 7776 this._generateRules(); 7777 this._reflow(); 7778 } 7779 7780 /** 7781 * Initializes events for Interchange. 7782 * @function 7783 * @private 7784 */ 7785 }, { 7786 key: "_events", 7787 value: function _events() { 7788 var _this = this; 7789 this.$element.off('resizeme.zf.trigger').on('resizeme.zf.trigger', function () { 7790 return _this._reflow(); 7791 }); 7792 } 7793 7794 /** 7795 * Calls necessary functions to update Interchange upon DOM change 7796 * @function 7797 * @private 7798 */ 7799 }, { 7800 key: "_reflow", 7801 value: function _reflow() { 7802 var match; 7803 7804 // Iterate through each rule, but only save the last match 7805 for (var i in this.rules) { 7806 if (this.rules.hasOwnProperty(i)) { 7807 var rule = this.rules[i]; 7808 if (window.matchMedia(rule.query).matches) { 7809 match = rule; 7810 } 7811 } 7812 } 7813 if (match) { 7814 this.replace(match.path); 7815 } 7816 } 7817 7818 /** 7819 * Check options valifity and set defaults for: 7820 * - `data-interchange-type`: if set, enforce the type of replacement (auto, src, background or html) 7821 * @function 7822 * @private 7823 */ 7824 }, { 7825 key: "_parseOptions", 7826 value: function _parseOptions() { 7827 var types = ['auto', 'src', 'background', 'html']; 7828 if (typeof this.options.type === 'undefined') this.options.type = 'auto';else if (types.indexOf(this.options.type) === -1) { 7829 console.warn("Warning: invalid value \"".concat(this.options.type, "\" for Interchange option \"type\"")); 7830 this.options.type = 'auto'; 7831 } 7832 } 7833 7834 /** 7835 * Gets the Foundation breakpoints and adds them to the Interchange.SPECIAL_QUERIES object. 7836 * @function 7837 * @private 7838 */ 7839 }, { 7840 key: "_addBreakpoints", 7841 value: function _addBreakpoints() { 7842 for (var i in _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery.queries) { 7843 if (_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery.queries.hasOwnProperty(i)) { 7844 var query = _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery.queries[i]; 7845 Interchange.SPECIAL_QUERIES[query.name] = query.value; 7846 } 7847 } 7848 } 7849 7850 /** 7851 * Checks the Interchange element for the provided media query + content pairings 7852 * @function 7853 * @private 7854 * @returns {Array} scenarios - Array of objects that have 'mq' and 'path' keys with corresponding keys 7855 */ 7856 }, { 7857 key: "_generateRules", 7858 value: function _generateRules() { 7859 var rulesList = []; 7860 var rules; 7861 if (this.options.rules) { 7862 rules = this.options.rules; 7863 } else { 7864 rules = this.$element.data('interchange'); 7865 } 7866 rules = typeof rules === 'string' ? rules.match(/\[.*?, .*?\]/g) : rules; 7867 for (var i in rules) { 7868 if (rules.hasOwnProperty(i)) { 7869 var rule = rules[i].slice(1, -1).split(', '); 7870 var path = rule.slice(0, -1).join(''); 7871 var query = rule[rule.length - 1]; 7872 if (Interchange.SPECIAL_QUERIES[query]) { 7873 query = Interchange.SPECIAL_QUERIES[query]; 7874 } 7875 rulesList.push({ 7876 path: path, 7877 query: query 7878 }); 7879 } 7880 } 7881 this.rules = rulesList; 7882 } 7883 7884 /** 7885 * Update the `src` property of an image, or change the HTML of a container, to the specified path. 7886 * @function 7887 * @param {String} path - Path to the image or HTML partial. 7888 * @fires Interchange#replaced 7889 */ 7890 }, { 7891 key: "replace", 7892 value: function replace(path) { 7893 var _this2 = this; 7894 if (this.currentPath === path) return; 7895 var trigger = 'replaced.zf.interchange'; 7896 var type = this.options.type; 7897 if (type === 'auto') { 7898 if (this.$element[0].nodeName === 'IMG') type = 'src';else if (path.match(/\.(gif|jpe?g|png|svg|tiff)([?#].*)?/i)) type = 'background';
vendor: 16,868 bytes, lines 7898-8238
7898else type = 'html'; 7899 } 7900 7901 // Replacing images 7902 if (type === 'src') { 7903 this.$element.attr('src', path).on('load', function () { 7904 _this2.currentPath = path; 7905 }).trigger(trigger); 7906 } 7907 // Replacing background images 7908 else if (type === 'background') { 7909 path = path.replace(/\(/g, '%28').replace(/\)/g, '%29'); 7910 this.$element.css({ 7911 'background-image': 'url(' + path + ')' 7912 }).trigger(trigger); 7913 } 7914 // Replacing HTML 7915 else if (type === 'html') { 7916 jquery__WEBPACK_IMPORTED_MODULE_0___default().get(path, function (response) { 7917 _this2.$element.html(response).trigger(trigger); 7918 jquery__WEBPACK_IMPORTED_MODULE_0___default()(response).foundation(); 7919 _this2.currentPath = path; 7920 }); 7921 } 7922 7923 /** 7924 * Fires when content in an Interchange element is done being loaded. 7925 * @event Interchange#replaced 7926 */ 7927 // this.$element.trigger('replaced.zf.interchange'); 7928 } 7929 7930 /** 7931 * Destroys an instance of interchange. 7932 * @function 7933 */ 7934 }, { 7935 key: "_destroy", 7936 value: function _destroy() { 7937 this.$element.off('resizeme.zf.trigger'); 7938 } 7939 }]); 7940 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_2__.Plugin); 7941 /** 7942 * Default settings for plugin 7943 */ 7944 Interchange.defaults = { 7945 /** 7946 * Rules to be applied to Interchange elements. Set with the `data-interchange` array notation. 7947 * @option 7948 * @type {?array} 7949 * @default null 7950 */ 7951 rules: null, 7952 /** 7953 * Type of the responsive ressource to replace. It can take the following options: 7954 * - `auto` (default): choose the type according to the element tag or the ressource extension, 7955 * - `src`: replace the `[src]` attribute, recommended for images `<img>`. 7956 * - `background`: replace the `background-image` CSS property. 7957 * - `html`: replace the element content. 7958 * @option 7959 * @type {string} 7960 * @default 'auto' 7961 */ 7962 type: 'auto' 7963 }; 7964 Interchange.SPECIAL_QUERIES = { 7965 'landscape': 'screen and (orientation: landscape)', 7966 'portrait': 'screen and (orientation: portrait)', 7967 '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)' 7968 }; 7969 7970 /***/ 7971 }), 7972 /***/"./js/foundation.util.triggers.js": ( 7973 /*!****************************************!*\ 7974 !*** ./js/foundation.util.triggers.js ***! 7975 \****************************************/ 7976 /***/ 7977 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 7978 __webpack_require__.r(__webpack_exports__); 7979 /* harmony export */ 7980 __webpack_require__.d(__webpack_exports__, { 7981 /* harmony export */Triggers: function () { 7982 return /* binding */Triggers; 7983 } 7984 /* harmony export */ 7985 }); 7986 /* harmony import */ 7987 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 7988 /* harmony import */ 7989 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 7990 /* harmony import */ 7991 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 7992 /* harmony import */ 7993 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 7994 /* harmony import */ 7995 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.motion */"./foundation.util.motion"); 7996 /* harmony import */ 7997 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__); 7998 function _typeof(o) { 7999 "@babel/helpers - typeof"; 8000 8001 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 8002 return typeof o; 8003 } : function (o) { 8004 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 8005 }, _typeof(o); 8006 } 8007 var MutationObserver = function () { 8008 var prefixes = ['WebKit', 'Moz', 'O', 'Ms', '']; 8009 for (var i = 0; i < prefixes.length; i++) { 8010 if ("".concat(prefixes[i], "MutationObserver") in window) { 8011 return window["".concat(prefixes[i], "MutationObserver")]; 8012 } 8013 } 8014 return false; 8015 }(); 8016 var triggers = function triggers(el, type) { 8017 el.data(type).split(' ').forEach(function (id) { 8018 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id))[type === 'close' ? 'trigger' : 'triggerHandler']("".concat(type, ".zf.trigger"), [el]); 8019 }); 8020 }; 8021 var Triggers = { 8022 Listeners: { 8023 Basic: {}, 8024 Global: {} 8025 }, 8026 Initializers: {} 8027 }; 8028 Triggers.Listeners.Basic = { 8029 openListener: function openListener() { 8030 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'open'); 8031 }, 8032 closeListener: function closeListener() { 8033 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('close'); 8034 if (id) { 8035 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'close'); 8036 } else { 8037 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('close.zf.trigger'); 8038 } 8039 }, 8040 toggleListener: function toggleListener() { 8041 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle'); 8042 if (id) { 8043 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'toggle'); 8044 } else { 8045 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('toggle.zf.trigger'); 8046 } 8047 }, 8048 closeableListener: function closeableListener(e) { 8049 var animation = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('closable'); 8050 8051 // Only close the first closable element. See https://git.io/zf-7833 8052 e.stopPropagation(); 8053 if (animation !== '') { 8054 _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__.Motion.animateOut(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), animation, function () { 8055 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('closed.zf'); 8056 }); 8057 } else { 8058 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).fadeOut().trigger('closed.zf'); 8059 } 8060 }, 8061 toggleFocusListener: function toggleFocusListener() { 8062 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle-focus'); 8063 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id)).triggerHandler('toggle.zf.trigger', [jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)]); 8064 } 8065 }; 8066 8067 // Elements with [data-open] will reveal a plugin that supports it when clicked. 8068 Triggers.Initializers.addOpenListener = function ($elem) { 8069 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.openListener); 8070 $elem.on('click.zf.trigger', '[data-open]', Triggers.Listeners.Basic.openListener); 8071 }; 8072 8073 // Elements with [data-close] will close a plugin that supports it when clicked. 8074 // If used without a value on [data-close], the event will bubble, allowing it to close a parent component. 8075 Triggers.Initializers.addCloseListener = function ($elem) { 8076 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.closeListener); 8077 $elem.on('click.zf.trigger', '[data-close]', Triggers.Listeners.Basic.closeListener); 8078 }; 8079 8080 // Elements with [data-toggle] will toggle a plugin that supports it when clicked. 8081 Triggers.Initializers.addToggleListener = function ($elem) { 8082 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.toggleListener); 8083 $elem.on('click.zf.trigger', '[data-toggle]', Triggers.Listeners.Basic.toggleListener); 8084 }; 8085 8086 // Elements with [data-closable] will respond to close.zf.trigger events. 8087 Triggers.Initializers.addCloseableListener = function ($elem) { 8088 $elem.off('close.zf.trigger', Triggers.Listeners.Basic.closeableListener); 8089 $elem.on('close.zf.trigger', '[data-closeable], [data-closable]', Triggers.Listeners.Basic.closeableListener); 8090 }; 8091 8092 // Elements with [data-toggle-focus] will respond to coming in and out of focus 8093 Triggers.Initializers.addToggleFocusListener = function ($elem) { 8094 $elem.off('focus.zf.trigger blur.zf.trigger', Triggers.Listeners.Basic.toggleFocusListener); 8095 $elem.on('focus.zf.trigger blur.zf.trigger', '[data-toggle-focus]', Triggers.Listeners.Basic.toggleFocusListener); 8096 }; 8097 8098 // More Global/complex listeners and triggers 8099 Triggers.Listeners.Global = { 8100 resizeListener: function resizeListener($nodes) { 8101 if (!MutationObserver) { 8102 //fallback for IE 9 8103 $nodes.each(function () { 8104 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('resizeme.zf.trigger'); 8105 }); 8106 } 8107 //trigger all listening elements and signal a resize event 8108 $nodes.attr('data-events', "resize"); 8109 }, 8110 scrollListener: function scrollListener($nodes) { 8111 if (!MutationObserver) { 8112 //fallback for IE 9 8113 $nodes.each(function () { 8114 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('scrollme.zf.trigger'); 8115 }); 8116 } 8117 //trigger all listening elements and signal a scroll event 8118 $nodes.attr('data-events', "scroll"); 8119 }, 8120 closeMeListener: function closeMeListener(e, pluginId) { 8121 var plugin = e.namespace.split('.')[0]; 8122 var plugins = jquery__WEBPACK_IMPORTED_MODULE_0___default()("[data-".concat(plugin, "]")).not("[data-yeti-box=\"".concat(pluginId, "\"]")); 8123 plugins.each(function () { 8124 var _this = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this); 8125 _this.triggerHandler('close.zf.trigger', [_this]); 8126 }); 8127 } 8128 }; 8129 8130 // Global, parses whole document. 8131 Triggers.Initializers.addClosemeListener = function (pluginName) { 8132 var yetiBoxes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-yeti-box]'), 8133 plugNames = ['dropdown', 'tooltip', 'reveal']; 8134 if (pluginName) { 8135 if (typeof pluginName === 'string') { 8136 plugNames.push(pluginName); 8137 } else if (_typeof(pluginName) === 'object' && typeof pluginName[0] === 'string') { 8138 plugNames = plugNames.concat(pluginName); 8139 } else { 8140 console.error('Plugin names must be strings'); 8141 } 8142 } 8143 if (yetiBoxes.length) { 8144 var listeners = plugNames.map(function (name) { 8145 return "closeme.zf.".concat(name); 8146 }).join(' '); 8147 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(listeners).on(listeners, Triggers.Listeners.Global.closeMeListener); 8148 } 8149 }; 8150 function debounceGlobalListener(debounce, trigger, listener) { 8151 var timer, 8152 args = Array.prototype.slice.call(arguments, 3); 8153 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on(trigger, function () { 8154 if (timer) { 8155 clearTimeout(timer); 8156 } 8157 timer = setTimeout(function () { 8158 listener.apply(null, args); 8159 }, debounce || 10); //default time to emit scroll event 8160 }); 8161 } 8162 Triggers.Initializers.addResizeListener = function (debounce) { 8163 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-resize]'); 8164 if ($nodes.length) { 8165 debounceGlobalListener(debounce, 'resize.zf.trigger', Triggers.Listeners.Global.resizeListener, $nodes); 8166 } 8167 }; 8168 Triggers.Initializers.addScrollListener = function (debounce) { 8169 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-scroll]'); 8170 if ($nodes.length) { 8171 debounceGlobalListener(debounce, 'scroll.zf.trigger', Triggers.Listeners.Global.scrollListener, $nodes); 8172 } 8173 }; 8174 Triggers.Initializers.addMutationEventsListener = function ($elem) { 8175 if (!MutationObserver) { 8176 return false; 8177 } 8178 var $nodes = $elem.find('[data-resize], [data-scroll], [data-mutate]'); 8179 8180 //element callback 8181 var listeningElementsMutation = function listeningElementsMutation(mutationRecordsList) { 8182 var $target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(mutationRecordsList[0].target); 8183 8184 //trigger the event handler for the element depending on type 8185 switch (mutationRecordsList[0].type) { 8186 case "attributes": 8187 if ($target.attr("data-events") === "scroll" && mutationRecordsList[0].attributeName === "data-events") { 8188 $target.triggerHandler('scrollme.zf.trigger', [$target, window.pageYOffset]); 8189 } 8190 if ($target.attr("data-events") === "resize" && mutationRecordsList[0].attributeName === "data-events") { 8191 $target.triggerHandler('resizeme.zf.trigger', [$target]); 8192 } 8193 if (mutationRecordsList[0].attributeName === "style") { 8194 $target.closest("[data-mutate]").attr("data-events", "mutate"); 8195 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 8196 } 8197 break; 8198 case "childList": 8199 $target.closest("[data-mutate]").attr("data-events", "mutate"); 8200 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 8201 break; 8202 default: 8203 return false; 8204 //nothing 8205 } 8206 }; 8207 if ($nodes.length) { 8208 //for each element that needs to listen for resizing, scrolling, or mutation add a single observer 8209 for (var i = 0; i <= $nodes.length - 1; i++) { 8210 var elementObserver = new MutationObserver(listeningElementsMutation); 8211 elementObserver.observe($nodes[i], { 8212 attributes: true, 8213 childList: true, 8214 characterData: false, 8215 subtree: true, 8216 attributeFilter: ["data-events", "style"] 8217 }); 8218 } 8219 } 8220 }; 8221 Triggers.Initializers.addSimpleListeners = function () { 8222 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 8223 Triggers.Initializers.addOpenListener($document); 8224 Triggers.Initializers.addCloseListener($document); 8225 Triggers.Initializers.addToggleListener($document); 8226 Triggers.Initializers.addCloseableListener($document); 8227 Triggers.Initializers.addToggleFocusListener($document); 8228 }; 8229 Triggers.Initializers.addGlobalListeners = function () { 8230 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 8231 Triggers.Initializers.addMutationEventsListener($document); 8232 Triggers.Initializers.addResizeListener(250); 8233 Triggers.Initializers.addScrollListener(); 8234 Triggers.Initializers.addClosemeListener(); 8235 }; 8236 Triggers.init = function (__, Foundation) { 8237 (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 8238 if (jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized !== true) {
8239 Triggers.Initializers.addSimpleListeners(); 8240 Triggers.Initializers.addGlobalListeners(); 8241 jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized = true; 8242 } 8243 }); 8244 if (Foundation) { 8245 Foundation.Triggers = Triggers; 8246 // Legacy included to be backwards compatible for now. 8247 Foundation.IHearYou = Triggers.Initializers.addGlobalListeners; 8248 } 8249 }; 8250 8251 /***/ 8252 }), 8253 /***/"./foundation.core": ( 8254 /*!****************************************************************************************************************************************************************!*\ 8255 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 8256 \****************************************************************************************************************************************************************/ 8257 /***/ 8258 function (module) { 8259 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 8260 8261 /***/ 8262 }), 8263 /***/"./foundation.util.mediaQuery": ( 8264 /*!************************************************************************************************************************************************************************************************************!*\ 8265 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.mediaQuery"],"amd":"./foundation.util.mediaQuery","commonjs":"./foundation.util.mediaQuery","commonjs2":"./foundation.util.mediaQuery"} ***! 8266 \************************************************************************************************************************************************************************************************************/ 8267 /***/ 8268 function (module) { 8269 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__; 8270 8271 /***/ 8272 }), 8273 /***/"./foundation.util.motion": ( 8274 /*!********************************************************************************************************************************************************************************************!*\ 8275 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.motion"],"amd":"./foundation.util.motion","commonjs":"./foundation.util.motion","commonjs2":"./foundation.util.motion"} ***! 8276 \********************************************************************************************************************************************************************************************/ 8277 /***/ 8278 function (module) { 8279 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__; 8280 8281 /***/ 8282 }), 8283 /***/"jquery": ( 8284 /*!********************************************************************************************!*\ 8285 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 8286 \********************************************************************************************/ 8287 /***/ 8288 function (module) { 8289 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 8290 8291 /***/ 8292 }) 8293 8294 /******/ 8295 }; 8296 /************************************************************************/ 8297 /******/ // The module cache 8298 /******/ 8299 var __webpack_module_cache__ = {}; 8300 /******/ 8301 /******/ // The require function 8302 /******/ 8303 function __webpack_require__(moduleId) { 8304 /******/ // Check if module is in cache 8305 /******/var cachedModule = __webpack_module_cache__[moduleId]; 8306 /******/ 8307 if (cachedModule !== undefined) { 8308 /******/return cachedModule.exports; 8309 /******/ 8310 } 8311 /******/ // Create a new module (and put it into the cache) 8312 /******/ 8313 var module = __webpack_module_cache__[moduleId] = { 8314 /******/ // no module.id needed 8315 /******/ // no module.loaded needed 8316 /******/exports: {} 8317 /******/ 8318 }; 8319 /******/ 8320 /******/ // Execute the module function 8321 /******/ 8322 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 8323 /******/ 8324 /******/ // Return the exports of the module 8325 /******/ 8326 return module.exports; 8327 /******/ 8328 } 8329 /******/ 8330 /************************************************************************/ 8331 /******/ /* webpack/runtime/compat get default export */ 8332 /******/ 8333 !function () { 8334 /******/ // getDefaultExport function for compatibility with non-harmony modules 8335 /******/__webpack_require__.n = function (module) {
vendor: 5,098 bytes, lines 8336-8442
8336 /******/var getter = module && module.__esModule ? /******/function () { 8337 return module['default']; 8338 } : /******/function () { 8339 return module; 8340 }; 8341 /******/ 8342 __webpack_require__.d(getter, { 8343 a: getter 8344 }); 8345 /******/ 8346 return getter; 8347 /******/ 8348 }; 8349 /******/ 8350 }(); 8351 /******/ 8352 /******/ /* webpack/runtime/define property getters */ 8353 /******/ 8354 !function () { 8355 /******/ // define getter functions for harmony exports 8356 /******/__webpack_require__.d = function (exports, definition) { 8357 /******/for (var key in definition) { 8358 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 8359 /******/Object.defineProperty(exports, key, { 8360 enumerable: true, 8361 get: definition[key] 8362 }); 8363 /******/ 8364 } 8365 /******/ 8366 } 8367 /******/ 8368 }; 8369 /******/ 8370 }(); 8371 /******/ 8372 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 8373 /******/ 8374 !function () { 8375 /******/__webpack_require__.o = function (obj, prop) { 8376 return Object.prototype.hasOwnProperty.call(obj, prop); 8377 }; 8378 /******/ 8379 }(); 8380 /******/ 8381 /******/ /* webpack/runtime/make namespace object */ 8382 /******/ 8383 !function () { 8384 /******/ // define __esModule on exports 8385 /******/__webpack_require__.r = function (exports) { 8386 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 8387 /******/Object.defineProperty(exports, Symbol.toStringTag, { 8388 value: 'Module' 8389 }); 8390 /******/ 8391 } 8392 /******/ 8393 Object.defineProperty(exports, '__esModule', { 8394 value: true 8395 }); 8396 /******/ 8397 }; 8398 /******/ 8399 }(); 8400 /******/ 8401 /************************************************************************/ 8402 var __webpack_exports__ = {}; 8403 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 8404 !function () { 8405 /*!******************************************************!*\ 8406 !*** ./js/entries/plugins/foundation.interchange.js ***! 8407 \******************************************************/ 8408 __webpack_require__.r(__webpack_exports__); 8409 /* harmony export */ 8410 __webpack_require__.d(__webpack_exports__, { 8411 /* harmony export */Foundation: function () { 8412 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 8413 }, 8414 /* harmony export */Interchange: function () { 8415 return /* reexport safe */_foundation_interchange__WEBPACK_IMPORTED_MODULE_1__.Interchange; 8416 } 8417 /* harmony export */ 8418 }); 8419 /* harmony import */ 8420 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 8421 /* harmony import */ 8422 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 8423 /* harmony import */ 8424 var _foundation_interchange__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.interchange */"./js/foundation.interchange.js"); 8425 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_interchange__WEBPACK_IMPORTED_MODULE_1__.Interchange, 'Interchange'); 8426 }(); 8427 /******/ 8428 return __webpack_exports__; 8429 /******/ 8430 }(); 8431}); 8432(function webpackUniversalModuleDefinition(root, factory) { 8433 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.keyboard", "./foundation.util.mediaQuery", "./foundation.util.motion"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.offcanvas"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.keyboard"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.motion"]); 8434})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__, __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__) { 8435 return /******/function () { 8436 // webpackBootstrap 8437 /******/ 8438 "use strict"; 8439 8440 /******/ 8441 var __webpack_modules__ = { 8442
vendor: 7,456 bytes, lines 8442-8591
8442/***/"./js/foundation.offcanvas.js": ( 8443 /*!************************************!*\ 8444 !*** ./js/foundation.offcanvas.js ***! 8445 \************************************/ 8446 /***/ 8447 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 8448 __webpack_require__.r(__webpack_exports__); 8449 /* harmony export */ 8450 __webpack_require__.d(__webpack_exports__, { 8451 /* harmony export */OffCanvas: function () { 8452 return /* binding */OffCanvas; 8453 } 8454 /* harmony export */ 8455 }); 8456 /* harmony import */ 8457 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 8458 /* harmony import */ 8459 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 8460 /* harmony import */ 8461 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 8462 /* harmony import */ 8463 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 8464 /* harmony import */ 8465 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.keyboard */"./foundation.util.keyboard"); 8466 /* harmony import */ 8467 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__); 8468 /* harmony import */ 8469 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./foundation.util.mediaQuery"); 8470 /* harmony import */ 8471 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__); 8472 /* harmony import */ 8473 var _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./foundation.util.triggers */"./js/foundation.util.triggers.js"); 8474 function _typeof(o) { 8475 "@babel/helpers - typeof"; 8476 8477 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 8478 return typeof o; 8479 } : function (o) { 8480 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 8481 }, _typeof(o); 8482 } 8483 function _classCallCheck(a, n) { 8484 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 8485 } 8486 function _defineProperties(e, r) { 8487 for (var t = 0; t < r.length; t++) { 8488 var o = r[t]; 8489 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 8490 } 8491 } 8492 function _createClass(e, r, t) { 8493 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 8494 writable: !1 8495 }), e; 8496 } 8497 function _toPropertyKey(t) { 8498 var i = _toPrimitive(t, "string"); 8499 return "symbol" == _typeof(i) ? i : i + ""; 8500 } 8501 function _toPrimitive(t, r) { 8502 if ("object" != _typeof(t) || !t) return t; 8503 var e = t[Symbol.toPrimitive]; 8504 if (void 0 !== e) { 8505 var i = e.call(t, r || "default"); 8506 if ("object" != _typeof(i)) return i; 8507 throw new TypeError("@@toPrimitive must return a primitive value."); 8508 } 8509 return ("string" === r ? String : Number)(t); 8510 } 8511 function _callSuper(t, o, e) { 8512 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 8513 } 8514 function _possibleConstructorReturn(t, e) { 8515 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 8516 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 8517 return _assertThisInitialized(t); 8518 } 8519 function _assertThisInitialized(e) { 8520 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 8521 return e; 8522 } 8523 function _isNativeReflectConstruct() { 8524 try { 8525 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 8526 } catch (t) {} 8527 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 8528 return !!t; 8529 })(); 8530 } 8531 function _getPrototypeOf(t) { 8532 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 8533 return t.__proto__ || Object.getPrototypeOf(t); 8534 }, _getPrototypeOf(t); 8535 } 8536 function _inherits(t, e) { 8537 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 8538 t.prototype = Object.create(e && e.prototype, { 8539 constructor: { 8540 value: t, 8541 writable: !0, 8542 configurable: !0 8543 } 8544 }), Object.defineProperty(t, "prototype", { 8545 writable: !1 8546 }), e && _setPrototypeOf(t, e); 8547 } 8548 function _setPrototypeOf(t, e) { 8549 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 8550 return t.__proto__ = e, t; 8551 }, _setPrototypeOf(t, e); 8552 } 8553 8554 /** 8555 * OffCanvas module. 8556 * @module foundation.offCanvas 8557 * @requires foundation.util.keyboard 8558 * @requires foundation.util.mediaQuery 8559 * @requires foundation.util.triggers 8560 */ 8561 var OffCanvas = /*#__PURE__*/function (_Plugin) { 8562 function OffCanvas() { 8563 _classCallCheck(this, OffCanvas); 8564 return _callSuper(this, OffCanvas, arguments); 8565 } 8566 _inherits(OffCanvas, _Plugin); 8567 return _createClass(OffCanvas, [{ 8568 key: "_setup", 8569 value: 8570 /** 8571 * Creates a new instance of an off-canvas wrapper. 8572 * @class 8573 * @name OffCanvas 8574 * @fires OffCanvas#init 8575 * @param {Object} element - jQuery object to initialize. 8576 * @param {Object} options - Overrides to the default plugin settings. 8577 */ 8578 function _setup(element, options) { 8579 var _this2 = this; 8580 this.className = 'OffCanvas'; // ie9 back compat 8581 this.$element = element; 8582 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, OffCanvas.defaults, this.$element.data(), options); 8583 this.contentClasses = { 8584 base: [], 8585 reveal: [] 8586 }; 8587 this.$lastTrigger = jquery__WEBPACK_IMPORTED_MODULE_0___default()(); 8588 this.$triggers = jquery__WEBPACK_IMPORTED_MODULE_0___default()(); 8589 this.position = 'left'; 8590 this.$content = jquery__WEBPACK_IMPORTED_MODULE_0___default()(); 8591 this.nested = !!this.options.nested;
vendor: 28,076 bytes, lines 8592-9204
8592 this.$sticky = jquery__WEBPACK_IMPORTED_MODULE_0___default()(); 8593 this.isInCanvas = false; 8594 8595 // Defines the CSS transition/position classes of the off-canvas content container. 8596 jquery__WEBPACK_IMPORTED_MODULE_0___default()(['push', 'overlap']).each(function (index, val) { 8597 _this2.contentClasses.base.push('has-transition-' + val); 8598 }); 8599 jquery__WEBPACK_IMPORTED_MODULE_0___default()(['left', 'right', 'top', 'bottom']).each(function (index, val) { 8600 _this2.contentClasses.base.push('has-position-' + val); 8601 _this2.contentClasses.reveal.push('has-reveal-' + val); 8602 }); 8603 8604 // Triggers init is idempotent, just need to make sure it is initialized 8605 _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_4__.Triggers.init(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 8606 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__.MediaQuery._init(); 8607 this._init(); 8608 this._events(); 8609 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.register('OffCanvas', { 8610 'ESCAPE': 'close' 8611 }); 8612 } 8613 8614 /** 8615 * Initializes the off-canvas wrapper by adding the exit overlay (if needed). 8616 * @function 8617 * @private 8618 */ 8619 }, { 8620 key: "_init", 8621 value: function _init() { 8622 var id = this.$element.attr('id'); 8623 this.$element.attr('aria-hidden', 'true'); 8624 8625 // Find off-canvas content, either by ID (if specified), by siblings or by closest selector (fallback) 8626 if (this.options.contentId) { 8627 this.$content = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#' + this.options.contentId); 8628 } else if (this.$element.siblings('[data-off-canvas-content]').length) { 8629 this.$content = this.$element.siblings('[data-off-canvas-content]').first(); 8630 } else { 8631 this.$content = this.$element.closest('[data-off-canvas-content]').first(); 8632 } 8633 if (!this.options.contentId) { 8634 // Assume that the off-canvas element is nested if it isn't a sibling of the content 8635 this.nested = this.$element.siblings('[data-off-canvas-content]').length === 0; 8636 } else if (this.options.contentId && this.options.nested === null) { 8637 // Warning if using content ID without setting the nested option 8638 // Once the element is nested it is required to work properly in this case 8639 console.warn('Remember to use the nested option if using the content ID option!'); 8640 } 8641 if (this.nested === true) { 8642 // Force transition overlap if nested 8643 this.options.transition = 'overlap'; 8644 // Remove appropriate classes if already assigned in markup 8645 this.$element.removeClass('is-transition-push'); 8646 } 8647 this.$element.addClass("is-transition-".concat(this.options.transition, " is-closed")); 8648 8649 // Find triggers that affect this element and add aria-expanded to them 8650 this.$triggers = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).find('[data-open="' + id + '"], [data-close="' + id + '"], [data-toggle="' + id + '"]').attr('aria-expanded', 'false').attr('aria-controls', id); 8651 8652 // Get position by checking for related CSS class 8653 this.position = this.$element.is('.position-left, .position-top, .position-right, .position-bottom') ? this.$element.attr('class').match(/position\-(left|top|right|bottom)/)[1] : this.position; 8654 8655 // Add an overlay over the content if necessary 8656 if (this.options.contentOverlay === true) { 8657 var overlay = document.createElement('div'); 8658 var overlayPosition = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.$element).css("position") === 'fixed' ? 'is-overlay-fixed' : 'is-overlay-absolute'; 8659 overlay.setAttribute('class', 'js-off-canvas-overlay ' + overlayPosition); 8660 this.$overlay = jquery__WEBPACK_IMPORTED_MODULE_0___default()(overlay); 8661 if (overlayPosition === 'is-overlay-fixed') { 8662 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.$overlay).insertAfter(this.$element); 8663 } else { 8664 this.$content.append(this.$overlay); 8665 } 8666 } 8667 8668 // Get the revealOn option from the class. 8669 var revealOnRegExp = new RegExp((0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.RegExpEscape)(this.options.revealClass) + '([^\\s]+)', 'g'); 8670 var revealOnClass = revealOnRegExp.exec(this.$element[0].className); 8671 if (revealOnClass) { 8672 this.options.isRevealed = true; 8673 this.options.revealOn = this.options.revealOn || revealOnClass[1]; 8674 } 8675 8676 // Ensure the `reveal-on-*` class is set. 8677 if (this.options.isRevealed === true && this.options.revealOn) { 8678 this.$element.first().addClass("".concat(this.options.revealClass).concat(this.options.revealOn)); 8679 this._setMQChecker(); 8680 } 8681 if (this.options.transitionTime) { 8682 this.$element.css('transition-duration', this.options.transitionTime); 8683 } 8684 8685 // Find fixed elements that should stay fixed while off-canvas is opened 8686 this.$sticky = this.$content.find('[data-off-canvas-sticky]'); 8687 if (this.$sticky.length > 0 && this.options.transition === 'push') { 8688 // If there's at least one match force contentScroll:false because the absolute top value doesn't get recalculated on scroll 8689 // Limit to push transition since there's no transform scope for overlap 8690 this.options.contentScroll = false; 8691 } 8692 var inCanvasFor = this.$element.attr('class').match(/\bin-canvas-for-(\w+)/); 8693 if (inCanvasFor && inCanvasFor.length === 2) { 8694 // Set `inCanvasOn` option if found in-canvas-for-[BREAKPONT] CSS class 8695 this.options.inCanvasOn = inCanvasFor[1]; 8696 } else if (this.options.inCanvasOn) { 8697 // Ensure the CSS class is set 8698 this.$element.addClass("in-canvas-for-".concat(this.options.inCanvasOn)); 8699 } 8700 if (this.options.inCanvasOn) { 8701 this._checkInCanvas(); 8702 } 8703 8704 // Initally remove all transition/position CSS classes from off-canvas content container. 8705 this._removeContentClasses(); 8706 } 8707 8708 /** 8709 * Adds event handlers to the off-canvas wrapper and the exit overlay. 8710 * @function 8711 * @private 8712 */ 8713 }, { 8714 key: "_events", 8715 value: function _events() { 8716 var _this3 = this; 8717 this.$element.off('.zf.trigger .zf.offCanvas').on({ 8718 'open.zf.trigger': this.open.bind(this), 8719 'close.zf.trigger': this.close.bind(this), 8720 'toggle.zf.trigger': this.toggle.bind(this), 8721 'keydown.zf.offCanvas': this._handleKeyboard.bind(this) 8722 }); 8723 if (this.options.closeOnClick === true) { 8724 var $target = this.options.contentOverlay ? this.$overlay : this.$content; 8725 $target.on({ 8726 'click.zf.offCanvas': this.close.bind(this) 8727 }); 8728 } 8729 if (this.options.inCanvasOn) { 8730 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('changed.zf.mediaquery', function () { 8731 _this3._checkInCanvas(); 8732 }); 8733 } 8734 } 8735 8736 /** 8737 * Applies event listener for elements that will reveal at certain breakpoints. 8738 * @private 8739 */ 8740 }, { 8741 key: "_setMQChecker", 8742 value: function _setMQChecker() { 8743 var _this = this; 8744 this.onLoadListener = (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 8745 if (_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__.MediaQuery.atLeast(_this.options.revealOn)) { 8746 _this.reveal(true); 8747 } 8748 }); 8749 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('changed.zf.mediaquery', function () { 8750 if (_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__.MediaQuery.atLeast(_this.options.revealOn)) { 8751 _this.reveal(true); 8752 } else { 8753 _this.reveal(false); 8754 } 8755 }); 8756 } 8757 8758 /** 8759 * Checks if InCanvas on current breakpoint and adjust off-canvas accordingly 8760 * @private 8761 */ 8762 }, { 8763 key: "_checkInCanvas", 8764 value: function _checkInCanvas() { 8765 this.isInCanvas = _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_3__.MediaQuery.atLeast(this.options.inCanvasOn); 8766 if (this.isInCanvas === true) { 8767 this.close(); 8768 } 8769 } 8770 8771 /** 8772 * Removes the CSS transition/position classes of the off-canvas content container. 8773 * Removing the classes is important when another off-canvas gets opened that uses the same content container. 8774 * @param {Boolean} hasReveal - true if related off-canvas element is revealed. 8775 * @private 8776 */ 8777 }, { 8778 key: "_removeContentClasses", 8779 value: function _removeContentClasses(hasReveal) { 8780 if (typeof hasReveal !== 'boolean') { 8781 this.$content.removeClass(this.contentClasses.base.join(' ')); 8782 } else if (hasReveal === false) { 8783 this.$content.removeClass("has-reveal-".concat(this.position)); 8784 } 8785 } 8786 8787 /** 8788 * Adds the CSS transition/position classes of the off-canvas content container, based on the opening off-canvas element. 8789 * Beforehand any transition/position class gets removed. 8790 * @param {Boolean} hasReveal - true if related off-canvas element is revealed. 8791 * @private 8792 */ 8793 }, { 8794 key: "_addContentClasses", 8795 value: function _addContentClasses(hasReveal) { 8796 this._removeContentClasses(hasReveal); 8797 if (typeof hasReveal !== 'boolean') { 8798 this.$content.addClass("has-transition-".concat(this.options.transition, " has-position-").concat(this.position)); 8799 } else if (hasReveal === true) { 8800 this.$content.addClass("has-reveal-".concat(this.position)); 8801 } 8802 } 8803 8804 /** 8805 * Preserves the fixed behavior of sticky elements on opening an off-canvas with push transition. 8806 * Since the off-canvas container has got a transform scope in such a case, it is done by calculating position absolute values. 8807 * @private 8808 */ 8809 }, { 8810 key: "_fixStickyElements", 8811 value: function _fixStickyElements() { 8812 this.$sticky.each(function (_, el) { 8813 var $el = jquery__WEBPACK_IMPORTED_MODULE_0___default()(el); 8814 8815 // If sticky element is currently fixed, adjust its top value to match absolute position due to transform scope 8816 // Limit to push transition because postion:fixed works without problems for overlap (no transform scope) 8817 if ($el.css('position') === 'fixed') { 8818 // Save current inline styling to restore it if undoing the absolute fixing 8819 var topVal = parseInt($el.css('top'), 10); 8820 $el.data('offCanvasSticky', { 8821 top: topVal 8822 }); 8823 var absoluteTopVal = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document).scrollTop() + topVal; 8824 $el.css({ 8825 top: "".concat(absoluteTopVal, "px"), 8826 width: '100%', 8827 transition: 'none' 8828 }); 8829 } 8830 }); 8831 } 8832 8833 /** 8834 * Restores the original fixed styling of sticky elements after having closed an off-canvas that got pseudo fixed beforehand. 8835 * This reverts the changes of _fixStickyElements() 8836 * @private 8837 */ 8838 }, { 8839 key: "_unfixStickyElements", 8840 value: function _unfixStickyElements() { 8841 this.$sticky.each(function (_, el) { 8842 var $el = jquery__WEBPACK_IMPORTED_MODULE_0___default()(el); 8843 var stickyData = $el.data('offCanvasSticky'); 8844 8845 // If sticky element has got data object with prior values (meaning it was originally fixed) restore these values once off-canvas is closed 8846 if (_typeof(stickyData) === 'object') { 8847 $el.css({ 8848 top: "".concat(stickyData.top, "px"), 8849 width: '', 8850 transition: '' 8851 }); 8852 $el.data('offCanvasSticky', ''); 8853 } 8854 }); 8855 } 8856 8857 /** 8858 * Handles the revealing/hiding the off-canvas at breakpoints, not the same as open. 8859 * @param {Boolean} isRevealed - true if element should be revealed. 8860 * @function 8861 */ 8862 }, { 8863 key: "reveal", 8864 value: function reveal(isRevealed) { 8865 if (isRevealed) { 8866 this.close(); 8867 this.isRevealed = true; 8868 this.$element.attr('aria-hidden', 'false'); 8869 this.$element.off('open.zf.trigger toggle.zf.trigger'); 8870 this.$element.removeClass('is-closed'); 8871 } else { 8872 this.isRevealed = false; 8873 this.$element.attr('aria-hidden', 'true'); 8874 this.$element.off('open.zf.trigger toggle.zf.trigger').on({ 8875 'open.zf.trigger': this.open.bind(this), 8876 'toggle.zf.trigger': this.toggle.bind(this) 8877 }); 8878 this.$element.addClass('is-closed'); 8879 } 8880 this._addContentClasses(isRevealed); 8881 } 8882 8883 /** 8884 * Stops scrolling of the body when OffCanvas is open on mobile Safari and other troublesome browsers. 8885 * @function 8886 * @private 8887 */ 8888 }, { 8889 key: "_stopScrolling", 8890 value: function _stopScrolling() { 8891 return false; 8892 } 8893 8894 /** 8895 * Save current finger y-position 8896 * @param event 8897 * @private 8898 */ 8899 }, { 8900 key: "_recordScrollable", 8901 value: function _recordScrollable(event) { 8902 var elem = this; 8903 elem.lastY = event.touches[0].pageY; 8904 } 8905 8906 /** 8907 * Prevent further scrolling when it hits the edges 8908 * @param event 8909 * @private 8910 */ 8911 }, { 8912 key: "_preventDefaultAtEdges", 8913 value: function _preventDefaultAtEdges(event) { 8914 var elem = this; 8915 var _this = event.data; 8916 var delta = elem.lastY - event.touches[0].pageY; 8917 elem.lastY = event.touches[0].pageY; 8918 if (!_this._canScroll(delta, elem)) { 8919 event.preventDefault(); 8920 } 8921 } 8922 8923 /** 8924 * Handle continuous scrolling of scrollbox 8925 * Don't bubble up to _preventDefaultAtEdges 8926 * @param event 8927 * @private 8928 */ 8929 }, { 8930 key: "_scrollboxTouchMoved", 8931 value: function _scrollboxTouchMoved(event) { 8932 var elem = this; 8933 var _this = event.data; 8934 var parent = elem.closest('[data-off-canvas], [data-off-canvas-scrollbox-outer]'); 8935 var delta = elem.lastY - event.touches[0].pageY; 8936 parent.lastY = elem.lastY = event.touches[0].pageY; 8937 event.stopPropagation(); 8938 if (!_this._canScroll(delta, elem)) { 8939 if (!_this._canScroll(delta, parent)) { 8940 event.preventDefault(); 8941 } else { 8942 parent.scrollTop += delta; 8943 } 8944 } 8945 } 8946 8947 /** 8948 * Detect possibility of scrolling 8949 * @param delta 8950 * @param elem 8951 * @returns boolean 8952 * @private 8953 */ 8954 }, { 8955 key: "_canScroll", 8956 value: function _canScroll(delta, elem) { 8957 var up = delta < 0; 8958 var down = delta > 0; 8959 var allowUp = elem.scrollTop > 0; 8960 var allowDown = elem.scrollTop < elem.scrollHeight - elem.clientHeight; 8961 return up && allowUp || down && allowDown; 8962 } 8963 8964 /** 8965 * Opens the off-canvas menu. 8966 * @function 8967 * @param {Object} event - Event object passed from listener. 8968 * @param {jQuery} trigger - element that triggered the off-canvas to open. 8969 * @fires OffCanvas#opened 8970 * @todo also trigger 'open' event? 8971 */ 8972 }, { 8973 key: "open", 8974 value: function open(event, trigger) { 8975 var _this4 = this; 8976 if (this.$element.hasClass('is-open') || this.isRevealed || this.isInCanvas) { 8977 return; 8978 } 8979 var _this = this; 8980 if (trigger) { 8981 this.$lastTrigger = trigger; 8982 } 8983 if (this.options.forceTo === 'top') { 8984 window.scrollTo(0, 0); 8985 } else if (this.options.forceTo === 'bottom') { 8986 window.scrollTo(0, document.body.scrollHeight); 8987 } 8988 if (this.options.transitionTime && this.options.transition !== 'overlap') { 8989 this.$element.siblings('[data-off-canvas-content]').css('transition-duration', this.options.transitionTime); 8990 } else { 8991 this.$element.siblings('[data-off-canvas-content]').css('transition-duration', ''); 8992 } 8993 this.$element.addClass('is-open').removeClass('is-closed'); 8994 this.$triggers.attr('aria-expanded', 'true'); 8995 this.$element.attr('aria-hidden', 'false'); 8996 this.$content.addClass('is-open-' + this.position); 8997 8998 // If `contentScroll` is set to false, add class and disable scrolling on touch devices. 8999 if (this.options.contentScroll === false) { 9000 jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').addClass('is-off-canvas-open').on('touchmove', this._stopScrolling); 9001 this.$element.on('touchstart', this._recordScrollable); 9002 this.$element.on('touchmove', this, this._preventDefaultAtEdges); 9003 this.$element.on('touchstart', '[data-off-canvas-scrollbox]', this._recordScrollable); 9004 this.$element.on('touchmove', '[data-off-canvas-scrollbox]', this, this._scrollboxTouchMoved); 9005 } 9006 if (this.options.contentOverlay === true) { 9007 this.$overlay.addClass('is-visible'); 9008 } 9009 if (this.options.closeOnClick === true && this.options.contentOverlay === true) { 9010 this.$overlay.addClass('is-closable'); 9011 } 9012 if (this.options.autoFocus === true) { 9013 this.$element.one((0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.transitionend)(this.$element), function () { 9014 if (!_this.$element.hasClass('is-open')) { 9015 return; // exit if prematurely closed 9016 } 9017 var canvasFocus = _this.$element.find('[data-autofocus]'); 9018 if (canvasFocus.length) { 9019 canvasFocus.eq(0).focus(); 9020 } else { 9021 _this.$element.find('a, button').eq(0).focus(); 9022 } 9023 }); 9024 } 9025 if (this.options.trapFocus === true) { 9026 this.$content.attr('tabindex', '-1'); 9027 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.trapFocus(this.$element); 9028 } 9029 if (this.options.transition === 'push') { 9030 this._fixStickyElements(); 9031 } 9032 this._addContentClasses(); 9033 9034 /** 9035 * Fires when the off-canvas menu opens. 9036 * @event OffCanvas#opened 9037 */ 9038 this.$element.trigger('opened.zf.offCanvas'); 9039 9040 /** 9041 * Fires when the off-canvas menu open transition is done. 9042 * @event OffCanvas#openedEnd 9043 */ 9044 this.$element.one((0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.transitionend)(this.$element), function () { 9045 _this4.$element.trigger('openedEnd.zf.offCanvas'); 9046 }); 9047 } 9048 9049 /** 9050 * Closes the off-canvas menu. 9051 * @function 9052 * @param {Function} cb - optional cb to fire after closure. 9053 * @fires OffCanvas#close 9054 * @fires OffCanvas#closed 9055 */ 9056 }, { 9057 key: "close", 9058 value: function close() { 9059 var _this5 = this; 9060 if (!this.$element.hasClass('is-open') || this.isRevealed) { 9061 return; 9062 } 9063 9064 /** 9065 * Fires when the off-canvas menu closes. 9066 * @event OffCanvas#close 9067 */ 9068 this.$element.trigger('close.zf.offCanvas'); 9069 this.$element.removeClass('is-open'); 9070 this.$element.attr('aria-hidden', 'true'); 9071 this.$content.removeClass('is-open-left is-open-top is-open-right is-open-bottom'); 9072 if (this.options.contentOverlay === true) { 9073 this.$overlay.removeClass('is-visible'); 9074 } 9075 if (this.options.closeOnClick === true && this.options.contentOverlay === true) { 9076 this.$overlay.removeClass('is-closable'); 9077 } 9078 this.$triggers.attr('aria-expanded', 'false'); 9079 9080 // Listen to transitionEnd: add class, re-enable scrolling and release focus when done. 9081 this.$element.one((0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.transitionend)(this.$element), function () { 9082 _this5.$element.addClass('is-closed'); 9083 _this5._removeContentClasses(); 9084 if (_this5.options.transition === 'push') { 9085 _this5._unfixStickyElements(); 9086 } 9087 9088 // If `contentScroll` is set to false, remove class and re-enable scrolling on touch devices. 9089 if (_this5.options.contentScroll === false) { 9090 jquery__WEBPACK_IMPORTED_MODULE_0___default()('body').removeClass('is-off-canvas-open').off('touchmove', _this5._stopScrolling); 9091 _this5.$element.off('touchstart', _this5._recordScrollable); 9092 _this5.$element.off('touchmove', _this5._preventDefaultAtEdges); 9093 _this5.$element.off('touchstart', '[data-off-canvas-scrollbox]', _this5._recordScrollable); 9094 _this5.$element.off('touchmove', '[data-off-canvas-scrollbox]', _this5._scrollboxTouchMoved); 9095 } 9096 if (_this5.options.trapFocus === true) { 9097 _this5.$content.removeAttr('tabindex'); 9098 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.releaseFocus(_this5.$element); 9099 } 9100 9101 /** 9102 * Fires when the off-canvas menu close transition is done. 9103 * @event OffCanvas#closed 9104 */ 9105 _this5.$element.trigger('closed.zf.offCanvas'); 9106 }); 9107 } 9108 9109 /** 9110 * Toggles the off-canvas menu open or closed. 9111 * @function 9112 * @param {Object} event - Event object passed from listener. 9113 * @param {jQuery} trigger - element that triggered the off-canvas to open. 9114 */ 9115 }, { 9116 key: "toggle", 9117 value: function toggle(event, trigger) { 9118 if (this.$element.hasClass('is-open')) { 9119 this.close(event, trigger); 9120 } else { 9121 this.open(event, trigger); 9122 } 9123 } 9124 9125 /** 9126 * 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. 9127 * @function 9128 * @private 9129 */ 9130 }, { 9131 key: "_handleKeyboard", 9132 value: function _handleKeyboard(e) { 9133 var _this6 = this; 9134 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.handleKey(e, 'OffCanvas', { 9135 close: function close() { 9136 _this6.close(); 9137 _this6.$lastTrigger.focus(); 9138 return true; 9139 }, 9140 handled: function handled() { 9141 e.preventDefault(); 9142 } 9143 }); 9144 } 9145 9146 /** 9147 * Destroys the OffCanvas plugin. 9148 * @function 9149 */ 9150 }, { 9151 key: "_destroy", 9152 value: function _destroy() { 9153 this.close(); 9154 this.$element.off('.zf.trigger .zf.offCanvas'); 9155 this.$overlay.off('.zf.offCanvas'); 9156 if (this.onLoadListener) jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(this.onLoadListener); 9157 } 9158 }]); 9159 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 9160 OffCanvas.defaults = { 9161 /** 9162 * Allow the user to click outside of the menu to close it. 9163 * @option 9164 * @type {boolean} 9165 * @default true 9166 */ 9167 closeOnClick: true, 9168 /** 9169 * Adds an overlay on top of `[data-off-canvas-content]`. 9170 * @option 9171 * @type {boolean} 9172 * @default true 9173 */ 9174 contentOverlay: true, 9175 /** 9176 * Target an off-canvas content container by ID that may be placed anywhere. If null the closest content container will be taken. 9177 * @option 9178 * @type {?string} 9179 * @default null 9180 */ 9181 contentId: null, 9182 /** 9183 * Define the off-canvas element is nested in an off-canvas content. This is required when using the contentId option for a nested element. 9184 * @option 9185 * @type {boolean} 9186 * @default null 9187 */ 9188 nested: null, 9189 /** 9190 * Enable/disable scrolling of the main content when an off canvas panel is open. 9191 * @option 9192 * @type {boolean} 9193 * @default true 9194 */ 9195 contentScroll: true, 9196 /** 9197 * Amount of time the open and close transition requires, including the appropriate milliseconds (`ms`) or seconds (`s`) unit (e.g. `500ms`, `.75s`) If none selected, pulls from body style. 9198 * @option 9199 * @type {string} 9200 * @default null 9201 */ 9202 transitionTime: null, 9203 /** 9204 * Type of transitio
9204n for the OffCanvas menu. Options are 'push', 'detached' or 'slide'. 9205 * @option 9206 * @type {string} 9207 * @default push 9208 */ 9209 transition: 'push', 9210 /** 9211 * Force the page to scroll to top or bottom on open. 9212 * @option 9213 * @type {?string} 9214 * @default null 9215 */ 9216 forceTo: null, 9217 /** 9218 * Allow the OffCanvas to remain open for certain breakpoints. 9219 * @option 9220 * @type {boolean} 9221 * @default false 9222 */ 9223 isRevealed: false, 9224 /** 9225 * Breakpoint at which to reveal. JS will use a RegExp to target standard classes, if changing classnames, pass your class with the `revealClass` option. 9226 * @option 9227 * @type {?string} 9228 * @default null 9229 */ 9230 revealOn: null, 9231 /** 9232 * Breakpoint at which the off-canvas gets moved into canvas content and acts as regular page element. 9233 * @option 9234 * @type {?string} 9235 * @default null 9236 */ 9237 inCanvasOn: null, 9238 /** 9239 * Force focus to the offcanvas on open. If true, will focus the opening trigger on close. 9240 * @option 9241 * @type {boolean} 9242 * @default true 9243 */ 9244 autoFocus: true, 9245 /** 9246 * Class used to force an OffCanvas to remain open. Foundation defaults for this are `reveal-for-large` & `reveal-for-medium`. 9247 * @option 9248 * @type {string} 9249 * @default reveal-for- 9250 * @todo improve the regex testing for this. 9251 */ 9252 revealClass: 'reveal-for-', 9253 /** 9254 * Triggers optional focus trapping when opening an OffCanvas. Sets tabindex of [data-off-canvas-content] to -1 for accessibility purposes. 9255 * @option 9256 * @type {boolean} 9257 * @default false 9258 */ 9259 trapFocus: false 9260 }; 9261 9262 /***/ 9263 }), 9264
vendor: 13,889 bytes, lines 9264-9530
9264/***/"./js/foundation.util.triggers.js": ( 9265 /*!****************************************!*\ 9266 !*** ./js/foundation.util.triggers.js ***! 9267 \****************************************/ 9268 /***/ 9269 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 9270 __webpack_require__.r(__webpack_exports__); 9271 /* harmony export */ 9272 __webpack_require__.d(__webpack_exports__, { 9273 /* harmony export */Triggers: function () { 9274 return /* binding */Triggers; 9275 } 9276 /* harmony export */ 9277 }); 9278 /* harmony import */ 9279 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 9280 /* harmony import */ 9281 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 9282 /* harmony import */ 9283 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 9284 /* harmony import */ 9285 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 9286 /* harmony import */ 9287 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.motion */"./foundation.util.motion"); 9288 /* harmony import */ 9289 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__); 9290 function _typeof(o) { 9291 "@babel/helpers - typeof"; 9292 9293 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 9294 return typeof o; 9295 } : function (o) { 9296 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 9297 }, _typeof(o); 9298 } 9299 var MutationObserver = function () { 9300 var prefixes = ['WebKit', 'Moz', 'O', 'Ms', '']; 9301 for (var i = 0; i < prefixes.length; i++) { 9302 if ("".concat(prefixes[i], "MutationObserver") in window) { 9303 return window["".concat(prefixes[i], "MutationObserver")]; 9304 } 9305 } 9306 return false; 9307 }(); 9308 var triggers = function triggers(el, type) { 9309 el.data(type).split(' ').forEach(function (id) { 9310 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id))[type === 'close' ? 'trigger' : 'triggerHandler']("".concat(type, ".zf.trigger"), [el]); 9311 }); 9312 }; 9313 var Triggers = { 9314 Listeners: { 9315 Basic: {}, 9316 Global: {} 9317 }, 9318 Initializers: {} 9319 }; 9320 Triggers.Listeners.Basic = { 9321 openListener: function openListener() { 9322 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'open'); 9323 }, 9324 closeListener: function closeListener() { 9325 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('close'); 9326 if (id) { 9327 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'close'); 9328 } else { 9329 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('close.zf.trigger'); 9330 } 9331 }, 9332 toggleListener: function toggleListener() { 9333 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle'); 9334 if (id) { 9335 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'toggle'); 9336 } else { 9337 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('toggle.zf.trigger'); 9338 } 9339 }, 9340 closeableListener: function closeableListener(e) { 9341 var animation = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('closable'); 9342 9343 // Only close the first closable element. See https://git.io/zf-7833 9344 e.stopPropagation(); 9345 if (animation !== '') { 9346 _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__.Motion.animateOut(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), animation, function () { 9347 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('closed.zf'); 9348 }); 9349 } else { 9350 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).fadeOut().trigger('closed.zf'); 9351 } 9352 }, 9353 toggleFocusListener: function toggleFocusListener() { 9354 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle-focus'); 9355 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id)).triggerHandler('toggle.zf.trigger', [jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)]); 9356 } 9357 }; 9358 9359 // Elements with [data-open] will reveal a plugin that supports it when clicked. 9360 Triggers.Initializers.addOpenListener = function ($elem) { 9361 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.openListener); 9362 $elem.on('click.zf.trigger', '[data-open]', Triggers.Listeners.Basic.openListener); 9363 }; 9364 9365 // Elements with [data-close] will close a plugin that supports it when clicked. 9366 // If used without a value on [data-close], the event will bubble, allowing it to close a parent component. 9367 Triggers.Initializers.addCloseListener = function ($elem) { 9368 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.closeListener); 9369 $elem.on('click.zf.trigger', '[data-close]', Triggers.Listeners.Basic.closeListener); 9370 }; 9371 9372 // Elements with [data-toggle] will toggle a plugin that supports it when clicked. 9373 Triggers.Initializers.addToggleListener = function ($elem) { 9374 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.toggleListener); 9375 $elem.on('click.zf.trigger', '[data-toggle]', Triggers.Listeners.Basic.toggleListener); 9376 }; 9377 9378 // Elements with [data-closable] will respond to close.zf.trigger events. 9379 Triggers.Initializers.addCloseableListener = function ($elem) { 9380 $elem.off('close.zf.trigger', Triggers.Listeners.Basic.closeableListener); 9381 $elem.on('close.zf.trigger', '[data-closeable], [data-closable]', Triggers.Listeners.Basic.closeableListener); 9382 }; 9383 9384 // Elements with [data-toggle-focus] will respond to coming in and out of focus 9385 Triggers.Initializers.addToggleFocusListener = function ($elem) { 9386 $elem.off('focus.zf.trigger blur.zf.trigger', Triggers.Listeners.Basic.toggleFocusListener); 9387 $elem.on('focus.zf.trigger blur.zf.trigger', '[data-toggle-focus]', Triggers.Listeners.Basic.toggleFocusListener); 9388 }; 9389 9390 // More Global/complex listeners and triggers 9391 Triggers.Listeners.Global = { 9392 resizeListener: function resizeListener($nodes) { 9393 if (!MutationObserver) { 9394 //fallback for IE 9 9395 $nodes.each(function () { 9396 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('resizeme.zf.trigger'); 9397 }); 9398 } 9399 //trigger all listening elements and signal a resize event 9400 $nodes.attr('data-events', "resize"); 9401 }, 9402 scrollListener: function scrollListener($nodes) { 9403 if (!MutationObserver) { 9404 //fallback for IE 9 9405 $nodes.each(function () { 9406 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('scrollme.zf.trigger'); 9407 }); 9408 } 9409 //trigger all listening elements and signal a scroll event 9410 $nodes.attr('data-events', "scroll"); 9411 }, 9412 closeMeListener: function closeMeListener(e, pluginId) { 9413 var plugin = e.namespace.split('.')[0]; 9414 var plugins = jquery__WEBPACK_IMPORTED_MODULE_0___default()("[data-".concat(plugin, "]")).not("[data-yeti-box=\"".concat(pluginId, "\"]")); 9415 plugins.each(function () { 9416 var _this = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this); 9417 _this.triggerHandler('close.zf.trigger', [_this]); 9418 }); 9419 } 9420 }; 9421 9422 // Global, parses whole document. 9423 Triggers.Initializers.addClosemeListener = function (pluginName) { 9424 var yetiBoxes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-yeti-box]'), 9425 plugNames = ['dropdown', 'tooltip', 'reveal']; 9426 if (pluginName) { 9427 if (typeof pluginName === 'string') { 9428 plugNames.push(pluginName); 9429 } else if (_typeof(pluginName) === 'object' && typeof pluginName[0] === 'string') { 9430 plugNames = plugNames.concat(pluginName); 9431 } else { 9432 console.error('Plugin names must be strings'); 9433 } 9434 } 9435 if (yetiBoxes.length) { 9436 var listeners = plugNames.map(function (name) { 9437 return "closeme.zf.".concat(name); 9438 }).join(' '); 9439 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(listeners).on(listeners, Triggers.Listeners.Global.closeMeListener); 9440 } 9441 }; 9442 function debounceGlobalListener(debounce, trigger, listener) { 9443 var timer, 9444 args = Array.prototype.slice.call(arguments, 3); 9445 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on(trigger, function () { 9446 if (timer) { 9447 clearTimeout(timer); 9448 } 9449 timer = setTimeout(function () { 9450 listener.apply(null, args); 9451 }, debounce || 10); //default time to emit scroll event 9452 }); 9453 } 9454 Triggers.Initializers.addResizeListener = function (debounce) { 9455 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-resize]'); 9456 if ($nodes.length) { 9457 debounceGlobalListener(debounce, 'resize.zf.trigger', Triggers.Listeners.Global.resizeListener, $nodes); 9458 } 9459 }; 9460 Triggers.Initializers.addScrollListener = function (debounce) { 9461 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-scroll]'); 9462 if ($nodes.length) { 9463 debounceGlobalListener(debounce, 'scroll.zf.trigger', Triggers.Listeners.Global.scrollListener, $nodes); 9464 } 9465 }; 9466 Triggers.Initializers.addMutationEventsListener = function ($elem) { 9467 if (!MutationObserver) { 9468 return false; 9469 } 9470 var $nodes = $elem.find('[data-resize], [data-scroll], [data-mutate]'); 9471 9472 //element callback 9473 var listeningElementsMutation = function listeningElementsMutation(mutationRecordsList) { 9474 var $target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(mutationRecordsList[0].target); 9475 9476 //trigger the event handler for the element depending on type 9477 switch (mutationRecordsList[0].type) { 9478 case "attributes": 9479 if ($target.attr("data-events") === "scroll" && mutationRecordsList[0].attributeName === "data-events") { 9480 $target.triggerHandler('scrollme.zf.trigger', [$target, window.pageYOffset]); 9481 } 9482 if ($target.attr("data-events") === "resize" && mutationRecordsList[0].attributeName === "data-events") { 9483 $target.triggerHandler('resizeme.zf.trigger', [$target]); 9484 } 9485 if (mutationRecordsList[0].attributeName === "style") { 9486 $target.closest("[data-mutate]").attr("data-events", "mutate"); 9487 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 9488 } 9489 break; 9490 case "childList": 9491 $target.closest("[data-mutate]").attr("data-events", "mutate"); 9492 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 9493 break; 9494 default: 9495 return false; 9496 //nothing 9497 } 9498 }; 9499 if ($nodes.length) { 9500 //for each element that needs to listen for resizing, scrolling, or mutation add a single observer 9501 for (var i = 0; i <= $nodes.length - 1; i++) { 9502 var elementObserver = new MutationObserver(listeningElementsMutation); 9503 elementObserver.observe($nodes[i], { 9504 attributes: true, 9505 childList: true, 9506 characterData: false, 9507 subtree: true, 9508 attributeFilter: ["data-events", "style"] 9509 }); 9510 } 9511 } 9512 }; 9513 Triggers.Initializers.addSimpleListeners = function () { 9514 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 9515 Triggers.Initializers.addOpenListener($document); 9516 Triggers.Initializers.addCloseListener($document); 9517 Triggers.Initializers.addToggleListener($document); 9518 Triggers.Initializers.addCloseableListener($document); 9519 Triggers.Initializers.addToggleFocusListener($document); 9520 }; 9521 Triggers.Initializers.addGlobalListeners = function () { 9522 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 9523 Triggers.Initializers.addMutationEventsListener($document); 9524 Triggers.Initializers.addResizeListener(250); 9525 Triggers.Initializers.addScrollListener(); 9526 Triggers.Initializers.addClosemeListener(); 9527 }; 9528 Triggers.init = function (__, Foundation) { 9529 (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 9530 if (jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized !== true) {
9531 Triggers.Initializers.addSimpleListeners(); 9532 Triggers.Initializers.addGlobalListeners(); 9533 jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized = true; 9534 } 9535 }); 9536 if (Foundation) { 9537 Foundation.Triggers = Triggers; 9538 // Legacy included to be backwards compatible for now. 9539 Foundation.IHearYou = Triggers.Initializers.addGlobalListeners; 9540 } 9541 }; 9542 9543 /***/ 9544 }), 9545 /***/"./foundation.core": ( 9546 /*!****************************************************************************************************************************************************************!*\ 9547 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 9548 \****************************************************************************************************************************************************************/ 9549 /***/ 9550 function (module) { 9551 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 9552 9553 /***/ 9554 }), 9555 /***/"./foundation.util.keyboard": ( 9556 /*!****************************************************************************************************************************************************************************************************!*\ 9557 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.keyboard"],"amd":"./foundation.util.keyboard","commonjs":"./foundation.util.keyboard","commonjs2":"./foundation.util.keyboard"} ***! 9558 \****************************************************************************************************************************************************************************************************/ 9559 /***/ 9560 function (module) { 9561 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__; 9562 9563 /***/ 9564 }), 9565 /***/"./foundation.util.mediaQuery": ( 9566 /*!************************************************************************************************************************************************************************************************************!*\ 9567 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.mediaQuery"],"amd":"./foundation.util.mediaQuery","commonjs":"./foundation.util.mediaQuery","commonjs2":"./foundation.util.mediaQuery"} ***! 9568 \************************************************************************************************************************************************************************************************************/ 9569 /***/ 9570 function (module) { 9571 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__; 9572 9573 /***/ 9574 }), 9575 /***/"./foundation.util.motion": ( 9576 /*!********************************************************************************************************************************************************************************************!*\ 9577 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.motion"],"amd":"./foundation.util.motion","commonjs":"./foundation.util.motion","commonjs2":"./foundation.util.motion"} ***! 9578 \********************************************************************************************************************************************************************************************/ 9579 /***/ 9580 function (module) { 9581 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__; 9582 9583 /***/ 9584 }), 9585 /***/"jquery": ( 9586 /*!********************************************************************************************!*\ 9587 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 9588 \********************************************************************************************/ 9589 /***/ 9590 function (module) { 9591 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 9592 9593 /***/ 9594 }) 9595 9596 /******/ 9597 }; 9598 /************************************************************************/ 9599 /******/ // The module cache 9600 /******/ 9601 var __webpack_module_cache__ = {}; 9602 /******/ 9603 /******/ // The require function 9604 /******/ 9605 function __webpack_require__(moduleId) { 9606 /******/ // Check if module is in cache 9607 /******/var cachedModule = __webpack_module_cache__[moduleId]; 9608 /******/ 9609 if (cachedModule !== undefined) { 9610 /******/return cachedModule.exports; 9611 /******/ 9612 } 9613 /******/ // Create a new module (and put it into the cache) 9614 /******/ 9615 var module = __webpack_module_cache__[moduleId] = { 9616 /******/ // no module.id needed 9617 /******/ // no module.loaded needed 9618 /******/exports: {} 9619 /******/ 9620 }; 9621 /******/ 9622 /******/ // Execute the module function 9623 /******/ 9624 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 9625 /******/ 9626 /******/ // Return the exports of the module 9627 /******/ 9628 return module.exports; 9629 /******/ 9630 } 9631 /******/ 9632 /************************************************************************/ 9633 /******/ /* webpack/runtime/compat get default export */ 9634 /******/ 9635 !function () { 9636 /******/ // getDefaultExport function for compatibility with non-harmony modules 9637 /******/__webpack_require__.n = function (module) {
vendor: 4,847 bytes, lines 9638-9744
9638 /******/var getter = module && module.__esModule ? /******/function () { 9639 return module['default']; 9640 } : /******/function () { 9641 return module; 9642 }; 9643 /******/ 9644 __webpack_require__.d(getter, { 9645 a: getter 9646 }); 9647 /******/ 9648 return getter; 9649 /******/ 9650 }; 9651 /******/ 9652 }(); 9653 /******/ 9654 /******/ /* webpack/runtime/define property getters */ 9655 /******/ 9656 !function () { 9657 /******/ // define getter functions for harmony exports 9658 /******/__webpack_require__.d = function (exports, definition) { 9659 /******/for (var key in definition) { 9660 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 9661 /******/Object.defineProperty(exports, key, { 9662 enumerable: true, 9663 get: definition[key] 9664 }); 9665 /******/ 9666 } 9667 /******/ 9668 } 9669 /******/ 9670 }; 9671 /******/ 9672 }(); 9673 /******/ 9674 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 9675 /******/ 9676 !function () { 9677 /******/__webpack_require__.o = function (obj, prop) { 9678 return Object.prototype.hasOwnProperty.call(obj, prop); 9679 }; 9680 /******/ 9681 }(); 9682 /******/ 9683 /******/ /* webpack/runtime/make namespace object */ 9684 /******/ 9685 !function () { 9686 /******/ // define __esModule on exports 9687 /******/__webpack_require__.r = function (exports) { 9688 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 9689 /******/Object.defineProperty(exports, Symbol.toStringTag, { 9690 value: 'Module' 9691 }); 9692 /******/ 9693 } 9694 /******/ 9695 Object.defineProperty(exports, '__esModule', { 9696 value: true 9697 }); 9698 /******/ 9699 }; 9700 /******/ 9701 }(); 9702 /******/ 9703 /************************************************************************/ 9704 var __webpack_exports__ = {}; 9705 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 9706 !function () { 9707 /*!****************************************************!*\ 9708 !*** ./js/entries/plugins/foundation.offcanvas.js ***! 9709 \****************************************************/ 9710 __webpack_require__.r(__webpack_exports__); 9711 /* harmony export */ 9712 __webpack_require__.d(__webpack_exports__, { 9713 /* harmony export */Foundation: function () { 9714 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 9715 }, 9716 /* harmony export */OffCanvas: function () { 9717 return /* reexport safe */_foundation_offcanvas__WEBPACK_IMPORTED_MODULE_1__.OffCanvas; 9718 } 9719 /* harmony export */ 9720 }); 9721 /* harmony import */ 9722 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 9723 /* harmony import */ 9724 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 9725 /* harmony import */ 9726 var _foundation_offcanvas__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.offcanvas */"./js/foundation.offcanvas.js"); 9727 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_offcanvas__WEBPACK_IMPORTED_MODULE_1__.OffCanvas, 'OffCanvas'); 9728 }(); 9729 /******/ 9730 return __webpack_exports__; 9731 /******/ 9732 }(); 9733}); 9734(function webpackUniversalModuleDefinition(root, factory) { 9735 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.mediaQuery", "./foundation.util.motion"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.util.motion"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.sticky"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.motion"]); 9736})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__) { 9737 return /******/function () { 9738 // webpackBootstrap 9739 /******/ 9740 "use strict"; 9741 9742 /******/ 9743 var __webpack_modules__ = { 9744
vendor: 8,169 bytes, lines 9744-9914
9744/***/"./js/foundation.sticky.js": ( 9745 /*!*********************************!*\ 9746 !*** ./js/foundation.sticky.js ***! 9747 \*********************************/ 9748 /***/ 9749 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 9750 __webpack_require__.r(__webpack_exports__); 9751 /* harmony export */ 9752 __webpack_require__.d(__webpack_exports__, { 9753 /* harmony export */Sticky: function () { 9754 return /* binding */Sticky; 9755 } 9756 /* harmony export */ 9757 }); 9758 /* harmony import */ 9759 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 9760 /* harmony import */ 9761 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 9762 /* harmony import */ 9763 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 9764 /* harmony import */ 9765 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 9766 /* harmony import */ 9767 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./foundation.util.mediaQuery"); 9768 /* harmony import */ 9769 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__); 9770 /* harmony import */ 9771 var _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.util.triggers */"./js/foundation.util.triggers.js"); 9772 function _typeof(o) { 9773 "@babel/helpers - typeof"; 9774 9775 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 9776 return typeof o; 9777 } : function (o) { 9778 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 9779 }, _typeof(o); 9780 } 9781 function _classCallCheck(a, n) { 9782 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 9783 } 9784 function _defineProperties(e, r) { 9785 for (var t = 0; t < r.length; t++) { 9786 var o = r[t]; 9787 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 9788 } 9789 } 9790 function _createClass(e, r, t) { 9791 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 9792 writable: !1 9793 }), e; 9794 } 9795 function _toPropertyKey(t) { 9796 var i = _toPrimitive(t, "string"); 9797 return "symbol" == _typeof(i) ? i : i + ""; 9798 } 9799 function _toPrimitive(t, r) { 9800 if ("object" != _typeof(t) || !t) return t; 9801 var e = t[Symbol.toPrimitive]; 9802 if (void 0 !== e) { 9803 var i = e.call(t, r || "default"); 9804 if ("object" != _typeof(i)) return i; 9805 throw new TypeError("@@toPrimitive must return a primitive value."); 9806 } 9807 return ("string" === r ? String : Number)(t); 9808 } 9809 function _callSuper(t, o, e) { 9810 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 9811 } 9812 function _possibleConstructorReturn(t, e) { 9813 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 9814 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 9815 return _assertThisInitialized(t); 9816 } 9817 function _assertThisInitialized(e) { 9818 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 9819 return e; 9820 } 9821 function _isNativeReflectConstruct() { 9822 try { 9823 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 9824 } catch (t) {} 9825 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 9826 return !!t; 9827 })(); 9828 } 9829 function _getPrototypeOf(t) { 9830 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 9831 return t.__proto__ || Object.getPrototypeOf(t); 9832 }, _getPrototypeOf(t); 9833 } 9834 function _inherits(t, e) { 9835 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 9836 t.prototype = Object.create(e && e.prototype, { 9837 constructor: { 9838 value: t, 9839 writable: !0, 9840 configurable: !0 9841 } 9842 }), Object.defineProperty(t, "prototype", { 9843 writable: !1 9844 }), e && _setPrototypeOf(t, e); 9845 } 9846 function _setPrototypeOf(t, e) { 9847 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 9848 return t.__proto__ = e, t; 9849 }, _setPrototypeOf(t, e); 9850 } 9851 9852 /** 9853 * Sticky module. 9854 * @module foundation.sticky 9855 * @requires foundation.util.triggers 9856 * @requires foundation.util.mediaQuery 9857 */ 9858 var Sticky = /*#__PURE__*/function (_Plugin) { 9859 function Sticky() { 9860 _classCallCheck(this, Sticky); 9861 return _callSuper(this, Sticky, arguments); 9862 } 9863 _inherits(Sticky, _Plugin); 9864 return _createClass(Sticky, [{ 9865 key: "_setup", 9866 value: 9867 /** 9868 * Creates a new instance of a sticky thing. 9869 * @class 9870 * @name Sticky 9871 * @param {jQuery} element - jQuery object to make sticky. 9872 * @param {Object} options - options object passed when creating the element programmatically. 9873 */ 9874 function _setup(element, options) { 9875 this.$element = element; 9876 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, Sticky.defaults, this.$element.data(), options); 9877 this.className = 'Sticky'; // ie9 back compat 9878 9879 // Triggers init is idempotent, just need to make sure it is initialized 9880 _foundation_util_triggers__WEBPACK_IMPORTED_MODULE_3__.Triggers.init(jquery__WEBPACK_IMPORTED_MODULE_0___default()); 9881 this._init(); 9882 } 9883 9884 /** 9885 * Initializes the sticky element by adding classes, getting/setting dimensions, breakpoints and attributes 9886 * @function 9887 * @private 9888 */ 9889 }, { 9890 key: "_init", 9891 value: function _init() { 9892 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__.MediaQuery._init(); 9893 var $parent = this.$element.parent('[data-sticky-container]'), 9894 id = this.$element[0].id || (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.GetYoDigits)(6, 'sticky'), 9895 _this = this; 9896 if ($parent.length) { 9897 this.$container = $parent; 9898 } else { 9899 this.wasWrapped = true; 9900 this.$element.wrap(this.options.container); 9901 this.$container = this.$element.parent(); 9902 } 9903 this.$container.addClass(this.options.containerClass); 9904 this.$element.addClass(this.options.stickyClass).attr({ 9905 'data-resize': id, 9906 'data-mutate': id 9907 }); 9908 if (this.options.anchor !== '') { 9909 jquery__WEBPACK_IMPORTED_MODULE_0___default()('#' + _this.options.anchor).attr({ 9910 'data-mutate': id 9911 }); 9912 } 9913 this.scrollCount = this.options.checkEvery; 9914 this.isStuck = false;
vendor: 9,404 bytes, lines 9915-10140
9915 this.onLoadListener = (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 9916 //We calculate the container height to have correct values for anchor points offset calculation. 9917 _this.containerHeight = _this.$element.css("display") === "none" ? 0 : _this.$element[0].getBoundingClientRect().height; 9918 _this.$container.css('height', _this.containerHeight); 9919 _this.elemHeight = _this.containerHeight; 9920 if (_this.options.anchor !== '') { 9921 _this.$anchor = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#' + _this.options.anchor); 9922 } else { 9923 _this._parsePoints(); 9924 } 9925 _this._setSizes(function () { 9926 var scroll = window.pageYOffset; 9927 _this._calc(false, scroll); 9928 //Unstick the element will ensure that proper classes are set. 9929 if (!_this.isStuck) { 9930 _this._removeSticky(scroll >= _this.topPoint ? false : true); 9931 } 9932 }); 9933 _this._events(id.split('-').reverse().join('-')); 9934 }); 9935 } 9936 9937 /** 9938 * If using multiple elements as anchors, calculates the top and bottom pixel values the sticky thing should stick and unstick on. 9939 * @function 9940 * @private 9941 */ 9942 }, { 9943 key: "_parsePoints", 9944 value: function _parsePoints() { 9945 var top = this.options.topAnchor === "" ? 1 : this.options.topAnchor, 9946 btm = this.options.btmAnchor === "" ? document.documentElement.scrollHeight : this.options.btmAnchor, 9947 pts = [top, btm], 9948 breaks = {}; 9949 for (var i = 0, len = pts.length; i < len && pts[i]; i++) { 9950 var pt; 9951 if (typeof pts[i] === 'number') { 9952 pt = pts[i]; 9953 } else { 9954 var place = pts[i].split(':'), 9955 anchor = jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(place[0])); 9956 pt = anchor.offset().top; 9957 if (place[1] && place[1].toLowerCase() === 'bottom') { 9958 pt += anchor[0].getBoundingClientRect().height; 9959 } 9960 } 9961 breaks[i] = pt; 9962 } 9963 this.points = breaks; 9964 return; 9965 } 9966 9967 /** 9968 * Adds event handlers for the scrolling element. 9969 * @private 9970 * @param {String} id - pseudo-random id for unique scroll event listener. 9971 */ 9972 }, { 9973 key: "_events", 9974 value: function _events(id) { 9975 var _this = this, 9976 scrollListener = this.scrollListener = "scroll.zf.".concat(id); 9977 if (this.isOn) { 9978 return; 9979 } 9980 if (this.canStick) { 9981 this.isOn = true; 9982 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(scrollListener).on(scrollListener, function () { 9983 if (_this.scrollCount === 0) { 9984 _this.scrollCount = _this.options.checkEvery; 9985 _this._setSizes(function () { 9986 _this._calc(false, window.pageYOffset); 9987 }); 9988 } else { 9989 _this.scrollCount--; 9990 _this._calc(false, window.pageYOffset); 9991 } 9992 }); 9993 } 9994 this.$element.off('resizeme.zf.trigger').on('resizeme.zf.trigger', function () { 9995 _this._eventsHandler(id); 9996 }); 9997 this.$element.on('mutateme.zf.trigger', function () { 9998 _this._eventsHandler(id); 9999 }); 10000 if (this.$anchor) { 10001 this.$anchor.on('mutateme.zf.trigger', function () { 10002 _this._eventsHandler(id); 10003 }); 10004 } 10005 } 10006 10007 /** 10008 * Handler for events. 10009 * @private 10010 * @param {String} id - pseudo-random id for unique scroll event listener. 10011 */ 10012 }, { 10013 key: "_eventsHandler", 10014 value: function _eventsHandler(id) { 10015 var _this = this, 10016 scrollListener = this.scrollListener = "scroll.zf.".concat(id); 10017 _this._setSizes(function () { 10018 _this._calc(false); 10019 if (_this.canStick) { 10020 if (!_this.isOn) { 10021 _this._events(id); 10022 } 10023 } else if (_this.isOn) { 10024 _this._pauseListeners(scrollListener); 10025 } 10026 }); 10027 } 10028 10029 /** 10030 * Removes event handlers for scroll and change events on anchor. 10031 * @fires Sticky#pause 10032 * @param {String} scrollListener - unique, namespaced scroll listener attached to `window` 10033 */ 10034 }, { 10035 key: "_pauseListeners", 10036 value: function _pauseListeners(scrollListener) { 10037 this.isOn = false; 10038 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(scrollListener); 10039 10040 /** 10041 * Fires when the plugin is paused due to resize event shrinking the view. 10042 * @event Sticky#pause 10043 * @private 10044 */ 10045 this.$element.trigger('pause.zf.sticky'); 10046 } 10047 10048 /** 10049 * Called on every `scroll` event and on `_init` 10050 * fires functions based on booleans and cached values 10051 * @param {Boolean} checkSizes - true if plugin should recalculate sizes and breakpoints. 10052 * @param {Number} scroll - current scroll position passed from scroll event cb function. If not passed, defaults to `window.pageYOffset`. 10053 */ 10054 }, { 10055 key: "_calc", 10056 value: function _calc(checkSizes, scroll) { 10057 if (checkSizes) { 10058 this._setSizes(); 10059 } 10060 if (!this.canStick) { 10061 if (this.isStuck) { 10062 this._removeSticky(true); 10063 } 10064 return false; 10065 } 10066 if (!scroll) { 10067 scroll = window.pageYOffset; 10068 } 10069 if (scroll >= this.topPoint) { 10070 if (scroll <= this.bottomPoint) { 10071 if (!this.isStuck) { 10072 this._setSticky(); 10073 } 10074 } else { 10075 if (this.isStuck) { 10076 this._removeSticky(false); 10077 } 10078 } 10079 } else { 10080 if (this.isStuck) { 10081 this._removeSticky(true); 10082 } 10083 } 10084 } 10085 10086 /** 10087 * Causes the $element to become stuck. 10088 * Adds `position: fixed;`, and helper classes. 10089 * @fires Sticky#stuckto 10090 * @function 10091 * @private 10092 */ 10093 }, { 10094 key: "_setSticky", 10095 value: function _setSticky() { 10096 var _this = this, 10097 stickTo = this.options.stickTo, 10098 mrgn = stickTo === 'top' ? 'marginTop' : 'marginBottom', 10099 notStuckTo = stickTo === 'top' ? 'bottom' : 'top', 10100 css = {}; 10101 css[mrgn] = "".concat(this.options[mrgn], "em"); 10102 css[stickTo] = 0; 10103 css[notStuckTo] = 'auto'; 10104 this.isStuck = true; 10105 this.$element.removeClass("is-anchored is-at-".concat(notStuckTo)).addClass("is-stuck is-at-".concat(stickTo)).css(css) 10106 /** 10107 * Fires when the $element has become `position: fixed;` 10108 * Namespaced to `top` or `bottom`, e.g. `sticky.zf.stuckto:top` 10109 * @event Sticky#stuckto 10110 */.trigger("sticky.zf.stuckto:".concat(stickTo)); 10111 this.$element.on("transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd", function () { 10112 _this._setSizes(); 10113 }); 10114 } 10115 10116 /** 10117 * Causes the $element to become unstuck. 10118 * Removes `position: fixed;`, and helper classes. 10119 * Adds other helper classes. 10120 * @param {Boolean} isTop - tells the function if the $element should anchor to the top or bottom of its $anchor element. 10121 * @fires Sticky#unstuckfrom 10122 * @private 10123 */ 10124 }, { 10125 key: "_removeSticky", 10126 value: function _removeSticky(isTop) { 10127 var stickTo = this.options.stickTo, 10128 stickToTop = stickTo === 'top', 10129 css = {}, 10130 anchorPt = (this.points ? this.points[1] - this.points[0] : this.anchorHeight) - this.elemHeight, 10131 mrgn = stickToTop ? 'marginTop' : 'marginBottom', 10132 topOrBottom = isTop ? 'top' : 'bottom'; 10133 css[mrgn] = 0; 10134 css.bottom = 'auto'; 10135 if (isTop) { 10136 css.top = 0; 10137 } else { 10138 css.top = anchorPt; 10139 } 10140 this.isStuck = false;
vendor: 4,167 bytes, lines 10141-10225
10141 this.$element.removeClass("is-stuck is-at-".concat(stickTo)).addClass("is-anchored is-at-".concat(topOrBottom)).css(css) 10142 /** 10143 * Fires when the $element has become anchored. 10144 * Namespaced to `top` or `bottom`, e.g. `sticky.zf.unstuckfrom:bottom` 10145 * @event Sticky#unstuckfrom 10146 */.trigger("sticky.zf.unstuckfrom:".concat(topOrBottom)); 10147 } 10148 10149 /** 10150 * Sets the $element and $container sizes for plugin. 10151 * Calls `_setBreakPoints`. 10152 * @param {Function} cb - optional callback function to fire on completion of `_setBreakPoints`. 10153 * @private 10154 */ 10155 }, { 10156 key: "_setSizes", 10157 value: function _setSizes(cb) { 10158 this.canStick = _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_2__.MediaQuery.is(this.options.stickyOn); 10159 if (!this.canStick) { 10160 if (cb && typeof cb === 'function') { 10161 cb(); 10162 } 10163 } 10164 var newElemWidth = this.$container[0].getBoundingClientRect().width, 10165 comp = window.getComputedStyle(this.$container[0]), 10166 pdngl = parseInt(comp['padding-left'], 10), 10167 pdngr = parseInt(comp['padding-right'], 10); 10168 if (this.$anchor && this.$anchor.length) { 10169 this.anchorHeight = this.$anchor[0].getBoundingClientRect().height; 10170 } else { 10171 this._parsePoints(); 10172 } 10173 this.$element.css({ 10174 'max-width': "".concat(newElemWidth - pdngl - pdngr, "px") 10175 }); 10176 10177 // Recalculate the height only if it is "dynamic" 10178 if (this.options.dynamicHeight || !this.containerHeight) { 10179 // Get the sticked element height and apply it to the container to "hold the place" 10180 var newContainerHeight = this.$element[0].getBoundingClientRect().height || this.containerHeight; 10181 newContainerHeight = this.$element.css("display") === "none" ? 0 : newContainerHeight; 10182 this.$container.css('height', newContainerHeight); 10183 this.containerHeight = newContainerHeight; 10184 } 10185 this.elemHeight = this.containerHeight; 10186 if (!this.isStuck) { 10187 if (this.$element.hasClass('is-at-bottom')) { 10188 var anchorPt = (this.points ? this.points[1] - this.$container.offset().top : this.anchorHeight) - this.elemHeight; 10189 this.$element.css('top', anchorPt); 10190 } 10191 } 10192 this._setBreakPoints(this.containerHeight, function () { 10193 if (cb && typeof cb === 'function') { 10194 cb(); 10195 } 10196 }); 10197 } 10198 10199 /** 10200 * Sets the upper and lower breakpoints for the element to become sticky/unsticky. 10201 * @param {Number} elemHeight - px value for sticky.$element height, calculated by `_setSizes`. 10202 * @param {Function} cb - optional callback function to be called on completion. 10203 * @private 10204 */ 10205 }, { 10206 key: "_setBreakPoints", 10207 value: function _setBreakPoints(elemHeight, cb) { 10208 if (!this.canStick) { 10209 if (cb && typeof cb === 'function') { 10210 cb(); 10211 } else { 10212 return false; 10213 } 10214 } 10215 var mTop = emCalc(this.options.marginTop), 10216 mBtm = emCalc(this.options.marginBottom), 10217 topPoint = this.points ? this.points[0] : this.$anchor.offset().top, 10218 bottomPoint = this.points ? this.points[1] : topPoint + this.anchorHeight, 10219 // topPoint = this.$anchor.offset().top || this.points[0], 10220 // bottomPoint = topPoint + this.anchorHeight || this.points[1], 10221 winHeight = window.innerHeight; 10222 if (this.options.stickTo === 'top') { 10223 topPoint -= mTop; 10224 bottomPoint -= elemHeight + mTop; 10225 }
vendor: 19,058 bytes, lines 10225-10632
10225 else if (this.options.stickTo === 'bottom') { 10226 topPoint -= winHeight - (elemHeight + mBtm); 10227 bottomPoint -= winHeight - mBtm; 10228 } else { 10229 //this would be the stickTo: both option... tricky 10230 } 10231 this.topPoint = topPoint; 10232 this.bottomPoint = bottomPoint; 10233 if (cb && typeof cb === 'function') { 10234 cb(); 10235 } 10236 } 10237 10238 /** 10239 * Destroys the current sticky element. 10240 * Resets the element to the top position first. 10241 * Removes event listeners, JS-added css properties and classes, and unwraps the $element if the JS added the $container. 10242 * @function 10243 */ 10244 }, { 10245 key: "_destroy", 10246 value: function _destroy() { 10247 this._removeSticky(true); 10248 this.$element.removeClass("".concat(this.options.stickyClass, " is-anchored is-at-top")).css({ 10249 height: '', 10250 top: '', 10251 bottom: '', 10252 'max-width': '' 10253 }).off('resizeme.zf.trigger').off('mutateme.zf.trigger'); 10254 if (this.$anchor && this.$anchor.length) { 10255 this.$anchor.off('change.zf.sticky'); 10256 } 10257 if (this.scrollListener) jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(this.scrollListener); 10258 if (this.onLoadListener) jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(this.onLoadListener); 10259 if (this.wasWrapped) { 10260 this.$element.unwrap(); 10261 } else { 10262 this.$container.removeClass(this.options.containerClass).css({ 10263 height: '' 10264 }); 10265 } 10266 } 10267 }]); 10268 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 10269 Sticky.defaults = { 10270 /** 10271 * Customizable container template. Add your own classes for styling and sizing. 10272 * @option 10273 * @type {string} 10274 * @default '<div data-sticky-container></div>' 10275 */ 10276 container: '<div data-sticky-container></div>', 10277 /** 10278 * Location in the view the element sticks to. Can be `'top'` or `'bottom'`. 10279 * @option 10280 * @type {string} 10281 * @default 'top' 10282 */ 10283 stickTo: 'top', 10284 /** 10285 * If anchored to a single element, the id of that element. 10286 * @option 10287 * @type {string} 10288 * @default '' 10289 */ 10290 anchor: '', 10291 /** 10292 * If using more than one element as anchor points, the id of the top anchor. 10293 * @option 10294 * @type {string} 10295 * @default '' 10296 */ 10297 topAnchor: '', 10298 /** 10299 * If using more than one element as anchor points, the id of the bottom anchor. 10300 * @option 10301 * @type {string} 10302 * @default '' 10303 */ 10304 btmAnchor: '', 10305 /** 10306 * Margin, in `em`'s to apply to the top of the element when it becomes sticky. 10307 * @option 10308 * @type {number} 10309 * @default 1 10310 */ 10311 marginTop: 1, 10312 /** 10313 * Margin, in `em`'s to apply to the bottom of the element when it becomes sticky. 10314 * @option 10315 * @type {number} 10316 * @default 1 10317 */ 10318 marginBottom: 1, 10319 /** 10320 * Breakpoint string that is the minimum screen size an element should become sticky. 10321 * @option 10322 * @type {string} 10323 * @default 'medium' 10324 */ 10325 stickyOn: 'medium', 10326 /** 10327 * Class applied to sticky element, and removed on destruction. Foundation defaults to `sticky`. 10328 * @option 10329 * @type {string} 10330 * @default 'sticky' 10331 */ 10332 stickyClass: 'sticky', 10333 /** 10334 * Class applied to sticky container. Foundation defaults to `sticky-container`. 10335 * @option 10336 * @type {string} 10337 * @default 'sticky-container' 10338 */ 10339 containerClass: 'sticky-container', 10340 /** 10341 * If true (by default), keep the sticky container the same height as the element. Otherwise, the container height is set once and does not change. 10342 * @option 10343 * @type {boolean} 10344 * @default true 10345 */ 10346 dynamicHeight: true, 10347 /** 10348 * 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. 10349 * @option 10350 * @type {number} 10351 * @default -1 10352 */ 10353 checkEvery: -1 10354 }; 10355 10356 /** 10357 * Helper function to calculate em values 10358 * @param Number {em} - number of em's to calculate into pixels 10359 */ 10360 function emCalc(em) { 10361 return parseInt(window.getComputedStyle(document.body, null).fontSize, 10) * em; 10362 } 10363 10364 /***/ 10365 }), 10366 /***/"./js/foundation.util.triggers.js": ( 10367 /*!****************************************!*\ 10368 !*** ./js/foundation.util.triggers.js ***! 10369 \****************************************/ 10370 /***/ 10371 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 10372 __webpack_require__.r(__webpack_exports__); 10373 /* harmony export */ 10374 __webpack_require__.d(__webpack_exports__, { 10375 /* harmony export */Triggers: function () { 10376 return /* binding */Triggers; 10377 } 10378 /* harmony export */ 10379 }); 10380 /* harmony import */ 10381 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 10382 /* harmony import */ 10383 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 10384 /* harmony import */ 10385 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 10386 /* harmony import */ 10387 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__); 10388 /* harmony import */ 10389 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.motion */"./foundation.util.motion"); 10390 /* harmony import */ 10391 var _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__); 10392 function _typeof(o) { 10393 "@babel/helpers - typeof"; 10394 10395 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 10396 return typeof o; 10397 } : function (o) { 10398 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 10399 }, _typeof(o); 10400 } 10401 var MutationObserver = function () { 10402 var prefixes = ['WebKit', 'Moz', 'O', 'Ms', '']; 10403 for (var i = 0; i < prefixes.length; i++) { 10404 if ("".concat(prefixes[i], "MutationObserver") in window) { 10405 return window["".concat(prefixes[i], "MutationObserver")]; 10406 } 10407 } 10408 return false; 10409 }(); 10410 var triggers = function triggers(el, type) { 10411 el.data(type).split(' ').forEach(function (id) { 10412 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id))[type === 'close' ? 'trigger' : 'triggerHandler']("".concat(type, ".zf.trigger"), [el]); 10413 }); 10414 }; 10415 var Triggers = { 10416 Listeners: { 10417 Basic: {}, 10418 Global: {} 10419 }, 10420 Initializers: {} 10421 }; 10422 Triggers.Listeners.Basic = { 10423 openListener: function openListener() { 10424 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'open'); 10425 }, 10426 closeListener: function closeListener() { 10427 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('close'); 10428 if (id) { 10429 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'close'); 10430 } else { 10431 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('close.zf.trigger'); 10432 } 10433 }, 10434 toggleListener: function toggleListener() { 10435 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle'); 10436 if (id) { 10437 triggers(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 'toggle'); 10438 } else { 10439 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('toggle.zf.trigger'); 10440 } 10441 }, 10442 closeableListener: function closeableListener(e) { 10443 var animation = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('closable'); 10444 10445 // Only close the first closable element. See https://git.io/zf-7833 10446 e.stopPropagation(); 10447 if (animation !== '') { 10448 _foundation_util_motion__WEBPACK_IMPORTED_MODULE_2__.Motion.animateOut(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), animation, function () { 10449 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).trigger('closed.zf'); 10450 }); 10451 } else { 10452 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).fadeOut().trigger('closed.zf'); 10453 } 10454 }, 10455 toggleFocusListener: function toggleFocusListener() { 10456 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).data('toggle-focus'); 10457 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(id)).triggerHandler('toggle.zf.trigger', [jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)]); 10458 } 10459 }; 10460 10461 // Elements with [data-open] will reveal a plugin that supports it when clicked. 10462 Triggers.Initializers.addOpenListener = function ($elem) { 10463 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.openListener); 10464 $elem.on('click.zf.trigger', '[data-open]', Triggers.Listeners.Basic.openListener); 10465 }; 10466 10467 // Elements with [data-close] will close a plugin that supports it when clicked. 10468 // If used without a value on [data-close], the event will bubble, allowing it to close a parent component. 10469 Triggers.Initializers.addCloseListener = function ($elem) { 10470 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.closeListener); 10471 $elem.on('click.zf.trigger', '[data-close]', Triggers.Listeners.Basic.closeListener); 10472 }; 10473 10474 // Elements with [data-toggle] will toggle a plugin that supports it when clicked. 10475 Triggers.Initializers.addToggleListener = function ($elem) { 10476 $elem.off('click.zf.trigger', Triggers.Listeners.Basic.toggleListener); 10477 $elem.on('click.zf.trigger', '[data-toggle]', Triggers.Listeners.Basic.toggleListener); 10478 }; 10479 10480 // Elements with [data-closable] will respond to close.zf.trigger events. 10481 Triggers.Initializers.addCloseableListener = function ($elem) { 10482 $elem.off('close.zf.trigger', Triggers.Listeners.Basic.closeableListener); 10483 $elem.on('close.zf.trigger', '[data-closeable], [data-closable]', Triggers.Listeners.Basic.closeableListener); 10484 }; 10485 10486 // Elements with [data-toggle-focus] will respond to coming in and out of focus 10487 Triggers.Initializers.addToggleFocusListener = function ($elem) { 10488 $elem.off('focus.zf.trigger blur.zf.trigger', Triggers.Listeners.Basic.toggleFocusListener); 10489 $elem.on('focus.zf.trigger blur.zf.trigger', '[data-toggle-focus]', Triggers.Listeners.Basic.toggleFocusListener); 10490 }; 10491 10492 // More Global/complex listeners and triggers 10493 Triggers.Listeners.Global = { 10494 resizeListener: function resizeListener($nodes) { 10495 if (!MutationObserver) { 10496 //fallback for IE 9 10497 $nodes.each(function () { 10498 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('resizeme.zf.trigger'); 10499 }); 10500 } 10501 //trigger all listening elements and signal a resize event 10502 $nodes.attr('data-events', "resize"); 10503 }, 10504 scrollListener: function scrollListener($nodes) { 10505 if (!MutationObserver) { 10506 //fallback for IE 9 10507 $nodes.each(function () { 10508 jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).triggerHandler('scrollme.zf.trigger'); 10509 }); 10510 } 10511 //trigger all listening elements and signal a scroll event 10512 $nodes.attr('data-events', "scroll"); 10513 }, 10514 closeMeListener: function closeMeListener(e, pluginId) { 10515 var plugin = e.namespace.split('.')[0]; 10516 var plugins = jquery__WEBPACK_IMPORTED_MODULE_0___default()("[data-".concat(plugin, "]")).not("[data-yeti-box=\"".concat(pluginId, "\"]")); 10517 plugins.each(function () { 10518 var _this = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this); 10519 _this.triggerHandler('close.zf.trigger', [_this]); 10520 }); 10521 } 10522 }; 10523 10524 // Global, parses whole document. 10525 Triggers.Initializers.addClosemeListener = function (pluginName) { 10526 var yetiBoxes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-yeti-box]'), 10527 plugNames = ['dropdown', 'tooltip', 'reveal']; 10528 if (pluginName) { 10529 if (typeof pluginName === 'string') { 10530 plugNames.push(pluginName); 10531 } else if (_typeof(pluginName) === 'object' && typeof pluginName[0] === 'string') { 10532 plugNames = plugNames.concat(pluginName); 10533 } else { 10534 console.error('Plugin names must be strings'); 10535 } 10536 } 10537 if (yetiBoxes.length) { 10538 var listeners = plugNames.map(function (name) { 10539 return "closeme.zf.".concat(name); 10540 }).join(' '); 10541 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(listeners).on(listeners, Triggers.Listeners.Global.closeMeListener); 10542 } 10543 }; 10544 function debounceGlobalListener(debounce, trigger, listener) { 10545 var timer, 10546 args = Array.prototype.slice.call(arguments, 3); 10547 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on(trigger, function () { 10548 if (timer) { 10549 clearTimeout(timer); 10550 } 10551 timer = setTimeout(function () { 10552 listener.apply(null, args); 10553 }, debounce || 10); //default time to emit scroll event 10554 }); 10555 } 10556 Triggers.Initializers.addResizeListener = function (debounce) { 10557 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-resize]'); 10558 if ($nodes.length) { 10559 debounceGlobalListener(debounce, 'resize.zf.trigger', Triggers.Listeners.Global.resizeListener, $nodes); 10560 } 10561 }; 10562 Triggers.Initializers.addScrollListener = function (debounce) { 10563 var $nodes = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-scroll]'); 10564 if ($nodes.length) { 10565 debounceGlobalListener(debounce, 'scroll.zf.trigger', Triggers.Listeners.Global.scrollListener, $nodes); 10566 } 10567 }; 10568 Triggers.Initializers.addMutationEventsListener = function ($elem) { 10569 if (!MutationObserver) { 10570 return false; 10571 } 10572 var $nodes = $elem.find('[data-resize], [data-scroll], [data-mutate]'); 10573 10574 //element callback 10575 var listeningElementsMutation = function listeningElementsMutation(mutationRecordsList) { 10576 var $target = jquery__WEBPACK_IMPORTED_MODULE_0___default()(mutationRecordsList[0].target); 10577 10578 //trigger the event handler for the element depending on type 10579 switch (mutationRecordsList[0].type) { 10580 case "attributes": 10581 if ($target.attr("data-events") === "scroll" && mutationRecordsList[0].attributeName === "data-events") { 10582 $target.triggerHandler('scrollme.zf.trigger', [$target, window.pageYOffset]); 10583 } 10584 if ($target.attr("data-events") === "resize" && mutationRecordsList[0].attributeName === "data-events") { 10585 $target.triggerHandler('resizeme.zf.trigger', [$target]); 10586 } 10587 if (mutationRecordsList[0].attributeName === "style") { 10588 $target.closest("[data-mutate]").attr("data-events", "mutate"); 10589 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 10590 } 10591 break; 10592 case "childList": 10593 $target.closest("[data-mutate]").attr("data-events", "mutate"); 10594 $target.closest("[data-mutate]").triggerHandler('mutateme.zf.trigger', [$target.closest("[data-mutate]")]); 10595 break; 10596 default: 10597 return false; 10598 //nothing 10599 } 10600 }; 10601 if ($nodes.length) { 10602 //for each element that needs to listen for resizing, scrolling, or mutation add a single observer 10603 for (var i = 0; i <= $nodes.length - 1; i++) { 10604 var elementObserver = new MutationObserver(listeningElementsMutation); 10605 elementObserver.observe($nodes[i], { 10606 attributes: true, 10607 childList: true, 10608 characterData: false, 10609 subtree: true, 10610 attributeFilter: ["data-events", "style"] 10611 }); 10612 } 10613 } 10614 }; 10615 Triggers.Initializers.addSimpleListeners = function () { 10616 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 10617 Triggers.Initializers.addOpenListener($document); 10618 Triggers.Initializers.addCloseListener($document); 10619 Triggers.Initializers.addToggleListener($document); 10620 Triggers.Initializers.addCloseableListener($document); 10621 Triggers.Initializers.addToggleFocusListener($document); 10622 }; 10623 Triggers.Initializers.addGlobalListeners = function () { 10624 var $document = jquery__WEBPACK_IMPORTED_MODULE_0___default()(document); 10625 Triggers.Initializers.addMutationEventsListener($document); 10626 Triggers.Initializers.addResizeListener(250); 10627 Triggers.Initializers.addScrollListener(); 10628 Triggers.Initializers.addClosemeListener(); 10629 }; 10630 Triggers.init = function (__, Foundation) { 10631 (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 10632 if (jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized !== true) {
10633 Triggers.Initializers.addSimpleListeners(); 10634 Triggers.Initializers.addGlobalListeners(); 10635 jquery__WEBPACK_IMPORTED_MODULE_0___default().triggersInitialized = true; 10636 } 10637 }); 10638 if (Foundation) { 10639 Foundation.Triggers = Triggers; 10640 // Legacy included to be backwards compatible for now. 10641 Foundation.IHearYou = Triggers.Initializers.addGlobalListeners; 10642 } 10643 }; 10644 10645 /***/ 10646 }), 10647 /***/"./foundation.core": ( 10648 /*!****************************************************************************************************************************************************************!*\ 10649 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 10650 \****************************************************************************************************************************************************************/ 10651 /***/ 10652 function (module) { 10653 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 10654 10655 /***/ 10656 }), 10657 /***/"./foundation.util.mediaQuery": ( 10658 /*!************************************************************************************************************************************************************************************************************!*\ 10659 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.mediaQuery"],"amd":"./foundation.util.mediaQuery","commonjs":"./foundation.util.mediaQuery","commonjs2":"./foundation.util.mediaQuery"} ***! 10660 \************************************************************************************************************************************************************************************************************/ 10661 /***/ 10662 function (module) { 10663 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__; 10664 10665 /***/ 10666 }), 10667 /***/"./foundation.util.motion": ( 10668 /*!********************************************************************************************************************************************************************************************!*\ 10669 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.motion"],"amd":"./foundation.util.motion","commonjs":"./foundation.util.motion","commonjs2":"./foundation.util.motion"} ***! 10670 \********************************************************************************************************************************************************************************************/ 10671 /***/ 10672 function (module) { 10673 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_motion__; 10674 10675 /***/ 10676 }), 10677 /***/"jquery": ( 10678 /*!********************************************************************************************!*\ 10679 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 10680 \********************************************************************************************/ 10681 /***/ 10682 function (module) { 10683 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 10684 10685 /***/ 10686 }) 10687 10688 /******/ 10689 }; 10690 /************************************************************************/ 10691 /******/ // The module cache 10692 /******/ 10693 var __webpack_module_cache__ = {}; 10694 /******/ 10695 /******/ // The require function 10696 /******/ 10697 function __webpack_require__(moduleId) { 10698 /******/ // Check if module is in cache 10699 /******/var cachedModule = __webpack_module_cache__[moduleId]; 10700 /******/ 10701 if (cachedModule !== undefined) { 10702 /******/return cachedModule.exports; 10703 /******/ 10704 } 10705 /******/ // Create a new module (and put it into the cache) 10706 /******/ 10707 var module = __webpack_module_cache__[moduleId] = { 10708 /******/ // no module.id needed 10709 /******/ // no module.loaded needed 10710 /******/exports: {} 10711 /******/ 10712 }; 10713 /******/ 10714 /******/ // Execute the module function 10715 /******/ 10716 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 10717 /******/ 10718 /******/ // Return the exports of the module 10719 /******/ 10720 return module.exports; 10721 /******/ 10722 } 10723 /******/ 10724 /************************************************************************/ 10725 /******/ /* webpack/runtime/compat get default export */ 10726 /******/ 10727 !function () { 10728 /******/ // getDefaultExport function for compatibility with non-harmony modules 10729 /******/__webpack_require__.n = function (module) {
vendor: 4,824 bytes, lines 10730-10836
10730 /******/var getter = module && module.__esModule ? /******/function () { 10731 return module['default']; 10732 } : /******/function () { 10733 return module; 10734 }; 10735 /******/ 10736 __webpack_require__.d(getter, { 10737 a: getter 10738 }); 10739 /******/ 10740 return getter; 10741 /******/ 10742 }; 10743 /******/ 10744 }(); 10745 /******/ 10746 /******/ /* webpack/runtime/define property getters */ 10747 /******/ 10748 !function () { 10749 /******/ // define getter functions for harmony exports 10750 /******/__webpack_require__.d = function (exports, definition) { 10751 /******/for (var key in definition) { 10752 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 10753 /******/Object.defineProperty(exports, key, { 10754 enumerable: true, 10755 get: definition[key] 10756 }); 10757 /******/ 10758 } 10759 /******/ 10760 } 10761 /******/ 10762 }; 10763 /******/ 10764 }(); 10765 /******/ 10766 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 10767 /******/ 10768 !function () { 10769 /******/__webpack_require__.o = function (obj, prop) { 10770 return Object.prototype.hasOwnProperty.call(obj, prop); 10771 }; 10772 /******/ 10773 }(); 10774 /******/ 10775 /******/ /* webpack/runtime/make namespace object */ 10776 /******/ 10777 !function () { 10778 /******/ // define __esModule on exports 10779 /******/__webpack_require__.r = function (exports) { 10780 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 10781 /******/Object.defineProperty(exports, Symbol.toStringTag, { 10782 value: 'Module' 10783 }); 10784 /******/ 10785 } 10786 /******/ 10787 Object.defineProperty(exports, '__esModule', { 10788 value: true 10789 }); 10790 /******/ 10791 }; 10792 /******/ 10793 }(); 10794 /******/ 10795 /************************************************************************/ 10796 var __webpack_exports__ = {}; 10797 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 10798 !function () { 10799 /*!*************************************************!*\ 10800 !*** ./js/entries/plugins/foundation.sticky.js ***! 10801 \*************************************************/ 10802 __webpack_require__.r(__webpack_exports__); 10803 /* harmony export */ 10804 __webpack_require__.d(__webpack_exports__, { 10805 /* harmony export */Foundation: function () { 10806 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 10807 }, 10808 /* harmony export */Sticky: function () { 10809 return /* reexport safe */_foundation_sticky__WEBPACK_IMPORTED_MODULE_1__.Sticky; 10810 } 10811 /* harmony export */ 10812 }); 10813 /* harmony import */ 10814 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 10815 /* harmony import */ 10816 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 10817 /* harmony import */ 10818 var _foundation_sticky__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.sticky */"./js/foundation.sticky.js"); 10819 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_sticky__WEBPACK_IMPORTED_MODULE_1__.Sticky, 'Sticky'); 10820 }(); 10821 /******/ 10822 return __webpack_exports__; 10823 /******/ 10824 }(); 10825}); 10826(function webpackUniversalModuleDefinition(root, factory) { 10827 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.imageLoader"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.keyboard", "./foundation.util.imageLoader"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.keyboard"), require("./foundation.util.imageLoader"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.tabs"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.keyboard"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.imageLoader"]); 10828})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__, __WEBPACK_EXTERNAL_MODULE__foundation_util_imageLoader__) { 10829 return /******/function () { 10830 // webpackBootstrap 10831 /******/ 10832 "use strict"; 10833 10834 /******/ 10835 var __webpack_modules__ = { 10836
vendor: 25,695 bytes, lines 10836-11420
10836/***/"./js/foundation.tabs.js": ( 10837 /*!*******************************!*\ 10838 !*** ./js/foundation.tabs.js ***! 10839 \*******************************/ 10840 /***/ 10841 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 10842 __webpack_require__.r(__webpack_exports__); 10843 /* harmony export */ 10844 __webpack_require__.d(__webpack_exports__, { 10845 /* harmony export */Tabs: function () { 10846 return /* binding */Tabs; 10847 } 10848 /* harmony export */ 10849 }); 10850 /* harmony import */ 10851 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 10852 /* harmony import */ 10853 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 10854 /* harmony import */ 10855 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.core.utils */"./foundation.core"); 10856 /* harmony import */ 10857 var _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__); 10858 /* harmony import */ 10859 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.util.keyboard */"./foundation.util.keyboard"); 10860 /* harmony import */ 10861 var _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__); 10862 /* harmony import */ 10863 var _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.util.imageLoader */"./foundation.util.imageLoader"); 10864 /* harmony import */ 10865 var _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_3__); 10866 function _typeof(o) { 10867 "@babel/helpers - typeof"; 10868 10869 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 10870 return typeof o; 10871 } : function (o) { 10872 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 10873 }, _typeof(o); 10874 } 10875 function _classCallCheck(a, n) { 10876 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 10877 } 10878 function _defineProperties(e, r) { 10879 for (var t = 0; t < r.length; t++) { 10880 var o = r[t]; 10881 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 10882 } 10883 } 10884 function _createClass(e, r, t) { 10885 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 10886 writable: !1 10887 }), e; 10888 } 10889 function _toPropertyKey(t) { 10890 var i = _toPrimitive(t, "string"); 10891 return "symbol" == _typeof(i) ? i : i + ""; 10892 } 10893 function _toPrimitive(t, r) { 10894 if ("object" != _typeof(t) || !t) return t; 10895 var e = t[Symbol.toPrimitive]; 10896 if (void 0 !== e) { 10897 var i = e.call(t, r || "default"); 10898 if ("object" != _typeof(i)) return i; 10899 throw new TypeError("@@toPrimitive must return a primitive value."); 10900 } 10901 return ("string" === r ? String : Number)(t); 10902 } 10903 function _callSuper(t, o, e) { 10904 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 10905 } 10906 function _possibleConstructorReturn(t, e) { 10907 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 10908 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 10909 return _assertThisInitialized(t); 10910 } 10911 function _assertThisInitialized(e) { 10912 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 10913 return e; 10914 } 10915 function _isNativeReflectConstruct() { 10916 try { 10917 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 10918 } catch (t) {} 10919 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 10920 return !!t; 10921 })(); 10922 } 10923 function _getPrototypeOf(t) { 10924 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 10925 return t.__proto__ || Object.getPrototypeOf(t); 10926 }, _getPrototypeOf(t); 10927 } 10928 function _inherits(t, e) { 10929 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 10930 t.prototype = Object.create(e && e.prototype, { 10931 constructor: { 10932 value: t, 10933 writable: !0, 10934 configurable: !0 10935 } 10936 }), Object.defineProperty(t, "prototype", { 10937 writable: !1 10938 }), e && _setPrototypeOf(t, e); 10939 } 10940 function _setPrototypeOf(t, e) { 10941 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 10942 return t.__proto__ = e, t; 10943 }, _setPrototypeOf(t, e); 10944 } 10945 10946 /** 10947 * Tabs module. 10948 * @module foundation.tabs 10949 * @requires foundation.util.keyboard 10950 * @requires foundation.util.imageLoader if tabs contain images 10951 */ 10952 var Tabs = /*#__PURE__*/function (_Plugin) { 10953 function Tabs() { 10954 _classCallCheck(this, Tabs); 10955 return _callSuper(this, Tabs, arguments); 10956 } 10957 _inherits(Tabs, _Plugin); 10958 return _createClass(Tabs, [{ 10959 key: "_setup", 10960 value: 10961 /** 10962 * Creates a new instance of tabs. 10963 * @class 10964 * @name Tabs 10965 * @fires Tabs#init 10966 * @param {jQuery} element - jQuery object to make into tabs. 10967 * @param {Object} options - Overrides to the default plugin settings. 10968 */ 10969 function _setup(element, options) { 10970 this.$element = element; 10971 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, Tabs.defaults, this.$element.data(), options); 10972 this.className = 'Tabs'; // ie9 back compat 10973 10974 this._init(); 10975 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.register('Tabs', { 10976 'ENTER': 'open', 10977 'SPACE': 'open', 10978 'ARROW_RIGHT': 'next', 10979 'ARROW_UP': 'previous', 10980 'ARROW_DOWN': 'next', 10981 'ARROW_LEFT': 'previous' 10982 // 'TAB': 'next', 10983 // 'SHIFT_TAB': 'previous' 10984 }); 10985 } 10986 10987 /** 10988 * Initializes the tabs by showing and focusing (if autoFocus=true) the preset active tab. 10989 * @private 10990 */ 10991 }, { 10992 key: "_init", 10993 value: function _init() { 10994 var _this2 = this; 10995 var _this = this; 10996 this._isInitializing = true; 10997 this.$element.attr({ 10998 'role': 'tablist' 10999 }); 11000 this.$tabTitles = this.$element.find(".".concat(this.options.linkClass)); 11001 this.$tabContent = jquery__WEBPACK_IMPORTED_MODULE_0___default()("[data-tabs-content=\"".concat(this.$element[0].id, "\"]")); 11002 this.$tabTitles.each(function () { 11003 var $elem = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 11004 $link = $elem.find('a'), 11005 isActive = $elem.hasClass("".concat(_this.options.linkActiveClass)), 11006 hash = $link.attr('data-tabs-target') || $link[0].hash.slice(1), 11007 linkId = $link[0].id ? $link[0].id : "".concat(hash, "-label"), 11008 $tabContent = jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(hash)); 11009 $elem.attr({ 11010 'role': 'presentation' 11011 }); 11012 $link.attr({ 11013 'role': 'tab', 11014 'aria-controls': hash, 11015 'aria-selected': isActive, 11016 'id': linkId, 11017 'tabindex': isActive ? '0' : '-1' 11018 }); 11019 $tabContent.attr({ 11020 'role': 'tabpanel', 11021 'aria-labelledby': linkId 11022 }); 11023 11024 // Save up the initial hash to return to it later when going back in history 11025 if (isActive) { 11026 _this._initialAnchor = "#".concat(hash); 11027 } 11028 if (!isActive) { 11029 $tabContent.attr('aria-hidden', 'true'); 11030 } 11031 if (isActive && _this.options.autoFocus) { 11032 _this.onLoadListener = (0, _foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.onLoad)(jquery__WEBPACK_IMPORTED_MODULE_0___default()(window), function () { 11033 jquery__WEBPACK_IMPORTED_MODULE_0___default()('html, body').animate({ 11034 scrollTop: $elem.offset().top 11035 }, _this.options.deepLinkSmudgeDelay, function () { 11036 $link.focus(); 11037 }); 11038 }); 11039 } 11040 }); 11041 if (this.options.matchHeight) { 11042 var $images = this.$tabContent.find('img'); 11043 if ($images.length) { 11044 (0, _foundation_util_imageLoader__WEBPACK_IMPORTED_MODULE_3__.onImagesLoaded)($images, this._setHeight.bind(this)); 11045 } else { 11046 this._setHeight(); 11047 } 11048 } 11049 11050 // Current context-bound function to open tabs on page load or history hashchange 11051 this._checkDeepLink = function () { 11052 var anchor = window.location.hash; 11053 if (!anchor.length) { 11054 // If we are still initializing and there is no anchor, then there is nothing to do 11055 if (_this2._isInitializing) return; 11056 // Otherwise, move to the initial anchor 11057 if (_this2._initialAnchor) anchor = _this2._initialAnchor; 11058 } 11059 var anchorNoHash = anchor.indexOf('#') >= 0 ? anchor.slice(1) : anchor; 11060 var $anchor = anchorNoHash && jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat(anchorNoHash)); 11061 var $link = anchor && _this2.$element.find("[href$=\"".concat(anchor, "\"],[data-tabs-target=\"").concat(anchorNoHash, "\"]")).first(); 11062 // Whether the anchor element that has been found is part of this element 11063 var isOwnAnchor = !!($anchor.length && $link.length); 11064 if (isOwnAnchor) { 11065 // If there is an anchor for the hash, select it 11066 if ($anchor && $anchor.length && $link && $link.length) { 11067 _this2.selectTab($anchor, true); 11068 } 11069 // Otherwise, collapse everything 11070 else { 11071 _this2._collapse(); 11072 } 11073 11074 // Roll up a little to show the titles 11075 if (_this2.options.deepLinkSmudge) { 11076 var offset = _this2.$element.offset(); 11077 jquery__WEBPACK_IMPORTED_MODULE_0___default()('html, body').animate({ 11078 scrollTop: offset.top - _this2.options.deepLinkSmudgeOffset 11079 }, _this2.options.deepLinkSmudgeDelay); 11080 } 11081 11082 /** 11083 * Fires when the plugin has deeplinked at pageload 11084 * @event Tabs#deeplink 11085 */ 11086 _this2.$element.trigger('deeplink.zf.tabs', [$link, $anchor]); 11087 } 11088 }; 11089 11090 //use browser to open a tab, if it exists in this tabset 11091 if (this.options.deepLink) { 11092 this._checkDeepLink(); 11093 } 11094 this._events(); 11095 this._isInitializing = false; 11096 } 11097 11098 /** 11099 * Adds event handlers for items within the tabs. 11100 * @private 11101 */ 11102 }, { 11103 key: "_events", 11104 value: function _events() { 11105 this._addKeyHandler(); 11106 this._addClickHandler(); 11107 this._setHeightMqHandler = null; 11108 if (this.options.matchHeight) { 11109 this._setHeightMqHandler = this._setHeight.bind(this); 11110 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('changed.zf.mediaquery', this._setHeightMqHandler); 11111 } 11112 if (this.options.deepLink) { 11113 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('hashchange', this._checkDeepLink); 11114 } 11115 } 11116 11117 /** 11118 * Adds click handlers for items within the tabs. 11119 * @private 11120 */ 11121 }, { 11122 key: "_addClickHandler", 11123 value: function _addClickHandler() { 11124 var _this = this; 11125 this.$element.off('click.zf.tabs').on('click.zf.tabs', ".".concat(this.options.linkClass), function (e) { 11126 e.preventDefault(); 11127 _this._handleTabChange(jquery__WEBPACK_IMPORTED_MODULE_0___default()(this)); 11128 }); 11129 } 11130 11131 /** 11132 * Adds keyboard event handlers for items within the tabs. 11133 * @private 11134 */ 11135 }, { 11136 key: "_addKeyHandler", 11137 value: function _addKeyHandler() { 11138 var _this = this; 11139 this.$tabTitles.off('keydown.zf.tabs').on('keydown.zf.tabs', function (e) { 11140 if (e.which === 9) return; 11141 var $element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 11142 $elements = $element.parent('ul').children('li'), 11143 $prevElement, 11144 $nextElement; 11145 $elements.each(function (i) { 11146 if (jquery__WEBPACK_IMPORTED_MODULE_0___default()(this).is($element)) { 11147 if (_this.options.wrapOnKeys) { 11148 $prevElement = i === 0 ? $elements.last() : $elements.eq(i - 1); 11149 $nextElement = i === $elements.length - 1 ? $elements.first() : $elements.eq(i + 1); 11150 } else { 11151 $prevElement = $elements.eq(Math.max(0, i - 1)); 11152 $nextElement = $elements.eq(Math.min(i + 1, $elements.length - 1)); 11153 } 11154 return; 11155 } 11156 }); 11157 11158 // handle keyboard event with keyboard util 11159 _foundation_util_keyboard__WEBPACK_IMPORTED_MODULE_2__.Keyboard.handleKey(e, 'Tabs', { 11160 open: function open() { 11161 $element.find('[role="tab"]').focus(); 11162 _this._handleTabChange($element); 11163 }, 11164 previous: function previous() { 11165 $prevElement.find('[role="tab"]').focus(); 11166 _this._handleTabChange($prevElement); 11167 }, 11168 next: function next() { 11169 $nextElement.find('[role="tab"]').focus(); 11170 _this._handleTabChange($nextElement); 11171 }, 11172 handled: function handled() { 11173 e.preventDefault(); 11174 } 11175 }); 11176 }); 11177 } 11178 11179 /** 11180 * Opens the tab `$targetContent` defined by `$target`. Collapses active tab. 11181 * @param {jQuery} $target - Tab to open. 11182 * @param {boolean} historyHandled - browser has already handled a history update 11183 * @fires Tabs#change 11184 * @function 11185 */ 11186 }, { 11187 key: "_handleTabChange", 11188 value: function _handleTabChange($target, historyHandled) { 11189 // With `activeCollapse`, if the target is the active Tab, collapse it. 11190 if ($target.hasClass("".concat(this.options.linkActiveClass))) { 11191 if (this.options.activeCollapse) { 11192 this._collapse(); 11193 } 11194 return; 11195 } 11196 var $oldTab = this.$element.find(".".concat(this.options.linkClass, ".").concat(this.options.linkActiveClass)), 11197 $tabLink = $target.find('[role="tab"]'), 11198 target = $tabLink.attr('data-tabs-target'), 11199 anchor = target && target.length ? "#".concat(target) : $tabLink[0].hash, 11200 $targetContent = this.$tabContent.find(anchor); 11201 11202 //close old tab 11203 this._collapseTab($oldTab); 11204 11205 //open new tab 11206 this._openTab($target); 11207 11208 //either replace or update browser history 11209 if (this.options.deepLink && !historyHandled) { 11210 if (this.options.updateHistory) { 11211 history.pushState({}, '', location.pathname + location.search + anchor); 11212 } else { 11213 history.replaceState({}, '', location.pathname + location.search + anchor); 11214 } 11215 } 11216 11217 /** 11218 * Fires when the plugin has successfully changed tabs. 11219 * @event Tabs#change 11220 */ 11221 this.$element.trigger('change.zf.tabs', [$target, $targetContent]); 11222 11223 //fire to children a mutation event 11224 $targetContent.find("[data-mutate]").trigger("mutateme.zf.trigger"); 11225 } 11226 11227 /** 11228 * Opens the tab `$targetContent` defined by `$target`. 11229 * @param {jQuery} $target - Tab to open. 11230 * @function 11231 */ 11232 }, { 11233 key: "_openTab", 11234 value: function _openTab($target) { 11235 var $tabLink = $target.find('[role="tab"]'), 11236 hash = $tabLink.attr('data-tabs-target') || $tabLink[0].hash.slice(1), 11237 $targetContent = this.$tabContent.find("#".concat(hash)); 11238 $target.addClass("".concat(this.options.linkActiveClass)); 11239 $tabLink.attr({ 11240 'aria-selected': 'true', 11241 'tabindex': '0' 11242 }); 11243 $targetContent.addClass("".concat(this.options.panelActiveClass)).removeAttr('aria-hidden'); 11244 } 11245 11246 /** 11247 * Collapses `$targetContent` defined by `$target`. 11248 * @param {jQuery} $target - Tab to collapse. 11249 * @function 11250 */ 11251 }, { 11252 key: "_collapseTab", 11253 value: function _collapseTab($target) { 11254 var $targetAnchor = $target.removeClass("".concat(this.options.linkActiveClass)).find('[role="tab"]').attr({ 11255 'aria-selected': 'false', 11256 'tabindex': -1 11257 }); 11258 jquery__WEBPACK_IMPORTED_MODULE_0___default()("#".concat($targetAnchor.attr('aria-controls'))).removeClass("".concat(this.options.panelActiveClass)).attr({ 11259 'aria-hidden': 'true' 11260 }); 11261 } 11262 11263 /** 11264 * Collapses the active Tab. 11265 * @fires Tabs#collapse 11266 * @function 11267 */ 11268 }, { 11269 key: "_collapse", 11270 value: function _collapse() { 11271 var $activeTab = this.$element.find(".".concat(this.options.linkClass, ".").concat(this.options.linkActiveClass)); 11272 if ($activeTab.length) { 11273 this._collapseTab($activeTab); 11274 11275 /** 11276 * Fires when the plugin has successfully collapsed tabs. 11277 * @event Tabs#collapse 11278 */ 11279 this.$element.trigger('collapse.zf.tabs', [$activeTab]); 11280 } 11281 } 11282 11283 /** 11284 * Public method for selecting a content pane to display. 11285 * @param {jQuery | String} elem - jQuery object or string of the id of the pane to display. 11286 * @param {boolean} historyHandled - browser has already handled a history update 11287 * @function 11288 */ 11289 }, { 11290 key: "selectTab", 11291 value: function selectTab(elem, historyHandled) { 11292 var idStr, hashIdStr; 11293 if (_typeof(elem) === 'object') { 11294 idStr = elem[0].id; 11295 } else { 11296 idStr = elem; 11297 } 11298 if (idStr.indexOf('#') < 0) { 11299 hashIdStr = "#".concat(idStr); 11300 } else { 11301 hashIdStr = idStr; 11302 idStr = idStr.slice(1); 11303 } 11304 var $target = this.$tabTitles.has("[href$=\"".concat(hashIdStr, "\"],[data-tabs-target=\"").concat(idStr, "\"]")).first(); 11305 this._handleTabChange($target, historyHandled); 11306 } 11307 }, { 11308 key: "_setHeight", 11309 value: 11310 /** 11311 * Sets the height of each panel to the height of the tallest panel. 11312 * If enabled in options, gets called on media query change. 11313 * If loading content via external source, can be called directly or with _reflow. 11314 * If enabled with `data-match-height="true"`, tabs sets to equal height 11315 * @function 11316 * @private 11317 */ 11318 function _setHeight() { 11319 var max = 0, 11320 _this = this; // Lock down the `this` value for the root tabs object 11321 11322 if (!this.$tabContent) { 11323 return; 11324 } 11325 this.$tabContent.find(".".concat(this.options.panelClass)).css('min-height', '').each(function () { 11326 var panel = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this), 11327 isActive = panel.hasClass("".concat(_this.options.panelActiveClass)); // get the options from the parent instead of trying to get them from the child 11328 11329 if (!isActive) { 11330 panel.css({ 11331 'visibility': 'hidden', 11332 'display': 'block' 11333 }); 11334 } 11335 var temp = this.getBoundingClientRect().height; 11336 if (!isActive) { 11337 panel.css({ 11338 'visibility': '', 11339 'display': '' 11340 }); 11341 } 11342 max = temp > max ? temp : max; 11343 }).css('min-height', "".concat(max, "px")); 11344 } 11345 11346 /** 11347 * Destroys an instance of tabs. 11348 * @fires Tabs#destroyed 11349 */ 11350 }, { 11351 key: "_destroy", 11352 value: function _destroy() { 11353 this.$element.find(".".concat(this.options.linkClass)).off('.zf.tabs').hide().end().find(".".concat(this.options.panelClass)).hide(); 11354 if (this.options.matchHeight) { 11355 if (this._setHeightMqHandler != null) { 11356 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off('changed.zf.mediaquery', this._setHeightMqHandler); 11357 } 11358 } 11359 if (this.options.deepLink) { 11360 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off('hashchange', this._checkDeepLink); 11361 } 11362 if (this.onLoadListener) { 11363 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off(this.onLoadListener); 11364 } 11365 } 11366 }]); 11367 }(_foundation_core_plugin__WEBPACK_IMPORTED_MODULE_1__.Plugin); 11368 Tabs.defaults = { 11369 /** 11370 * Link the location hash to the active pane. 11371 * Set the location hash when the active pane changes, and open the corresponding pane when the location changes. 11372 * @option 11373 * @type {boolean} 11374 * @default false 11375 */ 11376 deepLink: false, 11377 /** 11378 * If `deepLink` is enabled, adjust the deep link scroll to make sure the top of the tab panel is visible 11379 * @option 11380 * @type {boolean} 11381 * @default false 11382 */ 11383 deepLinkSmudge: false, 11384 /** 11385 * If `deepLinkSmudge` is enabled, animation time (ms) for the deep link adjustment 11386 * @option 11387 * @type {number} 11388 * @default 300 11389 */ 11390 deepLinkSmudgeDelay: 300, 11391 /** 11392 * If `deepLinkSmudge` is enabled, animation offset from the top for the deep link adjustment 11393 * @option 11394 * @type {number} 11395 * @default 0 11396 */ 11397 deepLinkSmudgeOffset: 0, 11398 /** 11399 * If `deepLink` is enabled, update the browser history with the open tab 11400 * @option 11401 * @type {boolean} 11402 * @default false 11403 */ 11404 updateHistory: false, 11405 /** 11406 * Allows the window to scroll to content of active pane on load. 11407 * Not recommended if more than one tab panel per page. 11408 * @option 11409 * @type {boolean} 11410 * @default false 11411 */ 11412 autoFocus: false, 11413 /** 11414 * Allows keyboard input to 'wrap' around the tab links. 11415 * @option 11416 * @type {boolean} 11417 * @default true 11418 */ 11419 wrapOnKeys: true, 11420 /**
11421 * Allows the tab content panes to match heights if set to true. 11422 * @option 11423 * @type {boolean} 11424 * @default false 11425 */ 11426 matchHeight: false, 11427 /** 11428 * Allows active tabs to collapse when clicked. 11429 * @option 11430 * @type {boolean} 11431 * @default false 11432 */ 11433 activeCollapse: false, 11434 /** 11435 * Class applied to `li`'s in tab link list. 11436 * @option 11437 * @type {string} 11438 * @default 'tabs-title' 11439 */ 11440 linkClass: 'tabs-title', 11441 /** 11442 * Class applied to the active `li` in tab link list. 11443 * @option 11444 * @type {string} 11445 * @default 'is-active' 11446 */ 11447 linkActiveClass: 'is-active', 11448 /** 11449 * Class applied to the content containers. 11450 * @option 11451 * @type {string} 11452 * @default 'tabs-panel' 11453 */ 11454 panelClass: 'tabs-panel', 11455 /** 11456 * Class applied to the active content container. 11457 * @option 11458 * @type {string} 11459 * @default 'is-active' 11460 */ 11461 panelActiveClass: 'is-active' 11462 }; 11463 11464 /***/ 11465 }), 11466 /***/"./foundation.core": ( 11467 /*!****************************************************************************************************************************************************************!*\ 11468 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 11469 \****************************************************************************************************************************************************************/ 11470 /***/ 11471 function (module) { 11472 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 11473 11474 /***/ 11475 }), 11476 /***/"./foundation.util.imageLoader": ( 11477 /*!****************************************************************************************************************************************************************************************************************!*\ 11478 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.imageLoader"],"amd":"./foundation.util.imageLoader","commonjs":"./foundation.util.imageLoader","commonjs2":"./foundation.util.imageLoader"} ***! 11479 \****************************************************************************************************************************************************************************************************************/ 11480 /***/ 11481 function (module) { 11482 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_imageLoader__; 11483 11484 /***/ 11485 }), 11486 /***/"./foundation.util.keyboard": ( 11487 /*!****************************************************************************************************************************************************************************************************!*\ 11488 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.keyboard"],"amd":"./foundation.util.keyboard","commonjs":"./foundation.util.keyboard","commonjs2":"./foundation.util.keyboard"} ***! 11489 \****************************************************************************************************************************************************************************************************/ 11490 /***/ 11491 function (module) { 11492 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_keyboard__; 11493 11494 /***/ 11495 }), 11496 /***/"jquery": ( 11497 /*!********************************************************************************************!*\ 11498 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 11499 \********************************************************************************************/ 11500 /***/ 11501 function (module) { 11502 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 11503 11504 /***/ 11505 }) 11506 11507 /******/ 11508 }; 11509 /************************************************************************/ 11510 /******/ // The module cache 11511 /******/ 11512 var __webpack_module_cache__ = {}; 11513 /******/ 11514 /******/ // The require function 11515 /******/ 11516 function __webpack_require__(moduleId) { 11517 /******/ // Check if module is in cache 11518 /******/var cachedModule = __webpack_module_cache__[moduleId]; 11519 /******/ 11520 if (cachedModule !== undefined) { 11521 /******/return cachedModule.exports; 11522 /******/ 11523 } 11524 /******/ // Create a new module (and put it into the cache) 11525 /******/ 11526 var module = __webpack_module_cache__[moduleId] = { 11527 /******/ // no module.id needed 11528 /******/ // no module.loaded needed 11529 /******/exports: {} 11530 /******/ 11531 }; 11532 /******/ 11533 /******/ // Execute the module function 11534 /******/ 11535 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 11536 /******/ 11537 /******/ // Return the exports of the module 11538 /******/ 11539 return module.exports; 11540 /******/ 11541 } 11542 /******/ 11543 /************************************************************************/ 11544 /******/ /* webpack/runtime/compat get default export */ 11545 /******/ 11546 !function () { 11547 /******/ // getDefaultExport function for compatibility with non-harmony modules 11548 /******/__webpack_require__.n = function (module) {
vendor: 4,973 bytes, lines 11549-11655
11549 /******/var getter = module && module.__esModule ? /******/function () { 11550 return module['default']; 11551 } : /******/function () { 11552 return module; 11553 }; 11554 /******/ 11555 __webpack_require__.d(getter, { 11556 a: getter 11557 }); 11558 /******/ 11559 return getter; 11560 /******/ 11561 }; 11562 /******/ 11563 }(); 11564 /******/ 11565 /******/ /* webpack/runtime/define property getters */ 11566 /******/ 11567 !function () { 11568 /******/ // define getter functions for harmony exports 11569 /******/__webpack_require__.d = function (exports, definition) { 11570 /******/for (var key in definition) { 11571 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 11572 /******/Object.defineProperty(exports, key, { 11573 enumerable: true, 11574 get: definition[key] 11575 }); 11576 /******/ 11577 } 11578 /******/ 11579 } 11580 /******/ 11581 }; 11582 /******/ 11583 }(); 11584 /******/ 11585 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 11586 /******/ 11587 !function () { 11588 /******/__webpack_require__.o = function (obj, prop) { 11589 return Object.prototype.hasOwnProperty.call(obj, prop); 11590 }; 11591 /******/ 11592 }(); 11593 /******/ 11594 /******/ /* webpack/runtime/make namespace object */ 11595 /******/ 11596 !function () { 11597 /******/ // define __esModule on exports 11598 /******/__webpack_require__.r = function (exports) { 11599 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 11600 /******/Object.defineProperty(exports, Symbol.toStringTag, { 11601 value: 'Module' 11602 }); 11603 /******/ 11604 } 11605 /******/ 11606 Object.defineProperty(exports, '__esModule', { 11607 value: true 11608 }); 11609 /******/ 11610 }; 11611 /******/ 11612 }(); 11613 /******/ 11614 /************************************************************************/ 11615 var __webpack_exports__ = {}; 11616 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 11617 !function () { 11618 /*!***********************************************!*\ 11619 !*** ./js/entries/plugins/foundation.tabs.js ***! 11620 \***********************************************/ 11621 __webpack_require__.r(__webpack_exports__); 11622 /* harmony export */ 11623 __webpack_require__.d(__webpack_exports__, { 11624 /* harmony export */Foundation: function () { 11625 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 11626 }, 11627 /* harmony export */Tabs: function () { 11628 return /* reexport safe */_foundation_tabs__WEBPACK_IMPORTED_MODULE_1__.Tabs; 11629 } 11630 /* harmony export */ 11631 }); 11632 /* harmony import */ 11633 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 11634 /* harmony import */ 11635 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 11636 /* harmony import */ 11637 var _foundation_tabs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.tabs */"./js/foundation.tabs.js"); 11638 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_tabs__WEBPACK_IMPORTED_MODULE_1__.Tabs, 'Tabs'); 11639 }(); 11640 /******/ 11641 return __webpack_exports__; 11642 /******/ 11643 }(); 11644}); 11645(function webpackUniversalModuleDefinition(root, factory) { 11646 if (typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.accordion"), require("./foundation.tabs"));else if (typeof define === 'function' && define.amd) define(["./foundation.core", "jquery", "./foundation.util.mediaQuery", "./foundation.accordion", "./foundation.tabs"], factory);else if (typeof exports === 'object') exports["__FOUNDATION_EXTERNAL__"] = factory(require("./foundation.core"), require("jquery"), require("./foundation.util.mediaQuery"), require("./foundation.accordion"), require("./foundation.tabs"));else root["__FOUNDATION_EXTERNAL__"] = root["__FOUNDATION_EXTERNAL__"] || {}, root["__FOUNDATION_EXTERNAL__"]["foundation.responsiveAccordionTabs"] = factory(root["__FOUNDATION_EXTERNAL__"]["foundation.core"], root["jQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.util.mediaQuery"], root["__FOUNDATION_EXTERNAL__"]["foundation.accordion"], root["__FOUNDATION_EXTERNAL__"]["foundation.tabs"]); 11647})(self, function (__WEBPACK_EXTERNAL_MODULE__foundation_core__, __WEBPACK_EXTERNAL_MODULE_jquery__, __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__, __WEBPACK_EXTERNAL_MODULE__foundation_accordion__, __WEBPACK_EXTERNAL_MODULE__foundation_tabs__) { 11648 return /******/function () { 11649 // webpackBootstrap 11650 /******/ 11651 "use strict"; 11652 11653 /******/ 11654 var __webpack_modules__ = { 11655
vendor: 20,433 bytes, lines 11655-12058
11655/***/"./js/foundation.responsiveAccordionTabs.js": ( 11656 /*!**************************************************!*\ 11657 !*** ./js/foundation.responsiveAccordionTabs.js ***! 11658 \**************************************************/ 11659 /***/ 11660 function (__unused_webpack_module, __webpack_exports__, __webpack_require__) { 11661 __webpack_require__.r(__webpack_exports__); 11662 /* harmony export */ 11663 __webpack_require__.d(__webpack_exports__, { 11664 /* harmony export */ResponsiveAccordionTabs: function () { 11665 return /* binding */ResponsiveAccordionTabs; 11666 } 11667 /* harmony export */ 11668 }); 11669 /* harmony import */ 11670 var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! jquery */"jquery"); 11671 /* harmony import */ 11672 var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__); 11673 /* harmony import */ 11674 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation.util.mediaQuery */"./foundation.util.mediaQuery"); 11675 /* harmony import */ 11676 var _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__); 11677 /* harmony import */ 11678 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation.core.plugin */"./foundation.core"); 11679 /* harmony import */ 11680 var _foundation_core_utils__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_2__); 11681 /* harmony import */ 11682 var _foundation_accordion__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation.accordion */"./foundation.accordion"); 11683 /* harmony import */ 11684 var _foundation_accordion__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_foundation_accordion__WEBPACK_IMPORTED_MODULE_3__); 11685 /* harmony import */ 11686 var _foundation_tabs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./foundation.tabs */"./foundation.tabs"); 11687 /* harmony import */ 11688 var _foundation_tabs__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_foundation_tabs__WEBPACK_IMPORTED_MODULE_4__); 11689 function _typeof(o) { 11690 "@babel/helpers - typeof"; 11691 11692 return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { 11693 return typeof o; 11694 } : function (o) { 11695 return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; 11696 }, _typeof(o); 11697 } 11698 function _classCallCheck(a, n) { 11699 if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); 11700 } 11701 function _defineProperties(e, r) { 11702 for (var t = 0; t < r.length; t++) { 11703 var o = r[t]; 11704 o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); 11705 } 11706 } 11707 function _createClass(e, r, t) { 11708 return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { 11709 writable: !1 11710 }), e; 11711 } 11712 function _toPropertyKey(t) { 11713 var i = _toPrimitive(t, "string"); 11714 return "symbol" == _typeof(i) ? i : i + ""; 11715 } 11716 function _toPrimitive(t, r) { 11717 if ("object" != _typeof(t) || !t) return t; 11718 var e = t[Symbol.toPrimitive]; 11719 if (void 0 !== e) { 11720 var i = e.call(t, r || "default"); 11721 if ("object" != _typeof(i)) return i; 11722 throw new TypeError("@@toPrimitive must return a primitive value."); 11723 } 11724 return ("string" === r ? String : Number)(t); 11725 } 11726 function _callSuper(t, o, e) { 11727 return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); 11728 } 11729 function _possibleConstructorReturn(t, e) { 11730 if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; 11731 if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); 11732 return _assertThisInitialized(t); 11733 } 11734 function _assertThisInitialized(e) { 11735 if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 11736 return e; 11737 } 11738 function _isNativeReflectConstruct() { 11739 try { 11740 var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); 11741 } catch (t) {} 11742 return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { 11743 return !!t; 11744 })(); 11745 } 11746 function _getPrototypeOf(t) { 11747 return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { 11748 return t.__proto__ || Object.getPrototypeOf(t); 11749 }, _getPrototypeOf(t); 11750 } 11751 function _inherits(t, e) { 11752 if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); 11753 t.prototype = Object.create(e && e.prototype, { 11754 constructor: { 11755 value: t, 11756 writable: !0, 11757 configurable: !0 11758 } 11759 }), Object.defineProperty(t, "prototype", { 11760 writable: !1 11761 }), e && _setPrototypeOf(t, e); 11762 } 11763 function _setPrototypeOf(t, e) { 11764 return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { 11765 return t.__proto__ = e, t; 11766 }, _setPrototypeOf(t, e); 11767 } 11768 11769 // The plugin matches the plugin classes with these plugin instances. 11770 var MenuPlugins = { 11771 tabs: { 11772 cssClass: 'tabs', 11773 plugin: _foundation_tabs__WEBPACK_IMPORTED_MODULE_4__.Tabs, 11774 open: function open(plugin, target) { 11775 return plugin.selectTab(target); 11776 }, 11777 close: null /* not supported */, 11778 toggle: null /* not supported */ 11779 }, 11780 accordion: { 11781 cssClass: 'accordion', 11782 plugin: _foundation_accordion__WEBPACK_IMPORTED_MODULE_3__.Accordion, 11783 open: function open(plugin, target) { 11784 return plugin.down(jquery__WEBPACK_IMPORTED_MODULE_0___default()(target)); 11785 }, 11786 close: function close(plugin, target) { 11787 return plugin.up(jquery__WEBPACK_IMPORTED_MODULE_0___default()(target)); 11788 }, 11789 toggle: function toggle(plugin, target) { 11790 return plugin.toggle(jquery__WEBPACK_IMPORTED_MODULE_0___default()(target)); 11791 } 11792 } 11793 }; 11794 11795 /** 11796 * ResponsiveAccordionTabs module. 11797 * @module foundation.responsiveAccordionTabs 11798 * @requires foundation.util.motion 11799 * @requires foundation.accordion 11800 * @requires foundation.tabs 11801 */ 11802 var ResponsiveAccordionTabs = /*#__PURE__*/function (_Plugin) { 11803 function ResponsiveAccordionTabs(element, options) { 11804 var _this2; 11805 _classCallCheck(this, ResponsiveAccordionTabs); 11806 _this2 = _callSuper(this, ResponsiveAccordionTabs, [element, options]); 11807 return _possibleConstructorReturn(_this2, _this2.options.reflow && _this2.storezfData || _this2); 11808 } 11809 11810 /** 11811 * Creates a new instance of a responsive accordion tabs. 11812 * @class 11813 * @name ResponsiveAccordionTabs 11814 * @fires ResponsiveAccordionTabs#init 11815 * @param {jQuery} element - jQuery object to make into Responsive Accordion Tabs. 11816 * @param {Object} options - Overrides to the default plugin settings. 11817 */ 11818 _inherits(ResponsiveAccordionTabs, _Plugin); 11819 return _createClass(ResponsiveAccordionTabs, [{ 11820 key: "_setup", 11821 value: function _setup(element, options) { 11822 this.$element = jquery__WEBPACK_IMPORTED_MODULE_0___default()(element); 11823 this.$element.data('zfPluginBase', this); 11824 this.options = jquery__WEBPACK_IMPORTED_MODULE_0___default().extend({}, ResponsiveAccordionTabs.defaults, this.$element.data(), options); 11825 this.rules = this.$element.data('responsive-accordion-tabs'); 11826 this.currentMq = null; 11827 this.currentRule = null; 11828 this.currentPlugin = null; 11829 this.className = 'ResponsiveAccordionTabs'; // ie9 back compat 11830 if (!this.$element.attr('id')) { 11831 this.$element.attr('id', (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_2__.GetYoDigits)(6, 'responsiveaccordiontabs')); 11832 } 11833 this._init(); 11834 this._events(); 11835 } 11836 11837 /** 11838 * Initializes the Menu by parsing the classes from the 'data-responsive-accordion-tabs' attribute on the element. 11839 * @function 11840 * @private 11841 */ 11842 }, { 11843 key: "_init", 11844 value: function _init() { 11845 _foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery._init(); 11846 11847 // The first time an Interchange plugin is initialized, this.rules is converted from a string of "classes" to an object of rules 11848 if (typeof this.rules === 'string') { 11849 var rulesTree = {}; 11850 11851 // Parse rules from "classes" pulled from data attribute 11852 var rules = this.rules.split(' '); 11853 11854 // Iterate through every rule found 11855 for (var i = 0; i < rules.length; i++) { 11856 var rule = rules[i].split('-'); 11857 var ruleSize = rule.length > 1 ? rule[0] : 'small'; 11858 var rulePlugin = rule.length > 1 ? rule[1] : rule[0]; 11859 if (MenuPlugins[rulePlugin] !== null) { 11860 rulesTree[ruleSize] = MenuPlugins[rulePlugin]; 11861 } 11862 } 11863 this.rules = rulesTree; 11864 } 11865 this._getAllOptions(); 11866 if (!jquery__WEBPACK_IMPORTED_MODULE_0___default().isEmptyObject(this.rules)) { 11867 this._checkMediaQueries(); 11868 } 11869 } 11870 }, { 11871 key: "_getAllOptions", 11872 value: function _getAllOptions() { 11873 //get all defaults and options 11874 var _this = this; 11875 _this.allOptions = {}; 11876 for (var key in MenuPlugins) { 11877 if (MenuPlugins.hasOwnProperty(key)) { 11878 var obj = MenuPlugins[key]; 11879 try { 11880 var dummyPlugin = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<ul></ul>'); 11881 var tmpPlugin = new obj.plugin(dummyPlugin, _this.options); 11882 for (var keyKey in tmpPlugin.options) { 11883 if (tmpPlugin.options.hasOwnProperty(keyKey) && keyKey !== 'zfPlugin') { 11884 var objObj = tmpPlugin.options[keyKey]; 11885 _this.allOptions[keyKey] = objObj; 11886 } 11887 } 11888 tmpPlugin.destroy(); 11889 } catch (e) { 11890 console.warn("Warning: Problems getting Accordion/Tab options: ".concat(e)); 11891 } 11892 } 11893 } 11894 } 11895 11896 /** 11897 * Initializes events for the Menu. 11898 * @function 11899 * @private 11900 */ 11901 }, { 11902 key: "_events", 11903 value: function _events() { 11904 this._changedZfMediaQueryHandler = this._checkMediaQueries.bind(this); 11905 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).on('changed.zf.mediaquery', this._changedZfMediaQueryHandler); 11906 } 11907 11908 /** 11909 * 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. 11910 * @function 11911 * @private 11912 */ 11913 }, { 11914 key: "_checkMediaQueries", 11915 value: function _checkMediaQueries() { 11916 var matchedMq, 11917 _this = this; 11918 // Iterate through each rule and find the last matching rule 11919 jquery__WEBPACK_IMPORTED_MODULE_0___default().each(this.rules, function (key) { 11920 if (_foundation_util_mediaQuery__WEBPACK_IMPORTED_MODULE_1__.MediaQuery.atLeast(key)) { 11921 matchedMq = key; 11922 } 11923 }); 11924 11925 // No match? No dice 11926 if (!matchedMq) return; 11927 11928 // Plugin already initialized? We good 11929 if (this.currentPlugin instanceof this.rules[matchedMq].plugin) return; 11930 11931 // Remove existing plugin-specific CSS classes 11932 jquery__WEBPACK_IMPORTED_MODULE_0___default().each(MenuPlugins, function (key, value) { 11933 _this.$element.removeClass(value.cssClass); 11934 }); 11935 11936 // Add the CSS class for the new plugin 11937 this.$element.addClass(this.rules[matchedMq].cssClass); 11938 11939 // Create an instance of the new plugin 11940 if (this.currentPlugin) { 11941 //don't know why but on nested elements data zfPlugin get's lost 11942 if (!this.currentPlugin.$element.data('zfPlugin') && this.storezfData) this.currentPlugin.$element.data('zfPlugin', this.storezfData); 11943 this.currentPlugin.destroy(); 11944 } 11945 this._handleMarkup(this.rules[matchedMq].cssClass); 11946 this.currentRule = this.rules[matchedMq]; 11947 this.currentPlugin = new this.currentRule.plugin(this.$element, this.options); 11948 this.storezfData = this.currentPlugin.$element.data('zfPlugin'); 11949 } 11950 }, { 11951 key: "_handleMarkup", 11952 value: function _handleMarkup(toSet) { 11953 var _this = this, 11954 fromString = 'accordion'; 11955 var $panels = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-tabs-content=' + this.$element.attr('id') + ']'); 11956 if ($panels.length) fromString = 'tabs'; 11957 if (fromString === toSet) { 11958 return; 11959 } 11960 var tabsTitle = _this.allOptions.linkClass ? _this.allOptions.linkClass : 'tabs-title'; 11961 var tabsPanel = _this.allOptions.panelClass ? _this.allOptions.panelClass : 'tabs-panel'; 11962 this.$element.removeAttr('role'); 11963 var $liHeads = this.$element.children('.' + tabsTitle + ',[data-accordion-item]').removeClass(tabsTitle).removeClass('accordion-item').removeAttr('data-accordion-item'); 11964 var $liHeadsA = $liHeads.children('a').removeClass('accordion-title'); 11965 if (fromString === 'tabs') { 11966 $panels = $panels.children('.' + tabsPanel).removeClass(tabsPanel).removeAttr('role').removeAttr('aria-hidden').removeAttr('aria-labelledby'); 11967 $panels.children('a').removeAttr('role').removeAttr('aria-controls').removeAttr('aria-selected'); 11968 } else { 11969 $panels = $liHeads.children('[data-tab-content]').removeClass('accordion-content'); 11970 } 11971 $panels.css({ 11972 display: '', 11973 visibility: '' 11974 }); 11975 $liHeads.css({ 11976 display: '', 11977 visibility: '' 11978 }); 11979 if (toSet === 'accordion') { 11980 $panels.each(function (key, value) { 11981 jquery__WEBPACK_IMPORTED_MODULE_0___default()(value).appendTo($liHeads.get(key)).addClass('accordion-content').attr('data-tab-content', '').removeClass('is-active').css({ 11982 height: '' 11983 }); 11984 jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-tabs-content=' + _this.$element.attr('id') + ']').after('<div id="tabs-placeholder-' + _this.$element.attr('id') + '"></div>').detach(); 11985 $liHeads.addClass('accordion-item').attr('data-accordion-item', ''); 11986 $liHeadsA.addClass('accordion-title'); 11987 }); 11988 } else if (toSet === 'tabs') { 11989 var $tabsContent = jquery__WEBPACK_IMPORTED_MODULE_0___default()('[data-tabs-content=' + _this.$element.attr('id') + ']'); 11990 var $placeholder = jquery__WEBPACK_IMPORTED_MODULE_0___default()('#tabs-placeholder-' + _this.$element.attr('id')); 11991 if ($placeholder.length) { 11992 $tabsContent = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class="tabs-content"></div>').insertAfter($placeholder).attr('data-tabs-content', _this.$element.attr('id')); 11993 $placeholder.remove(); 11994 } else { 11995 $tabsContent = jquery__WEBPACK_IMPORTED_MODULE_0___default()('<div class="tabs-content"></div>').insertAfter(_this.$element).attr('data-tabs-content', _this.$element.attr('id')); 11996 } 11997 $panels.each(function (key, value) { 11998 var tempValue = jquery__WEBPACK_IMPORTED_MODULE_0___default()(value).appendTo($tabsContent).addClass(tabsPanel); 11999 var hash = $liHeadsA.get(key).hash.slice(1); 12000 var id = jquery__WEBPACK_IMPORTED_MODULE_0___default()(value).attr('id') || (0, _foundation_core_utils__WEBPACK_IMPORTED_MODULE_2__.GetYoDigits)(6, 'accordion'); 12001 if (hash !== id) { 12002 if (hash !== '') { 12003 jquery__WEBPACK_IMPORTED_MODULE_0___default()(value).attr('id', hash); 12004 } else { 12005 hash = id; 12006 jquery__WEBPACK_IMPORTED_MODULE_0___default()(value).attr('id', hash); 12007 jquery__WEBPACK_IMPORTED_MODULE_0___default()($liHeadsA.get(key)).attr('href', jquery__WEBPACK_IMPORTED_MODULE_0___default()($liHeadsA.get(key)).attr('href').replace('#', '') + '#' + hash); 12008 } 12009 } 12010 var isActive = jquery__WEBPACK_IMPORTED_MODULE_0___default()($liHeads.get(key)).hasClass('is-active'); 12011 if (isActive) { 12012 tempValue.addClass('is-active'); 12013 } 12014 }); 12015 $liHeads.addClass(tabsTitle); 12016 } 12017 ; 12018 } 12019 12020 /** 12021 * Opens the plugin pane defined by `target`. 12022 * @param {jQuery | String} target - jQuery object or string of the id of the pane to open. 12023 * @see Accordion.down 12024 * @see Tabs.selectTab 12025 * @function 12026 */ 12027 }, { 12028 key: "open", 12029 value: function open() { 12030 if (this.currentRule && typeof this.currentRule.open === 'function') { 12031 var _this$currentRule; 12032 return (_this$currentRule = this.currentRule).open.apply(_this$currentRule, [this.currentPlugin].concat(Array.prototype.slice.call(arguments))); 12033 } 12034 } 12035 12036 /** 12037 * Closes the plugin pane defined by `target`. Not availaible for Tabs. 12038 * @param {jQuery | String} target - jQuery object or string of the id of the pane to close. 12039 * @see Accordion.up 12040 * @function 12041 */ 12042 }, { 12043 key: "close", 12044 value: function close() { 12045 if (this.currentRule && typeof this.currentRule.close === 'function') { 12046 var _this$currentRule2; 12047 return (_this$currentRule2 = this.currentRule).close.apply(_this$currentRule2, [this.currentPlugin].concat(Array.prototype.slice.call(arguments))); 12048 } 12049 } 12050 12051 /** 12052 * Toggles the plugin pane defined by `target`. Not availaible for Tabs. 12053 * @param {jQuery | String} target - jQuery object or string of the id of the pane to toggle. 12054 * @see Accordion.toggle 12055 * @function 12056 */ 12057 }, { 12058 key: "toggle",
12059 value: function toggle() { 12060 if (this.currentRule && typeof this.currentRule.toggle === 'function') { 12061 var _this$currentRule3; 12062 return (_this$currentRule3 = this.currentRule).toggle.apply(_this$currentRule3, [this.currentPlugin].concat(Array.prototype.slice.call(arguments))); 12063 } 12064 } 12065 12066 /** 12067 * Destroys the instance of the current plugin on this element, as well as the window resize handler that switches the plugins out. 12068 * @function 12069 */ 12070 }, { 12071 key: "_destroy", 12072 value: function _destroy() { 12073 if (this.currentPlugin) this.currentPlugin.destroy(); 12074 jquery__WEBPACK_IMPORTED_MODULE_0___default()(window).off('changed.zf.mediaquery', this._changedZfMediaQueryHandler); 12075 } 12076 }]); 12077 }(_foundation_core_utils__WEBPACK_IMPORTED_MODULE_2__.Plugin); 12078 ResponsiveAccordionTabs.defaults = {}; 12079 12080 /***/ 12081 })
12081, 12082 /***/"./foundation.accordion": ( 12083 /*!************************************************************************************************************************************************************************************!*\ 12084 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.accordion"],"amd":"./foundation.accordion","commonjs":"./foundation.accordion","commonjs2":"./foundation.accordion"} ***! 12085 \************************************************************************************************************************************************************************************/ 12086 /***/ 12087 function (module) { 12088 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_accordion__; 12089 12090 /***/ 12091 }), 12092 /***/"./foundation.core": ( 12093 /*!****************************************************************************************************************************************************************!*\ 12094 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.core"],"amd":"./foundation.core","commonjs":"./foundation.core","commonjs2":"./foundation.core"} ***! 12095 \****************************************************************************************************************************************************************/ 12096 /***/ 12097 function (module) { 12098 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_core__; 12099 12100 /***/ 12101 }), 12102 /***/"./foundation.tabs": ( 12103 /*!****************************************************************************************************************************************************************!*\ 12104 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.tabs"],"amd":"./foundation.tabs","commonjs":"./foundation.tabs","commonjs2":"./foundation.tabs"} ***! 12105 \****************************************************************************************************************************************************************/ 12106 /***/ 12107 function (module) { 12108 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_tabs__; 12109 12110 /***/ 12111 }), 12112 /***/"./foundation.util.mediaQuery": ( 12113 /*!************************************************************************************************************************************************************************************************************!*\ 12114 !*** external {"root":["__FOUNDATION_EXTERNAL__","foundation.util.mediaQuery"],"amd":"./foundation.util.mediaQuery","commonjs":"./foundation.util.mediaQuery","commonjs2":"./foundation.util.mediaQuery"} ***! 12115 \************************************************************************************************************************************************************************************************************/ 12116 /***/ 12117 function (module) { 12118 module.exports = __WEBPACK_EXTERNAL_MODULE__foundation_util_mediaQuery__; 12119 12120 /***/ 12121 }), 12122 /***/"jquery": ( 12123 /*!********************************************************************************************!*\ 12124 !*** external {"root":["jQuery"],"amd":"jquery","commonjs":"jquery","commonjs2":"jquery"} ***! 12125 \********************************************************************************************/ 12126 /***/ 12127 function (module) { 12128 module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__; 12129 12130 /***/ 12131 }) 12132 12133 /******/ 12134 }; 12135 /************************************************************************/ 12136 /******/ // The module cache 12137 /******/ 12138 var __webpack_module_cache__ = {}; 12139 /******/ 12140 /******/ // The require function 12141 /******/ 12142 function __webpack_require__(moduleId) { 12143 /******/ // Check if module is in cache 12144 /******/var cachedModule = __webpack_module_cache__[moduleId]; 12145 /******/ 12146 if (cachedModule !== undefined) { 12147 /******/return cachedModule.exports; 12148 /******/ 12149 } 12150 /******/ // Create a new module (and put it into the cache) 12151 /******/ 12152 var module = __webpack_module_cache__[moduleId] = { 12153 /******/ // no module.id needed 12154 /******/ // no module.loaded needed 12155 /******/exports: {} 12156 /******/ 12157 }; 12158 /******/ 12159 /******/ // Execute the module function 12160 /******/ 12161 __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 12162 /******/ 12163 /******/ // Return the exports of the module 12164 /******/ 12165 return module.exports; 12166 /******/ 12167 } 12168 /******/ 12169 /************************************************************************/ 12170 /******/ /* webpack/runtime/compat get default export */ 12171 /******/ 12172 !function () { 12173 /******/ // getDefaultExport function for compatibility with non-harmony modules 12174 /******/__webpack_require__.n = function (module) {
vendor: 3,727 bytes, lines 12175-12271
12175 /******/var getter = module && module.__esModule ? /******/function () { 12176 return module['default']; 12177 } : /******/function () { 12178 return module; 12179 }; 12180 /******/ 12181 __webpack_require__.d(getter, { 12182 a: getter 12183 }); 12184 /******/ 12185 return getter; 12186 /******/ 12187 }; 12188 /******/ 12189 }(); 12190 /******/ 12191 /******/ /* webpack/runtime/define property getters */ 12192 /******/ 12193 !function () { 12194 /******/ // define getter functions for harmony exports 12195 /******/__webpack_require__.d = function (exports, definition) { 12196 /******/for (var key in definition) { 12197 /******/if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { 12198 /******/Object.defineProperty(exports, key, { 12199 enumerable: true, 12200 get: definition[key] 12201 }); 12202 /******/ 12203 } 12204 /******/ 12205 } 12206 /******/ 12207 }; 12208 /******/ 12209 }(); 12210 /******/ 12211 /******/ /* webpack/runtime/hasOwnProperty shorthand */ 12212 /******/ 12213 !function () { 12214 /******/__webpack_require__.o = function (obj, prop) { 12215 return Object.prototype.hasOwnProperty.call(obj, prop); 12216 }; 12217 /******/ 12218 }(); 12219 /******/ 12220 /******/ /* webpack/runtime/make namespace object */ 12221 /******/ 12222 !function () { 12223 /******/ // define __esModule on exports 12224 /******/__webpack_require__.r = function (exports) { 12225 /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { 12226 /******/Object.defineProperty(exports, Symbol.toStringTag, { 12227 value: 'Module' 12228 }); 12229 /******/ 12230 } 12231 /******/ 12232 Object.defineProperty(exports, '__esModule', { 12233 value: true 12234 }); 12235 /******/ 12236 }; 12237 /******/ 12238 }(); 12239 /******/ 12240 /************************************************************************/ 12241 var __webpack_exports__ = {}; 12242 // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. 12243 !function () { 12244 /*!******************************************************************!*\ 12245 !*** ./js/entries/plugins/foundation.responsiveAccordionTabs.js ***! 12246 \******************************************************************/ 12247 __webpack_require__.r(__webpack_exports__); 12248 /* harmony export */ 12249 __webpack_require__.d(__webpack_exports__, { 12250 /* harmony export */Foundation: function () { 12251 return /* reexport safe */_foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation; 12252 }, 12253 /* harmony export */ResponsiveAccordionTabs: function () { 12254 return /* reexport safe */_foundation_responsiveAccordionTabs__WEBPACK_IMPORTED_MODULE_1__.ResponsiveAccordionTabs; 12255 } 12256 /* harmony export */ 12257 }); 12258 /* harmony import */ 12259 var _foundation_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./foundation.core */"./foundation.core"); 12260 /* harmony import */ 12261 var _foundation_core__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_foundation_core__WEBPACK_IMPORTED_MODULE_0__); 12262 /* harmony import */ 12263 var _foundation_responsiveAccordionTabs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../foundation.responsiveAccordionTabs */"./js/foundation.responsiveAccordionTabs.js"); 12264 _foundation_core__WEBPACK_IMPORTED_MODULE_0__.Foundation.plugin(_foundation_responsiveAccordionTabs__WEBPACK_IMPORTED_MODULE_1__.ResponsiveAccordionTabs, 'ResponsiveAccordionTabs'); 12265 }(); 12266 /******/ 12267 return __webpack_exports__; 12268 /******/ 12269 }(); 12270}); 12271//# sourceMappingURL=maps/foundation.js.map
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.