feat: Update image picker section to use dynamic primary color for icons and buttons
This commit is contained in:
parent
c78c14e409
commit
4d3a42e851
@ -291,6 +291,7 @@ class _ReportActionBottomSheetState extends State<ReportActionBottomSheet>
|
||||
onUploadTap: () => controller.pickImages(fromCamera: false),
|
||||
onRemoveImage: (index) => controller.removeImageAt(index),
|
||||
isProcessing: controller.isPickingImage.value,
|
||||
primaryColor: contentTheme.primary,
|
||||
onPreviewImage: (index) => showDialog(
|
||||
context: context,
|
||||
builder: (_) => ImageViewerDialog(
|
||||
@ -389,7 +390,7 @@ class _ReportActionBottomSheetState extends State<ReportActionBottomSheet>
|
||||
fontWeight: 600,
|
||||
),
|
||||
style: ElevatedButton.styleFrom(
|
||||
backgroundColor: Colors.indigo,
|
||||
backgroundColor: contentTheme.primary,
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(12)),
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
|
||||
@ -100,6 +100,7 @@ Widget buildImagePickerSection({
|
||||
required void Function(int index) onRemoveImage,
|
||||
required void Function(int initialIndex) onPreviewImage,
|
||||
required bool isProcessing, // New: show loader while image is being processed
|
||||
required Color primaryColor,
|
||||
}) {
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
@ -203,10 +204,10 @@ Widget buildImagePickerSection({
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const Icon(Icons.camera_alt,
|
||||
size: 16, color: Colors.blueAccent),
|
||||
Icon(Icons.camera_alt,
|
||||
size: 16, color: primaryColor),
|
||||
MySpacing.width(6),
|
||||
MyText.bodySmall('Capture', color: Colors.blueAccent),
|
||||
MyText.bodySmall('Capture', color: primaryColor),
|
||||
],
|
||||
),
|
||||
),
|
||||
@ -219,10 +220,10 @@ Widget buildImagePickerSection({
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const Icon(Icons.upload_file,
|
||||
size: 16, color: Colors.blueAccent),
|
||||
Icon(Icons.upload_file,
|
||||
size: 16, color: primaryColor),
|
||||
MySpacing.width(6),
|
||||
MyText.bodySmall('Upload', color: Colors.blueAccent),
|
||||
MyText.bodySmall('Upload', color: primaryColor),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user