better unsaved state management/notification