Further tweak the layout
This commit is contained in:
parent
bfa717bfa2
commit
21ac4cfa21
|
@ -22,9 +22,7 @@ struct StatusRowHeaderView: View {
|
||||||
}
|
}
|
||||||
.buttonStyle(.plain)
|
.buttonStyle(.plain)
|
||||||
Spacer()
|
Spacer()
|
||||||
if !isInCaptureMode {
|
dateView
|
||||||
threadIcon
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.accessibilityElement(children: .combine)
|
.accessibilityElement(children: .combine)
|
||||||
.accessibilityLabel(Text("\(viewModel.finalStatus.account.safeDisplayName)") + Text(", ") + Text(viewModel.finalStatus.createdAt.relativeFormatted))
|
.accessibilityLabel(Text("\(viewModel.finalStatus.account.safeDisplayName)") + Text(", ") + Text(viewModel.finalStatus.createdAt.relativeFormatted))
|
||||||
|
@ -59,27 +57,16 @@ struct StatusRowHeaderView: View {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.layoutPriority(1)
|
.layoutPriority(1)
|
||||||
if !redactionReasons.contains(.placeholder) {
|
|
||||||
if theme.avatarPosition == .leading {
|
|
||||||
dateView
|
|
||||||
} else {
|
|
||||||
Text("@\(theme.displayFullUsername ? viewModel.finalStatus.account.acct : viewModel.finalStatus.account.username)")
|
|
||||||
.font(.scaledFootnote)
|
|
||||||
.foregroundStyle(.secondary)
|
|
||||||
.lineLimit(1)
|
|
||||||
.accountPopover(viewModel.finalStatus.account)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if theme.avatarPosition == .top {
|
if !redactionReasons.contains(.placeholder) {
|
||||||
dateView
|
if (theme.displayFullUsername && theme.avatarPosition == .leading) ||
|
||||||
} else if theme.displayFullUsername, theme.avatarPosition == .leading {
|
theme.avatarPosition == .top {
|
||||||
Text("@\(viewModel.finalStatus.account.acct)")
|
Text("@\(theme.displayFullUsername ? viewModel.finalStatus.account.acct : viewModel.finalStatus.account.username)")
|
||||||
.font(.scaledFootnote)
|
.font(.scaledFootnote)
|
||||||
.foregroundStyle(.secondary)
|
.foregroundStyle(.secondary)
|
||||||
.lineLimit(1)
|
.lineLimit(1)
|
||||||
.offset(y: 1)
|
.accountPopover(viewModel.finalStatus.account)
|
||||||
.accountPopover(viewModel.finalStatus.account)
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -104,15 +91,4 @@ struct StatusRowHeaderView: View {
|
||||||
.foregroundStyle(.secondary)
|
.foregroundStyle(.secondary)
|
||||||
.lineLimit(1)
|
.lineLimit(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ViewBuilder
|
|
||||||
private var threadIcon: some View {
|
|
||||||
if viewModel.isThread {
|
|
||||||
Image(systemName: "bubble.left.and.bubble.right")
|
|
||||||
.resizable()
|
|
||||||
.aspectRatio(contentMode: .fit)
|
|
||||||
.frame(width: 15)
|
|
||||||
.foregroundStyle(.secondary)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue