mirror of
https://github.com/vector-im/element-ios.git
synced 2024-09-29 07:42:40 +00:00
fix for iPhone 14
This commit is contained in:
parent
1b6cabf2a7
commit
7869b8f0a2
1 changed files with 6 additions and 1 deletions
|
@ -296,7 +296,12 @@ class WysiwygInputToolbarView: MXKRoomInputToolbarView, NibLoadable, HtmlRoomInp
|
||||||
|
|
||||||
private func updateTextViewHeight() {
|
private func updateTextViewHeight() {
|
||||||
let height = UIScreen.main.bounds.height
|
let height = UIScreen.main.bounds.height
|
||||||
let barOffset: CGFloat = 68
|
let barOffset: CGFloat
|
||||||
|
if let topSafeArea = window?.safeAreaInsets.top, topSafeArea >= 68 {
|
||||||
|
barOffset = topSafeArea
|
||||||
|
} else {
|
||||||
|
barOffset = 68
|
||||||
|
}
|
||||||
let toolbarHeight: CGFloat = 96
|
let toolbarHeight: CGFloat = 96
|
||||||
let finalHeight = height - keyboardHeight - toolbarHeight - barOffset
|
let finalHeight = height - keyboardHeight - toolbarHeight - barOffset
|
||||||
wysiwygViewModel.maxExpandedHeight = finalHeight
|
wysiwygViewModel.maxExpandedHeight = finalHeight
|
||||||
|
|
Loading…
Reference in a new issue