general UI chnages has been made

This commit is contained in:
Daniah Ayad Al-sultani
2025-12-14 13:05:32 +03:00
parent 489a99a0a3
commit 2ce0e0103e
5 changed files with 286 additions and 233 deletions

View File

@@ -123,10 +123,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
} catch (e) {
// Show an error message if something went wrong
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text('حدث خطأ: $e'),
backgroundColor: Colors.red,
),
SnackBar(content: Text('حدث خطأ: $e'), backgroundColor: Colors.red),
);
}
}
@@ -151,10 +148,9 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
),
// Title
const SizedBox(height: 30),
Expanded(
child: SingleChildScrollView(
// const SizedBox(height: 30),
Flexible(
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 25),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
@@ -172,7 +168,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
),
),
const SizedBox(height: 25),
const SizedBox(height: 10),
//=============================
// DROPDOWN: نوع الإجازة
//=============================
@@ -188,7 +184,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
),
),
const SizedBox(height: 6),
const SizedBox(height: 5),
// Modified dropdown with disabled state
Directionality(
@@ -306,8 +302,8 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
// ---------- TOGGLE ----------
AnimatedContainer(
duration: const Duration(milliseconds: 250),
width: 95,
height: 42,
width: 75,
height: 30,
padding: const EdgeInsets.symmetric(
horizontal: 4,
),
@@ -329,8 +325,8 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
: Alignment.centerLeft,
child: AnimatedContainer(
duration: const Duration(milliseconds: 250),
width: 40,
height: 40,
width: 30,
height: 30,
decoration: BoxDecoration(
color:
isTimedLeave
@@ -461,7 +457,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
),
),
const SizedBox(height: 25),
const SizedBox(height: 10),
// =============================
// REASON TEXTFIELD (Two Containers)
@@ -484,7 +480,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
// OUTER BORDER CONTAINER
Container(
padding: const EdgeInsets.all(
15,
12,
), // border thickness space
decoration: BoxDecoration(
border: Border.all(
@@ -496,7 +492,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
// INNER TEXTFIELD CONTAINER
child: Container(
height: 100,
height: 70,
padding: const EdgeInsets.symmetric(
horizontal: 14,
vertical: 10,
@@ -525,7 +521,7 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
),
),
const SizedBox(height: 70),
const SizedBox(height: 20),
// CONFIRM BUTTON
Center(
@@ -536,8 +532,6 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
onPressed: _saveLeaveRequest, // Call the save method
),
),
const SizedBox(height: 40),
],
),
),
@@ -642,4 +636,4 @@ class _RequestLeaveScreenState extends State<RequestLeaveScreen> {
return "";
}
}
}
}