71 lines
1.3 KiB
Dart
71 lines
1.3 KiB
Dart
import 'package:flutter/cupertino.dart';
|
|
import 'package:flutter/material.dart';
|
|
|
|
class WDGProfileStat
|
|
extends
|
|
StatelessWidget {
|
|
const WDGProfileStat({
|
|
super.key,
|
|
this.amount = '',
|
|
this.label = '',
|
|
this.color = Colors.blue,
|
|
this.icon = CupertinoIcons.house_fill,
|
|
});
|
|
|
|
final String amount;
|
|
final String label;
|
|
final Color color;
|
|
final IconData icon;
|
|
|
|
@override
|
|
Widget build(
|
|
BuildContext context,
|
|
) {
|
|
return Column(
|
|
children: [
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
borderRadius: BorderRadius.circular(
|
|
100,
|
|
),
|
|
color: color,
|
|
),
|
|
|
|
padding: EdgeInsets.all(
|
|
10,
|
|
),
|
|
child: Icon(
|
|
icon,
|
|
color: Colors.white,
|
|
),
|
|
),
|
|
|
|
Padding(
|
|
padding: const EdgeInsets.only(
|
|
top: 12.0,
|
|
bottom: 2.0,
|
|
),
|
|
child: Text(
|
|
amount,
|
|
style: TextStyle(
|
|
fontSize: 20,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
|
|
Opacity(
|
|
opacity: .7,
|
|
child: Text(
|
|
label,
|
|
style: TextStyle(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.w400,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
);
|
|
}
|
|
}
|