import{ci as S,p as b,q as w,d as C,v as p,b_ as R,c9 as E,a5 as H,F as N,J as v,a as O,bf as j,bw as f}from"./index-DGnN4tUo.js";import{u as A}from"./use-houdini-DoGjazoX.js";function F(e){const{heightSmall:r,heightMedium:s,heightLarge:t,borderRadius:n}=e;return{color:"#eee",colorEnd:"#ddd",borderRadius:n,heightSmall:r,heightMedium:s,heightLarge:t}}const L={common:S,self:F},T=b([w("skeleton",`
 height: 1em;
 width: 100%;
 transition:
 --n-color-start .3s var(--n-bezier),
 --n-color-end .3s var(--n-bezier),
 background-color .3s var(--n-bezier);
 animation: 2s skeleton-loading infinite cubic-bezier(0.36, 0, 0.64, 1);
 background-color: var(--n-color-start);
 `),b("@keyframes skeleton-loading",`
 0% {
 background: var(--n-color-start);
 }
 40% {
 background: var(--n-color-end);
 }
 80% {
 background: var(--n-color-start);
 }
 100% {
 background: var(--n-color-start);
 }
 `)]),$=Object.assign(Object.assign({},v.props),{text:Boolean,round:Boolean,circle:Boolean,height:[String,Number],width:[String,Number],size:String,repeat:{type:Number,default:1},animated:{type:Boolean,default:!0},sharp:{type:Boolean,default:!0}}),J=C({name:"Skeleton",inheritAttrs:!1,props:$,setup(e){A();const{mergedClsPrefixRef:r}=N(e),s=v("Skeleton","-skeleton",T,L,e,r);return{mergedClsPrefix:r,style:O(()=>{var t,n;const a=s.value,{common:{cubicBezierEaseInOut:k}}=a,m=a.self,{color:y,colorEnd:z,borderRadius:_}=m;let i;const{circle:l,sharp:x,round:B,width:o,height:c,size:g,text:h,animated:P}=e;g!==void 0&&(i=m[j("height",g)]);const d=l?(t=o??c)!==null&&t!==void 0?t:i:o,u=(n=l?o??c:c)!==null&&n!==void 0?n:i;return{display:h?"inline-block":"",verticalAlign:h?"-0.125em":"",borderRadius:l?"50%":B?"4096px":x?"":_,width:typeof d=="number"?f(d):d,height:typeof u=="number"?f(u):u,animation:P?"":"none","--n-bezier":k,"--n-color-start":y,"--n-color-end":z}})}},render(){const{repeat:e,style:r,mergedClsPrefix:s,$attrs:t}=this,n=p("div",R({class:`${s}-skeleton`,style:r},t));return e>1?p(H,null,E(e,null).map(a=>[n,`
`])):n}});export{J as _};
