refactor(ui): update tags in DeviceLogsScreen

This commit is contained in:
anhtunz
2024-12-27 10:59:47 +07:00
parent 70e3ed8978
commit 178a00f5ba
11 changed files with 373 additions and 58 deletions

View File

@@ -0,0 +1,38 @@
import 'package:flutter/material.dart';
class TagWidgetShared extends StatelessWidget {
const TagWidgetShared({
super.key,
required this.boxColor,
this.boxRadius,
this.boxHeight,
this.boxWidth,
required this.tagContent,
});
final Color? boxColor;
final double? boxRadius;
final double? boxHeight;
final double? boxWidth;
final String? tagContent;
@override
Widget build(BuildContext context) {
return Container(
decoration: BoxDecoration(
color: boxColor,
borderRadius: BorderRadius.circular(boxRadius ?? 10),
),
height: boxHeight ?? 40,
width: boxWidth ?? 100,
child: Center(
child: Text(
tagContent ?? "",
style: const TextStyle(
color: Colors.white,
fontWeight: FontWeight.bold,
fontSize: 15,
),
),
),
);
}
}