feat(itinerary): reorder Add button after day header + comprehensive docs
- Move Add button to appear immediately after Day header (before games) - Split games out of dayHeader into separate row for correct ordering - Add 600+ lines of inline documentation to ItineraryTableViewController - Document architecture decisions, data flow, constraints, and algorithms - Add function-level comments explaining drag/drop, sortOrder calculation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -837,14 +837,14 @@ struct TripDetailView: View {
|
||||
|
||||
// Custom items for this day (sorted by sortOrder)
|
||||
if allowCustomItems {
|
||||
// Add button first - always right after day header
|
||||
sections.append(.addButton(day: dayNum))
|
||||
|
||||
let dayItems = customItems.filter { $0.day == dayNum }
|
||||
.sorted { $0.sortOrder < $1.sortOrder }
|
||||
for item in dayItems {
|
||||
sections.append(.customItem(item))
|
||||
}
|
||||
|
||||
// One add button per day
|
||||
sections.append(.addButton(day: dayNum))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user