mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-21 09:40:44 +00:00
Close modal when clicking outside the modal (#2017)
## Description: Small QoL update where when you click outside of the main content of the modal it closes the modal. ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced ## Please put your Discord username so you can be contacted if a bug or regression is found: rovi. Co-authored-by: evanpelle <evanpelle@gmail.com>
This commit is contained in:
@@ -85,8 +85,9 @@ export class OModal extends LitElement {
|
||||
return html`
|
||||
${this.isModalOpen
|
||||
? html`
|
||||
<aside class="c-modal">
|
||||
<aside class="c-modal" @click=${this.close}>
|
||||
<div
|
||||
@click=${(e: Event) => e.stopPropagation()}
|
||||
class="c-modal__wrapper ${this.alwaysMaximized
|
||||
? "always-maximized"
|
||||
: ""}"
|
||||
|
||||
Reference in New Issue
Block a user