@@ -48,9 +48,13 @@ struct GroupHomeView: View {
48
48
}
49
49
}
50
50
}
51
+ . onTapGestureForced {
52
+ UIApplication . shared. endEditing ( )
53
+ }
51
54
. frame ( maxWidth: isIpad ? 600 : nil , alignment: . center)
52
55
. frame ( maxWidth: . infinity, alignment: . center)
53
56
. background ( surfaceColor)
57
+ . toastView ( toast: $viewModel. toast)
54
58
. alertView. alert ( isPresented: $viewModel. showAlert, alertStruct: viewModel. alert)
55
59
. onDisappear {
56
60
if viewModel. showSearchBar {
@@ -68,7 +72,18 @@ struct GroupHomeView: View {
68
72
. ignoresSafeArea ( . keyboard)
69
73
}
70
74
}
71
- . toastView ( toast: $viewModel. toast)
75
+ . toolbarRole ( . editor)
76
+ . toolbar {
77
+ ToolbarItem ( placement: . topBarLeading) {
78
+ NavigationTitleTextView ( text: viewModel. group? . name ?? " " )
79
+ }
80
+ ToolbarItem ( placement: . topBarTrailing) {
81
+ ToolbarButtonView ( systemImageName: " magnifyingglass " , onClick: viewModel. handleSearchOptionTap)
82
+ }
83
+ ToolbarItem ( placement: . topBarTrailing) {
84
+ ToolbarButtonView ( systemImageName: " gearshape " , onClick: viewModel. handleSettingsOptionTap)
85
+ }
86
+ }
72
87
. fullScreenCover ( isPresented: $viewModel. showAddExpenseSheet) {
73
88
ExpenseRouteView ( selectedGroupId: viewModel. groupId)
74
89
}
@@ -107,18 +122,6 @@ struct GroupHomeView: View {
107
122
. presentationDetents ( [ . height( sheetHeight) ] )
108
123
. presentationCornerRadius ( 24 )
109
124
}
110
- . toolbarRole ( . editor)
111
- . toolbar {
112
- ToolbarItem ( placement: . topBarLeading) {
113
- NavigationTitleTextView ( text: viewModel. group? . name ?? " " )
114
- }
115
- ToolbarItem ( placement: . topBarTrailing) {
116
- ToolbarButtonView ( systemImageName: " magnifyingglass " , onClick: viewModel. handleSearchOptionTap)
117
- }
118
- ToolbarItem ( placement: . topBarTrailing) {
119
- ToolbarButtonView ( systemImageName: " gearshape " , onClick: viewModel. handleSettingsOptionTap)
120
- }
121
- }
122
125
}
123
126
}
124
127
@@ -136,7 +139,7 @@ struct GroupOptionsListView: View {
136
139
HStack ( spacing: 8 ) {
137
140
GroupOptionsButtonView ( text: " Settle up " , isForSettleUp: isSettleUpEnable, onTap: onSettleUpTap)
138
141
139
- GroupOptionsButtonView ( text: " Payments " , onTap: onTransactionsTap)
142
+ GroupOptionsButtonView ( text: " Settlements " , onTap: onTransactionsTap)
140
143
141
144
GroupOptionsButtonView ( text: " Balances " , onTap: onBalanceTap)
142
145
0 commit comments