restore options date display ui fix

This commit is contained in:
julian 2022-10-20 11:09:15 -06:00
parent a9e3b7696e
commit 6d77ecad3f
2 changed files with 8 additions and 9 deletions

View file

@ -273,6 +273,7 @@ class _RestoreOptionsViewState extends ConsumerState<RestoreOptionsView> {
// if (!isDesktop)
RestoreFromDatePicker(
onTap: chooseDate,
controller: _dateController,
),
// if (isDesktop)

View file

@ -5,10 +5,14 @@ import 'package:stackwallet/utilities/text_styles.dart';
import 'package:stackwallet/utilities/theme/stack_colors.dart';
class RestoreFromDatePicker extends StatefulWidget {
const RestoreFromDatePicker({Key? key, required this.onTap})
: super(key: key);
const RestoreFromDatePicker({
Key? key,
required this.onTap,
required this.controller,
}) : super(key: key);
final VoidCallback onTap;
final TextEditingController controller;
@override
State<RestoreFromDatePicker> createState() => _RestoreFromDatePickerState();
@ -21,17 +25,11 @@ class _RestoreFromDatePickerState extends State<RestoreFromDatePicker> {
@override
void initState() {
onTap = widget.onTap;
_dateController = TextEditingController();
_dateController = widget.controller;
super.initState();
}
@override
void dispose() {
_dateController.dispose();
super.dispose();
}
@override
Widget build(BuildContext context) {
return Container(