mirror of
https://github.com/yattee/yattee.git
synced 2024-12-13 13:50:32 +05:30
Minor performance improvement
This commit is contained in:
parent
b59baa6fab
commit
8ef016d792
@ -181,7 +181,7 @@ struct PlayerControls: View {
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.opacity(model.presentingControls ? 1 : 0)
|
.opacity(model.presentingControls && !player.availableStreams.isEmpty ? 1 : 0)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.frame(maxWidth: .infinity)
|
.frame(maxWidth: .infinity)
|
||||||
|
@ -348,7 +348,7 @@ struct VideoCell: View {
|
|||||||
DetailBadge(text: video.author, style: .prominent)
|
DetailBadge(text: video.author, style: .prominent)
|
||||||
.foregroundColor(.primary)
|
.foregroundColor(.primary)
|
||||||
} else {
|
} else {
|
||||||
Text(video.channel.name)
|
Text(verbatim: video.channel.name)
|
||||||
.fontWeight(.semibold)
|
.fontWeight(.semibold)
|
||||||
.foregroundColor(.secondary)
|
.foregroundColor(.secondary)
|
||||||
}
|
}
|
||||||
@ -473,7 +473,7 @@ struct VideoCell: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private func videoDetail(_ text: String, lineLimit: Int = 1) -> some View {
|
private func videoDetail(_ text: String, lineLimit: Int = 1) -> some View {
|
||||||
Text(text)
|
Text(verbatim: text)
|
||||||
.fontWeight(.bold)
|
.fontWeight(.bold)
|
||||||
.lineLimit(lineLimit)
|
.lineLimit(lineLimit)
|
||||||
.truncationMode(.middle)
|
.truncationMode(.middle)
|
||||||
|
Loading…
Reference in New Issue
Block a user