mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-25 04:36:46 +00:00
Change duration to countdown in MessageAudio
Message Audio UI should display remaining time not the duration of the audio.
This commit is contained in:
@@ -523,6 +523,8 @@ export const MessageAudio: React.FC<Props> = (props: Props) => {
|
||||
);
|
||||
}
|
||||
|
||||
const countDown = duration - currentTime;
|
||||
|
||||
return (
|
||||
<div
|
||||
className={classNames(
|
||||
@@ -534,7 +536,7 @@ export const MessageAudio: React.FC<Props> = (props: Props) => {
|
||||
>
|
||||
{button}
|
||||
{waveform}
|
||||
<div className={`${CSS_BASE}__duration`}>{timeToText(duration)}</div>
|
||||
<div className={`${CSS_BASE}__countdown`}>{timeToText(countDown)}</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user