Minor adjustments

master
Rafael 2024-06-14 14:15:11 +02:00
parent 3004915247
commit 94e78e91da
6 changed files with 12 additions and 22 deletions

View File

@ -55,9 +55,8 @@ class MyDrawer extends StatelessWidget {
title: const Text('Find Matches'), title: const Text('Find Matches'),
leading: const Icon(Icons.person_search), leading: const Icon(Icons.person_search),
onTap: () { onTap: () {
// pop the drawer // pop the drawer first, then navigate to destination
Navigator.pop(context); Navigator.pop(context);
// Navigate to UserProfile
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
@ -73,12 +72,10 @@ class MyDrawer extends StatelessWidget {
Padding( Padding(
padding: const EdgeInsets.only(left: 25), padding: const EdgeInsets.only(left: 25),
child: ListTile( child: ListTile(
title: const Text('Swiped Users List'), title: const Text('Swiped Profiles'),
leading: const Icon(Icons.format_list_bulleted), leading: const Icon(Icons.format_list_bulleted),
onTap: () { onTap: () {
// pop the drawer
Navigator.pop(context); Navigator.pop(context);
// Navigate to HomePage?
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(

View File

@ -4,7 +4,7 @@ class Constants {
/// Title of the app /// Title of the app
static const String appTitle = 'Cofounderella'; static const String appTitle = 'Cofounderella';
static const String appVersion = '1.0.0'; static const String appVersion = '1.0.0';
static const String appCompilationDate = '2024-05-26'; static const String appCompilationDate = '2024-06-13';
static const String dbCollectionFeedbacks = 'feedbacks'; static const String dbCollectionFeedbacks = 'feedbacks';
static const String dbCollectionUsers = 'Users'; static const String dbCollectionUsers = 'Users';

View File

@ -91,17 +91,11 @@ class ProfileCategoryFormState<T> extends State<ProfileCategoryForm<T>> {
if (!widget.hideSaveButton) if (!widget.hideSaveButton)
ElevatedButton( ElevatedButton(
onPressed: () { onPressed: () {
//if (!equalContent(_selectedOptions, widget.preSelectedOptions)) {
// Only save if options have changed
if (_selectedOptions.length >= widget.minSelections) { if (_selectedOptions.length >= widget.minSelections) {
widget.onSave(_selectedOptions); widget.onSave(_selectedOptions);
// TODO Navigation abhängig von caller
// Navigator.pop(context); // Navigate back after saving
} else { } else {
// Provide feedback that minimum selections not met
_showSnackBar('No selection made for ${widget.title}'); _showSnackBar('No selection made for ${widget.title}');
} }
// } else { print('No changes to save for ${widget.title}.'); }
}, },
child: Text(widget.saveButtonText ?? 'Save'), child: Text(widget.saveButtonText ?? 'Save'),
), ),

View File

@ -155,8 +155,8 @@ class _ChatPageState extends State<ChatPage> {
Padding( Padding(
padding: const EdgeInsets.symmetric(horizontal: 25.0), padding: const EdgeInsets.symmetric(horizontal: 25.0),
child: Text( child: Text(
"${msgDate[0]} ${msgDate[1].substring(0, 8)}", "${msgDate[0]} ${msgDate[1].substring(0, 5)}",
style: TextStyle(color: Colors.grey.shade600), style: const TextStyle(color: Colors.grey),
), ),
), ),
ChatBubble( ChatBubble(

View File

@ -16,7 +16,6 @@ class ConversationsPage extends StatelessWidget {
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
title: const Text('My Chat Contacts'), title: const Text('My Chat Contacts'),
backgroundColor: Colors.transparent,
), ),
body: _buildUserMatchesList(), body: _buildUserMatchesList(),
); );

View File

@ -24,8 +24,8 @@ class HomePage extends StatelessWidget {
double size = constraints.biggest.shortestSide / 2 - 16; double size = constraints.biggest.shortestSide / 2 - 16;
return GridView.count( return GridView.count(
crossAxisCount: 2, crossAxisCount: 2,
crossAxisSpacing: 16.0, crossAxisSpacing: 6.0,
mainAxisSpacing: 16.0, mainAxisSpacing: 6.0,
padding: const EdgeInsets.all(16.0), padding: const EdgeInsets.all(16.0),
shrinkWrap: true, shrinkWrap: true,
physics: const NeverScrollableScrollPhysics(), physics: const NeverScrollableScrollPhysics(),