Line data Source code
1 : // Copyright 2023 The terCAD team. All rights reserved. 2 : // Use of this source code is governed by a CC BY-NC-ND 4.0 license that can be found in the LICENSE file. 3 : 4 : import 'package:flutter/material.dart'; 5 : 6 : class BarHorizontalSingle extends StatelessWidget { 7 : final Color color; 8 : final double value; 9 : final double height; 10 : final double width; 11 : 12 1 : const BarHorizontalSingle({ 13 : super.key, 14 : required this.width, 15 : required this.color, 16 : required this.value, 17 : this.height = 1, 18 : }); 19 : 20 1 : @override 21 : Widget build(BuildContext context) { 22 1 : return LinearProgressIndicator( 23 1 : minHeight: height, 24 1 : value: value, 25 : backgroundColor: Colors.grey, 26 2 : valueColor: AlwaysStoppedAnimation<Color>(color), 27 : ); 28 : } 29 : }