diff --git a/ios/Platform/Platform/Features/Fitness/Views/AddFoodSheet.swift b/ios/Platform/Platform/Features/Fitness/Views/AddFoodSheet.swift index 56b4256..0fe38cb 100644 --- a/ios/Platform/Platform/Features/Fitness/Views/AddFoodSheet.swift +++ b/ios/Platform/Platform/Features/Fitness/Views/AddFoodSheet.swift @@ -165,29 +165,33 @@ struct AddFoodSheet: View { .font(.caption) .foregroundStyle(.red) } - - // Add button - Button { - addEntry() - } label: { - if isAdding { - ProgressView() - .tint(.white) - } else { - Text("Add to \(selectedMeal.displayName)") - .font(.headline) - } - } - .frame(maxWidth: .infinity) - .frame(height: 50) - .background(Color.accentWarm) - .foregroundStyle(.white) - .clipShape(RoundedRectangle(cornerRadius: 12)) - .disabled(isAdding) } .padding() } + .scrollDismissesKeyboard(.immediately) .background(Color.canvas) + .safeAreaInset(edge: .bottom) { + Button { + addEntry() + } label: { + if isAdding { + ProgressView() + .tint(.white) + } else { + Text("Add to \(selectedMeal.displayName)") + .font(.headline) + } + } + .frame(maxWidth: .infinity) + .frame(height: 50) + .background(Color.accentWarm) + .foregroundStyle(.white) + .clipShape(RoundedRectangle(cornerRadius: 12)) + .disabled(isAdding) + .padding(.horizontal) + .padding(.bottom, 8) + .background(Color.canvas) + } .navigationTitle("Add Food") .navigationBarTitleDisplayMode(.inline) .toolbar {