Skip to content

A platform for community discussion. Free, open, simple.

UX: fix z-index of chat actions when in livestream modal (#42588)

Krisef6d67069011
diff --git a/plugins/discourse-events/assets/javascripts/discourse/components/livestream/modal/mobile-embeddable-chat-modal.gjs b/plugins/discourse-events/assets/javascripts/discourse/components/livestream/modal/mobile-embeddable-chat-modal.gjs
index 7b0388f4116..86ccb4c77ec 100644
--- a/plugins/discourse-events/assets/javascripts/discourse/components/livestream/modal/mobile-embeddable-chat-modal.gjs
+++ b/plugins/discourse-events/assets/javascripts/discourse/components/livestream/modal/mobile-embeddable-chat-modal.gjs
@@ -2,6 +2,7 @@ import Component from "@glimmer/component";
import didUpdate from "@ember/render-modifiers/modifiers/did-update";
import { service } from "@ember/service";
import { modifier } from "ember-modifier";
+import bodyClass from "discourse/helpers/body-class";
import { lock, unlock } from "discourse/lib/body-scroll-lock";
import DModal from "discourse/ui-kit/d-modal";
import EmbeddableChatChannel from "../embeddable-chat-channel";
@@ -67,6 +68,8 @@ export default class MobileEmbeddableChatModal extends Component {
}
<template>
+ {{bodyClass "livestream-chat-modal-active"}}
+
<DModal
@closeModal={{@closeModal}}
class="livestream-chat-modal"
diff --git a/plugins/discourse-events/assets/stylesheets/common/livestream.scss b/plugins/discourse-events/assets/stylesheets/common/livestream.scss
index a28e0b4f864..f725a55e987 100644
--- a/plugins/discourse-events/assets/stylesheets/common/livestream.scss
+++ b/plugins/discourse-events/assets/stylesheets/common/livestream.scss
@@ -162,3 +162,12 @@ body.chat-enabled.livestream-topic.confirmed-event-assistance {
display: none;
}
}
+
+// we need to raise the z-index of the actions outlet
+// so they appear above the modal
+.livestream-chat-modal-active {
+ .chat-message-actions-desktop-outlet {
+ position: relative;
+ z-index: z("max");
+ }
+}