apisix-dashboard icon indicating copy to clipboard operation
apisix-dashboard copied to clipboard

fix(plugin): add confirmation dialog before deleting plugin card

Open Jaswanth-arjun opened this issue 8 months ago • 2 comments

Description

Currently, deleting a plugin from forms (Routes, Services, Plugin Configs) happens immediately without confirmation, which may lead to accidental data loss.

Changes

  • Added confirmation dialog using modals.openConfirmModal
  • Prevents accidental deletion of plugin configurations
  • Aligns behavior with existing DeleteResourceBtn UX

Impact

  • Improves user experience
  • Ensures consistency across dashboard delete actions
  • Reduces risk of unintended data loss

Related Issue

Testing

  • Added plugin, confirmed delete shows confirmation modal
  • Cancel button closes modal without deleting
  • Confirm button deletes plugin as expected image

Jaswanth-arjun avatar Mar 21 '26 10:03 Jaswanth-arjun

I don’t think this feature is necessary. Since we’re currently on the data creation page rather than the edit page, removing the plugin simply deletes it from the data being created—it has no impact on active configurations. Therefore, there’s no need for this additional confirmation.

Hi @Jaswanth-arjun, before submitting a contribution, please create an issue describing your problem or request. Once the community has reviewed and approved it, submit a pull request to complete the code.

Baoyuantop avatar Mar 23 '26 03:03 Baoyuantop

Hi @Baoyuantop actually i am fixing bugs which are i seen in issues tab #3342 and my PR was #3345 ,Thank you for your suggestion.

Jaswanth-arjun avatar Mar 23 '26 06:03 Jaswanth-arjun