mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-04-25 02:48:23 +01:00
Update Backup Media download progress indicator for narrow left panes
Co-authored-by: Jamie Kyle <jamie@signal.org>
This commit is contained in:
@@ -7,10 +7,12 @@ export function ProgressCircle({
|
||||
fractionComplete,
|
||||
width = 24,
|
||||
strokeWidth = 3,
|
||||
ariaLabel,
|
||||
}: {
|
||||
fractionComplete: number;
|
||||
width?: number;
|
||||
strokeWidth?: number;
|
||||
ariaLabel?: string;
|
||||
}): JSX.Element {
|
||||
const radius = width / 2 - strokeWidth / 2;
|
||||
const circumference = radius * 2 * Math.PI;
|
||||
@@ -21,6 +23,11 @@ export function ProgressCircle({
|
||||
className="ProgressCircle"
|
||||
width={widthInPixels}
|
||||
height={widthInPixels}
|
||||
role="progressbar"
|
||||
aria-label={ariaLabel}
|
||||
aria-valuenow={Math.trunc(fractionComplete * 100)}
|
||||
aria-valuemin={0}
|
||||
aria-valuemax={100}
|
||||
>
|
||||
<circle
|
||||
className="ProgressCircle__background"
|
||||
|
||||
Reference in New Issue
Block a user