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

Feature : Show conversation history - part 1 - Show conversation history in chat screen #233

Merged
merged 19 commits into from Jul 13, 2021

Conversation

ohassine
Copy link
Member

@ohassine ohassine commented Jul 9, 2021

What's new in this PR?

This PR is a follow up of #231.
It aims to display the conversation chat history.

Portrait Portrait RTL
Screenshot_1626077759 Screenshot_1626081472
Landscape
Screenshot_1626077783
Landscape RTL
Screenshot_1626081464

Showing message's time, displaying the right profile picture and dark mode will be done in the following PRs

@ohassine ohassine added DO NOT MERGE WIP Work In Progress labels Jul 9, 2021
@ohassine ohassine changed the title Show conversation history part1 eature : Show conversation history - part 1 - Show conversation history in chat screen Jul 9, 2021
@ohassine ohassine changed the title eature : Show conversation history - part 1 - Show conversation history in chat screen Feature : Show conversation history - part 1 - Show conversation history in chat screen Jul 9, 2021
…tion_history_part1

# Conflicts:
#	app/src/main/kotlin/com/wire/android/feature/conversation/content/ui/ConversationActivity.kt
#	app/src/main/kotlin/com/wire/android/feature/conversation/content/ui/ConversationFragment.kt
#	app/src/main/kotlin/com/wire/android/feature/conversation/di/ConversationsModule.kt
#	app/src/main/kotlin/com/wire/android/feature/conversation/list/ui/ConversationListFragment.kt
#	app/src/main/res/layout/fragment_conversation.xml
#	app/src/main/res/values/styles_textview.xml
@pull-request-size pull-request-size bot added size/L and removed size/XL labels Jul 9, 2021
Copy link
Contributor

@mejdoo mejdoo left a comment

Choose a reason for hiding this comment

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

I left some comment + I'm missing the tests for the viewModel and the use case

class ConversationTextMessageViewHolder(parent: ViewGroup, inflater: ViewHolderInflater) :
RecyclerView.ViewHolder(inflater.inflate(R.layout.conversation_chat_item_text, parent)) {

private val conversationChatItemUsernameTextView by lazyFind<TextView>(R.id.conversationChatItemUsernameTextView)
Copy link
Contributor

Choose a reason for hiding this comment

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

I think you can get rid of those 3 lines and call directly conversationChatItemUsernameTextView , conversationChatItemTextMessageTextView and conversationChatItemUserAvatarImageView

Copy link
Member Author

Choose a reason for hiding this comment

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

Kotlin Synthetics is deprecated, I think we should use findViewById or migrate to Jetpack View Binding.
About migration:
https://developer.android.com/topic/libraries/view-binding/migration

Copy link
Contributor

Choose a reason for hiding this comment

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

Let's do the migration later in different PRs ;)

@ohassine
Copy link
Member Author

ohassine commented Jul 9, 2021

I left some comment + I'm missing the tests for the viewModel and the use case

Yeah @mejdoo still work in progress, I am working on unit test

@pull-request-size pull-request-size bot added size/XL and removed size/L labels Jul 9, 2021
@ohassine ohassine removed DO NOT MERGE WIP Work In Progress labels Jul 12, 2021
Copy link
Contributor

@mejdoo mejdoo left a comment

Choose a reason for hiding this comment

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

Looks good overall 👍 I left a renaming proposal for MessageAndContactEntity and also it would be nice to share a screenshot for RTL layouts.

Copy link
Contributor

@vitorhugods vitorhugods left a comment

Choose a reason for hiding this comment

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

Just something I found a bit odd...

Other thant that, looks good.

… into show_conversation_history_part1

# Conflicts:
#	app/src/androidTest/kotlin/com/wire/android/feature/conversation/content/datasources/local/MessageDaoTest.kt
@ohassine ohassine merged commit c66f367 into main Jul 13, 2021
@ohassine ohassine deleted the show_conversation_history_part1 branch July 13, 2021 07:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
5 participants