fix: hide Creative Tools in release builds and improve Add Item keyboard behavior
Gate Icon Generator section behind #if DEBUG and group it with other debug sections at the bottom of Settings. Remove auto-focus on description field, dismiss keyboard on return key and on scroll. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -61,7 +61,7 @@ struct QuickAddItemSheet: View {
|
||||
.padding(.top, Theme.Spacing.md)
|
||||
.padding(.bottom, Theme.Spacing.xxl)
|
||||
}
|
||||
.scrollDismissesKeyboard(.interactively)
|
||||
.scrollDismissesKeyboard(.immediately)
|
||||
.background(Theme.backgroundGradient(colorScheme))
|
||||
.navigationTitle(isEditing ? "Edit Item" : "Add to Day \(day)")
|
||||
.navigationBarTitleDisplayMode(.inline)
|
||||
@@ -102,10 +102,6 @@ struct QuickAddItemSheet: View {
|
||||
}
|
||||
.onAppear {
|
||||
loadExistingItem()
|
||||
// Focus text field after a brief delay
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) {
|
||||
isTitleFocused = true
|
||||
}
|
||||
}
|
||||
.task {
|
||||
await loadNearbyPOIs()
|
||||
@@ -126,6 +122,8 @@ struct QuickAddItemSheet: View {
|
||||
.font(.body)
|
||||
.lineLimit(1...3)
|
||||
.focused($isTitleFocused)
|
||||
.submitLabel(.done)
|
||||
.onSubmit { isTitleFocused = false }
|
||||
.padding(Theme.Spacing.md)
|
||||
.background(inputBackground)
|
||||
.clipShape(RoundedRectangle(cornerRadius: Theme.CornerRadius.medium))
|
||||
|
||||
Reference in New Issue
Block a user