ctc-oss / fapolicy-analyzer

Tools to assist with the configuration and management of fapolicyd.
https://ctc-oss.github.io/fapolicy-analyzer
GNU General Public License v3.0
12 stars 5 forks source link

Text editor state issues #912

Closed jw3 closed 10 months ago

jw3 commented 11 months ago

The text editor views (rules, config) allow the user to navigate away from the editor while unsaved changes are present. When the user navigates back the unsaved changes are gone.

The system does however appear to track some notion of the missing state, this is evident from the rules editor

  1. Edit rule text
  2. Navigate away without saving
  3. Attempt to deploy from another view
  4. Observe the unsaved rules dialog

image

egbicker commented 11 months ago

Is the intent to discard changes upon navigation? Perhaps the unsaved dialog should show up when attempting to navigate away with unsaved changes present and then discard them to avoid this dialog in other pages?

jw3 commented 11 months ago

Yes adding an additional check and prompt when navigating away would be good. If they leave, the changes get discarded.