mirror of
https://github.com/yattee/yattee.git
synced 2026-07-20 14:22:02 +00:00
The Home settings screen copies settings into local @State on appear and saves on disappear. Pushing the card style page fired onDisappear (saving pre-edit values), and popping back re-ran loadSettings, clobbering the style just edited through the bindings — so the selection reverted. Load settings only once per presentation, and persist style, palette, and custom colors immediately from the style page via an onSave callback. The owning view sits covered in the navigation stack where its own onChange never fires, and swipe-dismissing the settings sheet from the style page skips its lifecycle entirely, so saving must happen from the visible child.