File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed
CriticalMapsKit/Sources/AppFeature Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,14 @@ public struct AppView: View {
2323 viewStore = ViewStore ( store)
2424 }
2525
26+ private var contextMenuTitle : String {
27+ if viewStore. bottomSheetPosition == . hidden {
28+ return L10n . Map. NextRideEvents. showAll
29+ } else {
30+ return L10n . Map. NextRideEvents. hideAll
31+ }
32+ }
33+
2634 public var body : some View {
2735 ZStack ( alignment: . topLeading) {
2836 MapFeatureView (
@@ -39,10 +47,7 @@ public struct AppView: View {
3947 . contextMenu {
4048 Button (
4149 action: { viewStore. send ( . set( \. $bottomSheetPosition, . relative( 0.4 ) ) ) } ,
42- label: {
43- let title = viewStore. bottomSheetPosition == . hidden ? L10n . Map. NextRideEvents. hideAll : L10n . Map. NextRideEvents. showAll
44- Label ( title, systemImage: " list.bullet " )
45- }
50+ label: { Label ( contextMenuTitle, systemImage: " list.bullet " ) }
4651 )
4752 }
4853 }
@@ -147,7 +152,7 @@ public struct AppView: View {
147152 ? Color . white
148153 : Color ( . attention)
149154 )
150- . accessibilityLabel ( Text ( " internet not available" ) )
155+ . accessibilityLabel ( Text ( " Internet not available" ) )
151156 . padding ( )
152157 . background (
153158 Group {
You can’t perform that action at this time.
0 commit comments