Enlarge viewer controls and respect safe areas
This commit is contained in:
@@ -48,14 +48,18 @@ Widget diffFormControl(
|
||||
},
|
||||
children: {
|
||||
for (final entry in diffFormLabels.entries)
|
||||
entry.key: Padding(
|
||||
padding: const EdgeInsets.all(6),
|
||||
child: Text(entry.value),
|
||||
entry.key: ConstrainedBox(
|
||||
constraints: const BoxConstraints(minHeight: 44),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 6),
|
||||
child: Center(child: Text(entry.value)),
|
||||
),
|
||||
),
|
||||
},
|
||||
);
|
||||
}
|
||||
return SegmentedButton<DiffForm>(
|
||||
style: ButtonStyle(minimumSize: const WidgetStatePropertyAll(Size(0, 48))),
|
||||
segments: [
|
||||
for (final entry in diffFormLabels.entries)
|
||||
ButtonSegment(value: entry.key, label: Text(entry.value)),
|
||||
@@ -80,6 +84,7 @@ Widget diffFormMenu(
|
||||
button: true,
|
||||
child: CupertinoButton(
|
||||
padding: EdgeInsets.zero,
|
||||
minimumSize: const Size(44, 44),
|
||||
onPressed: () => showCupertinoModalPopup<void>(
|
||||
context: context,
|
||||
builder: (sheetContext) => CupertinoActionSheet(
|
||||
@@ -97,13 +102,15 @@ Widget diffFormMenu(
|
||||
],
|
||||
),
|
||||
),
|
||||
child: const Icon(CupertinoIcons.ellipsis),
|
||||
child: const Icon(CupertinoIcons.ellipsis, size: 30),
|
||||
),
|
||||
);
|
||||
}
|
||||
return IconButton(
|
||||
tooltip: 'Diff form',
|
||||
icon: const Icon(Icons.more_vert),
|
||||
constraints: const BoxConstraints(minWidth: 48, minHeight: 48),
|
||||
padding: EdgeInsets.zero,
|
||||
icon: const Icon(Icons.more_vert, size: 28),
|
||||
onPressed: () => showModalBottomSheet<void>(
|
||||
context: context,
|
||||
showDragHandle: true,
|
||||
|
||||
Reference in New Issue
Block a user