Introduce a GroceryListManager facade that delegates to either the existing in-app GroceryList or a new RemindersGroceryStore backed by EventKit. Users choose the mode in Settings; when Reminders mode is active the Grocery List tab is hidden. Recipe-to-reminder grouping uses a local mapping file (reminder_mappings.data) instead of polluting the reminder's notes field, with automatic pruning when reminders are deleted externally. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
21 lines
476 B
Swift
21 lines
476 B
Swift
//
|
|
// GroceryListMode.swift
|
|
// Nextcloud Cookbook iOS Client
|
|
//
|
|
|
|
import Foundation
|
|
|
|
enum GroceryListMode: String, CaseIterable {
|
|
case inApp = "inApp"
|
|
case appleReminders = "appleReminders"
|
|
|
|
func descriptor() -> String {
|
|
switch self {
|
|
case .inApp: return String(localized: "In-App")
|
|
case .appleReminders: return String(localized: "Apple Reminders")
|
|
}
|
|
}
|
|
|
|
static let allValues: [GroceryListMode] = GroceryListMode.allCases
|
|
}
|