show free text against free plan
This commit is contained in:
parent
daa61af183
commit
4b039089c3
|
@ -16,6 +16,11 @@ class SubscriptionPlanWidget extends StatelessWidget {
|
||||||
final String period;
|
final String period;
|
||||||
final bool isActive;
|
final bool isActive;
|
||||||
|
|
||||||
|
String _displayPrice() {
|
||||||
|
var result = price + (period.isNotEmpty ? " per " + period : "");
|
||||||
|
return result.isNotEmpty ? result : "free";
|
||||||
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Container(
|
return Container(
|
||||||
|
@ -49,7 +54,7 @@ class SubscriptionPlanWidget extends StatelessWidget {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Text(price + (period.isNotEmpty ? " per " + period : "")),
|
Text(_displayPrice()),
|
||||||
Expanded(child: Container()),
|
Expanded(child: Container()),
|
||||||
isActive
|
isActive
|
||||||
? Expanded(
|
? Expanded(
|
||||||
|
|
Loading…
Reference in a new issue