UI_SEMATICS
This commit is contained in:
parent
07cc47d8bb
commit
a7310238c0
@ -137,7 +137,7 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
_hotelNameFocusNode,
|
||||
(focus) => _isHotelNameFocused = focus,
|
||||
);
|
||||
_addFocusListener( _CategoryFocusNode, (focus) => _CategoryFocused = focus);
|
||||
_addFocusListener(_CategoryFocusNode, (focus) => _CategoryFocused = focus);
|
||||
_addFocusListener(_checkInFocusNode, (focus) => _checkInFocus = focus);
|
||||
_addFocusListener(
|
||||
_checkInTimeFocusNode,
|
||||
@ -201,7 +201,7 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
// flightLastTripDateNotifier.value = checkoutDate;
|
||||
// }
|
||||
|
||||
final tripType = result['tripType'] ;
|
||||
final tripType = result['tripType'];
|
||||
|
||||
if (checkinDate != null) {
|
||||
flightFirstTripDateNotifier.value = checkinDate;
|
||||
@ -230,7 +230,9 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
final checkInDateInput = flightFirstTripDateNotifier.value;
|
||||
if (checkInDateInput != null && checkInDateInput.isNotEmpty) {
|
||||
try {
|
||||
final parsedDate = DateFormat("dd-MM-yyyy").parseStrict(checkInDateInput);
|
||||
final parsedDate = DateFormat(
|
||||
"dd-MM-yyyy",
|
||||
).parseStrict(checkInDateInput);
|
||||
_checkInController.text = DateFormat("dd-MM-yyyy").format(parsedDate);
|
||||
} catch (e) {
|
||||
_checkInController.text = '';
|
||||
@ -241,8 +243,12 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
final checkOutDateInput = flightLastTripDateNotifier.value;
|
||||
if (checkOutDateInput != null && checkOutDateInput.isNotEmpty) {
|
||||
try {
|
||||
final parsedDate = DateFormat("dd-MM-yyyy").parseStrict(checkOutDateInput);
|
||||
_checkOutController.text = DateFormat("dd-MM-yyyy").format(parsedDate);
|
||||
final parsedDate = DateFormat(
|
||||
"dd-MM-yyyy",
|
||||
).parseStrict(checkOutDateInput);
|
||||
_checkOutController.text = DateFormat(
|
||||
"dd-MM-yyyy",
|
||||
).format(parsedDate);
|
||||
} catch (e) {
|
||||
_checkOutController.text = '';
|
||||
}
|
||||
@ -581,7 +587,7 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
final List<String> items = ['Apple', 'Banana', 'Orange', 'Mango'];
|
||||
// Default selected value
|
||||
// selectedClass ??=
|
||||
// dropdownItems.isNotEmpty ? dropdownItems.first.value : null;
|
||||
@ -619,7 +625,7 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
width:
|
||||
isDesktop
|
||||
? MediaQuery.of(context).size.width * 0.34
|
||||
: null,//MediaQuery.of(context).size.width * 0.66,
|
||||
: null, //MediaQuery.of(context).size.width * 0.66,
|
||||
child: SizedBox(
|
||||
height: 40,
|
||||
child: TextField(
|
||||
@ -660,6 +666,7 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
SizedBox(height: 5),
|
||||
CustomTextFieldItnerarySubWrapper(
|
||||
isFocused: _isHotelNameFocused,
|
||||
|
||||
isDesktop: isDesktop,
|
||||
// width:
|
||||
// isDesktop
|
||||
@ -726,11 +733,10 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
_CategoryFocusNode?.requestFocus();
|
||||
},
|
||||
child: DropdownSearch<Map<String, dynamic>>(
|
||||
key:
|
||||
selectedClass == null
|
||||
? UniqueKey()
|
||||
: ValueKey(selectedClass),
|
||||
|
||||
// key:
|
||||
// selectedClass == null
|
||||
// ? UniqueKey()
|
||||
// : ValueKey(selectedClass),
|
||||
items: purposeList.cast<Map<String, dynamic>>(),
|
||||
// selectedItem: purposeList.firstWhere(
|
||||
// (item) => item['dropdown_key'] == selectedClass,
|
||||
@ -761,7 +767,10 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
item['dropdown_value'] ?? '',
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: isNotAllowed ? Colors.redAccent : Colors.black,
|
||||
color:
|
||||
isNotAllowed
|
||||
? Colors.redAccent
|
||||
: Colors.black,
|
||||
),
|
||||
),
|
||||
);
|
||||
@ -858,7 +867,9 @@ class _AccomodationScreenState extends State<AccomodationScreen> {
|
||||
}
|
||||
}
|
||||
: null,
|
||||
),),),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (errorMessages["class"] != null) ...[
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -674,10 +674,10 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
_typeOfClassFocusNode?.requestFocus();
|
||||
},
|
||||
child: DropdownSearch<Map<String, dynamic>>(
|
||||
key:
|
||||
selectedClass == null
|
||||
? UniqueKey()
|
||||
: ValueKey(selectedClass),
|
||||
// key:
|
||||
// selectedClass == null
|
||||
// ? UniqueKey()
|
||||
// : ValueKey(selectedClass),
|
||||
items: purposeList.cast<Map<String, dynamic>>(),
|
||||
|
||||
// selectedItem: purposeList.firstWhere(
|
||||
@ -707,7 +707,10 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
item['dropdown_value'] ?? '',
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: isNotAllowed ? Colors.redAccent : Colors.black,
|
||||
color:
|
||||
isNotAllowed
|
||||
? Colors.redAccent
|
||||
: Colors.black,
|
||||
),
|
||||
),
|
||||
);
|
||||
@ -818,7 +821,9 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
});
|
||||
}
|
||||
: null,
|
||||
),),)
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (errorMessages["class"] != null) ...[
|
||||
@ -953,7 +958,9 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
popupProps: PopupProps.menu(
|
||||
showSearchBox: true,
|
||||
fit: FlexFit.loose,
|
||||
constraints: BoxConstraints(maxHeight: 150),// maxHeight: 250
|
||||
constraints: BoxConstraints(
|
||||
maxHeight: 150,
|
||||
), // maxHeight: 250
|
||||
menuProps: const MenuProps(backgroundColor: Colors.white),
|
||||
itemBuilder:
|
||||
(context, item, isSelected) => Container(
|
||||
@ -1024,7 +1031,9 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
.key;
|
||||
});
|
||||
},
|
||||
),),)
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (errorMessages["from_station"] != null) ...[
|
||||
@ -1193,7 +1202,9 @@ class _TrainScreenState extends State<TrainScreen> {
|
||||
.key;
|
||||
});
|
||||
},
|
||||
),),),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
if (errorMessages["to_station"] != null) ...[
|
||||
|
||||
@ -768,9 +768,11 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "NA1",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
|
||||
color:
|
||||
Colors
|
||||
.black, // You can customize this
|
||||
@ -802,6 +804,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
selectedItem,
|
||||
) => Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "NA1",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -845,6 +848,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "NPP1",
|
||||
size: 15,
|
||||
color:
|
||||
(SelectedParallelProcess[ServiceId] ==
|
||||
@ -945,6 +949,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "NA2",
|
||||
style: TextStyle(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -978,6 +983,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
context,
|
||||
selectedItem,
|
||||
) => Text(
|
||||
semanticsLabel: "NA2",
|
||||
selectedItem ?? "Select",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
@ -1023,6 +1029,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
size: 15,
|
||||
semanticLabel: "NPP2",
|
||||
color:
|
||||
((SelectedParallelProcess[ServiceId] ==
|
||||
"1") ||
|
||||
@ -1128,6 +1135,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "NA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -1161,6 +1169,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// Center-align selected item
|
||||
Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "NA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -1204,6 +1213,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "NPP3",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelProcess[ServiceId] ==
|
||||
@ -1409,6 +1419,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "EA1",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -1486,6 +1497,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "EPP1",
|
||||
size: 15,
|
||||
color:
|
||||
(SelectedParallelExceptionalProcess[ServiceId] ==
|
||||
@ -1588,6 +1600,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "EA2",
|
||||
style: TextStyle(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -1622,6 +1635,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
selectedItem,
|
||||
) => Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "EA2",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -1665,6 +1679,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "EPP2",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelExceptionalProcess[ServiceId] ==
|
||||
@ -1774,6 +1789,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "EA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -1807,6 +1823,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// Center-align selected item
|
||||
Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "EA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -1849,6 +1866,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "EPP3",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelExceptionalProcess[ServiceId] ==
|
||||
@ -1966,6 +1984,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "EA4",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -1999,6 +2018,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// Center-align selected item
|
||||
Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "EA4",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -2055,7 +2075,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
size: 15,
|
||||
|
||||
semanticLabel: "EPP4",
|
||||
color:
|
||||
((SelectedParallelExceptionalProcess[ServiceId] ==
|
||||
"1") ||
|
||||
@ -2216,6 +2236,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "AA1",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -2250,6 +2271,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
selectedItem,
|
||||
) => Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "AA1",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -2293,6 +2315,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "AAPP1",
|
||||
size: 15,
|
||||
color:
|
||||
(SelectedParallelAmendProcess[ServiceId] ==
|
||||
@ -2395,6 +2418,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "AA2",
|
||||
style: TextStyle(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -2429,6 +2453,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
selectedItem,
|
||||
) => Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "AA2",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -2472,6 +2497,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "AAPP2",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelAmendProcess[ServiceId] ==
|
||||
@ -2582,6 +2608,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "AA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -2615,6 +2642,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// Center-align selected item
|
||||
Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "AA3",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -2657,6 +2685,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
width: 25,
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "AAPP3",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelAmendProcess[ServiceId] ==
|
||||
@ -2774,6 +2803,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
),
|
||||
child: Text(
|
||||
item,
|
||||
semanticsLabel: "AA4",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize:
|
||||
12, // 👈 Smaller text size here
|
||||
@ -2807,6 +2837,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// Center-align selected item
|
||||
Text(
|
||||
selectedItem ?? "Select",
|
||||
semanticsLabel: "AA4",
|
||||
style: GoogleFonts.poppins(
|
||||
fontSize: 12,
|
||||
color: Color(0xFF114D8B),
|
||||
@ -2862,6 +2893,7 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
// ),
|
||||
child: Icon(
|
||||
Icons.circle,
|
||||
semanticLabel: "AAPP4",
|
||||
size: 15,
|
||||
color:
|
||||
((SelectedParallelAmendProcess[ServiceId] ==
|
||||
@ -3048,10 +3080,10 @@ class PolicyCriteriaState extends State<PolicyCriteria> {
|
||||
(ServiceId!) != null && (isLoading || dropdownItems.isEmpty)
|
||||
? const Center(child: CircularProgressIndicator())
|
||||
: DropdownSearch<Map<String, dynamic>>(
|
||||
key:
|
||||
classAction[(ServiceId!)] == null
|
||||
? UniqueKey()
|
||||
: ValueKey(classAction[(ServiceId!)]),
|
||||
// key:
|
||||
// classAction[(ServiceId!)] == null
|
||||
// ? UniqueKey()
|
||||
// : ValueKey(classAction[(ServiceId!)]),
|
||||
items: purposeList.cast<Map<String, dynamic>>(),
|
||||
|
||||
// selectedItem: purposeList.firstWhere(
|
||||
|
||||
Loading…
Reference in New Issue
Block a user