@@ -30,10 +30,10 @@ struct MicrobolusView: View {
3030 @Published fileprivate var pickerMinimumBolusSizeIndex : Int
3131 @Published fileprivate var partialApplicationIndex : Int
3232
33- fileprivate let values = stride ( from: 30 , to: 301 , by: 5 ) . map { $0 }
33+ fileprivate let values = stride ( from: 30 , to: 301 , by: 5 ) . map { $0 } + [ 1440 ] // + 1 day
3434 // @ToDo: Should be able to get the to limit from the settings but for now defult to a low value
3535 fileprivate let minimumBolusSizeValues = stride ( from: 0.0 , to: 0.51 , by: 0.05 ) . map { $0 }
36- fileprivate let partialApplicationValues = stride ( from: 0.1 , to: 1.01 , by: 0.1 ) . map { $0 }
36+ fileprivate let partialApplicationValues = stride ( from: 0.1 , to: 1.01 , by: 0.05 ) . map { $0 }
3737
3838 private var cancellable : AnyCancellable !
3939 fileprivate let formatter : NumberFormatter = {
@@ -134,13 +134,13 @@ struct MicrobolusView: View {
134134
135135 var body : some View {
136136 Form {
137- self . topSection
138- self . withCobSection
139- self . withoutCobSection
140- self . partialApplicationSection
141- self . safeModeSection
142- self . temporaryOverridesSection
143- self . otherOptionsSection
137+ topSection
138+ partialApplicationSection
139+ withCobSection
140+ withoutCobSection
141+ safeModeSection
142+ temporaryOverridesSection
143+ otherOptionsSection
144144 }
145145 . navigationBarTitle ( " Microboluses " )
146146 . modifier ( AdaptsToSoftwareKeyboard ( ) )
@@ -170,7 +170,11 @@ struct MicrobolusView: View {
170170
171171 Picker ( selection: $viewModel. pickerWithCOBIndex, label: Text ( " Maximum Size " ) ) {
172172 ForEach ( 0 ..< viewModel. values. count) { index in
173- Text ( " \( self . viewModel. values [ index] ) " ) . tag ( index)
173+ if index == self . viewModel. values. count - 1 {
174+ Text ( " Not limited " ) . tag ( index)
175+ } else {
176+ Text ( " \( self . viewModel. values [ index] ) " ) . tag ( index)
177+ }
174178 }
175179 }
176180 }
@@ -185,7 +189,11 @@ struct MicrobolusView: View {
185189 }
186190 Picker ( selection: $viewModel. pickerWithoutCOBIndex, label: Text ( " Maximum Size " ) ) {
187191 ForEach ( 0 ..< viewModel. values. count) { index in
188- Text ( " \( self . viewModel. values [ index] ) " ) . tag ( index)
192+ if index == self . viewModel. values. count - 1 {
193+ Text ( " Not limited " ) . tag ( index)
194+ } else {
195+ Text ( " \( self . viewModel. values [ index] ) " ) . tag ( index)
196+ }
189197 }
190198 }
191199 }
0 commit comments