Commit 4a14ce2e authored by Quentin Muret's avatar Quentin Muret Committed by Kateryna Kostiuk

conversation header: user name position

- if the display name doesn't exist, the username is align vertically
 with the avatar

Change-Id: I6d49b893ce9393d2269807a25897ec81c5274ef9
Reviewed-by: Kateryna Kostiuk<kateryna.kostiuk@savoirfairelinux.com>
parent dffa0537
......@@ -284,13 +284,21 @@ class ConversationViewController: UIViewController,
titleView.addSubview(profileImageView)
}
var dnlabelYOffset: CGFloat
var dnlabelYOffset: CGFloat = 0
if UIDevice.current.hasNotch {
dnlabelYOffset = 4
userNameYOffset = 20
if displayName == nil || displayName == "" {
userNameYOffset = 10
} else {
dnlabelYOffset = 4
userNameYOffset = 20
}
} else {
if displayName == nil || displayName == "" {
userNameYOffset = 3
} else {
dnlabelYOffset = -2
userNameYOffset = 12
}
}
if let name = displayName, !name.isEmpty {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment