mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-10 15:17:31 +00:00
push tab to run and handling automation
This commit is contained in:
@ -30,19 +30,25 @@ class ThenContainer extends StatelessWidget {
|
||||
fontSize: 18, fontWeight: FontWeight.bold)),
|
||||
const SizedBox(height: 16),
|
||||
Wrap(
|
||||
spacing: 8,
|
||||
runSpacing: 8,
|
||||
children: state.thenItems
|
||||
.map((item) => DraggableCard(
|
||||
// key: Key(item['key']!),
|
||||
imagePath: item['imagePath']!,
|
||||
title: item['title']!,
|
||||
deviceData: item,
|
||||
padding: EdgeInsets.symmetric(
|
||||
horizontal: 4, vertical: 8),
|
||||
))
|
||||
.toList(),
|
||||
),
|
||||
spacing: 8,
|
||||
runSpacing: 8,
|
||||
children: List.generate(
|
||||
state.thenItems.length,
|
||||
(index) => DraggableCard(
|
||||
imagePath:
|
||||
state.thenItems[index]['imagePath'] ?? '',
|
||||
title: state.thenItems[index]['title'] ?? '',
|
||||
deviceData: state.thenItems[index],
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: 4, vertical: 8),
|
||||
isFromThen: true,
|
||||
isFromIf: false,
|
||||
onRemove: () {
|
||||
context.read<RoutineBloc>().add(
|
||||
RemoveDragCard(
|
||||
index: index, isFromThen: true));
|
||||
},
|
||||
))),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
Reference in New Issue
Block a user