mod: member archive: show progress

Closes #225

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-02-11 17:20:54 +08:00
parent 50022ae635
commit 4267a3b8e0
5 changed files with 52 additions and 26 deletions

View File

@@ -0,0 +1,27 @@
import 'package:flutter/material.dart';
Widget videoProgressIndicator(double progress) => ClipRect(
clipper: ProgressClipper(),
child: ClipRRect(
borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(12),
bottomRight: Radius.circular(12),
),
child: LinearProgressIndicator(
minHeight: 12,
value: progress,
),
),
);
class ProgressClipper extends CustomClipper<Rect> {
@override
Rect getClip(Size size) {
return Rect.fromLTWH(0, 8, size.width, size.height - 8);
}
@override
bool shouldReclip(CustomClipper<Rect> oldClipper) {
return false;
}
}