mirror of
https://github.com/urosran/cally.git
synced 2025-07-15 01:35:22 +00:00
- Added delete button on the checked grocery items
This commit is contained in:
@ -134,6 +134,17 @@ const GroceryItem = ({
|
||||
) : (
|
||||
!isEditingTitle &&
|
||||
(isParent || isCaregiver) && (
|
||||
<View row>
|
||||
{item.bought &&
|
||||
<AntDesign
|
||||
name="close"
|
||||
size={24}
|
||||
style={{ color: "grey", marginRight: 10 }}
|
||||
onPress={() => {
|
||||
handleItemApproved(item.id, { approved: false });
|
||||
deleteGrocery(item.id);
|
||||
}}/>
|
||||
}
|
||||
<Checkbox
|
||||
value={item.bought}
|
||||
containerStyle={[styles.checkbox, { borderRadius: 50 }]}
|
||||
@ -145,6 +156,7 @@ const GroceryItem = ({
|
||||
updateGroceryItem({ id: item.id, bought: !item.bought })
|
||||
}
|
||||
/>
|
||||
</View>
|
||||
)
|
||||
)}
|
||||
</View>
|
||||
|
Reference in New Issue
Block a user