From 2c783b710eeeedda24c2756014cf66e1677b12cf Mon Sep 17 00:00:00 2001 From: Guillermo Date: Sat, 20 Jan 2024 19:49:16 +0100 Subject: [PATCH] feat(web) dismiss user management modals on escape (#6530) Other modals throughout the web app close when the user presses the escape key, clicks outside the modal, or on the close button. Modals from the user management page missed the escape key functionality. This change makes the behavior more consistent across all views. --- web/src/routes/admin/user-management/+page.svelte | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/web/src/routes/admin/user-management/+page.svelte b/web/src/routes/admin/user-management/+page.svelte index 0d44730bd0..792838b6d4 100644 --- a/web/src/routes/admin/user-management/+page.svelte +++ b/web/src/routes/admin/user-management/+page.svelte @@ -110,13 +110,19 @@
{#if shouldShowCreateUserForm} - (shouldShowCreateUserForm = false)}> + (shouldShowCreateUserForm = false)} + on:escape={() => (shouldShowCreateUserForm = false)} + > (shouldShowCreateUserForm = false)} /> {/if} {#if shouldShowEditUserForm} - (shouldShowEditUserForm = false)}> + (shouldShowEditUserForm = false)} + on:escape={() => (shouldShowEditUserForm = false)} + > (shouldShowInfoPanel = false)}> + (shouldShowInfoPanel = false)} + on:escape={() => (shouldShowInfoPanel = false)} + >

Password reset success