ChecklistEditor: Make the Add Item more tappable

I would often tap on it and nothing would happen.
This commit is contained in:
Vishesh Handa
2020-05-08 10:15:36 +02:00
parent 62b5761ec4
commit 533d837b05
2 changed files with 11 additions and 5 deletions

View File

@ -20,3 +20,6 @@ settings:
usageStats: Collect Anonymous Usage Statistics
debug: Debug App
debugLog: Look under the hood
editors:
checklist:
add: Add Item

View File

@ -1,6 +1,7 @@
import 'dart:async';
import 'dart:io';
import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:gitjournal/core/checklist.dart';
@ -379,7 +380,7 @@ class AddItemButton extends StatelessWidget {
Widget build(BuildContext context) {
var style = Theme.of(context).textTheme.subhead;
return ListTile(
var tile = ListTile(
dense: true,
leading: Row(
children: <Widget>[
@ -397,10 +398,12 @@ class AddItemButton extends StatelessWidget {
],
mainAxisSize: MainAxisSize.min,
),
title: GestureDetector(
onTap: onPressed,
child: Text("Add Item", style: style),
),
title: Text(tr("editors.checklist.add"), style: style),
);
return GestureDetector(
onTap: onPressed,
child: tile,
);
}
}