Skip to content

[trello.com/c/jKqpxiCa] update for paragraph 8 and 13 in the card #865

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

Open
wants to merge 2 commits into
base: release/3.11.0
Choose a base branch
from

Conversation

vovameister
Copy link
Member

check by commits

return
}

guard let firstUnreadId = viewModel.unreadMessagesIds?.first,
Copy link
Collaborator

Choose a reason for hiding this comment

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

you could combine this with previous checking

let visibleBounds = messagesCollectionView.bounds
let restrictedVisibleRect = visibleBounds.insetBy(dx: 0, dy: 100)

let visibleSections: Set<Int> = Set(
Copy link
Collaborator

Choose a reason for hiding this comment

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

let visibleSections: Set<Int> = Set(
    messagesCollectionView.indexPathsForVisibleItems.compactMap {
        guard let frame = messagesCollectionView.layoutAttributesForItem(at: $0)?.frame,
              restrictedVisibleRect.intersects(frame) else { return nil }
        return $0.section
    }
)

@@ -1395,4 +1445,11 @@ private let messagePadding: CGFloat = 12
private let filesToolbarViewHeight: CGFloat = 140
private let targetYOffset: CGFloat = 20
private let scrollButtonHeight: CGFloat = 30
private let hiddenScrollViewPartHeight: CGFloat = 94
//not a real height just for reading messages
private var hiddenScrollViewPartHeight: CGFloat {
Copy link
Collaborator

Choose a reason for hiding this comment

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

How did you get this?

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