mirror of
https://github.com/upscayl/upscayl.git
synced 2024-11-27 17:00:52 +01:00
Add radial progress bar (#864)
* Revert "Revert "Add progressbar when upscaling image"" * Make bar primary * make radial * add aria values Co-authored by @coderabbitai --------- Co-authored-by: NayamAmarshe <nayam.emikx@aleeas.com>
This commit is contained in:
parent
f1be357f8a
commit
b22aa99bd6
@ -28,14 +28,14 @@ function ProgressBar({
|
|||||||
<div className="flex flex-col items-center rounded-btn bg-base-100/50 p-4 backdrop-blur-lg">
|
<div className="flex flex-col items-center rounded-btn bg-base-100/50 p-4 backdrop-blur-lg">
|
||||||
<Logo className="spinner mb-4 h-12 w-12" />
|
<Logo className="spinner mb-4 h-12 w-12" />
|
||||||
<p className="rounded-full px-2 pb-2 font-bold">
|
<p className="rounded-full px-2 pb-2 font-bold">
|
||||||
{batchMode && "Batch Upscale In Progress: " + batchProgress}
|
{batchMode && `Batch Upscayl In Progress: ${batchProgress}` }
|
||||||
|
|
||||||
{!batchMode &&
|
|
||||||
(doubleUpscaylCounter > 0
|
|
||||||
? `${progress}\nPass ${doubleUpscaylCounter}`
|
|
||||||
: `${progress}`)}
|
|
||||||
</p>
|
</p>
|
||||||
|
{progress !== "Hold on..." ? (
|
||||||
|
<div className="radial-progress text-center" style={{ "--value": parseFloat(progress.replace("%", '')) }} role="progressbar" aria-valuenow={ parseFloat(progress.replace("%", '')) } aria-valuemin="0" aria-valuemax="100">
|
||||||
|
{progress}
|
||||||
|
{!batchMode && (doubleUpscaylCounter > 0) && "\nPass " + doubleUpscaylCounter}
|
||||||
|
</div>
|
||||||
|
) : progress}
|
||||||
<p className="animate-pulse rounded-full px-2 pb-3 text-sm font-medium">
|
<p className="animate-pulse rounded-full px-2 pb-3 text-sm font-medium">
|
||||||
Doing the Upscayl magic...
|
Doing the Upscayl magic...
|
||||||
</p>
|
</p>
|
||||||
|
Loading…
Reference in New Issue
Block a user