final
This commit is contained in:
@@ -3,10 +3,10 @@ import 'package:flutter/material.dart';
|
||||
|
||||
class ShowPrice extends StatelessWidget {
|
||||
final double price;
|
||||
final double regularPrice;
|
||||
final double? regularPrice;
|
||||
final double largeFontSize;
|
||||
final double smallFontSize;
|
||||
final String currencySign;
|
||||
final String? currencySign;
|
||||
final Color color;
|
||||
final FontWeight fontWeight;
|
||||
|
||||
@@ -36,7 +36,7 @@ class ShowPrice extends StatelessWidget {
|
||||
Container(
|
||||
padding: EdgeInsets.only(top: largeFontSize / 10.0),
|
||||
child: Text(
|
||||
currencySign,
|
||||
currencySign!,
|
||||
style: TextStyle(
|
||||
fontSize: smallFontSize,
|
||||
color: color,
|
||||
@@ -65,12 +65,12 @@ class ShowPrice extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
),
|
||||
regularPrice == null || price.round() >= regularPrice.round() ?
|
||||
regularPrice == null || price.round() >= regularPrice!.round() ?
|
||||
SizedBox.shrink() :
|
||||
Container(
|
||||
padding: EdgeInsets.only(top: largeFontSize / 2),
|
||||
child: Text(
|
||||
regularPrice.toStringAsFixed(0),
|
||||
'${regularPrice?.toStringAsFixed(0)}',
|
||||
style: TextStyle(
|
||||
color: Colors.black38,
|
||||
fontSize: smallFontSize,
|
||||
|
||||
Reference in New Issue
Block a user