import { c as create_ssr_component, e as escape, v as validate_component, d as add_attribute, f as add_styles, n as compute_slots } from './ssr-pGtI3Kui.js'; import './ProgressBar.svelte_svelte_type_style_lang-Lwm3XjGR.js'; const cBase = "progress-radial relative overflow-hidden"; const cBaseTrack = "fill-transparent"; const cBaseMeter = "fill-transparent -rotate-90 origin-[50%_50%]"; const baseSize = 512; const ProgressRadial = create_ssr_component(($$result, $$props, $$bindings, slots) => { let classesBase; let $$slots = compute_slots(slots); let { value = void 0 } = $$props; let { stroke = 40 } = $$props; let { font = 56 } = $$props; let { strokeLinecap = "butt" } = $$props; let { transition = "transition-[stroke-dashoffset]" } = $$props; let { width = "w-36" } = $$props; let { meter = "stroke-surface-900 dark:stroke-surface-50" } = $$props; let { track = "stroke-surface-500/30" } = $$props; let { fill = "fill-token" } = $$props; let { labelledby = "" } = $$props; const radius = baseSize / 2 - stroke / 2; let circumference = radius; let dashoffset; function setProgress(percent) { circumference = radius * 2 * Math.PI; dashoffset = circumference - percent / 100 * circumference; } setProgress(0); if ($$props.value === void 0 && $$bindings.value && value !== void 0) $$bindings.value(value); if ($$props.stroke === void 0 && $$bindings.stroke && stroke !== void 0) $$bindings.stroke(stroke); if ($$props.font === void 0 && $$bindings.font && font !== void 0) $$bindings.font(font); if ($$props.strokeLinecap === void 0 && $$bindings.strokeLinecap && strokeLinecap !== void 0) $$bindings.strokeLinecap(strokeLinecap); if ($$props.transition === void 0 && $$bindings.transition && transition !== void 0) $$bindings.transition(transition); if ($$props.width === void 0 && $$bindings.width && width !== void 0) $$bindings.width(width); if ($$props.meter === void 0 && $$bindings.meter && meter !== void 0) $$bindings.meter(meter); if ($$props.track === void 0 && $$bindings.track && track !== void 0) $$bindings.track(track); if ($$props.fill === void 0 && $$bindings.fill && fill !== void 0) $$bindings.fill(fill); if ($$props.labelledby === void 0 && $$bindings.labelledby && labelledby !== void 0) $$bindings.labelledby(labelledby); classesBase = `${cBase} ${width} ${$$props.class ?? ""}`; return `
${value != void 0 && value >= 0 && $$slots.default ? `${slots.default ? slots.default({}) : ``}` : ``}
`; }); const Progress = create_ssr_component(($$result, $$props, $$bindings, slots) => { let { width = "" } = $$props; if ($$props.width === void 0 && $$bindings.width && width !== void 0) $$bindings.width(width); return `
${validate_component(ProgressRadial, "ProgressRadial").$$render( $$result, { width, stroke: 100, meter: "stroke-primary-500", track: "stroke-primary-500/30", class: "progress-bar" }, {}, {} )}
`; }); export { Progress as P }; //# sourceMappingURL=Progress-Bh0zkgr8.js.map