You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
644 B
21 lines
644 B
import 'package:flutter/material.dart';
|
|
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|
import 'package:thesis_shop/stores/cart_store.dart';
|
|
|
|
class TotalPriceText extends ConsumerWidget {
|
|
const TotalPriceText({Key? key}) : super(key: key);
|
|
|
|
@override
|
|
Widget build(BuildContext context, ref) {
|
|
final totalPrice = ref.watch(totalPriceProvider).toStringAsFixed(2);
|
|
return SafeArea(
|
|
child: Padding(
|
|
padding: const EdgeInsets.all(8.0),
|
|
child: Text(
|
|
'Gesamtpreis: $totalPrice€',
|
|
style: Theme.of(context).textTheme.labelLarge?.copyWith(fontSize: 24),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|
|
|