mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-06-08 01:17:23 +08:00
2 lines
3.3 KiB
JavaScript
2 lines
3.3 KiB
JavaScript
import{d as C,cP as x,cQ as j,a as s,aj as V,p as m,b as T,w as h,e as r,f as u,g as c,i as g,k as I,l as $,v as O,s as A,q as b,t as X,F as E,B as F,a5 as N,a0 as Y}from"./index-qIsAHwF6.js";const q=["bounce","flash","pulse","rubberBand","shakeX","headShake","swing","tada","wobble","jello","heartBeat","backInDown","backInLeft","backInRight","backInUp","backOutDown","backOutLeft","backOutRight","backOutUp","bounceIn","bounceInDown","bounceInLeft","bounceInRight","bounceInUp","bounceOut","bounceOutDown","bounceOutLeft","bounceOutRight","bounceOutUp","fadeIn","fadeInDown","fadeInDownBig","fadeInLeft","fadeInLeftBig","fadeInRight","fadeInRightBig","fadeInUp","fadeInUpBig","fadeInTopLeft","fadeInTopRight","fadeInBottomLeft","fadeInBottomRight","fadeOut","fadeOutDown","fadeOutDownBig","fadeOutLeft","fadeOutLeftBig","fadeOutRight","fadeOutRightBig","fadeOutUp","fadeOutUpBig","fadeOutTopLeft","fadeOutTopRight","fadeOutBottomRight","fadeOutBottomLeft","flip","flipInX","flipInY","flipOutX","flipOutY","lightSpeedInRight","lightSpeedInLeft","lightSpeedOutRight","lightSpeedOutLeft","rotateIn","rotateInDownLeft","rotateInDownRight","rotateInUpLeft","rotateInUpRight","rotateOut","rotateOutDownLeft","rotateOutDownRight","rotateOutUpLeft","rotateOutUpRight","hinge","jackInTheBox","rollIn","rollOut","zoomIn","zoomInDown","zoomInLeft","zoomInRight","zoomInUp","zoomOut","zoomOutDown","zoomOutLeft","zoomOutRight","zoomOutUp","slideInDown","slideInLeft","slideInRight","slideInUp","slideOutDown","slideOutLeft","slideOutRight","slideOutUp"],P={class:"w-[280px]"},Q={class:"flex flex-wrap justify-around mb-1"},G=["onMouseenter","onClick"],H=C({name:"ReAnimateSelector",__name:"index",props:x({placeholder:{type:String,default:"请选择动画"}},{modelValue:{type:String},modelModifiers:{}}),emits:["update:modelValue"],setup(d){const v=d,a=j(d,"modelValue"),f=s(),n=s(q),w=V(n),_=m(()=>["mt-1","flex","border","w-[130px]","h-[100px]","items-center","cursor-pointer","transition-all","justify-center","border-[#e5e7eb]","hover:text-primary","hover:duration-[700ms]"]),L=m(()=>e=>a.value===e?{borderColor:"var(--el-color-primary)",color:"var(--el-color-primary)"}:"");function R(e){a.value=e}function B(){a.value=""}function k(e){f.value=e,n.value=w.value.filter(o=>o.includes(e))}const t=s({});function D(e){var o;t.value[e]=(o=t.value[e])!=null&&o.loading?Object.assign({},t.value[e],{loading:!1}):Object.assign({},t.value[e],{loading:!0})}function y(){t.value={}}return(e,o)=>{const U=r("el-empty"),z=r("el-scrollbar"),S=r("el-select");return u(),T(S,{clearable:"",filterable:"",placeholder:v.placeholder,"popper-class":"pure-animate-popper","model-value":a.value,"filter-method":k,onClear:B},{empty:h(()=>[c("div",P,[g(z,{noresize:"",height:"212px","view-style":{overflow:"hidden"},class:"border-t border-[#e5e7eb]"},{default:h(()=>[c("ul",Q,[(u(!0),I(E,null,$(n.value,(l,i)=>{var p;return u(),I("li",{key:i,class:O(_.value),style:A(L.value(l)),onMouseenter:b(M=>D(i),["prevent"]),onMouseleave:b(y,["prevent"]),onClick:M=>R(l)},[c("h4",{class:O([`animate__animated animate__${(p=t.value[i])!=null&&p.loading?l+" animate__infinite":""} `])},X(l),3)],46,G)}),128))]),F(g(U,{description:`${f.value} 动画不存在`,"image-size":60},null,8,["description"]),[[N,n.value.length===0]])]),_:1})])]),_:1},8,["placeholder","model-value"])}}}),K=Y(H);export{K as R};
|