From e17abc34c1e5ed4c256beb8be4ebd0be5966efd7 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Thu, 5 Sep 2024 01:28:47 +0200 Subject: [PATCH] [UI] Several improvements on the Modal component. - Don't propagate `close` events. This prevents underlying modals from being closed on cascade when the current modal is closed. - Added logic to filter out keystrokes that have already targeted the outermost open modal, so underlying modals won't be closed. - Added `:before-close` property. This is a callback that can optionally be passed to the component and it will run some custom logic before the modal is closed. If it returns false then the modal will stay open. --- .../http/webapp/src/components/Modal.vue | 86 ++++++++++++++----- 1 file changed, 65 insertions(+), 21 deletions(-) diff --git a/platypush/backend/http/webapp/src/components/Modal.vue b/platypush/backend/http/webapp/src/components/Modal.vue index f0cd6ef152..931f80f400 100644 --- a/platypush/backend/http/webapp/src/components/Modal.vue +++ b/platypush/backend/http/webapp/src/components/Modal.vue @@ -1,7 +1,11 @@