fix: Discussions UI fixes on mobile resolutions (#689)

This commit is contained in:
Stanislav
2024-04-04 15:46:01 +03:00
committed by GitHub
parent 7db4fde252
commit 12fbe7eebd
4 changed files with 13 additions and 5 deletions

View File

@@ -99,7 +99,7 @@ const AuthorLabel = ({
return showUserNameAsLink
? (
<div className={className}>
<div className={`${className} flex-wrap`}>
<Link
data-testid="learner-posts-link"
id="learner-posts-link"
@@ -112,7 +112,7 @@ const AuthorLabel = ({
{labelContents}
</div>
)
: <div className={className}>{authorName}{labelContents}</div>;
: <div className={`${className} flex-wrap`}>{authorName}{labelContents}</div>;
};
AuthorLabel.propTypes = {

View File

@@ -50,7 +50,7 @@ const DiscussionSidebar = ({ displaySidebar, postActionBarRef }) => {
'd-none': !displaySidebar,
'd-flex overflow-auto box-shadow-centered-1': displaySidebar,
'w-100': !isOnDesktop,
'sidebar-desktop-width': isOnDesktop && !isOnXLDesktop,
'w-25 sidebar-desktop-width': isOnDesktop && !isOnXLDesktop,
'w-25 sidebar-XL-width': isOnXLDesktop,
'min-content-height': !enableInContextSidebar,
})}

View File

@@ -131,7 +131,7 @@ const Reply = ({ responseId }) => {
className="bg-light-300 pl-4 pt-2.5 pr-2.5 pb-10px flex-fill"
style={{ borderRadius: '0rem 0.375rem 0.375rem' }}
>
<div className="d-flex flex-row justify-content-between" style={{ height: '24px' }}>
<div className="d-flex flex-row justify-content-between">
<AuthorLabel
author={author}
authorLabel={authorLabel}

View File

@@ -230,6 +230,10 @@ header {
.sidebar-desktop-width {
min-width: 29rem !important;
@include media-breakpoint-down(lg) {
min-width: 25rem !important;
}
}
.sidebar-XL-width {
@@ -480,6 +484,10 @@ code {
display: flex;
}
}
.pgn__avatar {
flex-shrink: 0;
}
}
.spinner-dimensions {
@@ -560,7 +568,7 @@ code {
}
.author-name {
line-height: 1;
line-height: 1.5;
word-break: break-all;
}