forked from mastodon/mastodon
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge commit 'c91c0175db1cc8b954a977d29472886234ce9586' into glitch-s…
…oc/merge-upstream Conflicts: - `spec/controllers/api/v1/timelines/tag_controller_spec.rb`: Glitch-soc had a few extra lines in this file to account for a different default setting. This file got replaced by `spec/requests/api/v1/timelines/tag_spec.rb`, into which the glitch-soc additions were moved too. Additional changes: - `spec/requests/api/v1/statuses/sources_spec.rb`: Add glitch-soc-only attribute `content_type`.
- Loading branch information
Showing
89 changed files
with
1,735 additions
and
2,166 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
.strike-card | ||
- unless strike.none_action? | ||
%p= t "user_mailer.warning.explanation.#{strike.action}", instance: Rails.configuration.x.local_domain | ||
- if strike.text.present? | ||
= linkify(strike.text) | ||
- if strike.report && !strike.report.other? | ||
%p | ||
%strong= t('user_mailer.warning.reason') | ||
= t("user_mailer.warning.categories.#{strike.report.category}") | ||
- if strike.report.violation? && strike.report.rule_ids.present? | ||
%ul.strike-card__rules | ||
- strike.report.rules.each do |rule| | ||
%li | ||
%span.strike-card__rules__text= rule.text | ||
- if strike.status_ids.present? && !strike.status_ids.empty? | ||
%p | ||
%strong= t('user_mailer.warning.statuses') | ||
.strike-card__statuses-list | ||
- status_map = strike.statuses.includes(:application, :media_attachments).index_by(&:id) | ||
- strike.status_ids.each do |status_id| | ||
.strike-card__statuses-list__item | ||
- if (status = status_map[status_id.to_i]) | ||
.one-liner | ||
.emojify= one_line_preview(status) | ||
- status.ordered_media_attachments.each do |media_attachment| | ||
%abbr{ title: media_attachment.description } | ||
= fa_icon 'link' | ||
= media_attachment.file_file_name | ||
.strike-card__statuses-list__item__meta | ||
= link_to ActivityPub::TagManager.instance.url_for(status), target: '_blank', rel: 'noopener noreferrer' do | ||
%time.formatted{ datetime: status.created_at.iso8601, title: l(status.created_at) }= l(status.created_at) | ||
- unless status.application.nil? | ||
· | ||
= status.application.name | ||
- else | ||
.one-liner= t('disputes.strikes.status', id: status_id) | ||
.strike-card__statuses-list__item__meta | ||
= t('disputes.strikes.status_removed') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,51 +21,7 @@ | |
|
||
.report-header | ||
.report-header__card | ||
.strike-card | ||
- unless @strike.none_action? | ||
%p= t "user_mailer.warning.explanation.#{@strike.action}", instance: Rails.configuration.x.local_domain | ||
|
||
- if @strike.text.present? | ||
= linkify(@strike.text) | ||
|
||
- if @strike.report && [email protected]? | ||
%p | ||
%strong= t('user_mailer.warning.reason') | ||
= t("user_mailer.warning.categories.#{@strike.report.category}") | ||
|
||
- if @strike.report.violation? && @strike.report.rule_ids.present? | ||
%ul.strike-card__rules | ||
- @strike.report.rules.each do |rule| | ||
%li | ||
%span.strike-card__rules__text= rule.text | ||
|
||
- if @strike.status_ids.present? && [email protected]_ids.empty? | ||
%p | ||
%strong= t('user_mailer.warning.statuses') | ||
|
||
.strike-card__statuses-list | ||
- status_map = @strike.statuses.includes(:application, :media_attachments).index_by(&:id) | ||
|
||
- @strike.status_ids.each do |status_id| | ||
.strike-card__statuses-list__item | ||
- if (status = status_map[status_id.to_i]) | ||
.one-liner | ||
.emojify= one_line_preview(status) | ||
|
||
- status.ordered_media_attachments.each do |media_attachment| | ||
%abbr{ title: media_attachment.description } | ||
= fa_icon 'link' | ||
= media_attachment.file_file_name | ||
.strike-card__statuses-list__item__meta | ||
= link_to ActivityPub::TagManager.instance.url_for(status), target: '_blank', rel: 'noopener noreferrer' do | ||
%time.formatted{ datetime: status.created_at.iso8601, title: l(status.created_at) }= l(status.created_at) | ||
- unless status.application.nil? | ||
· | ||
= status.application.name | ||
- else | ||
.one-liner= t('disputes.strikes.status', id: status_id) | ||
.strike-card__statuses-list__item__meta | ||
= t('disputes.strikes.status_removed') | ||
= render 'card', strike: @strike | ||
|
||
.report-header__details | ||
.report-header__details__item | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.