UNPKG

@bothub-chat/ui

Version:

Bothub UI Components

2 lines (1 loc) 446 B
import{jsxs as e,jsx as t}from"react/jsx-runtime";import{ProgressStyled as l,ProgressLine as s,ProgressLineFilled as i}from"./styled.js";import{Skeleton as o}from"../skeleton/index.js";const m=({className:m,value:r=50,min:n=0,max:a=100,fullWidth:d=!1,skeleton:c=!1})=>e(l,{$fullWidth:d,className:m,children:[!c&&t(s,{$skeleton:!1,children:t(i,{style:{width:`${(r-n)/(a-n)*100}%`}})}),c&&t(s,{$skeleton:!0,as:c?o:"div"})]});export{m as Progress};