0
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2026-08-06 13:08:40 +08:00
discourse/themes/horizon/scss/chat.scss
David Battersby 1de80f36c2
UX: horizon chat reaction popup z-index fix (#41228)
Fixes the positioning of the new chat reactions popup on the Horizon
theme. Previously the popup was behind the chat drawer.

How it looks:

<img width="299" height="279" alt="Screenshot 2026-06-26 at 3 25 26 PM"
src="https://github.com/user-attachments/assets/b0760825-f04d-49e9-b7bf-6661af6f1dff"
/>
2026-06-26 16:27:29 +04:00

117 lines
2.3 KiB
SCSS
Vendored

@use "lib/viewport";
.full-page-chat.full-page-chat-sidebar-enabled {
border: none;
}
.c-navbar-container {
background-color: var(--d-content-background);
.full-page-chat & {
@include viewport.from(sm) {
padding: 0 1.5em;
}
}
.chat-drawer.is-collapsed & {
background: var(--tertiary-low);
opacity: 0.7;
}
}
body.has-full-page-chat {
background-color: var(--background-color);
#main-outlet-wrapper {
@media screen and (width < 87rem) {
// ideal width just slightly larger than our xl viewport variable
padding-inline: 0;
}
}
}
.chat-drawer-container {
.is-expanded & {
box-shadow: 0 0 0 2px var(--tertiary-medium);
}
.chat-drawer.is-expanded & {
border: none;
}
.c-navbar__title {
padding-left: 0.33em; // visual alignment for chat index, which does not have a back arrow
}
}
.chat-drawer-outlet-container {
z-index: z("composer", "content");
padding-bottom: 0;
right: var(--main-grid-gap);
&:has(.is-expanded) {
z-index: calc(z("composer", "dropdown") + 1);
}
&.above-composer {
padding-bottom: 0;
}
}
// the below are elements whose z-index needs to be adjusted due to the above change
.chat-message-actions-container {
.has-drawer-chat & {
z-index: calc(z("composer", "dropdown") + 1);
}
}
.fk-d-menu[data-identifier="usercard"],
.fk-d-menu[data-identifier="chat-message-reaction-users"] {
.has-drawer-chat & {
z-index: z("modal", "dialog");
}
}
.chat-drawer {
.peek-mode-active & {
max-width: 90vw;
}
}
.chat-drawer .channels-list-container .chat-channel-row {
margin-bottom: var(--spacing-block-xs);
font-size: var(--font-up-1);
border-bottom: none;
&:hover {
background-color: var(--d-sidebar-active-background);
}
}
.channel-title {
font-weight: bold;
text-transform: uppercase;
font-size: var(--font-down-1);
}
.chat-composer__wrapper {
background: var(--d-content-background);
}
.chat-message-actions .more-buttons .btn-icon-text {
&:hover {
background-color: var(--d-selected);
box-shadow: none;
color: var(--primary);
}
}
.chat-drawer-active.chat-drawer-expanded .chat-composer-dropdown__menu-content {
z-index: z("modal", "dialog");
}
.chat-replying-indicator-container {
@include viewport.from(sm) {
margin-left: calc(0.65em + 0.2rem);
}
}