From 185a745f265784d0611c7ff64c70a62525881675 Mon Sep 17 00:00:00 2001 From: flashwave Date: Sun, 21 Apr 2024 19:42:36 +0000 Subject: [PATCH] Fixed oversight of Everything causing a dismiss. --- src/mami.js/controls/msgbox.jsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/mami.js/controls/msgbox.jsx b/src/mami.js/controls/msgbox.jsx index f431a63..2192323 100644 --- a/src/mami.js/controls/msgbox.jsx +++ b/src/mami.js/controls/msgbox.jsx @@ -11,8 +11,10 @@ const MamiMessageBoxContainer = function() { if(typeof dialog !== 'object' || dialog === null) throw 'dialog must be a non-null object'; - const backgroundClick = () => { - dialog.clickButtonIndex(0); + const backgroundClick = ev => { + ev.stopPropagation(); + if(ev.target === container) + dialog.clickButtonIndex(0); }; try {