text: /*!
   * Spirit.js v2.1.3
   *
   * (c) 2017 Patrick Brouwer
   * Released under the MIT License.
   */
  !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("spirit",[],t):"object"==typeof exports?exports.spirit=t():e.spirit=t()}(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,t,n){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=33)}([function(e,t,n){"use strict";var r=n(4),i=n(27),o=n(3),a=n(25),u=n(30),c=n(5),s=(n(7),n(21),n(28)),l=(n(24),n(6));n.d(t,"f",function(){return l.a}),n.d(t,"d",function(){return r}),n.d(t,"e",function(){return i}),n.d(t,"c",function(){return o}),n.d(t,"b",function(){return a}),n.d(t,"g",function(){return u}),n.d(t,"a",function(){return c}),n.d(t,"h",function(){return s.a})},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function e(){r(this,e),this.debug=!0,this.gsap={tween:null,timeline:null,autoInject:!0,autoInjectUrl:"https://unpkg.com/gsap/src/minified/TweenMax.min.js"}};t.a=new i},function(e,t,n){"use strict";function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var u=n(5),c=n(3),s=n(29),l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),p=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;i(this,t);var c=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));if(c._list=[],c._model=null,c._duplicates=!0,c._sortOn=!1,c._linkedList=!1,c._model=n,n){var s=void 0!==a?new(Function.prototype.bind.apply(n,[null].concat(r(a)))):new n;if("function"!=typeof s.toObject)throw new Error("Invalid Model prototype. model.toObject does not exist.")}if(!Array.isArray(e))throw new Error("Items should be an array");return c._list=e.reduce(function(e,t){if(c._model)if(t instanceof c._model)t._list=c,t.setupBubbleEvents&&"function"==typeof t.setupBubbleEvents&&t.setupBubbleEvents(),e.push(t);else{if(!u.isObject(t)||"function"!=typeof n.fromObject)throw new Error("Could not parse item from model");var r=n.fromObject(t);r._list=c,r.setupBubbleEvents&&"function"==typeof r.setupBubbleEvents&&r.setupBubbleEvents(),e.push(r)}else e.push(t);return e},[]),c}return a(t,e),f(t,[{key:"checkOnDuplicates",value:function(){var e=this._duplicates,t=!1,n=!1;if("boolean"==typeof e&&e===!1&&(t=this.list.map(function(e){return{count:1,item:e}}).reduce(function(e,t){return e[t.item]=(e[t.item]||0)+t.count,e},{})),u.isObject(e)&&e.hasOwnProperty("prop")&&(n=!0,t=this.list.map(function(t){return{count:1,prop:t[e.prop]}}).reduce(function(e,t){return e[t.prop]=(e[t.prop]||0)+t.count,e},{})),t&&Object.keys(t).filter(function(e){return t[e]>1}).length>0){var r=Object.keys(t).find(function(e){return t[e]>1}),i=!!n&&e.prop+": "+r,o=!!this._model&&this.constructor.name+" > "+this._model.name+" > { "+i+" }";throw new Error("List has duplicates. "+o)}}},{key:"sort",value:function(){var e=this._sortOn;"boolean"==typeof e&&e===!0&&(this._list=this._list.sort()),"string"==typeof e&&(this._list=this._list.sort(function(t,n){return t[e]-n[e]})),"function"==typeof e&&(this._list=this._list.sort(e))}},{key:"linkItems",value:function(){if(this._linkedList)for(var e=0;e<this._list.length;e++){if(!u.isObject(this._list[e]))throw new Error("Can not link primitives.");this._list[e]._prev=e>0?this._list[e-1]:null,this._list[e]._next=e<this._list.length-1?this._list[e+1]:null}}},{key:"at",value:function(e){if(e>=this._list.length)throw new Error("Index exceeded. Requested "+e+", have length of "+this.length);return this._list[e]}},{key:"add",value:function(e){var t=this,n=null,r=function(e){var r=void 0;if(t._model)if(e instanceof t._model)r=e,r._list=t,r.setupBubbleEvents&&"function"==typeof r.setupBubbleEvents&&r.setupBubbleEvents();else{if(!u.isObject(e)||"function"!=typeof t._model.fromObject)throw new Error("Invalid item.");r=t._model.fromObject(e),r._list=t,r.setupBubbleEvents&&"function"==typeof r.setupBubbleEvents&&r.setupBubbleEvents()}else r=e;Array.isArray(n)?n.push(r):n=r,t._list.push(r),t.emit("add",r)};return Array.isArray(e)?(n=[],e.forEach(r)):r(e),this.checkOnDuplicates(),this.sort(),this.linkItems(),n}},{key:"remove",value:function(e){var n=this,r=null,i=function(e){var i=function(e){var i=n._list.indexOf(e);i>-1&&(n._list.splice(i,1),u.isObject(e)&&("_prev"in e&&delete e._prev,"_next"in e&&delete e._next),n.emit("remove",e),e._list&&e._list instanceof t&&(e._list=null),Array.isArray(r)?r.push(e):r=e)};n._model?e instanceof n._model&&i(e):i(e)};return Array.isArray(e)?(r=[],e.forEach(i)):i(e),this.sort(),this.linkItems(),r}},{key:"clear",value:function(){this.each(this.remove.bind(this))}},{key:"each",value:function(e){for(var t=[].concat(r(this.list)),n=[],i=!1,o=0;o<t.length;o++){var a=t[o];try{n.push(e(a,o))}catch(e){i=e}if(i)break}if(i)throw i;return n}},{key:"toArray",value:function(){var e=this._model?this.list.map(function(e){return e.toObject()}):this.list;return e.reduce(function(e,t){if(u.isObject(t)){var n=l({},t);delete n._prev,delete n._next,delete n._list,e.push(n)}else e.push(t);return e},[])}},{key:"duplicates",get:function(){return this._duplicates},set:function(e){this._duplicates=e,this.checkOnDuplicates()}},{key:"sortOn",get:function(){return this._sortOn},set:function(e){this._sortOn=e,this.sort()}},{key:"linkedList",get:function(){return this._linkedList},set:function(e){this._linkedList=e,this.linkItems()}},{key:"list",get:function(){return this._list},set:function(e){if(!Array.isArray(e))throw new Error("List should be an array");this._list=e,this._linkedList&&this.linkItems(),this.emit("change:list",e)}},{key:"length",get:function(){return this.list.length}}]),t}(n.i(s.a)(c.Emitter,"_list"));p.Events=["change:list","add","remove"],t.a=p},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o(e,t){if(!(t instanceof f))throw new Error("Scope needs to be an emitter.");return function(){if(this.emit.apply(this,[e].concat(Array.prototype.slice.call(arguments))),this._list instanceof u.a){var t;(t=this._list).emit.apply(t,[e].concat(Array.prototype.slice.call(arguments)))}}.bind(t)}function a(e,t,n,r,o){var a={prevModel:e.fromObject(t),model:e.fromObject(l({},t,i({},n,o))),changed:{type:n,from:r,to:o}};return a}var u=n(2),c=n(31);t.bubbleEvent=o,t.createEventObjectForModel=a,n.d(t,"Emitter",function(){return f});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(){r(this,e),this._events={},this._emitter=n.i(c.a)(this._events)}return s(e,[{key:"eventNames",value:function(){return Object.keys(this._events)}},{key:"emit",value:function(e){for(var t,n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];(t=this._emitter).emit.apply(t,[e].concat(r))}},{key:"on",value:function(e,t){this._emitter.on(e,t)}},{key:"removeListener",value:function(e,t){this._emitter.off(e,t)}},{key:"removeAllListeners",value:function(){var e=this;Object.keys(this._events).forEach(function(t){var n=e._events[t];n.forEach(function(n){return e._emitter.off(t,n)})})}}]),e}()},function(e,t,n){"use strict";(function(e){function n(){return"window"in e&&"document"in e}t.isBrowser=n}).call(t,n(32))},function(e,t,n){"use strict";function r(e){return"[object Object]"===Object.prototype.toString.call(e)}function i(e){return e instanceof window.SVGElement}function o(e){return"function"==typeof e}t.isObject=r,t.isSVG=i,t.isFunction=o},function(e,t,n){"use strict";var r=(n(4),n(1),function(){return!1});t.a=r},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];return e?function(i){var o;Object.defineProperties(i.prototype,(o={},r(o,"_"+e,{value:t,writable:!0,enumerable:!1,configurable:!0}),r(o,e,{configurable:!0,get:function(){return this["_"+e]},set:function(t){var r=n.reduce(function(e,n){return n.validator(t)||e.push(n.message),e},[]);if(r.length>0)throw new Error(""+r[0]);this["_"+e]=t}}),o));var a=Object.getOwnPropertyDescriptor(i.prototype,e);Object.defineProperty(i.prototype,e,s(i,e,a))}:s}var o=n(3),a=n(2),u=n(5);t.a=i;var c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(e,t,i){var s=i.set;if(!o.Emitter.prototype.isPrototypeOf(e)&&!o.Emitter.prototype.isPrototypeOf(e.prototype))throw new Error("@emitter.emitChange can only be applied to event emitters");return c({},i,{configurable:!0,set:function(e){var i=this,c=function(o){return n.i(u.isFunction)(i.toObject)?i.toObject():r({},t,void 0!==o?o:e)},l=this["_"+t];l&&"function"==typeof l.toArray?l=l.toArray():l&&"function"==typeof l.toObject&&(l=l.toObject());var f=void 0;if(l!==e&&(f=c(l)),s.call(this,e),this._list instanceof a.a&&this._list._duplicates!==!0)try{this._list.checkOnDuplicates()}catch(e){throw s.call(this,l),e}if(l!==e){var p=l&&n.i(u.isFunction)(l.toObject)?l.toObject():l,h=e&&n.i(u.isFunction)(e.toObject)?e.toObject():e,y={type:t,from:p,to:h},v=void 0;try{v=c()}catch(n){v=r({},t,e)}var m={previous:f,current:v,changed:y},b=["change",m],d=["change:"+t,m,e];if(this.emit.apply(this,b),this.emit.apply(this,d),this._list&&this._list instanceof o.Emitter){var _,g;(_=this._list).emit.apply(_,b),(g=this._list).emit.apply(g,d)}}}})}},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return!0;return!1}t.a=r},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=n(2),u=n(15),c=n(0),s=n(8),l=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),f=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;if(void 0!==a)return a.call(r)},p=function(e){function t(){return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,[]))}return o(t,e),l(t,[{key:"add",value:function(e){if(!(e instanceof u.a))throw new Error("Invalid group. Only Group instances allowed.");n.i(s.a)(this.groupNames(),e.name)?n.i(c.f)():(n.i(c.f)(),f(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"add",this).call(this,e))}},{key:"get",value:function(e){return this.list.find(function(t){return t.name===e})}},{key:"groupNames",value:function(){return this.list.map(function(e){return e.name})}}]),t}(a.a);t.a=new p},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(19),o=n(0),a=n(8),u=n(13),c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"dom",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new i.a,c=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null;if(r(this,e),this.type="dom",this.transformObject=null,this.label=null,this.path=null,this.id=null,this.props=null,a instanceof i.a||(a=new i.a(a)),Object.assign(this,{type:t,transformObject:n,props:a,label:l,path:c,id:s}),"dom"===t){if(!n||o.d.isBrowser()&&!(n instanceof window.Element))throw new Error("transformObject needs to be an element.");if(!s&&!c)throw new Error("path is not defined")}if("object"===t&&!n)throw new Error("transformObject needs to be an object");this.props.mappings=[new u.a(/this/g,n)]}return s(e,[{key:"toObject",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t={type:this.type,transformObject:this.transformObject,props:this.props.toObject(e),label:this.label,path:this.path,id:this.id};return Object.keys(t).forEach(function(e){t[e]||delete t[e]}),t}},{key:"destroy",value:function(){this.props instanceof i.a&&this.props.each(function(e){return e.destroy()})}}]),e}();l.fromObject=function(e){if(!o.a.isObject(e))throw new Error("Object is invalid.");var t=Object.keys(e);if(!n.i(a.a)(t,"transformObject"))throw new Error("Object is invalid");var r=o.b.objectToArray(e).filter(function(e){return void 0!==e});return r=c({type:r.type||"dom",props:{}},o.b.arrayToObject(r)),new l(r.type,r.transformObject,r.props,r.path||void 0,r.id||void 0,r.label||void 0)},t.a=l},function(e,t,n){"use strict";function r(e){return new Promise(function(t,r){var u=void 0,c=void 0;i.a.isObject(e)&&("function"==typeof e.timeline&&"function"==typeof e.tween&&(u=e.timeline,c=e.tween),"boolean"==typeof e.debug&&(o.a.debug=e.debug)),n.i(a.a)(),c&&u?(o.a.gsap.tween=c,o.a.gsap.timeline=u,t()):i.e.ensure().then(t).catch(r)})}var i=n(0),o=n(1),a=n(6);t.a=r},function(e,t,n){"use strict";function r(e,t){var r=void 0;if("object"!==t.type){if(t.id&&(r=e.querySelector('[data-spirit-id="'+t.id+'"]'),!r&&!t.path))throw n.i(s.f)(),new Error('Cannot find element with [data-spirit-id="'+t.id+'"]');if(!r&&t.path&&(e===document.body&&(e=void 0),r=s.g.getElement(t.path,e),!r))throw n.i(s.f)(),new Error("Cannot find element with path expression "+t.path);if(!r)throw n.i(s.f)(),new Error("Cannot find element.")}return r}function i(e){return"string"==typeof e.label&&e.label.trim().length>0?e.label:e.id?e.id:e.path?e.path:"undefined"}function o(e,t){return t.id&&e.getAttribute("data-spirit-id")===t.id?t.id:"dom"===t.type&&e.hasAttribute("data-spirit-id")?e.getAttribute("data-spirit-id"):null}function a(){var e=[],t=function(t){for(var n=0;n<e.length;n++){var r=e[n];if(r.rootEl===t)return r}return null};return{add:function(n,r){var i=t(n);i||(i=new l.b(n,[]),e.push(i)),r&&i.add(r)},groups:function(){return 1===e.length?e[0]:e}}}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;if(!s.d.isBrowser())throw new Error("Invalid context. spirit.create() can only be executed in the browser.");var n=!1;t instanceof window.Element||(n=!0,t=document.body||document.documentElement),s.a.isObject(e)&&e.groups&&Array.isArray(e.groups)&&(e=e.groups),Array.isArray(e)||(e=[e]);var u=a();return 0===e.length&&u.add(t,null),e.forEach(function(e){var a=t;n&&e.root&&(a=e.root.id?t.querySelector("[data-spirit-id="+e.root.id+"]"):s.g.getElement(e.root.path,t),a||(a=t));var c={name:e.name,timeScale:e.timeScale||1,timelines:[],unresolved:[]},f=e.timelines||[];f.forEach(function(e){var t=void 0;try{t=r(a,e),c.timelines.push({transformObject:t,type:e.type,props:e.props,label:i(e),path:s.g.getExpression(t,a),id:o(t,e)})}catch(t){c.unresolved.push({data:e,error:t})}}),u.add(a,new l.a(c))}),u.groups()}function c(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;return s.d.isBrowser()?n.i(s.h)(e).then(function(e){return u(e,t)}):Promise.reject(new Error("Invalid context: spirit.load() can only be executed in the browser."))}var s=n(0),l=n(15);t.a=u,t.b=c},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function e(t,n){if(r(this,e),!t||t&&!(t instanceof RegExp))throw new Error("Invalid expression.");if(null===n||void 0===n)throw new Error("Invalid mapping.");Object.assign(this,{regex:t,map:n})};t.a=i},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t,n,r,i){var o={};return Object.keys(r).forEach(function(e){o[e]=r[e]}),o.enumerable=!!o.enumerable,o.configurable=!!o.configurable,("value"in o||o.initializer)&&(o.writable=!0),o=n.slice().reverse().reduce(function(n,r){return r(e,t,n)||n},o),i&&void 0!==o.initializer&&(o.value=o.initializer?o.initializer.call(i):void 0,o.initializer=void 0),void 0===o.initializer&&(Object.defineProperty(e,t,o),o=null),o}var u,c,s,l,f,p=n(1),h=n(0),y=n(20),v=n(7),m=n(26),b=n(3),d=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),g=(u=n.i(v.a)(),c=n.i(v.a)(),s=n.i(v.a)(),l=n.i(v.a)(),f=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));if(n._name="untitled",n._timeScale=1,n._timelines=new y.a,n.timeline=null,n.unresolved=[],!e.name||"string"!=typeof e.name||""===e.name.trim())throw new Error("Cannot create group without a name.");var o={name:"untitled",timeScale:1,timelines:new y.a};return Object.assign(n,d({},o,e)),n}return o(t,e),_(t,[{key:"toObject",value:function(){var e=this.name,t=this.timeScale,n=this.timelines.toArray();return{name:e,timeScale:t,timelines:n}}},{key:"reset",value:function(){this.timeline&&h.e.killTimeline(this.timeline)}},{key:"construct",value:function(){var e=this;try{if(!p.a.gsap.timeline||!p.a.gsap.tween)throw n.i(h.f)(),new Error("GSAP cannot be found");this.timeline&&this.timeline instanceof p.a.gsap.timeline?h.e.killTimeline(this.timeline):this.timeline=new p.a.gsap.timeline({paused:!0}),this.timelines.each(function(t){if("dom"===t.type){var n=t.transformObject;if(!(n instanceof window.Element))throw new m.a("transformObject is not an Element",n);try{e.timeline.add(h.e.generateTimeline(t).play(),0,"start")}catch(e){throw new m.a(e.message,n,e.stack)}}}),this.timeline.timeScale(this.timeScale),this._duration=this.timeline.duration()}catch(e){throw e.message="Could not construct timeline: "+e.message,e}return this.emit("construct",this.timeline),this.timeline}},{key:"timelines",get:function(){return this._timelines},set:function(e){e instanceof y.a||(e=new y.a(Array.from(e))),this._timelines=e}},{key:"timeScale",get:function(){return this._timeScale},set:function(e){if("number"!=typeof e||!isFinite(e))throw new Error("timeScale needs to be a number");this.timeline&&this.timeline instanceof p.a.gsap.timeline&&this.timeline.timeScale(e),this._timeScale=e}},{key:"duration",get:function(){return this.timeline?this.timeline.duration():0},set:function(e){this.timeline&&this.timeline instanceof p.a.gsap.timeline&&(this.timeline.duration(e),this.timeScale=this.timeline.timeScale(),this._duration=this.timeline.duration())}},{key:"name",get:function(){return this._name},set:function(e){if("string"!=typeof e)throw new Error("Name needs to be a string");this._name=e}}]),t}(b.Emitter),a(f.prototype,"timelines",[u],Object.getOwnPropertyDescriptor(f.prototype,"timelines"),f.prototype),a(f.prototype,"timeScale",[c],Object.getOwnPropertyDescriptor(f.prototype,"timeScale"),f.prototype),a(f.prototype,"duration",[s],Object.getOwnPropertyDescriptor(f.prototype,"duration"),f.prototype),a(f.prototype,"name",[l],Object.getOwnPropertyDescriptor(f.prototype,"name"),f.prototype),f);g.fromObject=function(e){return new g(e)},t.a=g},function(e,t,n){"use strict";var r=(n(13),n(14)),i=n(23);n(16),n(17),n(18),n(19),n(10),n(20);n.d(t,"a",function(){return r.a}),n.d(t,"b",function(){return i.a})},function(module,exports,__webpack_require__){"use strict";function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function _inherits(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function _applyDecoratedDescriptor(e,t,n,r,i){var o={};return Object.keys(r).forEach(function(e){o[e]=r[e]}),o.enumerable=!!o.enumerable,o.configurable=!!o.configurable,("value"in o||o.initializer)&&(o.writable=!0),o=n.slice().reverse().reduce(function(n,r){return r(e,t,n)||n},o),i&&void 0!==o.initializer&&(o.value=o.initializer?o.initializer.call(i):void 0,o.initializer=void 0),void 0===o.initializer&&(Object.defineProperty(e,t,o),o=null),o}var __WEBPACK_IMPORTED_MODULE_0__utils__=__webpack_require__(0),__WEBPACK_IMPORTED_MODULE_1__utils_emitter__=__webpack_require__(7),__WEBPACK_IMPORTED_MODULE_2__utils_events__=__webpack_require__(3),_createClass=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),_dec,_dec2,_dec3,_class,_desc,_value,_class2,Keyframe=(_dec=__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__utils_emitter__.a)("time",null,[{validator:function(e){return"number"==typeof e},message:"Time must be a number"}]),_dec2=__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__utils_emitter__.a)("ease",null),_dec3=__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__utils_emitter__.a)(),_dec(_class=_dec2((_class2=function(_Emitter){function Keyframe(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;_classCallCheck(this,Keyframe);var r=_possibleConstructorReturn(this,(Keyframe.__proto__||Object.getPrototypeOf(Keyframe)).call(this));return r._list=null,r._value=null,r.mappings=[],n=n||null,Object.assign(r,{time:e,value:t,ease:n}),r}return _inherits(Keyframe,_Emitter),_createClass(Keyframe,[{key:"next",value:function(){return this._next}},{key:"prev",value:function(){return this._prev}},{key:"isEval",value:function(){return/{(.*?)}/.test(this._value)}},{key:"toObject",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=void 0;try{t=e?this._value:this.value}catch(e){t=this._value}return _defineProperty({},this.time+"s",{value:t,ease:this.ease})}},{key:"destroy",value:function(){this.removeAllListeners()}},{key:"value",get:function get(){var _this2=this;if(this.isEval()){var mappings=this.mappings.reduce(function(e,t){return t.regex.global&&(t.regex.lastIndex=0),t.regex.test(_this2._value)&&(e[t.regex]=t),e},{}),val=this._value;for(var mapping in mappings)val=val.replace(mappings[mapping].regex,"mappings["+mapping+"].map");var res=void 0;try{res=eval(val)}catch(e){if(this.mappings.length>0)throw e}return res}return this._value},set:function(e){this._value=e}},{key:"list",get:function(){return this._list}}]),Keyframe}(__WEBPACK_IMPORTED_MODULE_2__utils_events__.Emitter),_applyDecoratedDescriptor(_class2.prototype,"value",[_dec3],Object.getOwnPropertyDescriptor(_class2.prototype,"value"),_class2.prototype),_class=_class2))||_class)||_class);Keyframe.fromObject=function(e){if(!__WEBPACK_IMPORTED_MODULE_0__utils__.a.isObject(e))throw new Error("Object is invalid");var t=Object.keys(e);if(0===t.length||t.length>1)throw new Error("Object is invalid");var n=t[0],r=e[n],i=r.value,o=r.ease;if(__WEBPACK_IMPORTED_MODULE_0__utils__.a.isObject(e[n])||"string"!=typeof e[n]&&"number"!=typeof e[n]||(i=e[n],o=null),n=parseFloat(n),isNaN(n))throw new Error("Object is invalid. Invalid time object { `1s`: ... }");if(void 0===i||null===i)throw new Error("Object is invalid. No value found: {value}");return new Keyframe(n,i,o)},Keyframe.Events=["change","change:time","change:value","change:ease"],exports.a=Keyframe},function(e,t,n){"use strict";function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var u=n(2),c=n(16),s=n(0),l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),p=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;if(void 0!==a)return a.call(r)},h=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];i(this,t),s.a.isObject(e)&&(e=s.b.objectToArray(e));var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,c.a,[0,0]));return n.duplicates={prop:"time"},n.sortOn="time",n.linkedList=!0,n._mappings=[],n}return a(t,e),f(t,[{key:"add",value:function(e){var n=this;s.a.isObject(e)&&!(e instanceof c.a)&&Object.keys(e).length>1&&(e=s.b.objectToArray(e));var i=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"add",this).call(this,e),o=function(e){e.mappings=[].concat(r(n.mappings))};return Array.isArray(i)?i.forEach(o):o(i),i}},{key:"remove",value:function(e){var n=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"remove",this).call(this,e),r=function(e){e.mappings=[]};return Array.isArray(n)?n.forEach(r):r(n),n}},{key:"get",value:function(e){var t=parseFloat(e);return this._list.find(function(e){return e.time===t})}},{key:"toObject",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.list.reduce(function(t,n){return l({},t,n.toObject(e))},{})}},{key:"destroy",value:function(){this.removeAllListeners(),this.each(function(e){return e.destroy()})}},{key:"mappings",get:function(){return this._mappings},set:function(e){this._mappings=e,this.each(function(t){t.mappings=[].concat(r(e))})}}]),t}(u.a);h.Events=["change:list","add","remove","change","change:time","change:value","change:ease"],t.a=h},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function u(e,t,n,r,i){var o={};return Object.keys(r).forEach(function(e){o[e]=r[e]}),o.enumerable=!!o.enumerable,o.configurable=!!o.configurable,("value"in o||o.initializer)&&(o.writable=!0),o=n.slice().reverse().reduce(function(n,r){return r(e,t,n)||n},o),i&&void 0!==o.initializer&&(o.value=o.initializer?o.initializer.call(i):void 0,o.initializer=void 0),void 0===o.initializer&&(Object.defineProperty(e,t,o),o=null),o}var c,s,l,f,p=n(17),h=n(0),y=n(7),v=n(3),m=n(8),b=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),d=(c=n.i(y.a)("name",null,[{validator:function(e){return"string"==typeof e},message:"Name must be a string"},{validator:function(e){return!/^\d+\.?\d*?$/.test(e)},message:"Name must be a string"}]),s=n.i(y.a)(),c((f=function(e){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new p.a;i(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r._keyframes=null,r._list=null,n instanceof p.a||(n=new p.a(n)),e=e||null,Object.assign(r,{name:e,keyframes:n}),r}return a(t,e),
  b(t,[{key:"next",value:function(){return this._next}},{key:"prev",value:function(){return this._prev}},{key:"setupBubbleEvents",value:function(){var e=this;if(this._keyframes instanceof p.a){this._keyframes.removeAllListeners();var t=function(t,n){e._keyframes.on(t,h.c.bubbleEvent(n,e))};t("change:list","change:keyframes:list"),t("change","change:keyframe"),t("change:time","change:keyframe:time"),t("change:value","change:keyframe:value"),t("change:ease","change:keyframe:ease"),t("add","add:keyframe"),t("remove","remove:keyframe")}}},{key:"toObject",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.keyframes?this.keyframes.toObject(e):{};return r({},this.name,t)}},{key:"isCSSTransform",value:function(){return n.i(m.a)(["x","y","z","rotation","rotationZ","rotationX","rotationY","skewX","skewY","scale","scaleX","scaleY"],this.name)}},{key:"destroy",value:function(){this._keyframes&&this._keyframes.destroy(),this.removeAllListeners()}},{key:"list",get:function(){return this._list}},{key:"keyframes",get:function(){return this._keyframes},set:function(e){e instanceof p.a||(e=new p.a(e));var t=[];this._keyframes&&(t=this._keyframes.mappings,this._keyframes.removeAllListeners(),this._keyframes.clear()),this._keyframes=e,this._keyframes.mappings=t,this.setupBubbleEvents()}}]),t}(v.Emitter),u(f.prototype,"keyframes",[s],Object.getOwnPropertyDescriptor(f.prototype,"keyframes"),f.prototype),l=f))||l);d.fromObject=function(e){if(!h.a.isObject(e))throw new Error("Object is invalid");var t=Object.keys(e);if(0===t.length)throw new Error("Object is invalid");for(var n in e)if(!h.a.isObject(e[n]))throw new Error("Object is invalid");var r=t[0];return new d(r,e[r])},d.Events=["change","change:name","change:keyframes","change:keyframes:list","change:keyframe","change:keyframe:time","change:keyframe:value","change:keyframe:ease","add:keyframe","remove:keyframe"],t.a=d},function(e,t,n){"use strict";function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var u=n(2),c=n(18),s=n(0),l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),p=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;if(void 0!==a)return a.call(r)},h=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];i(this,t),s.a.isObject(e)&&(e=s.b.objectToArray(e));var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,c.a,["prop"]));return n.duplicates={prop:"name"},n.sortOn=function(e,t){return t.name<e.name},n.linkedList=!0,n._mappings=[],n}return a(t,e),f(t,[{key:"get",value:function(e){return this._list.find(function(t){return t.name===e})}},{key:"add",value:function(e){var n=this;s.a.isObject(e)&&!(e instanceof c.a)&&Object.keys(e).length>1&&(e=s.b.objectToArray(e));var i=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"add",this).call(this,e),o=function(e){e.keyframes.mappings=[].concat(r(n.mappings))};return Array.isArray(i)?i.forEach(o):o(i),i}},{key:"remove",value:function(e){var n=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"remove",this).call(this,e),r=function(e){e.keyframes.mappings=[]};return Array.isArray(n)?n.forEach(r):r(n),n}},{key:"haveProp",value:function(e){return!!this.get(e)}},{key:"toObject",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.list.reduce(function(t,n){return l({},t,n.toObject(e))},{})}},{key:"destroy",value:function(){this.each(function(e){return e.destroy()}),this.removeAllListeners()}},{key:"mappings",get:function(){return this._mappings},set:function(e){this._mappings=e,this.each(function(t){t.keyframes.mappings=[].concat(r(e))})}}]),t}(u.a);h.Events=["change:list","add","remove","change","change:name","change:keyframes","change:keyframes:list","change:keyframe","change:keyframe:time","change:keyframe:value","change:keyframe:ease","add:keyframe","remove:keyframe"],t.a=h},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=n(2),u=n(10),c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return r(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,u.a,["object",{}]))}return o(t,e),c(t,[{key:"get",value:function(e){return this._list.find(function(t){return t.transformObject===e})}}]),t}(a.a);t.a=s},function(e,t,n){"use strict";function r(e){return n.i(i.isBrowser)()?new Promise(function(t,n){var r=document.createElement("script");r.src=e,r.async=!0,r.onload=function(){document.body.removeChild(r),t()},r.onerror=function(){document.body.removeChild(r),n(new Error("Could not load script "+e))},document.body.appendChild(r)}):Promise.reject(new Error("Script can only be loaded in the browser: "+e))}var i=n(4);t.a=r},function(e,t,n){"use strict";function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){return void 0===e?Promise.resolve([]):n.i(c.isObject)(e)||Array.isArray(e)?Promise.resolve(n.i(u.a)(e,t)):Promise.reject(new Error("Invalid animation data"))}function o(e,t){return e&&"string"==typeof e&&e.length>0?n.i(u.b)(e,t):Promise.resolve([])}var a=n(11),u=n(12),c=n(5),s=n(1),l=n(9),f=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),p=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},h={loop:!1,autoPlay:!0,yoyo:!1,delay:0,timeScale:!1};t.a=function(e){var t=p({},h,e),u=t.animationData,c=t.container,y=t.path;return t.loop===!0&&(t.loop=-1),new Promise(function(e,p){var h=[],v=function(e){h=[].concat(r(h),r(Array.isArray(e)?[].concat(r(e)):[e]))};n.i(a.a)().then(function(){return Promise.all([i(u,c),o(y,c)])}).then(function(e){var t=f(e,2),n=t[0],r=t[1];v(n),v(r)}).then(function(){if(1===h.length&&1===h[0].length)return h[0].at(0).construct();var e={};return h.forEach(function(t){t.each(function(t){e[t.name]=t.construct(),e[t.name].construct=function(){var e=l.a.get(t.name).construct();return e.construct=this.construct,e}})}),e}).then(function(n){for(var r=n instanceof s.a.gsap.timeline?[n]:Object.keys(n).map(function(e){return n[e]}),i=0;i<r.length;i++){var o=r[i];t.loop&&o.repeat(t.loop),t.yoyo&&o.yoyo(!0),0!==t.delay&&o.repeatDelay(t.delay),t.timeScale&&o.timeScale(t.timeScale),t.autoPlay&&o.play(0)}e(n)}).catch(p)})}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=n(2),u=n(14),c=n(1),s=n(0),l=n(9),f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),p=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;if(void 0!==a)return a.call(r)},h=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];r(this,t);var o=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,n,u.a,[{name:"untitled"}]));if(o.rootEl=null,!(e instanceof window.Element))throw new Error("No root element provided.");return o.rootEl=e,o.each(function(e){return l.a.add(e)}),o}return o(t,e),f(t,[{key:"add",value:function(e){var n=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"add",this).call(this,e);return Array.isArray(n)?n.forEach(function(e){return l.a.add(e)}):l.a.add(n),n}},{key:"remove",value:function(e){var n=p(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"remove",this).call(this,e);return Array.isArray(n)?n.forEach(function(e){return l.a.remove(e)}):l.a.remove(n),n}},{key:"construct",value:function(){if(!c.a.gsap.timeline||!c.a.gsap.tween)throw n.i(s.f)(),new Error("GSAP cannot be found");return this.list.map(function(e){return e.construct()})}},{key:"get",value:function(e){return this.list.find(function(t){return t.name===e})}}]),t}(a.a);t.a=h},function(e,t,n){"use strict";n(8),"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){return Object.keys(e).reduce(function(t,n){return t.push(r({},n,e[n])),t},[])}function o(e){return e.reduce(function(e,t){return e=a({},e,t)},{})}t.objectToArray=i,t.arrayToObject=o;var a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}n.d(t,"a",function(){return a});var a=function(e){function t(e,n){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;r(this,t);var a=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return a.transformObject=null,o?a.stack=o:Error.captureStackTrace(a,t),a.transformObject=n,a.name="TimelineError",a.message=e,a}return o(t,e),t}(Error)},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(){return!(!s.a.gsap.tween||!s.a.gsap.timeline)}function o(){return i()?Promise.resolve():s.a.gsap.autoInject?(n.i(p.a)(),n.i(l.a)(s.a.gsap.autoInjectUrl).then(function(){return s.a.gsap.tween=window.TweenMax,s.a.gsap.timeline=window.TimelineMax,Promise.resolve()})):(n.i(p.a)(),Promise.reject(new Error("GSAP not found.")))}function a(e){var t=e.props.get("transformOrigin"),n=t&&t.keyframes.list.map(function(e){return{time:e.time,value:e.value}})||[];(n.length>0&&0!==n[0].time||0===n.length)&&n.unshift({time:0,value:"50% 50%"});var r=n.shift(),i=void 0,o=void 0;return o=function(){return{current:r,next:i}},i=function(){return r=n&&n.length>0&&n.shift()||null,o()},o()}function u(e){if(!(e&&e instanceof f.a))throw new Error("Need valid timeline data to generate GSAP timeline from");if(!s.a.gsap.timeline)throw new Error("GSAP not set. Please make sure GSAP is available.");if("dom"!==e.type)throw new Error("Timeline invalid. Needs a timeline with type of dom.");var t=new s.a.gsap.timeline({paused:!0}),n=a(e),i=n.current;return e.props.each(function(o){if(0!==o.keyframes.length&&"transformOrigin"!==o.name&&"svgOrigin"!==o.name)for(var a=o.keyframes.at(0);a;){var u=a,c=u.value,s=u.ease,l=u.time,f=a.prev(),p=f?f.time:0,y=f?l-f.time:l,v={ease:s||"Linear.easeNone"},m=r({},o.name,c);if(/\./.test(o.name)){for(var b=o.name.split("."),d=b.pop(),_={},g=_;b.length>0;){var w=b.shift();_[w]={},_=_[w]}_[d]=c,m=g}v=h({},v,m),0===l&&(v.immediateRender=!0),o.isCSSTransform()&&i&&l>=i.time&&(v.transformOrigin=i.value,i=n.next().current),t.to(e.transformObject,y,v,p),a=a.next()}}),t}function c(e){if(e&&e instanceof s.a.gsap.timeline){e.eventCallback("onComplete",null),e.eventCallback("onUpdate",null),e.eventCallback("onStart",null);var t=e.getChildren();e.kill();for(var n=0;n<t.length;n++)t[n]&&t[n]instanceof s.a.gsap.timeline?c(t[n]):null!==t[n].target&&s.a.gsap.tween.set(t[n].target,{clearProps:"all"});e.clear()}}var s=n(1),l=n(21),f=n(10),p=n(6);t.has=i,t.ensure=o,t.transformOrigins=a,t.generateTimeline=u,t.killTimeline=c;var h=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}},function(e,t,n){"use strict";var r=n(4),i={},o={};t.a=function(e){if(!n.i(r.isBrowser)())return Promise.reject(new Error("Invalid context. jsonLoader can only be used in browser."));if(e in o)return Promise.resolve(o[e]);if(e in i)return i[e];var t=new Promise(function(t,n){var r=new XMLHttpRequest;r.onreadystatechange=function(){if(4===this.readyState&&200===this.status)try{var r=JSON.parse(this.responseText);o[e]=r,t(r),delete i[e]}catch(t){n(new Error("jsonLoader: Invalid json for request "+e))}};try{r.open("GET",encodeURI(e),!0),r.send()}catch(t){n(new Error("Could not open request. Unable to load "+e))}});return i[e]||(i[e]=t),t}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){return function(a){function s(){var e,o;r(this,s);for(var a=arguments.length,c=Array(a),l=0;l<a;l++)c[l]=arguments[l];var f=i(this,(e=s.__proto__||Object.getPrototypeOf(s)).call.apply(e,[this].concat(c)));if(n.i(u.isBrowser)()&&!("Proxy"in window)){var p;return p=f,i(f,p)}return f[Symbol.iterator]=function(){var e=-1,n=this[t];return{next:function(){return{value:n[++e],done:!(e in n)}}}},o=new Proxy(f,{get:function(e,n,r){var i=!1;try{i=Number.isInteger(parseInt(n))}catch(e){}return i?f[t][n]:n===Symbol.iterator?f[Symbol.iterator]:Reflect.get(f,n,r)}}),i(f,o)}return o(s,a),c(s,null,[{key:"name",get:function(){return e.name}}]),s}(e)}var u=n(4);t.a=a;var c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}()},function(e,t,n){"use strict";function r(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=[],i=function(){return!t||t!==e};e.nodeType===window.Node.ELEMENT_NODE&&i();){for(var a=0,u=e.previousSibling;u;u=u.previousSibling)u.nodeType!==window.Node.DOCUMENT_TYPE_NODE&&u.nodeName===e.nodeName&&++a;var c=e.nodeName.toLowerCase(),s="["+(a+1)+"]";n.i(o.isSVG)(e)&&(c="*[local-name()='"+c+"']"),r.unshift(c+s),e=e.parentNode}return 0===r.length?null:t?r.join("/"):"/"+r.join("/")}function i(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;t||(t=document.body);try{var r=document.evaluate(e,t,null,window.XPathResult.ANY_TYPE,null);return r.iterateNext()}catch(e){n.i(a.a)()}return null}var o=n(5),a=n(6);t.getExpression=r,t.getElement=i},function(e,t,n){"use strict";function r(e){return e=e||Object.create(null),{on:function(t,n){(e[t]||(e[t]=[])).push(n)},off:function(t,n){e[t]&&e[t].splice(e[t].indexOf(n)>>>0,1)},emit:function(t,n){(e[t]||[]).map(function(e){e(n)}),(e["*"]||[]).map(function(e){e(t,n)})}}}t.a=r},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";var r=n(0),i=n(1),o=n(11),a=n(9),u=n(12),c=n(22);n.d(t,"version",function(){return s});var s="2.1.3",l=function(){};l.prototype={config:i.a,version:s,setup:o.a,groups:a.a,create:u.a,load:u.b,loadAnimation:c.a},n.d(t,"config",function(){return i.a}),n.d(t,"setup",function(){return o.a}),n.d(t,"groups",function(){return a.a}),n.d(t,"create",function(){return u.a}),n.d(t,"load",function(){return u.b}),n.d(t,"loadAnimation",function(){return c.a});var f=new l;e.exports=f,r.d.isBrowser()&&!window.spirit&&(window.spirit=f)}])});