fix: upgrade image_picker to 4.0.0

This commit is contained in:
mike doornenbal 2024-08-07 13:50:39 +02:00
parent 066cbe952e
commit 451f03ac5c
2 changed files with 15 additions and 17 deletions

View file

@ -184,22 +184,11 @@ Widget _createImagePickerContainer(
) { ) {
var theme = Theme.of(context); var theme = Theme.of(context);
return Container( return Container(
padding: const EdgeInsets.all(8.0), padding: const EdgeInsets.all(20),
color: Colors.white, color: Colors.white,
child: ImagePicker( child: ImagePicker(
imagePickerTheme: ImagePickerTheme( theme: ImagePickerTheme(
title: translations.imagePickerTitle, closeButtonBuilder: (ontap) => TextButton(
titleTextSize: 16,
titleAlignment: TextAlign.center,
iconSize: 40.0,
makePhotoText: translations.takePicture,
selectImageText: translations.uploadFile,
selectImageIcon: const Icon(
Icons.insert_drive_file_rounded,
size: 40,
),
),
customButton: TextButton(
onPressed: onClose, onPressed: onClose,
child: Text( child: Text(
translations.cancelImagePickerBtn, translations.cancelImagePickerBtn,
@ -209,6 +198,16 @@ Widget _createImagePickerContainer(
), ),
), ),
), ),
title: translations.imagePickerTitle,
titleStyle: theme.textTheme.titleMedium,
iconSize: 40.0,
makePhotoText: translations.takePicture,
selectImageText: translations.uploadFile,
selectImageIcon: const Icon(
Icons.insert_drive_file_rounded,
size: 40,
),
),
), ),
); );
} }

View file

@ -23,9 +23,8 @@ dependencies:
ref: 3.1.0 ref: 3.1.0
cached_network_image: ^3.2.2 cached_network_image: ^3.2.2
flutter_image_picker: flutter_image_picker:
git: hosted: https://forgejo.internal.iconica.nl/api/packages/internal/pub
url: https://github.com/Iconica-Development/flutter_image_picker version: ^4.0.0
ref: 1.0.5
flutter_profile: flutter_profile:
git: git:
ref: 1.5.0 ref: 1.5.0