show eu flag if it is empty
This commit is contained in:
+12
-11
@@ -11,16 +11,17 @@ class Flag extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return countryCode.isNotEmpty
|
||||
? ClipRRect(
|
||||
borderRadius: BorderRadius.circular(6),
|
||||
child: CachedSvg(
|
||||
url: '${AppConfig.flagUrl}$countryCode',
|
||||
width: 32.0.w(),
|
||||
height: 21.0.h(),
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
)
|
||||
: const SizedBox();
|
||||
return ClipRRect(
|
||||
borderRadius: BorderRadius.circular(6),
|
||||
child: CachedSvg(
|
||||
url:
|
||||
countryCode.isNotEmpty
|
||||
? '${AppConfig.flagUrl}$countryCode'
|
||||
: '${AppConfig.flagUrl}EU',
|
||||
width: 32.0.w(),
|
||||
height: 21.0.h(),
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user