Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clean up file page and reactions #7251

Merged
merged 1 commit into from
Oct 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion ui/component/commentsList/view.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ function CommentList(props: Props) {
{readyToDisplayComments && topLevelComments && getCommentElems(topLevelComments)}
</ul>

{!hasDefaultExpansion && (
{!hasDefaultExpansion && topLevelComments && Boolean(topLevelComments.length) && (
<div className="card__bottom-actions--comments">
{(!expandedComments || moreBelow) && (
<Button
Expand Down
10 changes: 8 additions & 2 deletions ui/component/fileReactions/view.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,10 @@ function FileReactions(props: Props) {
title={__('I like this')}
requiresAuth={IS_WEB}
authSrc="filereaction_like"
className={classnames('button--file-action', { 'button--fire': myReaction === REACTION_TYPES.LIKE })}
className={classnames('button--file-action', {
'button--fire': SIMPLE_SITE && myReaction === REACTION_TYPES.LIKE,
'button--file-action-active': !SIMPLE_SITE && myReaction === REACTION_TYPES.LIKE,
})}
label={
<>
{myReaction === REACTION_TYPES.LIKE && SIMPLE_SITE && (
Expand All @@ -101,7 +104,10 @@ function FileReactions(props: Props) {
requiresAuth={IS_WEB}
authSrc={'filereaction_dislike'}
title={__('I dislike this')}
className={classnames('button--file-action', { 'button--slime': myReaction === REACTION_TYPES.DISLIKE })}
className={classnames('button--file-action', {
'button--slime': SIMPLE_SITE && myReaction === REACTION_TYPES.DISLIKE,
'button--file-action-active': !SIMPLE_SITE && myReaction === REACTION_TYPES.DISLIKE,
})}
label={
<>
{myReaction === REACTION_TYPES.DISLIKE && SIMPLE_SITE && (
Expand Down
17 changes: 11 additions & 6 deletions ui/scss/component/_button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,12 @@
transition: background 0.2s;
}

.vjs-button--autoplay-next.vjs-button[aria-checked=true] {
.vjs-button--autoplay-next.vjs-button[aria-checked='true'] {
background: var(--color-primary);
}

.vjs-button--autoplay-next.vjs-button::after {
content: "";
content: '';
position: absolute;
top: 0;
left: 0;
Expand All @@ -193,7 +193,7 @@
transition: transform 0.2s;
}

.vjs-button--autoplay-next.vjs-button[aria-checked=true]::after {
.vjs-button--autoplay-next.vjs-button[aria-checked='true']::after {
transform: translateX(12px);
}

Expand Down Expand Up @@ -282,9 +282,7 @@
padding: 0 var(--spacing-xxs);

.icon {
&:not(.color-override) {
stroke: #777;
}
stroke: var(--color-text-subtitle);
}

.button__label {
Expand All @@ -305,6 +303,13 @@
}
}

.button--file-action-active {
.icon {
fill: var(--color-primary-alt);
stroke: var(--color-primary);
}
}

.button--fire {
color: var(--color-fire);
position: relative;
Expand Down