Removes @ViewBuilder from `var body`

This commit is contained in:
Stuart Breckenridge 2020-08-12 21:04:56 +08:00
parent 646a3190e5
commit 3ae4a85969
No known key found for this signature in database
GPG Key ID: 79BD673276AE83CE
10 changed files with 11 additions and 11 deletions

View File

@ -15,7 +15,7 @@ struct AddFolderView: View {
@Environment(\.presentationMode) private var presentationMode
@ObservedObject private var viewModel = AddFolderModel()
@ViewBuilder var body: some View {
var body: some View {
#if os(iOS)
iosForm
.onReceive(viewModel.$shouldDismiss, perform: {

View File

@ -16,7 +16,7 @@ struct AddWebFeedView: View {
@Environment(\.presentationMode) private var presentationMode
@StateObject private var viewModel = AddWebFeedModel()
@ViewBuilder var body: some View {
var body: some View {
#if os(iOS)
iosForm
.onAppear {

View File

@ -11,7 +11,7 @@ import Articles
struct ArticleContainerView: View {
@ViewBuilder var body: some View {
var body: some View {
ArticleView()
.modifier(ArticleToolbarModifier())
}

View File

@ -13,7 +13,7 @@ struct IconImageView: View {
@Environment(\.colorScheme) var colorScheme
var iconImage: IconImage
@ViewBuilder var body: some View {
var body: some View {
GeometryReader { proxy in
let newSize = newImageSize(viewSize: proxy.size)

View File

@ -15,7 +15,7 @@ struct SidebarContainerView: View {
@State var sidebarItems = [SidebarItem]()
@ViewBuilder var body: some View {
var body: some View {
SidebarView(sidebarItems: $sidebarItems)
.modifier(SidebarToolbarModifier())
.modifier(SidebarListStyleModifier())

View File

@ -19,7 +19,7 @@ struct SidebarContextMenu: View {
var sidebarItem: SidebarItem
@ViewBuilder var body: some View {
var body: some View {
// MARK: Account Context Menu
if sidebarItem.representedType == .account {
Button {

View File

@ -26,7 +26,7 @@ struct SidebarView: View {
@State var pulling: Bool = false
@State var refreshing: Bool = false
@ViewBuilder var body: some View {
var body: some View {
#if os(macOS)
VStack {
HStack {
@ -182,7 +182,7 @@ struct SidebarView: View {
@EnvironmentObject private var sidebarModel: SidebarModel
var sidebarItem: SidebarItem
@ViewBuilder var body: some View {
var body: some View {
#if os(macOS)
SidebarItemView(sidebarItem: sidebarItem)
.tag(sidebarItem.feed!.feedID!)

View File

@ -17,7 +17,7 @@ struct TimelineContainerView: View {
@State private var timelineItems = TimelineItems()
@State private var isReadFiltered: Bool? = nil
@ViewBuilder var body: some View {
var body: some View {
TimelineView(timelineItems: $timelineItems, isReadFiltered: $isReadFiltered)
.modifier(TimelineToolbarModifier())
.environmentObject(sceneModel.timelineModel)

View File

@ -13,7 +13,7 @@ struct TimelineContextMenu: View {
@EnvironmentObject private var timelineModel: TimelineModel
var timelineItem: TimelineItem
@ViewBuilder var body: some View {
var body: some View {
if timelineModel.canMarkIndicatedArticlesAsRead(timelineItem) {
Button {

View File

@ -17,7 +17,7 @@ struct TimelineView: View {
@State private var timelineItemFrames = [String: CGRect]()
@ViewBuilder var body: some View {
var body: some View {
GeometryReader { geometryReaderProxy in
#if os(macOS)
VStack {