Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: chat widget and messages logic #5

Merged
merged 6 commits into from
Oct 12, 2023
Merged

Conversation

nicolantean
Copy link
Collaborator

⭐ Feature


✏️ Description:

Chat widget with messages logic, including selecting from the table, real-time stream, and sending messages. Also, login logic is included.


🎥 Screen record:

iOS

Simulator.Screen.Recording.-.iPhone.14.Pro.Max.-.2023-10-06.at.03.34.22.mp4

Notes:

  • Textfield design is not included.

Copy link
Contributor

@mirland mirland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! 😄

One comment, in the video the send button disappeared, why did it happen?

]
}
]
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
}
}

Comment on lines +5 to +6
"version": "0.2.0",
"configurations": [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we should add it to the base project 🤔

@@ -30,3 +33,8 @@ extension _GetItDiModuleExtensions on GetIt {
);
}
}

Future<SupabaseClient> _initSupabase() => Supabase.initialize(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add todo here, we have to discuss where we should initialize... It's a ws, what do you think?

Comment on lines 34 to 36
registerLazySingleton(() => SessionRepository(get(), get(), get()));
registerLazySingleton(() => ProjectRepository(get(), get()));
registerLazySingleton(() => MessagesRepository(get()));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sort

registerLazySingleton(() => ProjectRemoteSource(get()));
registerLazySingleton(() => MessagesRemoteSource(get()));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same

body: Column(
children: [
state.messages.isEmpty
? Expanded(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extract to a class

),
),
)
: Expanded(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

to another class

}

class _TextFieldSectionState extends State<_TextFieldSection> {
final textController = TextEditingController();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

private and shouldn't be defined in the previous class? 🤔 What happen when the messages changes?

);
}

class _MessageWidget extends StatelessWidget {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to another place

});

@override
Widget build(BuildContext context) => Padding(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's long, maybe split it

@@ -1,5 +1,5 @@
buildscript {
ext.kotlin_version = '1.6.10'
ext.kotlin_version = '1.9.10'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you may have problems if you don't upgrade the wrapper version

@nicolantean nicolantean merged commit cbeaa91 into main Oct 12, 2023
2 checks passed
@nicolantean nicolantean deleted the feature/chat-screen branch October 12, 2023 16:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants