"use strict";(Object("undefined"!=typeof self?self:this).webpackChunk_transferwise_comparison_components_comparison=Object("undefined"!=typeof self?self:this).webpackChunk_transferwise_comparison_components_comparison||[]).push([[566],{426:function(e,n,t){t.d(n,{f:function(){return o}});var c=t(4119),r=t(9437),s=t(9949);function o(e,n){const t=c.useRef(),[o]=c.useState((()=>n?n instanceof r.Object3D?{current:n}:n:t)),[i]=c.useState((()=>new r.AnimationMixer(void 0)));c.useLayoutEffect((()=>{n&&(o.current=n instanceof r.Object3D?n:n.current),i._root=o.current}));const a=c.useRef({}),u=c.useMemo((()=>{const n={};return e.forEach((e=>Object.defineProperty(n,e.name,{enumerable:!0,get(){if(o.current)return a.current[e.name]||(a.current[e.name]=i.clipAction(e,o.current))},configurable:!0}))),{ref:o,clips:e,actions:n,names:e.map((e=>e.name)),mixer:i}}),[e]);return(0,s.C)(((e,n)=>i.update(n))),c.useEffect((()=>{const e=o.current;return()=>{a.current={},i.stopAllAction(),Object.values(u.actions).forEach((n=>{e&&i.uncacheAction(n,e)}))}}),[e]),u}},6566:function(e,n,t){t.r(n),t.d(n,{default:function(){return f}});var c=t(2603),r=t(426),s=t(9949),o=t(4119),i=t(9437),a=t(6574),u=t(4848);const f=()=>{const e=(0,o.useRef)(),n=(0,c.p)((0,a.d)("lock.glb")),t=(0,s.F)(i.ObjectLoader,(0,a.d)("lock-light.json"));n.scene.traverse((e=>{e.isMesh&&(e.castShadow=!0,e.receiveShadow=!0)}));const{clips:f,mixer:p}=(0,r.f)(n.animations,e);let l=0;return(0,s.C)((()=>{p.clipAction(f[0]).play().setLoop(i.LoopOnce,1),n.scene.position.y=.2*Math.sin(.04*l++),n.materials.Standard.map.offset.x+=-.001})),(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("primitive",{ref:e,scale:1.4,object:n.scene}),(0,u.jsx)("primitive",{object:t})]})}}}]);
//# sourceMappingURL=566.comparison.js.map