added spacing at the end of the form and delete button for alarms
This commit is contained in:
@@ -168,7 +168,10 @@ class _TaskEditPageState extends State<TaskEditPage> {
|
||||
icon: Icon(Icons.location_on),
|
||||
),
|
||||
for (final (index, alarmRequest) in alarmRequests.indexed)
|
||||
AlarmForm(
|
||||
Row(
|
||||
children: [
|
||||
Expanded(
|
||||
child: AlarmForm(
|
||||
request: alarmRequest,
|
||||
onChanged: (updated) {
|
||||
setState(() {
|
||||
@@ -176,6 +179,16 @@ class _TaskEditPageState extends State<TaskEditPage> {
|
||||
});
|
||||
},
|
||||
),
|
||||
),
|
||||
IconButton(
|
||||
onPressed: () => setState(() {
|
||||
alarmRequests.removeAt(index);
|
||||
}),
|
||||
icon: Icon(Icons.close),
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(height: 120),
|
||||
],
|
||||
),
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user