mirror of
https://github.com/storytold/storyteller-bevy.git
synced 2026-10-17 00:13:17 +00:00
Respect the autoClose property
This commit is contained in:
@@ -204,7 +204,7 @@ export class AppElement extends LitElement {
|
||||
<!-- Studio-mode-only elements -->
|
||||
${this.#params.mode === StudioMode.Editor ? html`
|
||||
<!-- TODO: Move this -->
|
||||
<sts-menu .trigger=${this.#addToSceneButtonRef}>
|
||||
<sts-menu autoClose .trigger=${this.#addToSceneButtonRef}>
|
||||
<sts-button
|
||||
role="menuitem"
|
||||
icon="cube"
|
||||
|
||||
@@ -81,7 +81,8 @@ export class MenuElement extends LitElement {
|
||||
event.stopPropagation();
|
||||
|
||||
if (
|
||||
event.target
|
||||
this.autoClose
|
||||
&& event.target
|
||||
&& event.target instanceof HTMLElement
|
||||
&& event.target.role === "menuitem"
|
||||
) {
|
||||
|
||||
Reference in New Issue
Block a user