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
[NT-2171]: Position of item on ViewHolder #1354
[NT-2171]: Position of item on ViewHolder #1354
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1354 +/- ##
=========================================
Coverage 74.16% 74.16%
Complexity 743 743
=========================================
Files 221 221
Lines 6669 6669
Branches 409 409
=========================================
Hits 4946 4946
Misses 1584 1584
Partials 139 139 Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved
@@ -111,12 +111,12 @@ class CommentCardViewHolder( | |||
this.vm.outputs.isSuccessfullyPosted() | |||
.compose(bindToLifecycle()) | |||
.compose(Transformers.observeForUI()) | |||
.subscribe { this.delegate.onCommentPostedSuccessFully(it) } | |||
.subscribe { this.delegate.onCommentPostedSuccessFully(it, absoluteAdapterPosition) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(cherry picked from commit 3449c33)
📲 What
getAbsoluteAdapterPosition
bindData(data: Any?)
as we have available the previously mentioned functionCommentExt
I gather together the comment extension in just one.Comment.updateCommentAfterSuccessfulPost
andfun Comment.updateCommentFailedToPost
to receive as parameter the position to update in the comment list.fun onCommentPostedSuccessFully(comment: Comment)
andfun onCommentPostedFailed(comment: Comment)
now get the position as parameter as well.🤔 Why
🛠 How
getAbsoluteAdapterPosition
👀 See
| | |
📋 QA
Story 📖
NT-2171