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

Messages in drawer #526

Merged
merged 7 commits into from
May 28, 2019
Merged

Messages in drawer #526

merged 7 commits into from
May 28, 2019

Conversation

eoji
Copy link
Contributor

@eoji eoji commented May 22, 2019

What ❓

  • Adding Messages to the navigation drawer in Discovery.
  • When a user has an unreadMessagesCount > 0, we display the count to the right of the label.
  • Since there are now 3 ways to get to the MessageThreadsActivity, we added KoalaContext.Mailbox. Users can access their mailbox from creator_dashboard, drawer, or `profile.
  • LoggedInViewHolder didn't have a ViewModel so I added one so I could test!

How to QA? 🤔

  1. Open the app and verify the Messages row is only there for logged in users.
  2. The unread count should display if it's greater than 0.
  3. Clicking the row should take you to your inbox.

Story 📖

Trello Story

See 👀

@eoji eoji requested review from Scollaco and Rcureton May 22, 2019 19:58
@eoji
Copy link
Contributor Author

eoji commented May 22, 2019

@Scollaco
Copy link
Contributor

This is looking awesome! (And I could see I have 3 unread messages 😅 )

I noticed, though, that when I go to Sent messages, I still see the 2 unread text. Is it intended to be like that? Maybe we could show it only for messages in the Inbox , since we don't have unread sent messages.

Screenshot 2019-05-24 at 11 47 48

@eoji
Copy link
Contributor Author

eoji commented May 24, 2019

Yeah, I wasn't sure because we only get unreadMessagesCount and those unreads could be in your sent inbox also. Maybe we could parking lot during standup?

@eoji
Copy link
Contributor Author

eoji commented May 24, 2019

Sent mailbox doesn't show unread count

Copy link
Contributor

@Scollaco Scollaco left a comment

Choose a reason for hiding this comment

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

Nice job, @eoji ! I just left a few comments. Let me know if you have any questions.

import com.squareup.picasso.Picasso
import kotlinx.android.synthetic.main.discovery_drawer_logged_in_view.view.*

class LoggedInViewHolder(@NonNull view: View, @NonNull private val delegate: Delegate) : KSViewHolder(view) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't this class be final?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nope!
Screen Shot 2019-05-28 at 10 17 31 AM

eoji added 3 commits May 24, 2019 17:34
# Conflicts:
#	app/src/main/java/com/kickstarter/viewmodels/DiscoveryViewModel.java
#	app/src/test/java/com/kickstarter/viewmodels/DiscoveryViewModelTest.java
@eoji eoji merged commit 4026930 into master May 28, 2019
@eoji eoji deleted the messages-in-drawer branch May 28, 2019 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants