Merge remote-tracking branch 'parent/main' into upstream-20241119

This commit is contained in:
KMY 2024-11-19 08:49:55 +09:00
commit 055045981f
221 changed files with 2006 additions and 1127 deletions

View file

@ -1,5 +1,4 @@
- content_for :page_title do
= t('about.title')
- content_for :page_title, t('about.title')
- content_for :header_tags do
= render partial: 'shared/og'

View file

@ -1,5 +1,4 @@
- content_for :page_title do
#{display_name(@account)} (#{acct(@account)})
- content_for :page_title, "#{display_name(@account)} (#{acct(@account)})"
- content_for :header_tags do
- if @account.noindex?

View file

@ -30,12 +30,12 @@
%label.batch-table__row__select.batch-table__row__select--aligned.batch-checkbox
= f.input_field :other_domains,
as: :boolean,
checked_value: record.exchange.to_s,
checked_value: record,
include_hidden: false,
multiple: true
.batch-table__row__content.pending-account
.pending-account__header
%samp= record.exchange.to_s
%samp= record
%br
= t('admin.email_domain_blocks.dns.types.mx')

View file

@ -2,40 +2,52 @@
%label.batch-table__row__select.batch-checkbox
= f.check_box :status_ids, { multiple: true, include_hidden: false }, status.id
.batch-table__row__content
.status__content><
- if status.proper.spoiler_text.blank?
= prerender_custom_emojis(status_content_format(status.proper), status.proper.emojis)
- else
%details<
%summary><
%strong> Content warning: #{prerender_custom_emojis(h(status.proper.spoiler_text), status.proper.emojis)}
= prerender_custom_emojis(status_content_format(status.proper), status.proper.emojis)
- unless status.proper.ordered_media_attachments.empty?
= render partial: 'admin/reports/media_attachments', locals: { status: status.proper }
.detailed-status__meta
- if status.application
= status.application.name
·
= link_to ActivityPub::TagManager.instance.url_for(status.proper), class: 'detailed-status__datetime', target: stream_link_target, rel: 'noopener noreferrer' do
%time.formatted{ datetime: status.created_at.iso8601, title: l(status.created_at) }= l(status.created_at)
- if status.edited?
·
= link_to t('statuses.edited_at_html', date: content_tag(:time, l(status.edited_at), datetime: status.edited_at.iso8601, title: l(status.edited_at), class: 'formatted')),
admin_account_status_path(status.account_id, status),
class: 'detailed-status__datetime'
- if status.discarded?
·
%span.negative-hint= t('admin.statuses.deleted')
·
.status__card
- if status.reblog?
= material_symbol('repeat_active')
= t('statuses.boosted_from_html', acct_link: admin_account_inline_link_to(status.proper.account))
- else
.status__prepend
= material_symbol('repeat')
= t('statuses.boosted_from_html', acct_link: admin_account_inline_link_to(status.proper.account, path: admin_account_status_path(status.proper.account.id, status.proper.id)))
- elsif status.reply? && status.in_reply_to_id.present?
.status__prepend
= material_symbol('reply')
= t('admin.statuses.replied_to_html', acct_link: admin_account_inline_link_to(status.in_reply_to_account, path: admin_account_status_path(status.thread.account_id, status.in_reply_to_id)))
.status__content><
- if status.proper.spoiler_text.blank?
= prerender_custom_emojis(status_content_format(status.proper), status.proper.emojis)
- else
%details<
%summary><
%strong> Content warning: #{prerender_custom_emojis(h(status.proper.spoiler_text), status.proper.emojis)}
= prerender_custom_emojis(status_content_format(status.proper), status.proper.emojis)
- unless status.proper.ordered_media_attachments.empty?
= render partial: 'admin/reports/media_attachments', locals: { status: status.proper }
.detailed-status__meta
- if status.application
= status.application.name
·
= link_to admin_account_status_path(status.account.id, status), class: 'detailed-status__datetime' do
%time.formatted{ datetime: status.created_at.iso8601, title: l(status.created_at) }= l(status.created_at)
- if status.edited?
·
= link_to t('statuses.edited_at_html', date: content_tag(:time, l(status.edited_at), datetime: status.edited_at.iso8601, title: l(status.edited_at), class: 'formatted')),
admin_account_status_path(status.account_id, status),
class: 'detailed-status__datetime'
- if status.discarded?
·
%span.negative-hint= t('admin.statuses.deleted')
·
= material_symbol visibility_icon(status)
= t("statuses.visibilities.#{status.visibility}")
- if status.proper.sensitive?
·
= material_symbol('visibility_off')
= t('stream_entries.sensitive_content')
= link_to ActivityPub::TagManager.instance.url_for(status.proper), class: 'detailed-status__link', rel: 'noopener noreferrer' do
= t('admin.statuses.view_publicly')
- if status.proper.sensitive?
·
= material_symbol('visibility_off')
= t('stream_entries.sensitive_content')

View file

@ -1,7 +1,5 @@
- content_for :page_title do
= t('admin.statuses.title')
\-
@#{@account.pretty_acct}
= t('admin.statuses.title', name: @account.pretty_acct)
.filters
.filter-subset
@ -33,11 +31,18 @@
= check_box_tag :batch_checkbox_all, nil, false
.batch-table__toolbar__actions
- unless @statuses.empty?
= f.button safe_join([material_symbol('flag'), t('admin.statuses.batch.report')]),
class: 'table-action-link',
data: { confirm: t('admin.reports.are_you_sure') },
name: :report,
type: :submit
- if params[:report_id]
= f.button safe_join([material_symbol('add'), t('admin.statuses.batch.add_to_report', id: params[:report_id])]),
class: 'table-action-link',
data: { confirm: t('admin.reports.are_you_sure') },
name: :report,
type: :submit
- else
= f.button safe_join([material_symbol('flag'), t('admin.statuses.batch.report')]),
class: 'table-action-link',
data: { confirm: t('admin.reports.are_you_sure') },
name: :report,
type: :submit
.batch-table__body
- if @statuses.empty?
= nothing_here 'nothing-here--under-tabs'

View file

@ -1,7 +1,14 @@
- content_for :page_title do
= t('statuses.title', name: display_name(@account), quote: truncate(@status.spoiler_text.presence || @status.text, length: 50, omission: '…', escape: false))
= t('admin.statuses.status_title', name: @account.pretty_acct)
- content_for :heading_actions do
= form_with model: @status_batch_action, url: batch_admin_account_statuses_path(@account.id) do |f|
= f.hidden_field :status_ids, { multiple: true, value: @status.id }
= f.button safe_join([material_symbol('flag'), t('admin.statuses.batch.report')]),
class: 'button',
data: { confirm: t('admin.reports.are_you_sure') },
name: :report,
type: :submit
= link_to t('admin.statuses.open'), ActivityPub::TagManager.instance.url_for(@status), class: 'button', target: '_blank', rel: 'noopener noreferrer'
%h3= t('admin.statuses.metadata')
@ -57,7 +64,56 @@
%hr.spacer/
%h3= t('admin.statuses.history')
%h3= t('admin.statuses.contents')
%ol.history
= render partial: 'admin/status_edits/status_edit', collection: batched_ordered_status_edits
.status__card
- if @status.reblog?
.status__prepend
= material_symbol('repeat')
= t('statuses.boosted_from_html', acct_link: admin_account_inline_link_to(@status.proper.account, path: admin_account_status_path(@status.proper.account.id, @status.proper.id)))
- elsif @status.reply? && @status.in_reply_to_id.present?
.status__prepend
= material_symbol('reply')
= t('admin.statuses.replied_to_html', acct_link: admin_account_inline_link_to(@status.in_reply_to_account, path: admin_account_status_path(@status.thread.account_id, @status.in_reply_to_id)))
.status__content><
- if @status.proper.spoiler_text.blank?
= prerender_custom_emojis(status_content_format(@status.proper), @status.proper.emojis)
- else
%details<
%summary><
%strong> Content warning: #{prerender_custom_emojis(h(@status.proper.spoiler_text), @status.proper.emojis)}
= prerender_custom_emojis(status_content_format(@status.proper), @status.proper.emojis)
- unless @status.proper.ordered_media_attachments.empty?
= render partial: 'admin/reports/media_attachments', locals: { status: @status.proper }
.detailed-status__meta
- if @status.application
= @status.application.name
·
%span.detailed-status__datetime
%time.formatted{ datetime: @status.created_at.iso8601, title: l(@status.created_at) }= l(@status.created_at)
- if @status.edited?
·
%span.detailed-status__datetime
= t('statuses.edited_at_html', date: content_tag(:time, l(@status.edited_at), datetime: @status.edited_at.iso8601, title: l(@status.edited_at), class: 'formatted'))
- if @status.discarded?
·
%span.negative-hint= t('admin.statuses.deleted')
- unless @status.reblog?
·
= material_symbol(visibility_icon(@status))
= t("statuses.visibilities.#{@status.visibility}")
- if @status.proper.sensitive?
·
= material_symbol('visibility_off')
= t('stream_entries.sensitive_content')
%hr.spacer/
%h3= t('admin.statuses.history')
- if @status.edits.empty?
%p= t('admin.statuses.no_history')
- else
%ol.history
= render partial: 'admin/status_edits/status_edit', collection: batched_ordered_status_edits

View file

@ -23,7 +23,7 @@
= image_tag(status.account.avatar.url, width: 15, height: 15, alt: '', class: 'avatar')
.username= status.account.acct
·
= link_to ActivityPub::TagManager.instance.url_for(status), class: 'detailed-status__datetime', target: stream_link_target, rel: 'noopener noreferrer' do
= link_to ActivityPub::TagManager.instance.url_for(status), class: 'detailed-status__datetime', rel: 'noopener noreferrer' do
%time.formatted{ datetime: status.created_at.iso8601, title: l(status.created_at) }= l(status.created_at)
- if status.edited?
·

View file

@ -1,5 +1,4 @@
- content_for :page_title do
= t('privacy_policy.title')
- content_for :page_title, t('privacy_policy.title')
- content_for :header_tags do
= render partial: 'shared/og'

View file

@ -42,13 +42,33 @@
%label.batch-table__toolbar__select.batch-checkbox-all
= check_box_tag :batch_checkbox_all, nil, false
.batch-table__toolbar__actions
= f.button safe_join([material_symbol('person_add'), t('relationships.follow_selected_followers')]), name: :follow, class: 'table-action-link', type: :submit, data: { confirm: t('relationships.confirm_follow_selected_followers') } if followed_by_relationship? && !mutual_relationship?
- if followed_by_relationship? && !mutual_relationship?
= f.button safe_join([material_symbol('person_add'), t('relationships.follow_selected_followers')]),
class: 'table-action-link',
data: { confirm: t('relationships.confirm_follow_selected_followers') },
name: :follow,
type: :submit
= f.button safe_join([material_symbol('person_remove'), t('relationships.remove_selected_follows')]), name: :unfollow, class: 'table-action-link', type: :submit, data: { confirm: t('relationships.confirm_remove_selected_follows') } unless followed_by_relationship?
- unless followed_by_relationship?
= f.button safe_join([material_symbol('person_remove'), t('relationships.remove_selected_follows')]),
class: 'table-action-link',
data: { confirm: t('relationships.confirm_remove_selected_follows') },
name: :unfollow,
type: :submit
= f.button safe_join([material_symbol('delete'), t('relationships.remove_selected_followers')]), name: :remove_from_followers, class: 'table-action-link', type: :submit, data: { confirm: t('relationships.confirm_remove_selected_followers') } unless following_relationship?
- unless following_relationship?
= f.button safe_join([material_symbol('delete'), t('relationships.remove_selected_followers')]),
class: 'table-action-link',
data: { confirm: t('relationships.confirm_remove_selected_followers') },
name: :remove_from_followers,
type: :submit
= f.button safe_join([material_symbol('delete'), t('relationships.remove_selected_domains')]), name: :remove_domains_from_followers, class: 'table-action-link', type: :submit, data: { confirm: t('admin.reports.are_you_sure') } if followed_by_relationship?
- if followed_by_relationship?
= f.button safe_join([material_symbol('delete'), t('relationships.remove_selected_domains')]),
class: 'table-action-link',
data: { confirm: t('admin.reports.are_you_sure') },
name: :remove_domains_from_followers,
type: :submit
.batch-table__body
- if @accounts.empty?
= nothing_here 'nothing-here--under-tabs'

View file

@ -65,7 +65,7 @@
%p.lead= t('author_attribution.then_instructions')
.fields-group
= f.input :attribution_domains_as_text, as: :text, wrapper: :with_block_label, input_html: { placeholder: "example1.com\nexample2.com\nexample3.com", rows: 4 }
= f.input :attribution_domains_as_text, as: :text, wrapper: :with_block_label, input_html: { placeholder: "example1.com\nexample2.com\nexample3.com", rows: 4, autocapitalize: 'none', autocorrect: 'off' }
.actions
= f.button :button, t('generic.save_changes'), type: :submit

View file

@ -1,3 +1,4 @@
- content_for :body_classes, 'app-body'
- content_for :header_tags do
- if user_signed_in?
= preload_pack_asset 'features/compose.js'

View file

@ -1,5 +1,4 @@
- content_for :page_title do
= t('statuses.title', name: display_name(@account), quote: truncate(@status.spoiler_text.presence || @status.text, length: 50, omission: '…', escape: false))
- content_for :page_title, t('statuses.title', name: display_name(@account), quote: truncate(@status.spoiler_text.presence || @status.text, length: 50, omission: '…', escape: false))
- content_for :header_tags do
- if @account.noindex?