add plugin to warn before navigating away from unsaved changes