(window.webpackJsonp=window.webpackJsonp||[]).push([[11],{"2F2M":function(t,e,n){"use strict";n.d(e,"a",(function(){return Yr})),n.d(e,"b",(function(){return Rr})),n.d(e,"c",(function(){return Gr})),n.d(e,"d",(function(){return Kr}));var r=n("TMUO"),i=n("aJ2Q"),o=n("eEGw"),a=n("D9XU"),s=n("c2I6"),u=n("eEvI"),c=n("UqkS"),l=n("Kaa3"),f=n("fGTS"),d=n("gBps"),p=n("7Ici"),v=n("BmB5"),h=(n("jzZ6"),n("FwVG"),n("cVtW")),m=n("xnaF"),g=n("LE4C"),y=n("IGs+"),b=n("/47t"),x=n("NN0J"),O=n("ERkP"),j=n.n(O),E=function(t){return"object"===typeof t&&t.hasOwnProperty("current")},w=function(){function t(){this.subscriptions=new Set}return t.prototype.add=function(t){var e=this;return this.subscriptions.add(t),function(){e.subscriptions.delete(t)}},t.prototype.notify=function(t,e,n){var i,o;if(this.subscriptions.size)try{for(var a=Object(r.f)(this.subscriptions),s=a.next();!s.done;s=a.next()){(0,s.value)(t,e,n)}}catch(u){i={error:u}}finally{try{s&&!s.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}},t.prototype.clear=function(){this.subscriptions.clear()},t}(),C=function(t){return!isNaN(parseFloat(t))},P=function(){function t(t){var e=this;this.timeDelta=0,this.lastUpdated=0,this.updateSubscribers=new w,this.renderSubscribers=new w,this.canTrackVelocity=!1,this.updateAndNotify=function(t,n){void 0===n&&(n=!0),e.prev=e.current,e.current=t,e.prev!==e.current&&e.updateSubscribers.notify(e.current),n&&e.renderSubscribers.notify(e.current);var r=Object(i.c)(),o=r.delta,a=r.timestamp;e.lastUpdated!==a&&(e.timeDelta=o,e.lastUpdated=a,i.b.postRender(e.scheduleVelocityCheck))},this.scheduleVelocityCheck=function(){return i.b.postRender(e.velocityCheck)},this.velocityCheck=function(t){t.timestamp!==e.lastUpdated&&(e.prev=e.current)},this.current=t,this.canTrackVelocity=C(this.current)}return t.prototype.onChange=function(t){return this.updateSubscribers.add(t)},t.prototype.clearListeners=function(){this.updateSubscribers.clear()},t.prototype.onRenderRequest=function(t){return t(this.get()),this.renderSubscribers.add(t)},t.prototype.attach=function(t){this.passiveEffect=t},t.prototype.set=function(t,e){void 0===e&&(e=!0),e&&this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t,e)},t.prototype.get=function(){return this.current},t.prototype.getPrevious=function(){return this.prev},t.prototype.getVelocity=function(){return this.canTrackVelocity?Object(o.a)(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0},t.prototype.start=function(t){var e=this;return this.stop(),new Promise((function(n){e.stopAnimation=t(n)})).then((function(){return e.clearAnimation()}))},t.prototype.stop=function(){this.stopAnimation&&this.stopAnimation(),this.clearAnimation()},t.prototype.isAnimating=function(){return!!this.stopAnimation},t.prototype.clearAnimation=function(){this.stopAnimation=null},t.prototype.destroy=function(){this.updateSubscribers.clear(),this.renderSubscribers.clear(),this.stop()},t}();function A(t){return new P(t)}var S=function(){function t(t,e){var n=this;this.children=new Set,this.isHoverEventsEnabled=!0,this.baseTarget={},this.latest={},this.values=new Map,this.valueSubscriptions=new Map,this.config={},this.isMounted=!1,this.update=function(){return n.config.onUpdate(n.latest)},this.triggerRender=function(){return n.render()},this.ref=function(t){t?n.mount(t):n.unmount(),n.externalRef&&("function"===typeof n.externalRef?n.externalRef(t):E(n.externalRef)&&(n.externalRef.current=t))},this.parent=t,this.rootParent=t?t.rootParent:this,this.treePath=t?Object(r.e)(t.treePath,[t]):[],this.depth=t?t.depth+1:0,this.externalRef=e}return t.prototype.suspendHoverEvents=function(){var t=this;this.isHoverEventsEnabled=!1,i.b.postRender((function(){return setTimeout((function(){return t.isHoverEventsEnabled=!0}),10)}))},t.prototype.getVariantPayload=function(){return this.config.custom},t.prototype.getVariant=function(t){var e;return null===(e=this.config.variants)||void 0===e?void 0:e[t]},t.prototype.addVariantChild=function(t){var e=this;return this.variantChildren||(this.variantChildren=new Set),this.variantChildren.add(t),function(){return e.variantChildren.delete(t)}},t.prototype.addVariantChildOrder=function(t){this.variantChildrenOrder||(this.variantChildrenOrder=new Set),this.variantChildrenOrder.add(t)},t.prototype.onAnimationStart=function(){var t,e;null===(e=(t=this.config).onAnimationStart)||void 0===e||e.call(t)},t.prototype.onAnimationComplete=function(){var t,e;this.isMounted&&(null===(e=(t=this.config).onAnimationComplete)||void 0===e||e.call(t))},t.prototype.getDefaultTransition=function(){return this.config.transition},t.prototype.subscribe=function(t){var e=this;return this.children.add(t),function(){return e.children.delete(t)}},t.prototype.hasValue=function(t){return this.values.has(t)},t.prototype.addValue=function(t,e){this.hasValue(t)&&this.removeValue(t),this.values.set(t,e),this.setSingleStaticValue(t,e.get()),this.subscribeToValue(t,e)},t.prototype.removeValue=function(t){var e;null===(e=this.valueSubscriptions.get(t))||void 0===e||e(),this.valueSubscriptions.delete(t),this.values.delete(t),delete this.latest[t]},t.prototype.getValue=function(t,e){var n=this.values.get(t);return void 0===n&&void 0!==e&&(n=new P(e),this.addValue(t,n)),n},t.prototype.forEachValue=function(t){this.values.forEach(t)},t.prototype.getInstance=function(){return this.element},t.prototype.updateConfig=function(t){void 0===t&&(t={}),this.config=Object(r.a)({},t)},t.prototype.getBaseValue=function(t,e){return this.baseTarget[t]},t.prototype.setSingleStaticValue=function(t,e){this.latest[t]=e},t.prototype.setStaticValues=function(t,e){if("string"===typeof t)this.setSingleStaticValue(t,e);else for(var n in t)this.setSingleStaticValue(n,t[n])},t.prototype.scheduleRender=function(){i.b.render(this.triggerRender,!1,!0)},t.prototype.scheduleUpdateLayoutDelta=function(){i.b.preRender(this.rootParent.updateLayoutDelta,!1,!0)},t.prototype.subscribeToValue=function(t,e){var n=this,r=e.onChange((function(e){n.setSingleStaticValue(t,e),n.element&&n.config.onUpdate&&i.b.update(n.update,!1,!0)})),o=e.onRenderRequest((function(){n.element&&n.scheduleRender()}));this.valueSubscriptions.set(t,(function(){r(),o()}))},t.prototype.mount=function(t){Object(h.a)(!!t,"No ref found. Ensure components created with motion.custom forward refs using React.forwardRef"),this.parent&&(this.removeFromParent=this.parent.subscribe(this)),this.element=this.current=t},t.prototype.unmount=function(){var t=this;this.forEachValue((function(e,n){return t.removeValue(n)})),i.a.update(this.update),i.a.render(this.render),this.removeFromParent&&this.removeFromParent()},t}();function V(t){return t}function B(t){var e=t.top;return{x:{min:t.left,max:t.right},y:{min:e,max:t.bottom}}}function T(t){return{x:Object(r.a)({},t.x),y:Object(r.a)({},t.y)}}var L={translate:0,scale:1,origin:0,originPoint:0};function k(){return{x:Object(r.a)({},L),y:Object(r.a)({},L)}}var M=Object(r.a)(Object(r.a)({},m.b),{transform:Math.round}),R={color:g.a,backgroundColor:g.a,outlineColor:g.a,fill:g.a,stroke:g.a,borderColor:g.a,borderTopColor:g.a,borderRightColor:g.a,borderBottomColor:g.a,borderLeftColor:g.a,borderWidth:y.d,borderTopWidth:y.d,borderRightWidth:y.d,borderBottomWidth:y.d,borderLeftWidth:y.d,borderRadius:y.d,radius:y.d,borderTopLeftRadius:y.d,borderTopRightRadius:y.d,borderBottomRightRadius:y.d,borderBottomLeftRadius:y.d,width:y.d,maxWidth:y.d,height:y.d,maxHeight:y.d,size:y.d,top:y.d,right:y.d,bottom:y.d,left:y.d,padding:y.d,paddingTop:y.d,paddingRight:y.d,paddingBottom:y.d,paddingLeft:y.d,margin:y.d,marginTop:y.d,marginRight:y.d,marginBottom:y.d,marginLeft:y.d,rotate:y.a,rotateX:y.a,rotateY:y.a,rotateZ:y.a,scale:m.c,scaleX:m.c,scaleY:m.c,scaleZ:m.c,skew:y.a,skewX:y.a,skewY:y.a,distance:y.d,translateX:y.d,translateY:y.d,translateZ:y.d,x:y.d,y:y.d,z:y.d,perspective:y.d,transformPerspective:y.d,opacity:m.a,originX:y.c,originY:y.c,originZ:y.d,zIndex:M,filter:b.a,WebkitFilter:b.a,fillOpacity:m.a,strokeOpacity:m.a,numOctaves:M},D=[m.b,y.d,y.b,y.a,y.f,y.e,{test:function(t){return"auto"===t},parse:function(t){return t}}],F=function(t){return function(e){return e.test(t)}},U=function(t){return D.find(F(t))},I=Object(r.e)(D,[g.a,x.a]),H=function(t){return I.find(F(t))},Y=function(t){return R[t]},X=function(t,e){return e&&"number"===typeof t?e.transform(t):t};function z(t,e){var n,r=Y(t);return r!==b.a&&(r=x.a),null===(n=r.getAnimatableNone)||void 0===n?void 0:n.call(r,e)}var W=["","X","Y","Z"],G=["transformPerspective","x","y","z"];function N(t,e){return G.indexOf(t)-G.indexOf(e)}["perspective","translate","scale","rotate","skew"].forEach((function(t){W.forEach((function(e){var n=t+e;G.push(n)}))}));var Z=new Set(G);function K(t){return Z.has(t)}var $=new Set(["originX","originY","originZ"]);function _(t){return $.has(t)}var q={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"};function J(t,e,n){var r=t.x,i=t.y,o="translate3d("+r.translate/e.x+"px, "+i.translate/e.y+"px, 0) ";if(n){var a=n.rotate,s=n.rotateX,u=n.rotateY;a&&(o+="rotate("+a+") "),s&&(o+="rotateX("+s+") "),u&&(o+="rotateY("+u+") ")}return o+="scale("+r.scale+", "+i.scale+")",n||o!==Q?o:""}var Q=J(k(),{x:1,y:1});function tt(t){return t.startsWith("--")}function et(t){return"string"===typeof t&&t.startsWith("var(--")}var nt=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;var rt=4;function it(t,e,n){void 0===n&&(n=1),Object(h.a)(n<=rt,'Max CSS variable fallback depth detected in property "'+t+'". This may indicate a circular fallback dependency.');var i=Object(r.c)(function(t){var e=nt.exec(t);if(!e)return[,];var n=Object(r.c)(e,3);return[n[1],n[2]]}(t),2),o=i[0],a=i[1];if(o){var s=window.getComputedStyle(e).getPropertyValue(o);return s?s.trim():et(a)?it(a,e,n+1):a}}function ot(t,e){return t/(e.max-e.min)*100}var at="_$css";var st={process:function(t,e){if("string"===typeof t){if(!y.d.test(t))return t;t=parseFloat(t)}return ot(t,e.x)+"% "+ot(t,e.y)+"%"}},ut={borderRadius:Object(r.a)(Object(r.a)({},st),{applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]}),borderTopLeftRadius:st,borderTopRightRadius:st,borderBottomLeftRadius:st,borderBottomRightRadius:st,boxShadow:{process:function(t,e,n,r){var i=t,o=t.includes("var("),s=[];o&&(t=t.replace(nt,(function(t){return s.push(t),at})));var u=x.a.parse(t);if(u.length>5)return i;var c=x.a.createTransformer(t),l="number"!==typeof u[0]?1:0,f=n.x.scale*r.x,d=n.y.scale*r.y;u[0+l]/=f,u[1+l]/=d;var p=Object(a.a)(f,d,.5);"number"===typeof u[2+l]&&(u[2+l]/=p),"number"===typeof u[3+l]&&(u[3+l]/=p);var v=c(u);if(o){var h=0;v=v.replace(at,(function(){var t=s[h];return h++,t}))}return v}}};function ct(t,e,n,r,i,o,a,s,u,c,l,f){var d=a.enableHardwareAcceleration,p=a.transformTemplate,v=a.allowTransformNone;o.length=0;var h=!1,m=!1,g=!0;for(var y in t){var b=t[y],x=Y(y),O=X(b,x);if(K(y)){if(h=!0,r[y]=O,o.push(y),!g)continue;b!==(void 0!==x.default?x.default:0)&&(g=!1)}else if(_(y))i[y]=O,m=!0;else if("transform"!==y||"function"!==typeof b){var j=tt(y)?n:e;if(s&&ut[y]){var E=ut[y].process(b,f,u,l),w=ut[y].applyTo;if(w)for(var C=w.length,P=0;Pr?n=Object(c.a)(e.min,e.max-r,t.min):r>i&&(n=Object(c.a)(t.min,t.max-i,e.min)),xt(n)}function wt(t,e,n,r){t.origin=void 0===r?Et(e,n):r,t.originPoint=Object(a.a)(e.min,e.max,t.origin),t.scale=jt(n)/jt(e),Ot(t.scale,1,1e-4)&&(t.scale=1),t.translate=Object(a.a)(n.min,n.max,t.origin)-t.originPoint,Ot(t.translate)&&(t.translate=0)}function Ct(t,e,n,r){wt(t.x,e.x,n.x,r),wt(t.y,e.y,n.y,r)}function Pt(t){return[t("x"),t("y")]}function At(t,e){return B(function(t,e){var n=t.top,r=t.left,i=t.bottom,o=t.right;void 0===e&&(e=V);var a=e({x:r,y:n}),s=e({x:o,y:i});return{top:a.y,left:a.x,bottom:s.y,right:s.x}}(t.getBoundingClientRect(),e))}var St,Vt=function(t){return Array.isArray(t)},Bt=new Set(["width","height","top","left","right","bottom","x","y"]),Tt=function(t){return Bt.has(t)},Lt=function(t){return Object.keys(t).some(Tt)},kt=function(t,e){t.set(e,!1),t.set(e)},Mt=function(t){return t===m.b||t===y.d};!function(t){t.width="width",t.height="height",t.left="left",t.right="right",t.top="top",t.bottom="bottom"}(St||(St={}));var Rt=function(t,e){return parseFloat(t.split(", ")[e])},Dt=function(t,e){return function(n,r){var i=r.transform;if("none"===i||!i)return 0;var o=i.match(/^matrix3d\((.+)\)$/);if(o)return Rt(o[1],e);var a=i.match(/^matrix\((.+)\)$/);return a?Rt(a[1],t):0}},Ft=new Set(["x","y","z"]),Ut=G.filter((function(t){return!Ft.has(t)}));var It={width:function(t){var e=t.x;return e.max-e.min},height:function(t){var e=t.y;return e.max-e.min},top:function(t,e){var n=e.top;return parseFloat(n)},left:function(t,e){var n=e.left;return parseFloat(n)},bottom:function(t,e){var n=t.y,r=e.top;return parseFloat(r)+(n.max-n.min)},right:function(t,e){var n=t.x,r=e.left;return parseFloat(r)+(n.max-n.min)},x:Dt(4,13),y:Dt(5,14)},Ht=function(t,e,n,i){void 0===n&&(n={}),void 0===i&&(i={}),e=Object(r.a)({},e),i=Object(r.a)({},i);var o=Object.keys(e).filter(Tt),a=[],s=!1,u=[];if(o.forEach((function(r){var o=t.getValue(r);if(t.hasValue(r)){var c,l=n[r],f=e[r],d=U(l);if(Vt(f))for(var p=f.length,v=null===f[0]?1:0;v=3;if(e||n){var a=t.point,s=Object(i.c)().timestamp;o.history.push(Object(r.a)(Object(r.a)({},a),{timestamp:s}));var c=o.handlers,l=c.onStart,f=c.onMove;e||(l&&l(o.lastMoveEvent,t),o.startEvent=o.lastMoveEvent),f&&f(o.lastMoveEvent,t)}}},this.handlePointerMove=function(t,e){o.lastMoveEvent=t,o.lastMoveEventInfo=ze(e,o.transformPagePoint),we(t)&&0===t.buttons?o.handlePointerUp(t,e):i.b.update(o.updatePoint,!0)},this.handlePointerUp=function(t,e){o.end();var n=o.handlers.onEnd;if(n){var r=Ge(ze(e,o.transformPagePoint),o.history);n&&n(t,r)}},!(Ce(t)&&t.touches.length>1)){this.handlers=e,this.transformPagePoint=a;var s=ze(Ve(t),this.transformPagePoint),c=s.point,f=Object(i.c)().timestamp;this.history=[Object(r.a)(Object(r.a)({},c),{timestamp:f})];var d=e.onSessionStart;d&&d(t,Ge(s,this.history)),this.removeListeners=Object(l.a)(Ie(window,"pointermove",this.handlePointerMove),Ie(window,"pointerup",this.handlePointerUp),Ie(window,"pointercancel",this.handlePointerUp))}}return t.prototype.updateHandlers=function(t){this.handlers=t},t.prototype.end=function(){this.removeListeners&&this.removeListeners(),i.a.update(this.updatePoint)},t}();function ze(t,e){return e?{point:e(t.point)}:t}function We(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Ge(t,e){var n=t.point;return{point:n,delta:We(n,Ze(e)),offset:We(n,Ne(e)),velocity:Ke(e,.1)}}function Ne(t){return t[0]}function Ze(t){return t[t.length-1]}function Ke(t,e){if(t.length<2)return{x:0,y:0};for(var n=t.length-1,r=null,i=Ze(t);n>=0&&(r=t[n],!(i.timestamp-r.timestamp>Ye(e)));)n--;if(!r)return{x:0,y:0};var o=(i.timestamp-r.timestamp)/1e3;if(0===o)return{x:0,y:0};var a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}var $e=function(t,e){return!!e&&(t===e||$e(t,e.parentElement))},_e={linear:f.n,easeIn:f.k,easeInOut:f.l,easeOut:f.m,circIn:f.h,circInOut:f.i,circOut:f.j,backIn:f.b,backInOut:f.c,backOut:f.d,anticipate:f.a,bounceIn:f.e,bounceInOut:f.f,bounceOut:f.g},qe=function(t){if(Array.isArray(t)){Object(h.a)(4===t.length,"Cubic bezier arrays must contain four numerical values.");var e=Object(r.c)(t,4),n=e[0],i=e[1],o=e[2],a=e[3];return Object(d.a)(n,i,o,a)}return"string"===typeof t?(Object(h.a)(void 0!==_e[t],"Invalid easing type '"+t+"'"),_e[t]):t},Je=function(t){return Array.isArray(t)&&"number"!==typeof t[0]},Qe=function(t,e){return"zIndex"!==t&&(!("number"!==typeof e&&!Array.isArray(e))||!("string"!==typeof e||!x.a.test(e)||e.startsWith("url(")))},tn=function(){return{type:"spring",stiffness:500,damping:25,restDelta:.5,restSpeed:10}},en=function(t){return{type:"spring",stiffness:550,damping:0===t?100:30,restDelta:.01,restSpeed:10}},nn=function(){return{type:"keyframes",ease:"linear",duration:.3}},rn=function(t){return{type:"keyframes",duration:.8,values:t}},on={x:tn,y:tn,z:tn,rotate:tn,rotateX:tn,rotateY:tn,rotateZ:tn,scaleX:en,scaleY:en,scale:en,opacity:nn,backgroundColor:nn,color:nn,default:en},an=function(t,e){var n;return n=Vt(e)?rn:on[t]||on.default,Object(r.a)({to:e},n(e))};var sn=!1;function un(t,e,n){var i;return Array.isArray(e.to)&&(null!==(i=t.duration)&&void 0!==i||(t.duration=.8)),function(t){Array.isArray(t.to)&&null===t.to[0]&&(t.to=Object(r.e)(t.to),t.to[0]=t.from)}(e),function(t){t.when,t.delay,t.delayChildren,t.staggerChildren,t.staggerDirection,t.repeat,t.repeatType,t.repeatDelay,t.from;var e=Object(r.d)(t,["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from"]);return!!Object.keys(e).length}(t)||(t=Object(r.a)(Object(r.a)({},t),an(n,e.to))),Object(r.a)(Object(r.a)({},e),function(t){var e=t.ease,n=t.times,i=t.yoyo,o=t.flip,a=t.loop,s=Object(r.d)(t,["ease","times","yoyo","flip","loop"]),u=Object(r.a)({},s);return n&&(u.offset=n),s.duration&&(u.duration=Ye(s.duration)),s.repeatDelay&&(u.repeatDelay=Ye(s.repeatDelay)),e&&(u.ease=Je(e)?e.map(qe):qe(e)),"tween"===s.type&&(u.type="keyframes"),(i||a||o)&&(Object(h.b)(!sn,"yoyo, loop and flip have been removed from the API. Replace with repeat and repeatType options."),sn=!0,i?u.repeatType="reverse":a?u.repeatType="loop":o&&(u.repeatType="mirror"),u.repeat=a||i||o||s.repeat),"spring"!==s.type&&(u.type="keyframes"),u}(t))}function cn(t,e,n,i){return void 0===i&&(i={}),e.start((function(o){var a,s,u=function(t,e,n,i,o){var a,s=function(t,e){return t[e]||t.default||t}(i,t),u=null!==(a=s.from)&&void 0!==a?a:e.get(),c=Qe(t,n);"none"===u&&c&&"string"===typeof n&&(u=z(t,n));var l=Qe(t,u);return Object(h.b)(l===c,"You are trying to animate "+t+' from "'+u+'" to "'+n+'". '+u+" is not an animatable value - to enable this animation set "+u+" to a value animatable to "+n+" via the `style` property."),l&&c&&!1!==s.type?function(){var i={from:u,to:n,velocity:e.getVelocity(),onComplete:o,onUpdate:function(t){return e.set(t)}};return"inertia"===s.type||"decay"===s.type?Object(p.a)(Object(r.a)(Object(r.a)({},i),s)):Object(v.a)(Object(r.a)(Object(r.a)({},un(s,i,t)),{onUpdate:function(t){var e;i.onUpdate(t),null===(e=s.onUpdate)||void 0===e||e.call(s,t)},onComplete:function(){var t;i.onComplete(),null===(t=s.onComplete)||void 0===t||t.call(s)}}))}:function(){var t;return e.set(n),o(),null===(t=null===s||void 0===s?void 0:s.onComplete)||void 0===t||t.call(s),{stop:function(){}}}}(t,e,n,i,o),c=function(t,e){var n,r,i,o,a;return null!==(a=null!==(o=null!==(r=null===(n=t[e])||void 0===n?void 0:n.delay)&&void 0!==r?r:null===(i=t.default)||void 0===i?void 0:i.delay)&&void 0!==o?o:t.delay)&&void 0!==a?a:0}(i,t),l=function(){return s=u()};return c?a=setTimeout(l,Ye(c)):l(),function(){clearTimeout(a),null===s||void 0===s||s.stop()}}))}function ln(t,e,n){var r;if(t.onAnimationStart(),Array.isArray(e)){var i=e.map((function(e){return fn(t,e,n)}));r=Promise.all(i)}else r="string"===typeof e?fn(t,e,n):dn(t,e,n);return r.then((function(){return t.onAnimationComplete()}))}function fn(t,e,n){var i;void 0===n&&(n={});var o=Gt(t,e,n.custom),a=(o||{}).transition,s=void 0===a?t.getDefaultTransition()||{}:a;n.transitionOverride&&(s=n.transitionOverride);var u=o?function(){return dn(t,o,n)}:function(){return Promise.resolve()},c=(null===(i=t.variantChildrenOrder)||void 0===i?void 0:i.size)?function(i){void 0===i&&(i=0);var o=s.delayChildren,a=void 0===o?0:o,u=s.staggerChildren,c=s.staggerDirection;return function(t,e,n,i,o,a){void 0===n&&(n=0);void 0===i&&(i=0);void 0===o&&(o=1);var s=[],u=(t.variantChildrenOrder.size-1)*i,c=1===o?function(t){return void 0===t&&(t=0),t*i}:function(t){return void 0===t&&(t=0),u-t*i};return Array.from(t.variantChildrenOrder).forEach((function(t,i){var o=fn(t,e,Object(r.a)(Object(r.a)({},a),{delay:n+c(i)}));s.push(o)})),Promise.all(s)}(t,e,a+i,u,c,n)}:function(){return Promise.resolve()},l=s.when;if(l){var f=Object(r.c)("beforeChildren"===l?[u,c]:[c,u],2),d=f[0],p=f[1];return d().then(p)}return Promise.all([u(),c(n.delay)])}function dn(t,e,n){var i,o=void 0===n?{}:n,a=o.delay,s=void 0===a?0:a,u=o.transitionOverride,c=o.type,l=t.makeTargetAnimatable(e),f=l.transition,d=void 0===f?t.getDefaultTransition():f,p=l.transitionEnd,v=Object(r.d)(l,["transition","transitionEnd"]);u&&(d=u);var h=[],m=c&&(null===(i=t.animationState)||void 0===i?void 0:i.getProtectedKeys(c));for(var g in v){var y=t.getValue(g),b=v[g];if(y&&void 0!==b&&void 0===(null===m||void 0===m?void 0:m[g])){var x=cn(g,y,b,Object(r.a)({delay:s},d));h.push(x)}}return Promise.all(h).then((function(){p&&Zt(t,p)}))}var pn,vn=function(){function t(){this.hasMounted=!1,this.pendingAnimations=[],this.subscribers=new Set}return t.prototype.subscribe=function(t){var e=this;return this.subscribers.add(t),function(){return e.subscribers.delete(t)}},t.prototype.start=function(t,e){var n=this;if(this.hasMounted){var r=[];return this.subscribers.forEach((function(n){r.push(ln(n,t,{transitionOverride:e}))})),Promise.all(r)}return new Promise((function(r){n.pendingAnimations.push({animation:[t,e],resolve:r})}))},t.prototype.set=function(t){return Object(h.a)(this.hasMounted,"controls.set() should only be called after a component has mounted. Consider calling within a useEffect hook."),this.subscribers.forEach((function(e){$t(e,t)}))},t.prototype.stop=function(){this.subscribers.forEach((function(t){!function(t){t.forEachValue((function(t){return t.stop()}))}(t)}))},t.prototype.mount=function(){var t=this;this.hasMounted=!0,this.pendingAnimations.forEach((function(e){var n=e.animation,i=e.resolve;t.start.apply(t,Object(r.e)(n)).then(i)}))},t.prototype.unmount=function(){this.hasMounted=!1,this.stop()},t}();!function(t){t.Animate="animate",t.Hover="whileHover",t.Tap="whileTap",t.Drag="whileDrag",t.Focus="whileFocus",t.Exit="exit"}(pn||(pn={}));var hn=[pn.Animate,pn.Hover,pn.Tap,pn.Drag,pn.Focus,pn.Exit],mn=Object(r.e)(hn).reverse(),gn=hn.length;function yn(t){var e,n,i=function(t){return function(e){return Promise.all(e.map((function(e){var n=e.animation,r=e.options;return ln(t,n,r)})))}}(t),o=function(){var t;return(t={})[pn.Animate]=bn(!0),t[pn.Hover]=bn(),t[pn.Tap]=bn(),t[pn.Drag]=bn(),t[pn.Focus]=bn(),t[pn.Exit]=bn(),t}(),a=!0,s=function(e,n){var i=Gt(t,n);if(i){i.transition;var o=i.transitionEnd,a=Object(r.d)(i,["transition","transitionEnd"]);e=Object(r.a)(Object(r.a)(Object(r.a)({},e),a),o)}return e};function u(u,c,l,f){void 0===c&&(c={}),e=u,n=c;var d=[],p=new Set,v={};u.variants&&t.updateConfig(Object(r.a)(Object(r.a)({},t.config),{variants:u.variants}));for(var h=1/0,m=function(e){var n,i=mn[e],m=o[i],g=null!==(w=u[i])&&void 0!==w?w:c[i],y="string"===typeof(n=g)||Wt(n),b=i===f?m.isActive:null;!1===b&&(h=e);var x=g===c[i]&&y;if(x&&a&&t.manuallyAnimateOnMount&&(x=!1),a&&i===pn.Animate&&t.prevSnapshot&&(a=!1,m.prevResolvedValues=t.prevSnapshot),m.protectedKeys=Object(r.a)({},v),!m.isActive&&null===b||!g&&!m.prevProp||g instanceof vn||"boolean"===typeof g)return"continue";var O=function(t,e){if("string"===typeof e)return e!==t;if(Wt(e))return!function(t,e){if(!Array.isArray(e))return!1;var n=e.length;if(n!==t.length)return!1;for(var r=0;rh&&y,j=Array.isArray(g)?g:[g],E=j.reduce(s,{});!1===b&&(E={});var w=m.prevResolvedValues,C=void 0===w?{}:w,P=Object(r.a)(Object(r.a)({},C),E);for(var A in P){var S=E[A],V=C[A];v.hasOwnProperty(A)||(S!==V?void 0!==S?(O=!0,p.delete(A)):p.add(A):void 0!==S&&p.has(A)?(O=!0,p.delete(A)):m.protectedKeys[A]=!0)}m.prevProp=g,m.prevResolvedValues=E,m.isActive&&(v=Object(r.a)(Object(r.a)({},v),E)),O&&!x&&d.push.apply(d,Object(r.e)(j.map((function(t){return{animation:t,options:Object(r.a)({type:i},l)}}))))},g=0;gi&&(t=n?Object(a.a)(i,t,n):Math.min(t,i)),t}function sr(t,e,n){return{min:void 0!==e?t.min+e:void 0,max:void 0!==n?t.max+n-(t.max-t.min):void 0}}function ur(t,e){var n,i=e.min-t.min,o=e.max-t.max;return e.max-e.mine?n="y":Math.abs(t.x)>e&&(n="x");return n}(l),void(null!==n.currentDirection&&(null===(i=(r=n.props).onDirectionLock)||void 0===i||i.call(r,n.currentDirection)));n.updateAxis("x",t,l),n.updateAxis("y",t,l),null===(a=(o=n.props).onDrag)||void 0===a||a.call(o,t,e),cr=t}},onEnd:function(t,e){return n.stop(t,e)}},{transformPagePoint:s})},t.prototype.prepareBoundingBox=function(){var t=this.visualElement;t.withoutTransform((function(){t.measureLayout()})),t.rebaseTargetBox(!0,t.getBoundingBoxWithoutTransforms())},t.prototype.resolveDragConstraints=function(){var t=this,e=this.props.dragConstraints;this.constraints=!!e&&(E(e)?this.resolveRefConstraints(this.visualElement.box,e):function(t,e){var n=e.top,r=e.left,i=e.bottom,o=e.right;return{x:sr(t.x,r,o),y:sr(t.y,n,i)}}(this.visualElement.box,e)),this.constraints&&!this.hasMutatedConstraints&&Pt((function(e){t.getAxisMotionValue(e)&&(t.constraints[e]=function(t,e){var n={};return void 0!==e.min&&(n.min=e.min-t.min),void 0!==e.max&&(n.max=e.max-t.min),n}(t.visualElement.box[e],t.constraints[e]))}))},t.prototype.resolveRefConstraints=function(t,e){var n=this.props,r=n.onMeasureDragConstraints,i=n.transformPagePoint,o=e.current;Object(h.a)(null!==o,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop."),this.constraintsBox=At(o,i);var a=function(t,e){return{x:ur(t.x,e.x),y:ur(t.y,e.y)}}(t,this.constraintsBox);if(r){var s=r(function(t){var e=t.x,n=t.y;return{top:n.min,bottom:n.max,left:e.min,right:e.max}}(a));this.hasMutatedConstraints=!!s,s&&(a=B(s))}return a},t.prototype.cancelDrag=function(){var t;this.isDragging=!1,this.panSession&&this.panSession.end(),this.panSession=null,!this.props.dragPropagation&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),null===(t=this.visualElement.animationState)||void 0===t||t.setActive(pn.Drag,!1)},t.prototype.stop=function(t,e){var n;this.visualElement.unlockTargetBox(),null===(n=this.panSession)||void 0===n||n.end(),this.panSession=null;var r=this.isDragging;if(this.cancelDrag(),r){var i=this.props,o=i.dragMomentum,a=i.dragElastic,s=i.onDragEnd;if(o||a){var u=e.velocity;this.animateDragEnd(u)}null===s||void 0===s||s(t,e)}},t.prototype.snapToCursor=function(t){var e=this;this.prepareBoundingBox(),Pt((function(n){if(dr(n,e.props.drag,e.currentDirection)){var r=e.getAxisMotionValue(n);if(r){var i=Be(t).point,o=e.visualElement.box,a=o[n].max-o[n].min,s=o[n].min+a/2,u=i[n]-s;e.originPoint[n]=i[n],r.set(u)}else e.cursorProgress[n]=.5,e.updateVisualElementAxis(n,t)}}))},t.prototype.updateAxis=function(t,e,n){if(dr(t,this.props.drag,this.currentDirection))return this.getAxisMotionValue(t)?this.updateAxisMotionValue(t,n):this.updateVisualElementAxis(t,e)},t.prototype.updateAxisMotionValue=function(t,e){var n=this.getAxisMotionValue(t);if(e&&n){var r=this.props.dragElastic,i=this.originPoint[t]+e[t],o=this.constraints?ar(i,this.constraints[t],r):i;n.set(o)}},t.prototype.updateVisualElementAxis=function(t,e){var n,r=this.props.dragElastic,i=this.visualElement.box[t],o=i.max-i.min,a=this.cursorProgress[t],s=function(t,e,n,r,i){var o=t-e*n;return r?ar(o,r,i):o}(Be(e).point[t],o,a,null===(n=this.constraints)||void 0===n?void 0:n[t],r);this.visualElement.setAxisTarget(t,s,s+o)},t.prototype.updateProps=function(t){var e=t.drag,n=void 0!==e&&e,i=t.dragDirectionLock,o=void 0!==i&&i,a=t.dragPropagation,s=void 0!==a&&a,u=t.dragConstraints,c=void 0!==u&&u,l=t.dragElastic,f=void 0===l?.35:l,d=t.dragMomentum,p=void 0===d||d,v=Object(r.d)(t,["drag","dragDirectionLock","dragPropagation","dragConstraints","dragElastic","dragMomentum"]);this.props=Object(r.a)({drag:n,dragDirectionLock:o,dragPropagation:s,dragConstraints:c,dragElastic:f,dragMomentum:p},v)},t.prototype.getAxisMotionValue=function(t){var e=this.props,n=e.layout,r=e.layoutId,i="_drag"+t.toUpperCase();return this.props[i]?this.props[i]:n||void 0!==r?void 0:this.visualElement.getValue(t,0)},t.prototype.animateDragEnd=function(t){var e=this,n=this.props,i=n.drag,o=n.dragMomentum,a=n.dragElastic,s=n.dragTransition,u=Pt((function(n){if(dr(n,i,e.currentDirection)){var u=e.constraints?e.constraints[n]:{},c=a?200:1e6,l=a?40:1e7,f=Object(r.a)(Object(r.a)({type:"inertia",velocity:o?t[n]:0,bounceStiffness:c,bounceDamping:l,timeConstant:750,restDelta:1,restSpeed:10},s),u);return e.getAxisMotionValue(n)?e.startAxisValueAnimation(n,f):e.visualElement.startLayoutAxisAnimation(n,f)}}));return Promise.all(u).then((function(){var t,n;null===(n=(t=e.props).onDragTransitionEnd)||void 0===n||n.call(t)}))},t.prototype.stopMotion=function(){var t=this;Pt((function(e){var n=t.getAxisMotionValue(e);n?n.stop():t.visualElement.stopLayoutAnimation()}))},t.prototype.startAxisValueAnimation=function(t,e){var n=this.getAxisMotionValue(t);if(n){var r=n.get();return n.set(r),n.set(r),cn(t,n,0,e)}},t.prototype.scalePoint=function(){var t=this,e=this.props,n=e.drag,r=e.dragConstraints;if(E(r)&&this.constraintsBox){this.stopMotion();var i={x:0,y:0};Pt((function(e){i[e]=Et(t.visualElement.targetBox[e],t.constraintsBox[e])})),this.prepareBoundingBox(),this.resolveDragConstraints(),Pt((function(e){if(dr(e,n,null)){var r=function(t,e,n){var r=t.max-t.min,i=Object(a.a)(e.min,e.max-r,n);return{min:i,max:i+r}}(t.visualElement.targetBox[e],t.constraintsBox[e],i[e]),o=r.min,s=r.max;t.visualElement.setAxisTarget(e,o,s)}}))}},t.prototype.mount=function(t){var e=this,n=Ie(t.getInstance(),"pointerdown",(function(t){var n=e.props,r=n.drag,i=n.dragListener;r&&(void 0===i||i)&&e.start(t)})),r=je(window,"resize",(function(){e.scalePoint()})),i=t.onLayoutUpdate((function(){e.isDragging&&e.resolveDragConstraints()})),o=t.prevSnapshot;return(null===o||void 0===o?void 0:o.isDragging)&&this.start(cr,{cursorProgress:o.cursorProgress}),function(){null===n||void 0===n||n(),null===r||void 0===r||r(),null===i||void 0===i||i(),e.cancelDrag()}},t}();function dr(t,e,n){return(!0===e||e===t)&&(null===n||n===t)}var pr=An((function(t){var e=t.visualElement;return function(t,e){var n=t.dragControls,i=Object(O.useContext)(xe).transformPagePoint,o=ne((function(){return new fr({visualElement:e})}));o.updateProps(Object(r.a)(Object(r.a)({},t),{transformPagePoint:i})),Object(O.useEffect)((function(){return n&&n.subscribe(o)}),[o]),Object(O.useEffect)((function(){return o.mount(e)}),[])}(Object(r.d)(t,["visualElement"]),e)})),vr={key:"drag",shouldRender:function(t){return!!t.drag||!!t.dragControls},getComponent:function(){return pr}},hr=An((function(t){var e=t.custom,n=t.visualElement,i=Object(r.c)(Kn(),2),o=i[0],a=i[1],s=Object(O.useContext)(he);Object(O.useEffect)((function(){var t,r,i=null===(t=n.animationState)||void 0===t?void 0:t.setActive(pn.Exit,!o,{custom:null!==(r=null===s||void 0===s?void 0:s.custom)&&void 0!==r?r:e});!o&&(null===i||void 0===i||i.then(a))}),[o])})),mr={key:"exit",shouldRender:function(t){return!!t.exit&&!tr(t)},getComponent:function(){return hr}};var gr=An((function(t){var e=t.visualElement,n=t.animate;e.animationState||(e.animationState=yn(e));var r=ge();Object(O.useEffect)((function(){e.animationState.setProps(t,e.inheritsVariants?r:void 0)})),n instanceof vn&&function(t,e){var n=Object(O.useMemo)((function(){return e.subscribe(t)}),[e]);Oe((function(){return null===n||void 0===n?void 0:n()}))}(e,n)})),yr={key:"animation",shouldRender:function(){return!0},getComponent:function(t){var e=t.animate,n=t.whileHover,r=t.whileFocus,i=t.whileTap,o=t.whileDrag,a=t.exit,s=t.variants;return e||n||r||i||o||a||s?gr:void 0}};var br=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.frameTarget={x:{min:0,max:0},y:{min:0,max:0}},e.stopAxisAnimation={x:void 0,y:void 0},e.animate=function(t,n,i){void 0===i&&(i={});var o=i.originBox,a=i.targetBox,s=i.visibilityAction,u=i.shouldStackAnimate,c=Object(r.d)(i,["originBox","targetBox","visibilityAction","shouldStackAnimate"]),l=e.props,f=l.visualElement,d=l.layout;if(!1===u)return e.safeToRemove();var p,v,h=(v=t=a||t,!jr(p=n=o||n)&&!jr(v)&&(!Er(p.x,v.x)||!Er(p.y,v.y))),m=Pt((function(r){if("position"===d){var i=t[r].max-t[r].min;n[r].max=n[r].min+i}if(!f.isTargetBoxLocked)return void 0===s?h?e.animateAxis(r,t[r],n[r],c):f.setAxisTarget(r,t[r].min,t[r].max):void(s===Un.Hide?f.hide():f.show())}));return f.render(),Promise.all(m).then((function(){var t,n;null===(n=(t=e.props).onLayoutAnimationComplete)||void 0===n||n.call(t),f.isPresent?f.presence=Fn.Present:e.safeToRemove()}))},e}return Object(r.b)(e,t),e.prototype.componentDidMount=function(){var t=this,e=this.props.visualElement;e.animateMotionValue=cn,e.enableLayoutProjection(),this.unsubLayoutReady=e.onLayoutUpdate(this.animate),e.updateConfig(Object(r.a)(Object(r.a)({},e.config),{safeToRemove:function(){return t.safeToRemove()}}))},e.prototype.componentWillUnmount=function(){var t=this;this.unsubLayoutReady(),Pt((function(e){var n,r;return null===(r=(n=t.stopAxisAnimation)[e])||void 0===r?void 0:r.call(n)}))},e.prototype.animateAxis=function(t,e,n,r){var i,o,s=void 0===r?{}:r,u=s.transition,c=s.crossfadeOpacity;null===(o=(i=this.stopAxisAnimation)[t])||void 0===o||o.call(i);var l,f=this.props.visualElement,d=this.frameTarget[t],p=f.getAxisProgress()[t];p.clearListeners(),p.set(0),p.set(0),c&&(l=this.createCrossfadeAnimation(c),f.show());var v=function(){var r=p.get()/1e3;!function(t,e,n,r){t.min=Object(a.a)(e.min,n.min,r),t.max=Object(a.a)(e.max,n.max,r)}(d,n,e,r),f.setAxisTarget(t,d.min,d.max),null===l||void 0===l||l(r)};v(),f.updateLayoutDelta();var h=p.onChange(v),m=cn("x"===t?"layoutX":"layoutY",p,1e3,u||this.props.transition||wr).then(h);return this.stopAxisAnimation[t]=function(){p.stop(),h()},m},e.prototype.createCrossfadeAnimation=function(t){var e=this.props.visualElement.getValue("opacity",0);return function(n){e.set(Pr(Object(a.a)(0,1,n))),t.set(Ar(Object(a.a)(1,0,n)))}},e.prototype.safeToRemove=function(){var t,e;null===(e=(t=this.props).safeToRemove)||void 0===e||e.call(t)},e.prototype.render=function(){return null},e}(O.Component);function xr(t){var e=Object(r.c)(Kn(),2)[1];return Object(O.createElement)(br,Object(r.a)({},t,{safeToRemove:e}))}var Or={min:0,max:0};function jr(t){return Er(t.x,Or)&&Er(t.y,Or)}function Er(t,e){return t.min===e.min&&t.max===e.max}var wr={duration:.45,ease:[.4,0,.1,1]};function Cr(t,e,n){return function(r){return re?1:n(Object(c.a)(t,e,r))}}var Pr=Cr(0,.5,f.j),Ar=Cr(.5,.95,f.n),Sr={key:"animate-layout",shouldRender:function(t){return!!t.layout||!!t.layoutId},getComponent:function(){return xr}},Vr=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.b)(e,t),e.prototype.componentDidMount=function(){var t=this.props,e=t.syncLayout,n=t.framerSyncLayout,r=t.visualElement;Wn(e)&&e.register(r),Wn(n)&&n.register(r)},e.prototype.getSnapshotBeforeUpdate=function(){var t=this.props,e=t.syncLayout,n=t.visualElement;return Wn(e)?e.syncUpdate():(n.snapshotBoundingBox(),e.add(n)),null},e.prototype.componentDidUpdate=function(){var t=this.props,e=t.syncLayout,n=t.visualElement;Wn(e)||e.flush(),n.rebaseTargetBox()},e.prototype.render=function(){return null},e}(j.a.Component);function Br(t){var e=Object(O.useContext)(Gn),n=Object(O.useContext)(Nn);return j.a.createElement(Vr,Object(r.a)({},t,{syncLayout:e,framerSyncLayout:n}))}var Tr={key:"measure-layout",shouldRender:function(t){return!!t.drag||!!t.layout||!!t.layoutId},getComponent:function(){return Br}},Lr=[Tr,yr,vr,Bn,mr,Sr],kr={useVisualElement:function(t,e,n,i){var o=ye(),a=ne((function(){return new(ve(t)?de:te)(o,i)}));n&&(a.values.clear(),a.latest={}),a.updateConfig(Object(r.a)(Object(r.a)(Object(r.a)({},a.config),{enableHardwareAcceleration:!n}),e));var s=Object(O.useContext)(be);a.layoutId=s&&e.layoutId?s+"-"+e.layoutId:e.layoutId;var u=Object(O.useContext)(he),c=null===u||u.isPresent;a.isPresent=void 0!==e.isPresent?e.isPresent:c;var l=null===u||void 0===u?void 0:u.id;return a.isPresenceRoot=!o||o.presenceId!==l,Object(O.useEffect)((function(){if(e.onViewportBoxUpdate)return a.onViewportBoxUpdate(e.onViewportBoxUpdate)}),[e.onViewportBoxUpdate]),a},useRender:function(t,e,n){var i="string"===typeof t?function(t){var e={};for(var n in t)kn(n)&&(e[n]=t[n]);return e}(e):e;n.clean(),n.build();var o=ve(t)?function(t){return Object(r.a)(Object(r.a)({},t.attrs),{style:Object(r.a)({},t.reactStyle)})}(n):function(t,e){var n=e.drag,i={},o=Object(r.a)(Object(r.a)(Object(r.a)({},t.reactStyle),t.style),t.vars);return n&&(i.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===n?"none":"pan-"+("x"===n?"y":"x")),i.style=o,i}(n,e);return Object(O.createElement)(t,Object(r.a)(Object(r.a)(Object(r.a)({},i),{ref:n.ref}),o))}};function Mr(t){var e=Object(r.a)(Object(r.a)({},kr),{defaultFeatures:t});var n=new Map;return new Proxy({custom:function(t){return or(t,e)}},{get:function(t,r){return"custom"===r?t.custom:(n.has(r)||n.set(r,or(r,e)),n.get(r))}})}var Rr=Mr(Lr);var Dr=0;function Fr(){var t=Dr;return Dr++,t}var Ur=function(t){var e=t.children,n=t.initial,r=t.isPresent,i=t.onExitComplete,o=t.custom,a=t.presenceAffectsLayout,s=ne(Ir),u=ne(Fr),c=Object(O.useMemo)((function(){return{id:u,initial:n,isPresent:r,custom:o,onExitComplete:function(t){s.set(t,!0);var e=!0;s.forEach((function(t){t||(e=!1)})),e&&(null===i||void 0===i||i())},register:function(t){return s.set(t,!1),function(){return s.delete(t)}}}}),a?void 0:[r]);return Object(O.useMemo)((function(){s.forEach((function(t,e){return s.set(e,!1)}))}),[r]),Object(O.createElement)(he.Provider,{value:c},e)};function Ir(){return new Map}function Hr(t){return t.key||""}var Yr=function(t){var e=t.children,n=t.custom,i=t.initial,o=void 0===i||i,a=t.onExitComplete,s=t.exitBeforeEnter,u=t.presenceAffectsLayout,c=void 0===u||u,l=function(){var t=Object(O.useRef)(!1),e=Object(r.c)(Object(O.useState)(0),2),n=e[0],i=e[1];return Oe((function(){return t.current=!0})),Object(O.useCallback)((function(){!t.current&&i(n+1)}),[n])}(),f=Object(O.useContext)(Gn);Wn(f)&&(l=f.forceUpdate);var d=Object(O.useRef)(!0),p=function(t){var e=[];return O.Children.forEach(t,(function(t){Object(O.isValidElement)(t)&&e.push(t)})),e}(e),v=Object(O.useRef)(p),h=Object(O.useRef)(new Map).current,m=Object(O.useRef)(new Set).current;if(function(t,e){t.forEach((function(t){var n=Hr(t);e.set(n,t)}))}(p,h),d.current)return d.current=!1,Object(O.createElement)(O.Fragment,null,p.map((function(t){return Object(O.createElement)(Ur,{key:Hr(t),isPresent:!0,initial:!!o&&void 0,presenceAffectsLayout:c},t)})));for(var g=Object(r.e)(p),y=v.current.map(Hr),b=p.map(Hr),x=y.length,j=0;j=0;f--){var d=t[f];if(f===c-1&&(l=d.isPresent),l)a=d;else{var p=t[f-1];p&&p.isPresent&&(a=d)}if(a){s=f;break}}if(a||(a=t[0]),u=t[s-1],a)for(f=s-1;f>=0;f--){if((d=t[f]).isPresent){u=d;break}}return a!==i&&!l&&u===o&&t.find((function(t){return t===i}))&&(a=i),[a,u]}(this.order,[this.lead,this.follow]),2),e=t[0],n=t[1];this.lead=e,this.follow=n},t.prototype.updateSnapshot=function(){if(this.lead){var t={boundingBox:this.lead.prevViewportBox,latestMotionValues:{}};this.lead.forEachValue((function(e,n){var r=e.get();K(r)||(t.latestMotionValues[n]=r)}));var e=lr.get(this.lead);e&&e.isDragging&&(t.isDragging=!0,t.cursorProgress=e.cursorProgress),this.snapshot=t}},t.prototype.isLeadPresent=function(){var t;return this.lead&&(null===(t=this.lead)||void 0===t?void 0:t.presence)!==Fn.Exiting},t.prototype.getFollowOrigin=function(){var t;return this.follow?this.follow.prevViewportBox:null===(t=this.snapshot)||void 0===t?void 0:t.boundingBox},t.prototype.getFollowTarget=function(){var t;return null===(t=this.follow)||void 0===t?void 0:t.box},t.prototype.getLeadOrigin=function(){var t;return null===(t=this.lead)||void 0===t?void 0:t.prevViewportBox},t.prototype.getLeadTarget=function(){var t;return null===(t=this.lead)||void 0===t?void 0:t.box},t.prototype.getLeadTransition=function(){var t;return null===(t=this.lead)||void 0===t?void 0:t.config.transition},t}();!function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.children=new Set,e.stacks=new Map,e.hasMounted=!1,e.updateScheduled=!1,e.renderScheduled=!1,e.syncContext=Object(r.a)(Object(r.a)({},zn()),{syncUpdate:function(t){return e.scheduleUpdate(t)},forceUpdate:function(){e.syncContext=Object(r.a)({},e.syncContext),e.scheduleUpdate(!0)},register:function(t){return e.addChild(t)},remove:function(t){return e.removeChild(t)}}),e}Object(r.b)(e,t),e.prototype.componentDidMount=function(){this.hasMounted=!0,this.updateStacks()},e.prototype.componentDidUpdate=function(){this.startLayoutAnimation()},e.prototype.shouldComponentUpdate=function(){return this.renderScheduled=!0,!0},e.prototype.startLayoutAnimation=function(){var t=this;this.renderScheduled=this.updateScheduled=!1;var e=this.props.type;this.children.forEach((function(t){t.isPresent?t.presence!==Fn.Entering&&(t.presence=t.presence===Fn.Exiting?Fn.Entering:Fn.Present):t.presence=Fn.Exiting})),this.updateStacks();var n="crossfade"===e?zr:Xr,r={measureLayout:function(t){return t.measureLayout()},layoutReady:function(e){var r=e.layoutId;e.layoutReady(n(e,t.getStack(r)))},parent:this.context.visualElement};this.children.forEach((function(e){return t.syncContext.add(e)})),this.syncContext.flush(r),this.stacks.forEach((function(t){return t.snapshot=void 0}))},e.prototype.updateStacks=function(){this.stacks.forEach((function(t){return t.updateLeadAndFollow()}))},e.prototype.scheduleUpdate=function(t){void 0===t&&(t=!1),!t&&this.updateScheduled||(this.updateScheduled=!0,this.children.forEach((function(t){return function(t){for(var e=!1,n={},r=0;r