-
Notifications
You must be signed in to change notification settings - Fork 5.5k
/
foundation.core.min.js
2 lines (2 loc) · 13.8 KB
/
foundation.core.min.js
1
2
!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],n):"object"==typeof exports?exports["foundation.core"]=n(require("jquery")):(t.__FOUNDATION_EXTERNAL__=t.__FOUNDATION_EXTERNAL__||{},t.__FOUNDATION_EXTERNAL__["foundation.core"]=n(t.jQuery))}(window,function(e){return r={"./js/entries/plugins/foundation.core.js":function(t,n,e){"use strict";e.r(n);var r=e("jquery"),r=e.n(r),i=e("./js/foundation.core.js");e.d(n,"Foundation",function(){return i.Foundation});var o=e("./js/foundation.core.plugin.js"),a=e("./js/foundation.core.utils.js");e.d(n,"Plugin",function(){return o.Plugin}),e.d(n,"rtl",function(){return a.rtl}),e.d(n,"GetYoDigits",function(){return a.GetYoDigits}),e.d(n,"RegExpEscape",function(){return a.RegExpEscape}),e.d(n,"transitionend",function(){return a.transitionend}),e.d(n,"onLoad",function(){return a.onLoad}),e.d(n,"ignoreMousedisappear",function(){return a.ignoreMousedisappear}),i.Foundation.addToJquery(r.a),i.Foundation.Plugin=o.Plugin,i.Foundation.rtl=a.rtl,i.Foundation.GetYoDigits=a.GetYoDigits,i.Foundation.transitionend=a.transitionend,i.Foundation.RegExpEscape=a.RegExpEscape,i.Foundation.onLoad=a.onLoad,window.Foundation=i.Foundation},"./js/foundation.core.js":function(t,n,e){"use strict";e.r(n),e.d(n,"Foundation",function(){return s});var n=e("jquery"),o=e.n(n),r=e("./js/foundation.core.utils.js"),a=e("./js/foundation.util.mediaQuery.js");function u(t){return(u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var s={version:"6.7.3",_plugins:{},_uuids:[],plugin:function(t,n){var e=n||c(t),n=i(e);this._plugins[n]=this[e]=t},registerPlugin:function(t,n){n=n?i(n):c(t.constructor).toLowerCase();t.uuid=Object(r.GetYoDigits)(6,n),t.$element.attr("data-".concat(n))||t.$element.attr("data-".concat(n),t.uuid),t.$element.data("zfPlugin")||t.$element.data("zfPlugin",t),t.$element.trigger("init.zf.".concat(n)),this._uuids.push(t.uuid)},unregisterPlugin:function(t){var n,e=i(c(t.$element.data("zfPlugin").constructor));for(n in this._uuids.splice(this._uuids.indexOf(t.uuid),1),t.$element.removeAttr("data-".concat(e)).removeData("zfPlugin").trigger("destroyed.zf.".concat(e)),t)t[n]=null},reInit:function(t){var n,e,r=t instanceof o.a;try{r?t.each(function(){o()(this).data("zfPlugin")._init()}):(n=u(t),e=this,{object:function(t){t.forEach(function(t){t=i(t),o()("[data-"+t+"]").foundation("_init")})},string:function(){t=i(t),o()("[data-"+t+"]").foundation("_init")},undefined:function(){this.object(Object.keys(e._plugins))}}[n](t))}catch(t){console.error(t)}finally{return t}},reflow:function(e,t){void 0===t?t=Object.keys(this._plugins):"string"==typeof t&&(t=[t]);var i=this;o.a.each(t,function(t,n){var r=i._plugins[n];o()(e).find("[data-"+n+"]").addBack("[data-"+n+"]").filter(function(){return void 0===o()(this).data("zfPlugin")}).each(function(){var t=o()(this),e={reflow:!0};t.attr("data-options")&&t.attr("data-options").split(";").forEach(function(t,n){t=t.split(":").map(function(t){return t.trim()});t[0]&&(e[t[0]]=function(t){{if("true"===t)return!0;if("false"===t)return!1;if(!isNaN(+t))return parseFloat(t)}return t}(t[1]))});try{t.data("zfPlugin",new r(o()(this),e))}catch(t){console.error(t)}finally{return}})})},getFnName:c,addToJquery:function(o){return o.fn.foundation=function(e){var t=u(e),n=o(".no-js");if(n.length&&n.removeClass("no-js"),"undefined"===t)a.MediaQuery._init(),s.reflow(this);else{if("string"!==t)throw new TypeError("We're sorry, ".concat(t," is not a valid parameter. You must use a string representing the method you wish to invoke."));var r=Array.prototype.slice.call(arguments,1),i=this.data("zfPlugin");if(void 0===i||void 0===i[e])throw new ReferenceError("We're sorry, '"+e+"' is not an available method for "+(i?c(i):"this element")+".");1===this.length?i[e].apply(i,r):this.each(function(t,n){i[e].apply(o(n).data("zfPlugin"),r)})}return this},o}};function c(t){if(void 0!==Function.prototype.name)return(void 0===t.prototype?t:t.prototype).constructor.name;t=/function\s([^(]{1,})\(/.exec(t.toString());return t&&1<t.length?t[1].trim():""}function i(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}s.util={throttle:function(e,r){var i=null;return function(){var t=this,n=arguments;null===i&&(i=setTimeout(function(){e.apply(t,n),i=null},r))}}},window.Foundation=s,function(){Date.now&&window.Date.now||(window.Date.now=Date.now=function(){return(new Date).getTime()});for(var r,t=["webkit","moz"],n=0;n<t.length&&!window.requestAnimationFrame;++n){var e=t[n];window.requestAnimationFrame=window[e+"RequestAnimationFrame"],window.cancelAnimationFrame=window[e+"CancelAnimationFrame"]||window[e+"CancelRequestAnimationFrame"]}!/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent)&&window.requestAnimationFrame&&window.cancelAnimationFrame||(r=0,window.requestAnimationFrame=function(t){var n=Date.now(),e=Math.max(r+16,n);return setTimeout(function(){t(r=e)},e-n)},window.cancelAnimationFrame=clearTimeout),window.performance&&window.performance.now||(window.performance={start:Date.now(),now:function(){return Date.now()-this.start}})}(),Function.prototype.bind||(Function.prototype.bind=function(t){if("function"!=typeof this)throw new TypeError("Function.prototype.bind - what is trying to be bound is not callable");function n(){return r.apply(this instanceof i?this:t,e.concat(Array.prototype.slice.call(arguments)))}var e=Array.prototype.slice.call(arguments,1),r=this,i=function(){};return this.prototype&&(i.prototype=this.prototype),n.prototype=new i,n})},"./js/foundation.core.plugin.js":function(t,n,e){"use strict";e.r(n),e.d(n,"Plugin",function(){return r});var n=e("jquery"),i=e("./js/foundation.core.utils.js");function o(t,n){for(var e=0;e<n.length;e++){var r=n[e];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var r=function(){function e(t,n){!function(t,n){if(!(t instanceof n))throw new TypeError("Cannot call a class as a function")}(this,e),this._setup(t,n);n=a(this);this.uuid=Object(i.GetYoDigits)(6,n),this.$element.attr("data-".concat(n))||this.$element.attr("data-".concat(n),this.uuid),this.$element.data("zfPlugin")||this.$element.data("zfPlugin",this),this.$element.trigger("init.zf.".concat(n))}var t,n,r;return t=e,(n=[{key:"destroy",value:function(){this._destroy();var t,n=a(this);for(t in this.$element.removeAttr("data-".concat(n)).removeData("zfPlugin").trigger("destroyed.zf.".concat(n)),this)this[t]=null}}])&&o(t.prototype,n),r&&o(t,r),e}();function a(t){return t.className.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}},"./js/foundation.core.utils.js":function(t,n,e){"use strict";e.r(n),e.d(n,"rtl",function(){return r}),e.d(n,"GetYoDigits",function(){return i}),e.d(n,"RegExpEscape",function(){return o}),e.d(n,"transitionend",function(){return a}),e.d(n,"onLoad",function(){return u}),e.d(n,"ignoreMousedisappear",function(){return c});var n=e("jquery"),s=e.n(n);function r(){return"rtl"===s()("html").attr("dir")}function i(){for(var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:6,n=1<arguments.length?arguments[1]:void 0,e="",r="0123456789abcdefghijklmnopqrstuvwxyz",i=r.length,o=0;o<t;o++)e+=r[Math.floor(Math.random()*i)];return n?"".concat(e,"-").concat(n):e}function o(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}function a(t){var n,e,r={transition:"transitionend",WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"otransitionend"},i=document.createElement("div");for(e in r)void 0!==i.style[e]&&(n=r[e]);return n||(setTimeout(function(){t.triggerHandler("transitionend",[t])},1),"transitionend")}function u(t,n){function e(){return t.triggerHandler(i)}var r="complete"===document.readyState,i=(r?"_didLoad":"load")+".zf.util.onLoad";return t&&(n&&t.one(i,n),r?setTimeout(e):s()(window).one("load",e)),i}function c(o){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.ignoreLeaveWindow,a=void 0!==n&&n,t=t.ignoreReappear,u=void 0!==t&&t;return function(n){for(var t=arguments.length,e=new Array(1<t?t-1:0),r=1;r<t;r++)e[r-1]=arguments[r];var i=o.bind.apply(o,[this,n].concat(e));if(null!==n.relatedTarget)return i();setTimeout(function(){return a||!document.hasFocus||document.hasFocus()?void(u||s()(document).one("mouseenter",function(t){s()(n.currentTarget).has(t.target).length||(n.relatedTarget=t.target,i())})):i()},0)}}},"./js/foundation.util.mediaQuery.js":function(t,n,e){"use strict";e.r(n),e.d(n,"MediaQuery",function(){return d});var n=e("jquery"),i=e.n(n);function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t,n){return function(t){if(Array.isArray(t))return t}(t)||function(t,n){var e=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=e){var r,i,o=[],a=!0,u=!1;try{for(e=e.call(t);!(a=(r=e.next()).done)&&(o.push(r.value),!n||o.length!==n);a=!0);}catch(t){u=!0,i=t}finally{try{a||null==e.return||e.return()}finally{if(u)throw i}}return o}}(t,n)||function(t,n){if(t){if("string"==typeof t)return a(t,n);var e=Object.prototype.toString.call(t).slice(8,-1);return"Map"===(e="Object"===e&&t.constructor?t.constructor.name:e)||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?a(t,n):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(t,n){(null==n||n>t.length)&&(n=t.length);for(var e=0,r=new Array(n);e<n;e++)r[e]=t[e];return r}var u,s,c;window.matchMedia||(window.matchMedia=((c=window.styleMedia||window.media)||(u=document.createElement("style"),n=document.getElementsByTagName("script")[0],s=null,u.type="text/css",u.id="matchmediajs-test",n?n.parentNode.insertBefore(u,n):document.head.appendChild(u),s="getComputedStyle"in window&&window.getComputedStyle(u,null)||u.currentStyle,c={matchMedium:function(t){t="@media "+t+"{ #matchmediajs-test { width: 1px; } }";return u.styleSheet?u.styleSheet.cssText=t:u.textContent=t,"1px"===s.width}}),function(t){return{matches:c.matchMedium(t||"all"),media:t||"all"}}));var d={queries:[],current:"",_init:function(){if(!0!==this.isInitialized){this.isInitialized=!0;i()("meta.foundation-mq").length||i()('<meta class="foundation-mq" name="foundation-mq" content>').appendTo(document.head);var t,n,e,r=i()(".foundation-mq").css("font-family");for(e in n={},t="string"==typeof(r=r)&&(r=r.trim().slice(1,-1))?n=r.split("&").reduce(function(t,n){var e=n.replace(/\+/g," ").split("="),n=e[0],e=e[1],n=decodeURIComponent(n),e=void 0===e?null:decodeURIComponent(e);return t.hasOwnProperty(n)?Array.isArray(t[n])?t[n].push(e):t[n]=[t[n],e]:t[n]=e,t},{}):n,this.queries=[],t)t.hasOwnProperty(e)&&this.queries.push({name:e,value:"only screen and (min-width: ".concat(t[e],")")});this.current=this._getCurrentSize(),this._watcher()}},_reInit:function(){this.isInitialized=!1,this._init()},atLeast:function(t){t=this.get(t);return!!t&&window.matchMedia(t).matches},only:function(t){return t===this._getCurrentSize()},upTo:function(t){t=this.next(t);return!t||!this.atLeast(t)},is:function(t){var n=o(t.trim().split(" ").filter(function(t){return!!t.length}),2),e=n[0],n=n[1],n=void 0===n?"":n;if("only"===n)return this.only(e);if(!n||"up"===n)return this.atLeast(e);if("down"===n)return this.upTo(e);throw new Error('\n Invalid breakpoint passed to MediaQuery.is().\n Expected a breakpoint name formatted like "<size> <modifier>", got "'.concat(t,'".\n '))},get:function(t){for(var n in this.queries)if(this.queries.hasOwnProperty(n)){n=this.queries[n];if(t===n.name)return n.value}return null},next:function(n){var e=this,t=this.queries.findIndex(function(t){return e._getQueryName(t)===n});if(-1===t)throw new Error('\n Unknown breakpoint "'.concat(n,'" passed to MediaQuery.next().\n Ensure it is present in your Sass "$breakpoints" setting.\n '));t=this.queries[t+1];return t?t.name:null},_getQueryName:function(t){if("string"==typeof t)return t;if("object"===r(t))return t.name;throw new TypeError('\n Invalid value passed to MediaQuery._getQueryName().\n Expected a breakpoint name (String) or a breakpoint query (Object), got "'.concat(t,'" (').concat(r(t),")\n "))},_getCurrentSize:function(){for(var t,n=0;n<this.queries.length;n++){var e=this.queries[n];window.matchMedia(e.value).matches&&(t=e)}return t&&this._getQueryName(t)},_watcher:function(){var e=this;i()(window).off("resize.zf.mediaquery").on("resize.zf.mediaquery",function(){var t=e._getCurrentSize(),n=e.current;t!==n&&(e.current=t,i()(window).trigger("changed.zf.mediaquery",[t,n]))})}}},0:function(t,n,e){t.exports=e("./js/entries/plugins/foundation.core.js")},jquery:function(t,n){t.exports=e}},o={},i.m=r,i.c=o,i.d=function(t,n,e){i.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:e})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(n,t){if(1&t&&(n=i(n)),8&t)return n;if(4&t&&"object"==typeof n&&n&&n.__esModule)return n;var e=Object.create(null);if(i.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:n}),2&t&&"string"!=typeof n)for(var r in n)i.d(e,r,function(t){return n[t]}.bind(null,r));return e},i.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(n,"a",n),n},i.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},i.p="",i(i.s=0);function i(t){if(o[t])return o[t].exports;var n=o[t]={i:t,l:!1,exports:{}};return r[t].call(n.exports,n,n.exports,i),n.l=!0,n.exports}var r,o});
//# sourceMappingURL=foundation.core.min.js.map