Vaibhav_Feature-#768 #59

Closed
vaibhav.surve wants to merge 74 commits from Vaibhav_Feature-#768 into Feature_Expense
Showing only changes of commit 5f66c4c647 - Show all commits

View File

@ -446,7 +446,7 @@ class _TileContainer extends StatelessWidget {
}
class _AttachmentsSection extends StatelessWidget {
final List<File> attachments;
final RxList<File> attachments;
final ValueChanged<File> onRemove;
final VoidCallback onAdd;
@ -458,27 +458,29 @@ class _AttachmentsSection extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Wrap(
spacing: 8,
runSpacing: 8,
children: [
...attachments.map((file) =>
_AttachmentTile(file: file, onRemove: () => onRemove(file))),
GestureDetector(
onTap: onAdd,
child: Container(
width: 80,
height: 80,
decoration: BoxDecoration(
border: Border.all(color: Colors.grey.shade400),
borderRadius: BorderRadius.circular(8),
color: Colors.grey.shade100,
return Obx(() => Wrap(
spacing: 8,
runSpacing: 8,
children: [
...attachments.map((file) => _AttachmentTile(
file: file,
onRemove: () => onRemove(file),
)),
GestureDetector(
onTap: onAdd,
child: Container(
width: 80,
height: 80,
decoration: BoxDecoration(
border: Border.all(color: Colors.grey.shade400),
borderRadius: BorderRadius.circular(8),
color: Colors.grey.shade100,
),
child: const Icon(Icons.add, size: 30, color: Colors.grey),
),
),
child: const Icon(Icons.add, size: 30, color: Colors.grey),
),
),
],
);
],
));
}
}