You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

96 lines
3.7 KiB

  1. - content_for :page_title do
  2. = site_hostname
  3. - content_for :header_tags do
  4. = javascript_pack_tag 'public', 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= friendly_number_to_human @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= friendly_number_to_human @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? && @rules.empty? && (!display_blocks? || @blocks&.empty?)
  38. = nothing_here
  39. - else
  40. .box-widget
  41. .rich-formatting
  42. - unless @rules.empty?
  43. %h2#rules= t('about.rules')
  44. %p= t('about.rules_html')
  45. %ol.rules-list
  46. - @rules.each do |rule|
  47. %li
  48. .rules-list__text= rule.text
  49. = @contents.html_safe
  50. - if display_blocks? && !@blocks.empty?
  51. %h2#unavailable-content= t('about.unavailable_content')
  52. %p= t('about.unavailable_content_html')
  53. - if (blocks = @blocks.select(&:reject_media?)) && !blocks.empty?
  54. %h3= t('about.unavailable_content_description.rejecting_media_title')
  55. %p= t('about.unavailable_content_description.rejecting_media')
  56. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  57. - if (blocks = @blocks.select(&:silence?)) && !blocks.empty?
  58. %h3= t('about.unavailable_content_description.silenced_title')
  59. %p= t('about.unavailable_content_description.silenced')
  60. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  61. - if (blocks = @blocks.select(&:suspend?)) && !blocks.empty?
  62. %h3= t('about.unavailable_content_description.suspended_title')
  63. %p= t('about.unavailable_content_description.suspended')
  64. = render partial: 'domain_blocks', locals: { domain_blocks: blocks }
  65. .column-4
  66. %ul.table-of-contents
  67. - unless @rules.empty?
  68. %li= link_to t('about.rules'), '#rules'
  69. - @table_of_contents.each do |item|
  70. %li
  71. = link_to item.title, "##{item.anchor}"
  72. - unless item.children.empty?
  73. %ul
  74. - item.children.each do |sub_item|
  75. %li= link_to sub_item.title, "##{sub_item.anchor}"
  76. - if display_blocks? && !@blocks.empty?
  77. %li= link_to t('about.unavailable_content'), '#unavailable-content'