Fix bottom margins as requested (IOS-241)
This commit is contained in:
parent
9da5b99b28
commit
8d535be84a
|
@ -39,9 +39,9 @@ extension NotificationView {
|
|||
|
||||
switch notification.entity.type {
|
||||
case .follow:
|
||||
setAuthorContainerBottomPaddingViewDisplay()
|
||||
setAuthorContainerBottomPaddingViewDisplay(isHidden: true)
|
||||
case .followRequest:
|
||||
setFollowRequestAdaptiveMarginContainerViewDisplay()
|
||||
setFollowRequestAdaptiveMarginContainerViewDisplay(isHidden: true)
|
||||
case .mention, .status:
|
||||
if let status = notification.status {
|
||||
statusView.configure(status: status)
|
||||
|
|
|
@ -210,7 +210,7 @@ extension NotificationView {
|
|||
containerStackView.topAnchor.constraint(equalTo: topAnchor),
|
||||
containerStackView.leadingAnchor.constraint(equalTo: leadingAnchor),
|
||||
containerStackView.trailingAnchor.constraint(equalTo: trailingAnchor),
|
||||
bottomAnchor.constraint(equalTo: containerStackView.bottomAnchor),
|
||||
bottomAnchor.constraint(equalTo: containerStackView.bottomAnchor, constant: 8),
|
||||
])
|
||||
|
||||
// author container: H - [ avatarButton | author meta container ]
|
||||
|
@ -420,12 +420,12 @@ extension NotificationView {
|
|||
|
||||
extension NotificationView {
|
||||
|
||||
public func setAuthorContainerBottomPaddingViewDisplay() {
|
||||
authorContainerViewBottomPaddingView.isHidden = false
|
||||
public func setAuthorContainerBottomPaddingViewDisplay(isHidden: Bool = false) {
|
||||
authorContainerViewBottomPaddingView.isHidden = isHidden
|
||||
}
|
||||
|
||||
public func setFollowRequestAdaptiveMarginContainerViewDisplay() {
|
||||
followRequestAdaptiveMarginContainerView.isHidden = false
|
||||
public func setFollowRequestAdaptiveMarginContainerViewDisplay(isHidden: Bool = false) {
|
||||
followRequestAdaptiveMarginContainerView.isHidden = isHidden
|
||||
}
|
||||
|
||||
public func setStatusViewDisplay() {
|
||||
|
|
|
@ -290,19 +290,3 @@ extension ActionToolbarContainer {
|
|||
set { }
|
||||
}
|
||||
}
|
||||
|
||||
#if DEBUG
|
||||
import SwiftUI
|
||||
|
||||
struct ActionToolbarContainer_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
Group {
|
||||
UIViewPreview(width: 300) {
|
||||
ActionToolbarContainer()
|
||||
}
|
||||
.previewLayout(.fixed(width: 300, height: 44))
|
||||
.previewDisplayName("Inline")
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue