import{g as f,p as k,aB as x,u as y,bk as S,bl as B,Z as C,a5 as L,a4 as w,c as P,i as r,E as V,F as T,bh as A,bm as _,f as E,e as F}from"./index-BBhBboPS.js";const D={actions:"button@2",article:"heading, paragraph",avatar:"avatar",button:"button",card:"image, heading","card-avatar":"image, list-item-avatar",chip:"chip","date-picker":"list-item, heading, divider, date-picker-options, date-picker-days, actions","date-picker-options":"text, avatar@2","date-picker-days":"avatar@28",divider:"divider",heading:"heading",image:"image","list-item":"text","list-item-avatar":"avatar, text","list-item-two-line":"sentences","list-item-avatar-two-line":"avatar, sentences","list-item-three-line":"paragraph","list-item-avatar-three-line":"avatar, paragraph",ossein:"ossein",paragraph:"text@3",sentences:"text@2",subtitle:"text",table:"table-heading, table-thead, table-tbody, table-tfoot","table-heading":"chip, text","table-thead":"heading@6","table-tbody":"table-row-divider@6","table-row-divider":"table-row, divider","table-row":"text@6","table-tfoot":"text@2, avatar@2",text:"text"};function $(e){let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return r("div",{class:F(["v-skeleton-loader__bone",`v-skeleton-loader__${e}`])},[a])}function l(e){const[a,t]=e.split("@");return Array.from({length:t}).map(()=>i(a))}function i(e){let a=[];if(!e)return a;const t=D[e];if(e!==t){if(e.includes(","))return d(e);if(e.includes("@"))return l(e);t.includes(",")?a=d(t):t.includes("@")?a=l(t):t&&a.push(i(t))}return[$(e,a)]}function d(e){return e.replace(/\s/g,"").split(",").map(i)}const j=k({boilerplate:Boolean,color:String,loading:Boolean,loadingText:{type:String,default:"$vuetify.loading"},type:{type:[String,Array],default:"ossein"},...E(),..._(),...A()},"VSkeletonLoader"),I=f()({name:"VSkeletonLoader",inheritAttrs:!1,props:j(),setup(e,a){let{attrs:t,slots:n}=a;const{backgroundColorClasses:c,backgroundColorStyles:u}=x(()=>e.color),{dimensionStyles:g}=y(e),{elevationClasses:m}=S(e),{themeClasses:v}=B(e),{t:b}=C(),p=L(()=>i(w(e.type).join(",")));return P(()=>{var s;const o=!n.default||e.loading,h=e.boilerplate||!o?{}:{ariaLive:"polite",ariaLabel:b(e.loadingText),role:"alert"};return o?r("div",V({class:["v-skeleton-loader",{"v-skeleton-loader--boilerplate":e.boilerplate},v.value,c.value,m.value],style:[u.value,g.value]},h,t),[p.value]):r(T,null,[(s=n.default)==null?void 0:s.call(n)])}),{}}});export{I as V};
