|
|
|
@ -487,7 +487,8 @@ class _AttachmentPickerState extends State<AttachmentPicker> {
|
|
|
|
return Container(
|
|
|
|
return Container(
|
|
|
|
padding: const EdgeInsets.all(12),
|
|
|
|
padding: const EdgeInsets.all(12),
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
color: Colors.white,
|
|
|
|
color: AppColor.background(context),
|
|
|
|
|
|
|
|
// color: Colors.white,
|
|
|
|
borderRadius: BorderRadius.circular(12),
|
|
|
|
borderRadius: BorderRadius.circular(12),
|
|
|
|
border: Border.all(color: const Color(0xffF1F1F1), width: 1),
|
|
|
|
border: Border.all(color: const Color(0xffF1F1F1), width: 1),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
@ -495,7 +496,7 @@ class _AttachmentPickerState extends State<AttachmentPicker> {
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
icon.toSvgAsset(color: const Color(0xff7D859A), width: 36, height: 36),
|
|
|
|
icon.toSvgAsset(color: AppColor.iconColor(context), width: 36, height: 36),
|
|
|
|
// Icon(iconData, color: const Color(0xff7D859A), size: 36),
|
|
|
|
// Icon(iconData, color: const Color(0xff7D859A), size: 36),
|
|
|
|
Text(
|
|
|
|
Text(
|
|
|
|
label,
|
|
|
|
label,
|
|
|
|
@ -508,74 +509,78 @@ class _AttachmentPickerState extends State<AttachmentPicker> {
|
|
|
|
|
|
|
|
|
|
|
|
return SafeArea(
|
|
|
|
return SafeArea(
|
|
|
|
top: false,
|
|
|
|
top: false,
|
|
|
|
child: Column(
|
|
|
|
child: Container(
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
width: double.infinity,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
color: AppColor.background(context),
|
|
|
|
children: [
|
|
|
|
child: Column(
|
|
|
|
"Attach File".heading4(context),
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
12.height,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
GridView(
|
|
|
|
children: [
|
|
|
|
padding: const EdgeInsets.all(0),
|
|
|
|
"Attach File".heading4(context),
|
|
|
|
shrinkWrap: true,
|
|
|
|
12.height,
|
|
|
|
physics: const NeverScrollableScrollPhysics(),
|
|
|
|
GridView(
|
|
|
|
gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 3, childAspectRatio: 1, crossAxisSpacing: 12, mainAxisSpacing: 12),
|
|
|
|
padding: const EdgeInsets.all(0),
|
|
|
|
children: <Widget>[
|
|
|
|
shrinkWrap: true,
|
|
|
|
listCard(
|
|
|
|
physics: const NeverScrollableScrollPhysics(),
|
|
|
|
icon: 'camera_icon',
|
|
|
|
gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 3, childAspectRatio: 1, crossAxisSpacing: 12, mainAxisSpacing: 12),
|
|
|
|
label: '${context.translation.open}\n${context.translation.camera}',
|
|
|
|
children: <Widget>[
|
|
|
|
onTap: () {
|
|
|
|
listCard(
|
|
|
|
Navigator.of(context).pop(ImageSource.camera);
|
|
|
|
icon: 'camera_icon',
|
|
|
|
},
|
|
|
|
label: '${context.translation.open}\n${context.translation.camera}',
|
|
|
|
),
|
|
|
|
onTap: () {
|
|
|
|
listCard(
|
|
|
|
Navigator.of(context).pop(ImageSource.camera);
|
|
|
|
icon: 'gallery_icon',
|
|
|
|
},
|
|
|
|
label: '${context.translation.open}\n${context.translation.gallery}',
|
|
|
|
),
|
|
|
|
onTap: () {
|
|
|
|
listCard(
|
|
|
|
Navigator.of(context).pop(ImageSource.gallery);
|
|
|
|
icon: 'gallery_icon',
|
|
|
|
},
|
|
|
|
label: '${context.translation.open}\n${context.translation.gallery}',
|
|
|
|
),
|
|
|
|
onTap: () {
|
|
|
|
listCard(
|
|
|
|
Navigator.of(context).pop(ImageSource.gallery);
|
|
|
|
icon: 'file_icon',
|
|
|
|
},
|
|
|
|
label: '${context.translation.open}\n${context.translation.files}',
|
|
|
|
),
|
|
|
|
onTap: () async {
|
|
|
|
listCard(
|
|
|
|
await fromFilePicker();
|
|
|
|
icon: 'file_icon',
|
|
|
|
Navigator.pop(context);
|
|
|
|
label: '${context.translation.open}\n${context.translation.files}',
|
|
|
|
},
|
|
|
|
onTap: () async {
|
|
|
|
),
|
|
|
|
await fromFilePicker();
|
|
|
|
],
|
|
|
|
Navigator.pop(context);
|
|
|
|
),
|
|
|
|
},
|
|
|
|
// Container(
|
|
|
|
),
|
|
|
|
// padding: const EdgeInsets.all(16.0),
|
|
|
|
],
|
|
|
|
// child: Row(
|
|
|
|
),
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
// Container(
|
|
|
|
// children: <Widget>[
|
|
|
|
// padding: const EdgeInsets.all(16.0),
|
|
|
|
// listCard(
|
|
|
|
// child: Row(
|
|
|
|
// icon: 'camera_icon',
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
// label: '${context.translation.open}\n${context.translation.camera}',
|
|
|
|
// children: <Widget>[
|
|
|
|
// onTap: () {
|
|
|
|
// listCard(
|
|
|
|
// Navigator.of(context).pop(ImageSource.camera);
|
|
|
|
// icon: 'camera_icon',
|
|
|
|
// },
|
|
|
|
// label: '${context.translation.open}\n${context.translation.camera}',
|
|
|
|
// ),
|
|
|
|
// onTap: () {
|
|
|
|
// listCard(
|
|
|
|
// Navigator.of(context).pop(ImageSource.camera);
|
|
|
|
// icon: 'gallery_icon',
|
|
|
|
// },
|
|
|
|
// label: '${context.translation.open}\n${context.translation.gallery}',
|
|
|
|
// ),
|
|
|
|
// onTap: () {
|
|
|
|
// listCard(
|
|
|
|
// Navigator.of(context).pop(ImageSource.gallery);
|
|
|
|
// icon: 'gallery_icon',
|
|
|
|
// },
|
|
|
|
// label: '${context.translation.open}\n${context.translation.gallery}',
|
|
|
|
// ),
|
|
|
|
// onTap: () {
|
|
|
|
// listCard(
|
|
|
|
// Navigator.of(context).pop(ImageSource.gallery);
|
|
|
|
// icon: 'file_icon',
|
|
|
|
// },
|
|
|
|
// label: '${context.translation.open}\n${context.translation.files}',
|
|
|
|
// ),
|
|
|
|
// onTap: () async {
|
|
|
|
// listCard(
|
|
|
|
// await fromFilePicker();
|
|
|
|
// icon: 'file_icon',
|
|
|
|
// Navigator.pop(context);
|
|
|
|
// label: '${context.translation.open}\n${context.translation.files}',
|
|
|
|
// },
|
|
|
|
// onTap: () async {
|
|
|
|
// ),
|
|
|
|
// await fromFilePicker();
|
|
|
|
// ],
|
|
|
|
// Navigator.pop(context);
|
|
|
|
// ),
|
|
|
|
// },
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
],
|
|
|
|
// ],
|
|
|
|
).paddingAll(16),
|
|
|
|
// ),
|
|
|
|
|
|
|
|
// ),
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
).paddingAll(16),
|
|
|
|
|
|
|
|
),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|