import{_ as e,b as t,s as n}from"./runtime-core.esm-bundler-Babufkcf.js";import{t as r}from"./create-CGAkPJkS.js";import{l as i,r as a,s as o}from"./QIcon-cTVL6ikA.js";import{n as s,t as c}from"./use-dark-B6e4te0z.js";var l={xs:2,sm:4,md:6,lg:10,xl:14};function u(e,t,n){return{transform:t?`translateX(${n.lang.rtl?`-`:``}100%) scale3d(${-e},1,1)`:`scale3d(${e},1,1)`}}var d=r({name:`QLinearProgress`,props:{...s,...i,value:{type:Number,default:0},buffer:Number,color:String,trackColor:String,reverse:Boolean,stripe:Boolean,indeterminate:Boolean,query:Boolean,rounded:Boolean,animationSpeed:{type:[String,Number],default:2100},instantFeedback:Boolean},setup(r,{slots:i}){let{proxy:s}=e(),d=c(r,s.$q),f=o(r,l),p=n(()=>r.indeterminate||r.query),m=n(()=>r.reverse!==r.query),h=n(()=>({...f.value===null?{}:f.value,"--q-linear-progress-speed":`${r.animationSpeed}ms`})),g=n(()=>`q-linear-progress`+(r.color===void 0?``:` text-${r.color}`)+(r.reverse||r.query?` q-linear-progress--reverse`:``)+(r.rounded?` rounded-borders`:``)),_=n(()=>u(r.buffer===void 0?1:r.buffer,m.value,s.$q)),v=n(()=>`with${r.instantFeedback?`out`:``}-transition`),y=n(()=>`q-linear-progress__track absolute-full q-linear-progress__track--${v.value} q-linear-progress__track--${d.value?`dark`:`light`}`+(r.trackColor===void 0?``:` bg-${r.trackColor}`)),b=n(()=>u(p.value?1:r.value,m.value,s.$q)),x=n(()=>`q-linear-progress__model absolute-full q-linear-progress__model--${v.value} q-linear-progress__model--${p.value?`in`:``}determinate`),S=n(()=>({width:`${r.value*100}%`})),C=n(()=>`q-linear-progress__stripe absolute-${r.reverse?`right`:`left`} q-linear-progress__stripe--${v.value}`);return()=>{let e=[t(`div`,{class:y.value,style:_.value}),t(`div`,{class:x.value,style:b.value})];return r.stripe&&!p.value&&e.push(t(`div`,{class:C.value,style:S.value})),t(`div`,{class:g.value,style:h.value,role:`progressbar`,"aria-valuemin":0,"aria-valuemax":1,"aria-valuenow":r.indeterminate?void 0:r.value},a(i.default,e))}}});export{d as t};