update chief complaint design

merge-requests/431/head
Elham Rababah 5 years ago
parent d8cce04b8a
commit 9559265a2d

@ -38,7 +38,7 @@ class ExpandableSOAPWidget extends StatelessWidget {
Texts(headerTitle, Texts(headerTitle,
variant: isExpanded ? "bodyText" : '', variant: isExpanded ? "bodyText" : '',
bold: isExpanded ? true : false, bold: isExpanded ? true : false,
fontSize: 20, fontSize: 15,
color: Colors.black), color: Colors.black),
Icon( Icon(
FontAwesomeIcons.asterisk, FontAwesomeIcons.asterisk,

@ -222,6 +222,7 @@ class StepsWidget extends StatelessWidget {
), ),
Center( Center(
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.end,
children: [ children: [
AppText( AppText(
"Plan", "Plan",

@ -28,80 +28,78 @@ class UpdateChiefComplaints extends StatelessWidget {
SizedBox( SizedBox(
height: 20, height: 20,
), ),
//TODO handel error cases
Container( NewTextFields(
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.all(
Radius.circular(10.0),
),
border: Border.all(
color: HexColor('#707070'),
width: 0.30),
),
child: NewTextFields(
hintText: TranslationBase.of(context).addChiefComplaints, hintText: TranslationBase.of(context).addChiefComplaints,
controller: complaintsController, controller: complaintsController,
),
),
Container(
margin:
EdgeInsets.only(left: 10, right: 10, top: 15),
child: TextFields(
hasLabelText: complaintsController.text != ''
? true
: false,
hintText: TranslationBase
.of(context)
.addChiefComplaints,
fontSize: 13.5,
// hintColor: Colors.black,
showLabelText: true,
fontWeight: FontWeight.w600,
maxLines: 25, maxLines: 25,
minLines: 13, minLines: 13,
controller: complaintsController,
validator: (value) {
if (value == null || value == "")
return TranslationBase.of(context)
.emptyMessage;
else if (value.length < 25)
return TranslationBase
.of(context)
.chiefComplaintLength;
//"";
else
return null;
}),
), ),
// Container(
// margin:
// EdgeInsets.only(left: 10, right: 10, top: 15),
// child: TextFields(
// hasLabelText: complaintsController.text != ''
// ? true
// : false,
// hintText: TranslationBase
// .of(context)
// .addChiefComplaints,
// fontSize: 13.5,
// // hintColor: Colors.black,
// showLabelText: true,
// fontWeight: FontWeight.w600,
// maxLines: 25,
// minLines: 13,
// controller: complaintsController,
// validator: (value) {
// if (value == null || value == "")
// return TranslationBase.of(context)
// .emptyMessage;
// else if (value.length < 25)
// return TranslationBase
// .of(context)
// .chiefComplaintLength;
// //"";
// else
// return null;
// }),
// ),
SizedBox( SizedBox(
height: 20, height: 20,
), ),
Container(
margin: NewTextFields(
EdgeInsets.only(left: 10, right: 10, top: 15), hintText: TranslationBase.of(context).historyOfPresentIllness,
child: TextFields( controller: illnessController,
hasLabelText:
illnessController.text != '' ? true : false,
showLabelText: true,
hintText: TranslationBase
.of(context)
.historyOfPresentIllness,
fontSize: 13.5,
// hintColor: Colors.black,
fontWeight: FontWeight.w600,
maxLines: 25, maxLines: 25,
minLines: 13, minLines: 13,
controller: illnessController,
validator: (value) {
if (value == null || value == "")
return TranslationBase.of(context)
.emptyMessage;
else
return null;
}),
), ),
// Container(
// margin:
// EdgeInsets.only(left: 10, right: 10, top: 15),
// child: TextFields(
// hasLabelText:
// illnessController.text != '' ? true : false,
// showLabelText: true,
// hintText: TranslationBase
// .of(context)
// .historyOfPresentIllness,
// fontSize: 13.5,
// // hintColor: Colors.black,
// fontWeight: FontWeight.w600,
// maxLines: 25,
// minLines: 13,
// controller: illnessController,
// validator: (value) {
// if (value == null || value == "")
// return TranslationBase.of(context)
// .emptyMessage;
// else
// return null;
// }),
// ),
SizedBox( SizedBox(
height: 20, height: 20,
), ),
@ -114,31 +112,38 @@ class UpdateChiefComplaints extends StatelessWidget {
SizedBox( SizedBox(
height: 10, height: 10,
), ),
Container( // Container(
margin: // margin:
EdgeInsets.only(left: 10, right: 10, top: 15), // EdgeInsets.only(left: 10, right: 10, top: 15),
child: TextFields( // child: TextFields(
hasLabelText: medicationController.text != '' // hasLabelText: medicationController.text != ''
? true // ? true
: false, // : false,
showLabelText: true, // showLabelText: true,
hintText: TranslationBase // hintText: TranslationBase
.of(context) // .of(context)
.currentMedications, // .currentMedications,
fontSize: 13.5, // fontSize: 13.5,
// hintColor: Colors.black, // // hintColor: Colors.black,
fontWeight: FontWeight.w600, // fontWeight: FontWeight.w600,
// maxLines: 23,
// minLines: 10,
// controller: medicationController,
// validator: (value) {
// if (value == null || value == "")
// return TranslationBase
// .of(context)
// .emptyMessage;
// else
// return null;
// }),
// ),
NewTextFields(
hintText: TranslationBase.of(context).currentMedications,
controller: medicationController,
maxLines: 23, maxLines: 23,
minLines: 10, minLines: 10,
controller: medicationController,
validator: (value) {
if (value == null || value == "")
return TranslationBase
.of(context)
.emptyMessage;
else
return null;
}),
), ),
SizedBox( SizedBox(
height: 10, height: 10,

@ -2,6 +2,7 @@ import 'package:eva_icons_flutter/eva_icons_flutter.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:hexcolor/hexcolor.dart';
class NumberTextInputFormatter extends TextInputFormatter { class NumberTextInputFormatter extends TextInputFormatter {
@override @override
@ -158,9 +159,15 @@ class _NewTextFieldsState extends State<NewTextFields> {
duration: Duration(milliseconds: 300), duration: Duration(milliseconds: 300),
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(12), borderRadius: BorderRadius.circular(12),
border: Border.all(
color: HexColor('#707070'),
width: 0.30),
color: Colors.white), color: Colors.white),
child: Container( child: Container(
margin: EdgeInsets.only(top: 8), margin: EdgeInsets.only(top: 8),
padding: EdgeInsets.only(top: 8),
child: TextFormField( child: TextFormField(
enabled: widget.isEnabled, enabled: widget.isEnabled,
initialValue: widget.initialValue, initialValue: widget.initialValue,

Loading…
Cancel
Save