From 1a830b7f44f1b22b991e7f08d7ecc6ac5a7a8cea Mon Sep 17 00:00:00 2001 From: Elham Rababah Date: Fri, 23 Apr 2021 23:28:52 +0300 Subject: [PATCH] make icon on top --- .../patients/profile/note/update_note.dart | 59 +++++++++++-------- .../referral/AddReplayOnReferralPatient.dart | 45 ++++++++------ 2 files changed, 61 insertions(+), 43 deletions(-) diff --git a/lib/screens/patients/profile/note/update_note.dart b/lib/screens/patients/profile/note/update_note.dart index 8c2f7a45..c9932e63 100644 --- a/lib/screens/patients/profile/note/update_note.dart +++ b/lib/screens/patients/profile/note/update_note.dart @@ -95,32 +95,41 @@ class _UpdateNoteOrderState extends State { widthFactor: 0.9, child: Column( children: [ - AppTextFieldCustom( - hintText: widget.visitType == 3 - ? (widget.isUpdate ? 'Update' : 'Add') + - ' Order Sheet' - : (widget.isUpdate ? 'Update' : 'Add') + - ' Progress Note', - //TranslationBase.of(context).addProgressNote, - controller: progressNoteController, - maxLines: 35, - minLines: 25, - hasBorder: true, - suffixIcon: IconButton( - icon: Icon( - DoctorApp.speechtotext, - color: Colors.black, + Stack( + children: [ + AppTextFieldCustom( + hintText: widget.visitType == 3 + ? (widget.isUpdate ? 'Update' : 'Add') + + ' Order Sheet' + : (widget.isUpdate ? 'Update' : 'Add') + + ' Progress Note', + //TranslationBase.of(context).addProgressNote, + controller: progressNoteController, + maxLines: 35, + minLines: 25, + hasBorder: true, + + // isTextFieldHasSuffix: true, + validationError: + progressNoteController.text.isEmpty && isSubmitted + ? TranslationBase.of(context).emptyMessage + : null, ), - onPressed: () { - onVoiceText(); - }, - ), - - isTextFieldHasSuffix: true, - validationError: - progressNoteController.text.isEmpty && isSubmitted - ? TranslationBase.of(context).emptyMessage - : null, + + Positioned( + top: 0,//MediaQuery.of(context).size.height * 0, + right: 15, + child: IconButton( + icon: Icon( + DoctorApp.speechtotext, + color: Colors.black, + ), + onPressed: () { + onVoiceText(); + }, + ), + ) + ], ), ], ), diff --git a/lib/screens/patients/profile/referral/AddReplayOnReferralPatient.dart b/lib/screens/patients/profile/referral/AddReplayOnReferralPatient.dart index 051fc6aa..1a90b708 100644 --- a/lib/screens/patients/profile/referral/AddReplayOnReferralPatient.dart +++ b/lib/screens/patients/profile/referral/AddReplayOnReferralPatient.dart @@ -69,25 +69,34 @@ class _AddReplayOnReferralPatientState extends State widthFactor: 0.9, child: Column( children: [ - AppTextFieldCustom( - hintText: 'Replay your responses here', - controller: progressNoteController, - maxLines: 35, - minLines: 25, - hasBorder: true, - suffixIcon: IconButton( - icon: Icon( - DoctorApp.speechtotext, - color: Colors.black, + Stack( + children: [ + AppTextFieldCustom( + hintText: 'Replay your responses here', + controller: progressNoteController, + maxLines: 35, + minLines: 25, + hasBorder: true, + validationError: + progressNoteController.text.isEmpty && + isSubmitted + ? TranslationBase.of(context).emptyMessage + : null, ), - onPressed: () { - onVoiceText(); - }, - ), - validationError: - progressNoteController.text.isEmpty && isSubmitted - ? TranslationBase.of(context).emptyMessage - : null, + Positioned( + top: 0,//MediaQuery.of(context).size.height * 0, + right: 15, + child: IconButton( + icon: Icon( + DoctorApp.speechtotext, + color: Colors.black, + ), + onPressed: () { + onVoiceText(); + }, + ), + ) + ], ), ], ),