From f3c93cfb4f9fc14904eeccf94b4baf9305743f2f Mon Sep 17 00:00:00 2001 From: YoheiZuho Date: Tue, 15 Aug 2023 11:35:53 +0000 Subject: [PATCH] =?UTF-8?q?=E4=B8=80=E7=99=BA=E3=81=A7=E5=BC=95=E7=94=A8?= =?UTF-8?q?=E3=81=AE=E6=8A=95=E7=A8=BF=E8=80=85=E3=81=AB=E9=A3=9B=E3=81=B6?= =?UTF-8?q?=E3=82=88=E3=81=86=E3=81=AB=E3=81=97=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/javascript/mastodon/components/status.jsx | 13 +++++++++++-- .../features/status/components/detailed_status.jsx | 11 ++++++++++- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/app/javascript/mastodon/components/status.jsx b/app/javascript/mastodon/components/status.jsx index 63acf54a5..a7cf887f4 100644 --- a/app/javascript/mastodon/components/status.jsx +++ b/app/javascript/mastodon/components/status.jsx @@ -275,6 +275,15 @@ class Status extends ImmutablePureComponent { this.context.router.history.push(`/statuses/${status.getIn(['reblog', 'quote', 'id'], status.getIn(['quote', 'id']))}`); } + handleQuoteUserClick = () =>{ + if (!this.context.router) { + return; + } + + const { status } = this.props; + this.location.href(`/@${status.getIn(['account', 'acct'])}`); + } + handleExpandedToggle = () => { this.props.onToggleHidden(this._properStatus()); }; @@ -644,8 +653,8 @@ class Status extends ImmutablePureComponent { } }; - const identity = (status, account) => ( - + const identity = (status, account, _0, quote = false) => ( +
{statusAvatar(status, account)}
diff --git a/app/javascript/mastodon/features/status/components/detailed_status.jsx b/app/javascript/mastodon/features/status/components/detailed_status.jsx index f86c3c680..cf2f37594 100644 --- a/app/javascript/mastodon/features/status/components/detailed_status.jsx +++ b/app/javascript/mastodon/features/status/components/detailed_status.jsx @@ -93,6 +93,15 @@ class DetailedStatus extends ImmutablePureComponent { const { status } = this.props; this.context.router.history.push(`/statuses/${status.getIn(['quote', 'id'])}`); } + + handleQuoteUserClick = () =>{ + if (!this.context.router) { + return; + } + + const { status } = this.props; + this.location.href(`/@${status.getIn(['account', 'acct'])}`); + } _measureHeight (heightJustChanged) { if (this.props.measureHeight && this.node) { @@ -176,7 +185,7 @@ class DetailedStatus extends ImmutablePureComponent { const language = status.getIn(['translation', 'language']) || status.get('language'); const identity = (status, _0, _1, quote = false) => ( -
+