This commit is contained in:
zeppi 2021-08-03 11:03:08 -04:00 committed by jessopb
parent f01fb7dd22
commit 2d66b8666d

View file

@ -283,10 +283,13 @@ function CommentList(props: Props) {
<Empty padded text={__('That was pretty deep. What do you think?')} /> <Empty padded text={__('That was pretty deep. What do you think?')} />
)} )}
<ul className={classnames({ <ul
'comments': expandedComments, className={classnames({
comments: expandedComments,
'comments--contracted': !expandedComments, 'comments--contracted': !expandedComments,
})} ref={commentRef}> })}
ref={commentRef}
>
{topLevelComments && {topLevelComments &&
displayedComments && displayedComments &&
displayedComments.map((comment) => { displayedComments.map((comment) => {
@ -318,9 +321,9 @@ function CommentList(props: Props) {
<div className="card__bottom-actions--comments"> <div className="card__bottom-actions--comments">
{moreBelow && ( {moreBelow && (
<Button <Button
button="alt" button="link"
title={!expandedComments ? __('Expand Comments') : __('Load More')} title={!expandedComments ? __('Expand Comments') : __('Load More')}
label={!expandedComments ? __('Expand Comments') : __('Load More')} label={!expandedComments ? __('Expand') : __('More')}
onClick={() => { onClick={() => {
if (!expandedComments) { if (!expandedComments) {
setExpandedComments(true); setExpandedComments(true);
@ -332,9 +335,9 @@ function CommentList(props: Props) {
)} )}
{expandedComments && ( {expandedComments && (
<Button <Button
button="alt" button="link"
title={__('Collapse Thread')} title={__('Collapse Thread')}
label={__('Collapse Thread')} label={__('Collapse')}
onClick={() => { onClick={() => {
setExpandedComments(false); setExpandedComments(false);
}} }}