diff --git a/frontend/app_info.txt b/frontend/app_info.txt deleted file mode 100644 index 89f5596..0000000 --- a/frontend/app_info.txt +++ /dev/null @@ -1,11 +0,0 @@ -Wesal App - Connecting Colleagues - -Wesal (وصال) is a social networking mobile application designed specifically for connecting colleagues and transforming workplace social interactions. The app name is Arabic for "connection" or "union." - -It is a platform that enhances communication and collaboration among division members allowing them to build deeper connections and share experiences beyond formal work-related discussions. - -The app was fully developed by Saleh Bubshait within the COD/DPSD/ERP Mgmt Group. However, the app was proposed by Weed Batarfi and Insijam team. - -The app is being minimally maintained but is not actively developed at the moment as the developer is currently on assignment. For any help or inquiries, please reach out to the DPSD/ERP Mgmt Group. - -Thank you for using Wesal! \ No newline at end of file diff --git a/frontend/assets/app_info.txt b/frontend/assets/app_info.txt index 6a0710c..89f5596 100644 --- a/frontend/assets/app_info.txt +++ b/frontend/assets/app_info.txt @@ -2,15 +2,10 @@ Wesal App - Connecting Colleagues Wesal (وصال) is a social networking mobile application designed specifically for connecting colleagues and transforming workplace social interactions. The app name is Arabic for "connection" or "union." -Features: -• Social feed for sharing updates and thoughts -• Event invitations and RSVP management -• Real-time notifications for engagement -• Profile management and customization -• Secure authentication and data protection +It is a platform that enhances communication and collaboration among division members allowing them to build deeper connections and share experiences beyond formal work-related discussions. -This application was developed to foster better communication and stronger relationships among team members, making workplace collaboration more enjoyable and effective. +The app was fully developed by Saleh Bubshait within the COD/DPSD/ERP Mgmt Group. However, the app was proposed by Weed Batarfi and Insijam team. -For technical support or account-related inquiries, please contact the ERP Management Group from your official company email address. +The app is being minimally maintained but is not actively developed at the moment as the developer is currently on assignment. For any help or inquiries, please reach out to the DPSD/ERP Mgmt Group. Thank you for using Wesal! \ No newline at end of file diff --git a/frontend/lib/screens/create_post_screen.dart b/frontend/lib/screens/create_post_screen.dart index 09598bb..a10985d 100644 --- a/frontend/lib/screens/create_post_screen.dart +++ b/frontend/lib/screens/create_post_screen.dart @@ -34,7 +34,7 @@ class _CreatePostScreenState extends State { try { final result = await PostService.createPost(_bodyController.text.trim()); - + if (result['success']) { Navigator.of(context).pop(true); // Return true to indicate success ScaffoldMessenger.of(context).showSnackBar( @@ -73,182 +73,190 @@ class _CreatePostScreenState extends State { return PopScope( canPop: true, // Allow back navigation to go back to feed page only child: Scaffold( - appBar: AppBar( - title: Text('Create Post', style: TextStyle(fontWeight: FontWeight.w600)), - backgroundColor: Colors.white, - foregroundColor: Color(0xFF6A4C93), - elevation: 0, - bottom: PreferredSize( - preferredSize: Size.fromHeight(1), - child: Container(height: 1, color: Colors.grey[200]), - ), - actions: [ - TextButton( - onPressed: _isLoading || isOverLimit || _bodyController.text.trim().isEmpty - ? null - : _createPost, - child: _isLoading - ? SizedBox( - width: 20, - height: 20, - child: CircularProgressIndicator( - strokeWidth: 2, - valueColor: AlwaysStoppedAnimation(Color(0xFF6A4C93)), - ), - ) - : Text( - 'Post', - style: TextStyle( - color: _bodyController.text.trim().isEmpty || isOverLimit - ? Colors.grey - : Color(0xFF6A4C93), - fontWeight: FontWeight.w600, - fontSize: 16, - ), - ), + appBar: AppBar( + title: Text( + 'Create Post', + style: TextStyle(fontWeight: FontWeight.w600), ), - SizedBox(width: 16), - ], - ), - body: Container( - decoration: BoxDecoration( - gradient: LinearGradient( - begin: Alignment.topLeft, - end: Alignment.bottomRight, - colors: [ - Color(0xFF32B0A5).withOpacity(0.05), - Color(0xFF4600B9).withOpacity(0.05), - ], + backgroundColor: Colors.white, + foregroundColor: Color(0xFF6A4C93), + elevation: 0, + bottom: PreferredSize( + preferredSize: Size.fromHeight(1), + child: Container(height: 1, color: Colors.grey[200]), ), - ), - child: Padding( - padding: EdgeInsets.all(16), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Container( - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(12), - boxShadow: [ - BoxShadow( - color: Colors.black.withOpacity(0.05), - blurRadius: 10, - offset: Offset(0, 2), + actions: [ + TextButton( + onPressed: + _isLoading || + isOverLimit || + _bodyController.text.trim().isEmpty + ? null + : _createPost, + child: _isLoading + ? SizedBox( + width: 20, + height: 20, + child: CircularProgressIndicator( + strokeWidth: 2, + valueColor: AlwaysStoppedAnimation( + Color(0xFF6A4C93), + ), + ), + ) + : Text( + 'Post', + style: TextStyle( + color: + _bodyController.text.trim().isEmpty || isOverLimit + ? Colors.grey + : Color(0xFF6A4C93), + fontWeight: FontWeight.w600, + fontSize: 16, + ), ), - ], - ), - child: Padding( - padding: EdgeInsets.all(16), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - "What's on your mind?", - style: TextStyle( - fontSize: 18, - fontWeight: FontWeight.w600, - color: Color(0xFF6A4C93), - ), + ), + SizedBox(width: 16), + ], + ), + body: Container( + decoration: BoxDecoration( + gradient: LinearGradient( + begin: Alignment.topLeft, + end: Alignment.bottomRight, + colors: [ + Color(0xFF32B0A5).withOpacity(0.05), + Color(0xFF4600B9).withOpacity(0.05), + ], + ), + ), + child: Padding( + padding: EdgeInsets.all(16), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Container( + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(12), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.05), + blurRadius: 10, + offset: Offset(0, 2), ), - SizedBox(height: 16), - TextField( - controller: _bodyController, - maxLines: 6, - decoration: InputDecoration( - hintText: 'Share your thoughts...', - hintStyle: TextStyle(color: Colors.grey[500]), - border: InputBorder.none, - enabledBorder: InputBorder.none, - focusedBorder: InputBorder.none, - ), - style: TextStyle( - fontSize: 16, - height: 1.4, - color: Colors.black87, - ), - onChanged: (text) { - setState(() {}); - }, - ), - SizedBox(height: 16), - Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Text( - 'Share your thoughts with the community', - style: TextStyle( - color: Colors.grey[600], - fontSize: 12, - ), - ), - Text( - '$remainingChars', - style: TextStyle( - color: isOverLimit ? Colors.red : Colors.grey[600], - fontSize: 12, - fontWeight: FontWeight.w500, - ), - ), - ], - ), - if (isOverLimit) - Padding( - padding: EdgeInsets.only(top: 8), - child: Text( - 'Post is too long. Please keep it under $_maxCharacters characters.', - style: TextStyle( - color: Colors.red, - fontSize: 12, - ), - ), - ), ], ), - ), - ), - SizedBox(height: 24), - Container( - decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(12), - boxShadow: [ - BoxShadow( - color: Colors.black.withOpacity(0.05), - blurRadius: 10, - offset: Offset(0, 2), - ), - ], - ), - child: Padding( - padding: EdgeInsets.all(16), - child: Row( - children: [ - Icon( - Icons.lightbulb_outline, - color: Color(0xFF6A4C93), - size: 20, - ), - SizedBox(width: 12), - Expanded( - child: Text( - 'Keep it friendly and respectful. Your post will be visible to everyone in the community.', + child: Padding( + padding: EdgeInsets.all(16), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + "What's on your mind?", style: TextStyle( - color: Colors.grey[700], - fontSize: 13, - height: 1.3, + fontSize: 18, + fontWeight: FontWeight.w600, + color: Color(0xFF6A4C93), ), ), + SizedBox(height: 16), + TextField( + controller: _bodyController, + maxLines: 6, + decoration: InputDecoration( + hintText: 'Share your thoughts...', + hintStyle: TextStyle(color: Colors.grey[500]), + border: InputBorder.none, + enabledBorder: InputBorder.none, + focusedBorder: InputBorder.none, + ), + style: TextStyle( + fontSize: 16, + height: 1.4, + color: Colors.black87, + ), + onChanged: (text) { + setState(() {}); + }, + ), + SizedBox(height: 16), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Text( + 'Share your thoughts with the community', + style: TextStyle( + color: Colors.grey[600], + fontSize: 12, + ), + ), + Text( + '$remainingChars', + style: TextStyle( + color: isOverLimit + ? Colors.red + : Colors.grey[600], + fontSize: 12, + fontWeight: FontWeight.w500, + ), + ), + ], + ), + if (isOverLimit) + Padding( + padding: EdgeInsets.only(top: 8), + child: Text( + 'Post is too long. Please keep it under $_maxCharacters characters.', + style: TextStyle(color: Colors.red, fontSize: 12), + ), + ), + ], + ), + ), + ), + SizedBox(height: 24), + Container( + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(12), + boxShadow: [ + BoxShadow( + color: Colors.black.withOpacity(0.05), + blurRadius: 10, + offset: Offset(0, 2), ), ], ), + child: Padding( + padding: EdgeInsets.all(16), + child: Row( + children: [ + Icon( + Icons.lightbulb_outline, + color: Color(0xFF6A4C93), + size: 20, + ), + SizedBox(width: 12), + Expanded( + child: Text( + 'Keep it friendly and respectful. Your post will be visible to everyone in the community.', + style: TextStyle( + color: Colors.grey[700], + fontSize: 13, + height: 1.3, + ), + ), + ), + ], + ), + ), ), - ), - ], + ], + ), ), ), - ), ), ); } -} \ No newline at end of file +} diff --git a/frontend/lib/widgets/posts_list.dart b/frontend/lib/widgets/posts_list.dart index 0b1ed69..e87731e 100644 --- a/frontend/lib/widgets/posts_list.dart +++ b/frontend/lib/widgets/posts_list.dart @@ -411,14 +411,6 @@ class _PostCardState extends State { ], ), ), - IconButton( - onPressed: () { - ScaffoldMessenger.of(context).showSnackBar( - SnackBar(content: Text('More options pressed')), - ); - }, - icon: Icon(Icons.more_horiz, color: Colors.grey[600]), - ), ], ), SizedBox(height: 12),