Skip to content

Commit

Permalink
fix: change unlisted quote display
Browse files Browse the repository at this point in the history
  • Loading branch information
mashirozx committed Aug 2, 2022
1 parent fbadcee commit 8fbdef7
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 3 deletions.
8 changes: 6 additions & 2 deletions app/javascript/mastodon/components/status.js
Original file line number Diff line number Diff line change
Expand Up @@ -637,11 +637,15 @@ class Status extends ImmutablePureComponent {
}

if (quote_status.get('visibility') === 'unlisted' && contextType !== 'home') {
unlistedQuoteText = intl.formatMessage({ id: 'status.unlisted_quote', defaultMessage: 'Unlisted quote' });
unlistedQuoteText = intl.formatMessage({ id: 'status.unlisted_quote', defaultMessage: 'Unlisted quote content, click to expand' });
quote = (
<div className={classNames('quote-status', `status-${quote_status.get('visibility')}`, { muted: this.props.muted })} data-id={quote_status.get('id')}>
<div className={classNames('status__content unlisted-quote', { 'status__content--with-action': this.context.router })}>
<button onClick={this.handleQuoteClick}>{unlistedQuoteText}</button>
<button onClick={this.handleQuoteClick}>
<Icon id='unlock:fad' />
{unlistedQuoteText}
<Icon id='angle-double-right:fad' />
</button>
</div>
</div>
);
Expand Down
2 changes: 1 addition & 1 deletion app/javascript/mastodon/locales/defaultMessages.json
Original file line number Diff line number Diff line change
Expand Up @@ -573,7 +573,7 @@
"id": "status.quote"
},
{
"defaultMessage": "Unlisted quote",
"defaultMessage": "Unlisted quote content, click to expand",
"id": "status.unlisted_quote"
},
{
Expand Down
13 changes: 13 additions & 0 deletions app/javascript/styles/mastodon/components.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,19 @@
outline: none;
padding: 0;
appearance: none;
text-align: left;

i {
font-style: normal;

&:first-child{
margin-right: 4px;
}

&:last-child{
margin-left: 4px;
}
}
}
}

Expand Down

0 comments on commit 8fbdef7

Please sign in to comment.