import{_ as a,aR as t,b as n,d as i,p as o,w as s,H as e,i as l,o as m,f as r,k as c,R as h,S as d}from"./index-2PZN6pGH.js";const u=a({data:()=>({title:"createAnimation",animationData:""}),onUnload(){this.animationData=""},onLoad(){this.animation=t()},methods:{rotate:function(){this.animation.rotate(720*Math.random()-360).step(),this.animationData=this.animation.export()},scale:function(){this.animation.scale(2*Math.random()).step(),this.animationData=this.animation.export()},translate:function(){this.animation.translate(100*Math.random()-50,100*Math.random()-50).step(),this.animationData=this.animation.export()},skew:function(){this.animation.skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},rotateAndScale:function(){this.animation.rotate(720*Math.random()-360).scale(2*Math.random()).step(),this.animationData=this.animation.export()},rotateThenScale:function(){this.animation.rotate(720*Math.random()-360).step().scale(2*Math.random()).step(),this.animationData=this.animation.export()},all:function(){this.animation.rotate(720*Math.random()-360).scale(2*Math.random()).translate(100*Math.random()-50,100*Math.random()-50).skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},allInQueue:function(){this.animation.rotate(720*Math.random()-360).step().scale(2*Math.random()).step().translate(100*Math.random()-50,100*Math.random()-50).step().skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},reset:function(){this.animation.rotate(0,0).scale(1).translate(0,0).skew(0,0).step({duration:0}),this.animationData=this.animation.export()}}},[["render",function(a,t,u,p,f,k){const M=n(i("page-head"),e),C=l,_=h,b=d;return m(),o(C,null,{default:s((()=>[r(M,{title:f.title},null,8,["title"]),r(C,{class:"uni-padding-wrap uni-common-mt"},{default:s((()=>[r(C,{class:"animation-element-wrapper"},{default:s((()=>[r(C,{class:"animation-element",animation:f.animationData},null,8,["animation"])])),_:1}),r(b,{class:"animation-buttons","scroll-y":"true"},{default:s((()=>[r(_,{class:"animation-button",onClick:k.rotate},{default:s((()=>[c("旋转")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.scale},{default:s((()=>[c("缩放")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.translate},{default:s((()=>[c("移动")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.skew},{default:s((()=>[c("倾斜")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.rotateAndScale},{default:s((()=>[c("旋转并缩放")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.rotateThenScale},{default:s((()=>[c("旋转后缩放")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.all},{default:s((()=>[c("同时展示全部")])),_:1},8,["onClick"]),r(_,{class:"animation-button",onClick:k.allInQueue},{default:s((()=>[c("顺序展示全部")])),_:1},8,["onClick"]),r(_,{class:"animation-button animation-button-reset",onClick:k.reset},{default:s((()=>[c("还原")])),_:1},8,["onClick"])])),_:1})])),_:1})])),_:1})}],["__scopeId","data-v-68893260"]]);export{u as default};
