mirror of
https://github.com/yattee/yattee.git
synced 2024-12-22 13:33:42 +00:00
Detail badges improvement
This commit is contained in:
parent
74d65f6ab8
commit
92999118fd
@ -77,13 +77,21 @@ struct DetailBadge: View {
|
||||
@Default(.roundedThumbnails) private var roundedThumbnails
|
||||
|
||||
var body: some View {
|
||||
Text(text)
|
||||
let text = Text(text)
|
||||
.truncationMode(.middle)
|
||||
.padding(4)
|
||||
#if os(tvOS)
|
||||
.padding(.horizontal, 5)
|
||||
#endif
|
||||
|
||||
Group {
|
||||
if style == .default {
|
||||
text
|
||||
} else {
|
||||
text
|
||||
.modifier(StyleModifier(style: style))
|
||||
}
|
||||
}
|
||||
.mask(RoundedRectangle(cornerRadius: roundedThumbnails ? 6 : 0))
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user