Files
igny8/frontend/dist/assets/js/ProgressBar-0v269fGL.js
IGNY8 VPS (Salman) 3c100be1cf more
2025-11-13 14:12:36 +00:00

2 lines
860 B
JavaScript

import{j as s}from"./chunk-UIGDSWPH-BhuNDbxn.js";const o=({value:t,color:l="primary",size:e="md",showLabel:n=!1,label:i,className:d=""})=>{const a={sm:"h-1",md:"h-2",lg:"h-3"},m={primary:"bg-brand-500",success:"bg-success-500",error:"bg-error-500",warning:"bg-warning-500",info:"bg-blue-light-500"},r=Math.min(100,Math.max(0,t));return s.jsxs("div",{className:d,children:[n&&s.jsxs("div",{className:"flex items-center justify-between mb-2",children:[s.jsx("span",{className:"text-sm font-medium text-gray-700 dark:text-gray-300",children:i||`${r}%`}),s.jsxs("span",{className:"text-sm text-gray-500 dark:text-gray-400",children:[r,"%"]})]}),s.jsx("div",{className:`w-full rounded-full bg-gray-200 dark:bg-gray-700 ${a[e]}`,children:s.jsx("div",{className:`rounded-full transition-all duration-300 ${a[e]} ${m[l]}`,style:{width:`${r}%`}})})]})};export{o as P};