show.html.haml 1.0 KB

1234567891011121314151617181920
  1. - content_for :page_title, t('statuses.title', name: display_name(@account), quote: truncate(@status.spoiler_text.presence || @status.text, length: 50, omission: '…', escape: false))
  2. - content_for :header_tags do
  3. - if @account.user_prefers_noindex?
  4. %meta{ name: 'robots', content: 'noindex, noarchive' }/
  5. %link{ rel: 'alternate', type: 'application/json+oembed', href: api_oembed_url(url: short_account_status_url(@account, @status), format: 'json') }/
  6. %link{ rel: 'alternate', type: 'application/activity+json', href: ActivityPub::TagManager.instance.uri_for(@status) }/
  7. = opengraph 'og:site_name', site_title
  8. = opengraph 'og:type', 'article'
  9. = opengraph 'og:title', "#{display_name(@account)} (#{acct(@account)})"
  10. = opengraph 'og:url', short_account_status_url(@account, @status)
  11. = opengraph 'og:published_time', @status.created_at.iso8601
  12. = opengraph 'profile:username', acct(@account)[1..]
  13. = render 'og_description', activity: @status
  14. = render 'og_image', activity: @status, account: @account
  15. = render 'shared/web_app'