@ -51,7 +51,7 @@ class AdsListWidget extends StatelessWidget {
mainAxisAlignment: MainAxisAlignment . center ,
children: [
const SizedBox ( height: 25 ) ,
( adVM . adsFiltersCounter > 0 ? " No Ads that matches your search " : LocaleKeys . noAdsShow . tr ( ) ) . toText ( fontSize: 16 , color: MyColors . lightTextColor , fontWeight: MyFonts . Medium ) ,
( adVM . adsFiltersCounter > 0 ? LocaleKeys . noAdsMatchesYourSearch . tr ( ) : LocaleKeys . noAdsShow . tr ( ) ) . toText ( fontSize: 16 , color: MyColors . lightTextColor , fontWeight: MyFonts . Medium ) ,
if ( adVM . adsFiltersCounter > 0 ) . . . [
const SizedBox ( height: 16 ) ,
GestureDetector (
@ -166,7 +166,8 @@ class _AdCardState extends State<AdCard> {
Expanded (
child: Column (
children: [
" Ad format needs to be updated. " . toText ( ) ,
LocaleKeys . formatNeedsUpdate . tr ( ) . toText ( ) ,
/ / " Ad format needs to be updated. " . toText ( ) ,
] ,
) ,
) ,
@ -308,12 +309,12 @@ class _AdCardState extends State<AdCard> {
else if ( isAdsFragment & & widget . adDetails . adPostStatus ! = = AdPostStatus . sold & & widget . adDetails . statuslabel ! = null & & widget . adDetails . statuslabel ! . isNotEmpty ) . . . [
Padding (
padding: const EdgeInsets . only ( top: 5 ) ,
child: Utils . statusContainerChip ( text: widget. adDetails . statuslabel ? ? " " , chipColor: Utils . getChipColorByAdStatus ( widget . adDetails . adPostStatus ! ) ) ,
child: Utils . statusContainerChip ( text: isArabic ? widget . adDetails . statuslabelN ? ? " " : widget. adDetails . statuslabel ? ? " " , chipColor: Utils . getChipColorByAdStatus ( widget . adDetails . adPostStatus ! ) ) ,
) ,
] else if ( isAdsFragment & & ! context . read < AdVM > ( ) . isExploreAdsTapped & & widget . adDetails . statuslabel ! = null & & widget . adDetails . statuslabel ! . isNotEmpty ) . . . [
Padding (
padding: const EdgeInsets . only ( top: 5 ) ,
child: Utils . statusContainerChip ( text: widget. adDetails . statuslabel ? ? " " , chipColor: Utils . getChipColorByAdStatus ( widget . adDetails . adPostStatus ! ) ) ,
child: Utils . statusContainerChip ( text: isArabic ? widget . adDetails . statuslabelN ? ? " " : widget. adDetails . statuslabel ? ? " " , chipColor: Utils . getChipColorByAdStatus ( widget . adDetails . adPostStatus ! ) ) ,
) ,
] ,
( widget . adDetails . vehicle ! . vehicleTitle ? ? " " ) . toText (
@ -347,7 +348,8 @@ class _AdCardState extends State<AdCard> {
) ,
2. width ,
Expanded (
child: " ${ widget . adDetails . vehicle ? . mileage ? . mileageStart ? ? " " } - ${ widget . adDetails . vehicle ? . mileage ? . mileageEnd ? ? " " } km " . toText (
child: " ${ widget . adDetails . vehicle ? . mileage ? . mileageStart ? ? " " } - ${ widget . adDetails . vehicle ? . mileage ? . mileageEnd ? ? " " } "
" ${ LocaleKeys . km . tr ( ) } " . toText (
overflow: TextOverflow . ellipsis ,
fontSize: 12 ,
letterSpacing: - 0.48 ,
@ -362,11 +364,15 @@ class _AdCardState extends State<AdCard> {
Column (
crossAxisAlignment: CrossAxisAlignment . end ,
mainAxisAlignment: MainAxisAlignment . start ,
/ / children: [
/ / ( widget . adDetails . vehicle ! . cityName ? ? " " ) . toText ( color: MyColors . lightTextColor , fontSize: 4 ) ,
/ / widget . adDetails . createdOn ! = null
/ / ? DateTime . parse ( widget . adDetails . createdOn ! ) . getTimeAgo ( isArabic: isArabic ) . toText ( color: MyColors . lightTextColor , fontSize: 4 )
/ / : const SizedBox ( ) ,
/ / ] ,
children: [
( widget . adDetails . vehicle ! . cityName ? ? " " ) . toText ( color: MyColors . lightTextColor , fontSize: 4 ) ,
widget . adDetails . createdOn ! = null
? DateTime . parse ( widget . adDetails . createdOn ! ) . getTimeAgo ( isArabic: isArabic ) . toText ( color: MyColors . lightTextColor , fontSize: 4 )
: const SizedBox ( ) ,
( isArabic ? widget . adDetails . vehicle ! . cityNameN ? ? " " : widget . adDetails . vehicle ! . cityName ? ? " " ) . toText ( color: MyColors . lightTextColor , fontSize: 4 ) ,
widget . adDetails . createdOn ! = null ? DateTime . parse ( widget . adDetails . createdOn ! ) . getTimeAgo ( isArabic: context . locale . languageCode = = ' ar ' , ) . toText ( color: MyColors . lightTextColor , fontSize: 4 ) : const SizedBox ( ) ,
] ,
) ,
] ,
@ -381,14 +387,17 @@ class _AdCardState extends State<AdCard> {
children: [
( widget . adDetails . vehicle ! . demandAmount ! . toInt ( ) . toString ( ) ) . toText ( fontSize: 19 , isBold: true , letterSpacing: - 1.16 , height: 29 / 19 ) ,
2. width ,
( widget. adDetails . vehicle ! . currency ? ? " " ) . toText ( color: MyColors . lightTextColor , fontSize: 10 , letterSpacing: - 0.4 , height: 16 / 10 ) . paddingOnly ( bottom: 3 ) ,
( isArabic ? widget . adDetails . vehicle ! . currencyN ? ? " " : widget. adDetails . vehicle ! . currency ? ? " " ) . toText ( color: MyColors . lightTextColor , fontSize: 10 , letterSpacing: - 0.4 , height: 16 / 10 ) . paddingOnly ( bottom: 3 ) ,
] ,
) ,
) ,
SvgPicture . asset (
MyAssets . arrowRight ,
height: 9.69 ,
width: 13 ,
Transform . flip (
flipX: isArabic ,
child: SvgPicture . asset (
MyAssets . arrowRight ,
height: 9.69 ,
width: 13 ,
) ,
) ,
/ / const Icon ( Icons . arrow_forward )