TF-1798 Fix error message is displayed behind the keyboard on IOS platform only
(cherry picked from commit 615ff21ce96440cb1da47720116efacb5328cc13)
This commit is contained in:
@@ -1457,6 +1457,8 @@ class ComposerController extends BaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void insertImage(BuildContext context, double maxWith) async {
|
void insertImage(BuildContext context, double maxWith) async {
|
||||||
|
clearFocusEditor(context);
|
||||||
|
|
||||||
if (_responsiveUtils.isMobile(context)) {
|
if (_responsiveUtils.isMobile(context)) {
|
||||||
maxWithEditor = maxWith - 40;
|
maxWithEditor = maxWith - 40;
|
||||||
} else {
|
} else {
|
||||||
@@ -1470,6 +1472,10 @@ class ComposerController extends BaseController {
|
|||||||
} else {
|
} else {
|
||||||
_insertImageOnMobileAndTablet(inlineImage);
|
_insertImageOnMobileAndTablet(inlineImage);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if (context.mounted) {
|
||||||
|
_appToast.showToastErrorMessage(context, AppLocalizations.of(context).cannotSelectThisImage);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ class PendingAttachmentUploadState extends Success {
|
|||||||
PendingAttachmentUploadState(this.uploadId, this.progress, this.total);
|
PendingAttachmentUploadState(this.uploadId, this.progress, this.total);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
List<Object?> get props => [progress, total];
|
List<Object?> get props => [uploadId, progress, total];
|
||||||
}
|
}
|
||||||
|
|
||||||
class UploadingAttachmentUploadState extends Success {
|
class UploadingAttachmentUploadState extends Success {
|
||||||
@@ -24,7 +24,7 @@ class UploadingAttachmentUploadState extends Success {
|
|||||||
UploadingAttachmentUploadState(this.uploadId, this.progress, this.total);
|
UploadingAttachmentUploadState(this.uploadId, this.progress, this.total);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
List<Object?> get props => [progress, total];
|
List<Object?> get props => [uploadId, progress, total];
|
||||||
}
|
}
|
||||||
|
|
||||||
class SuccessAttachmentUploadState extends Success {
|
class SuccessAttachmentUploadState extends Success {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"@@last_modified": "2023-04-12T12:10:00.382074",
|
"@@last_modified": "2023-05-05T18:33:11.589556",
|
||||||
"initializing_data": "Initializing data...",
|
"initializing_data": "Initializing data...",
|
||||||
"@initializing_data": {
|
"@initializing_data": {
|
||||||
"type": "text",
|
"type": "text",
|
||||||
@@ -2757,5 +2757,41 @@
|
|||||||
"type": "text",
|
"type": "text",
|
||||||
"placeholders_order": [],
|
"placeholders_order": [],
|
||||||
"placeholders": {}
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"forwardedMessage": "Forwarded message",
|
||||||
|
"@forwardedMessage": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"repliedMessage": "Replied message",
|
||||||
|
"@repliedMessage": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"repliedAndForwardedMessage": "Replied and Forwarded message",
|
||||||
|
"@repliedAndForwardedMessage": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"emptyTrash": "Empty Trash",
|
||||||
|
"@emptyTrash": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"emptyTrashMessageDialog": "You are about to permanently delete all items in Trash . Do you want to continue?",
|
||||||
|
"@emptyTrashMessageDialog": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
|
},
|
||||||
|
"cannotSelectThisImage": "Cannot select this image.",
|
||||||
|
"@cannotSelectThisImage": {
|
||||||
|
"type": "text",
|
||||||
|
"placeholders_order": [],
|
||||||
|
"placeholders": {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2863,4 +2863,10 @@ class AppLocalizations {
|
|||||||
'You are about to permanently delete all items in Trash . Do you want to continue?',
|
'You are about to permanently delete all items in Trash . Do you want to continue?',
|
||||||
name: 'emptyTrashMessageDialog');
|
name: 'emptyTrashMessageDialog');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
String get cannotSelectThisImage {
|
||||||
|
return Intl.message(
|
||||||
|
'Cannot select this image.',
|
||||||
|
name: 'cannotSelectThisImage');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user