more.html.haml 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. - content_for :page_title do
  2. = site_hostname
  3. - content_for :header_tags do
  4. = javascript_pack_tag 'public', integrity: true, crossorigin: 'anonymous'
  5. = render partial: 'shared/og'
  6. .grid-4
  7. .column-0
  8. .public-account-header.public-account-header--no-bar
  9. .public-account-header__image
  10. = image_tag @instance_presenter.hero&.file&.url || @instance_presenter.thumbnail&.file&.url || asset_pack_path('media/images/preview.jpg'), alt: @instance_presenter.site_title, class: 'parallax'
  11. .column-1
  12. .landing-page__call-to-action{ dir: 'ltr' }
  13. .row
  14. .row__information-board
  15. .information-board__section
  16. %span= t 'about.user_count_before'
  17. %strong= number_with_delimiter @instance_presenter.user_count
  18. %span= t 'about.user_count_after', count: @instance_presenter.user_count
  19. .information-board__section
  20. %span= t 'about.status_count_before'
  21. %strong= number_with_delimiter @instance_presenter.status_count
  22. %span= t 'about.status_count_after', count: @instance_presenter.status_count
  23. .row__mascot
  24. .landing-page__mascot
  25. = image_tag @instance_presenter.mascot&.file&.url || asset_pack_path('media/images/elephant_ui_plane.svg'), alt: ''
  26. .column-2
  27. .contact-widget
  28. %h4= t 'about.administered_by'
  29. = account_link_to(@instance_presenter.contact_account)
  30. - if @instance_presenter.site_contact_email.present?
  31. %h4
  32. = succeed ':' do
  33. = t 'about.contact'
  34. = mail_to @instance_presenter.site_contact_email, nil, title: @instance_presenter.site_contact_email
  35. .column-3
  36. = render 'application/flashes'
  37. - if @contents.blank? && (!display_blocks? || @blocks&.empty?)
  38. = nothing_here
  39. - else
  40. .box-widget
  41. .rich-formatting
  42. = @contents.html_safe
  43. - if display_blocks? && !@blocks.empty?
  44. %h2#unavailable-content= t('about.unavailable_content')
  45. %p= t('about.unavailable_content_html')
  46. - if (blocks = @blocks.select(&:reject_media?)) && !blocks.empty?
  47. %h3= t('about.unavailable_content_description.rejecting_media_title')
  48. %p= t('about.unavailable_content_description.rejecting_media')
  49. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  50. - if (blocks = @blocks.select(&:silence?)) && !blocks.empty?
  51. %h3= t('about.unavailable_content_description.silenced_title')
  52. %p= t('about.unavailable_content_description.silenced')
  53. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  54. - if (blocks = @blocks.select(&:suspend?)) && !blocks.empty?
  55. %h3= t('about.unavailable_content_description.suspended_title')
  56. %p= t('about.unavailable_content_description.suspended')
  57. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  58. .column-4
  59. %ul.table-of-contents
  60. - @table_of_contents.each do |item|
  61. %li
  62. = link_to item.title, "##{item.anchor}"
  63. - unless item.children.empty?
  64. %ul
  65. - item.children.each do |sub_item|
  66. %li= link_to sub_item.title, "##{sub_item.anchor}"
  67. - if display_blocks? && !@blocks.empty?
  68. %li= link_to t('about.unavailable_content'), '#unavailable-content'