Replace `data-confirm` modals with `GlModal` in `app/views/profiles/two_factor_auths/show.html.haml`
requested to merge 344185-replace-data-confirm-modals-with-glmodal-in-app-views-profiles-two_factor_auths-show-html into master
What does this MR do and why?
Related to #344185 (closed) as part of &6854 (closed).
The confirm modal works as expected for the "Delete [WebAuthn Device]" button. And this MR:
- Adds the
data-confirm-btn-variant="danger"
attribute to the button. - Adds an
aria-label
attribute.
Screenshots or screen recordings
Before | After |
---|---|
![]() |
![]() |
How to set up and validate locally
- Enable the feature flag
Feature.enable(:bootstrap_confirmation_modals)
- Optionally, enable HTTPS for the GDK.
- Visit
https://gdk.test:3443/-/profile/two_factor_auth
and register a WebAuthn Device. You might need to enable 2FA first. - Click the WebAuthn Devices "Delete" button.
- The confirm modal should show "Delete", and it'd delete the device.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.