29 lines
795 B
Dart
29 lines
795 B
Dart
import 'package:flutter/material.dart';
|
|
import 'package:gascom/constants/app_theme.dart';
|
|
|
|
class OrderStateBadge extends StatelessWidget {
|
|
const OrderStateBadge({
|
|
super.key,
|
|
required this.state,
|
|
});
|
|
|
|
final String state;
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Container(
|
|
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 2),
|
|
decoration: BoxDecoration(
|
|
color: state == "قيد المراجعة" ? AppTheme.yellowColor : AppTheme.primaryColor,
|
|
borderRadius: BorderRadius.circular(20),
|
|
),
|
|
child: Text(
|
|
state,
|
|
style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
|
color: state == "قيد المراجعة" ? AppTheme.brownColor : AppTheme.textColor,
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|