闭社主体 forked from https://github.com/tootsuite/mastodon
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.

146 lines
5.8 KiB

  1. - content_for :page_title do
  2. = site_hostname
  3. - content_for :header_tags do
  4. %link{ rel: 'canonical', href: about_url }/
  5. %script#initial-state{ type: 'application/json' }!= json_escape(@initial_state_json)
  6. = javascript_pack_tag 'about', integrity: true, crossorigin: 'anonymous'
  7. = render partial: 'shared/og'
  8. .landing-page.alternative
  9. .container
  10. .grid
  11. .column-0
  12. .brand
  13. = link_to root_url do
  14. = image_tag asset_pack_path('logo_full.svg'), alt: 'Mastodon'
  15. - if Setting.timeline_preview
  16. .column-1
  17. .landing-page__forms
  18. .brand
  19. = link_to root_url do
  20. = image_tag asset_pack_path('logo_full.svg'), alt: 'Mastodon'
  21. = render 'forms'
  22. - else
  23. .column-1.non-preview
  24. .landing-page__forms
  25. .brand
  26. = link_to root_url do
  27. = image_tag asset_pack_path('logo_full.svg'), alt: 'Mastodon'
  28. = render 'forms'
  29. - if Setting.timeline_preview
  30. .column-2
  31. .landing-page__hero
  32. = image_tag @instance_presenter.hero&.file&.url || @instance_presenter.thumbnail&.file&.url || asset_pack_path('preview.jpg'), alt: @instance_presenter.site_title
  33. .landing-page__information
  34. .landing-page__short-description
  35. .row
  36. .landing-page__logo
  37. = image_tag asset_pack_path('logo_transparent.svg'), alt: 'Mastodon'
  38. %h1
  39. = @instance_presenter.site_title
  40. %small!= t 'about.hosted_on', domain: content_tag(:span, site_hostname)
  41. %p= @instance_presenter.site_description.html_safe.presence || t('about.generic_description', domain: site_hostname)
  42. .landing-page__call-to-action{ dir: 'ltr' }
  43. .row
  44. .row__information-board
  45. .information-board__section
  46. %span= t 'about.user_count_before'
  47. %strong= number_with_delimiter @instance_presenter.user_count
  48. %span= t 'about.user_count_after', count: @instance_presenter.user_count
  49. .information-board__section
  50. %span= t 'about.status_count_before'
  51. %strong= number_with_delimiter @instance_presenter.status_count
  52. %span= t 'about.status_count_after', count: @instance_presenter.status_count
  53. .row__mascot
  54. .landing-page__mascot
  55. = image_tag asset_pack_path('elephant_ui_plane.svg'), alt: ''
  56. - else
  57. .column-2.non-preview
  58. .landing-page__hero
  59. = image_tag @instance_presenter.hero&.file&.url || @instance_presenter.thumbnail&.file&.url || asset_pack_path('preview.jpg'), alt: @instance_presenter.site_title
  60. .landing-page__information
  61. .landing-page__short-description
  62. .row
  63. .landing-page__logo
  64. = image_tag asset_pack_path('logo_transparent.svg'), alt: 'Mastodon'
  65. %h1
  66. = @instance_presenter.site_title
  67. %small!= t 'about.hosted_on', domain: content_tag(:span, site_hostname)
  68. %p= @instance_presenter.site_description.html_safe.presence || t('about.generic_description', domain: site_hostname)
  69. .landing-page__call-to-action
  70. .row
  71. .row__information-board
  72. .information-board__section
  73. %span= t 'about.user_count_before'
  74. %strong= number_with_delimiter @instance_presenter.user_count
  75. %span= t 'about.user_count_after', count: @instance_presenter.user_count
  76. .information-board__section
  77. %span= t 'about.status_count_before'
  78. %strong= number_with_delimiter @instance_presenter.status_count
  79. %span= t 'about.status_count_after', count: @instance_presenter.status_count
  80. .row__mascot
  81. .landing-page__mascot
  82. = image_tag asset_pack_path('elephant_ui_plane.svg'), alt: ''
  83. - if Setting.timeline_preview
  84. .column-3
  85. #mastodon-timeline{ data: { props: Oj.dump(default_props) } }
  86. - if Setting.timeline_preview
  87. .column-4.landing-page__information
  88. .landing-page__features
  89. .features-list
  90. %div
  91. %h3= t 'about.what_is_mastodon'
  92. %p= t 'about.about_mastodon_html'
  93. %div.contact
  94. %h3= t 'about.administered_by'
  95. = account_link_to(@instance_presenter.contact_account, link_to(t('about.learn_more'), about_more_path, class: 'button button-alternative'))
  96. = render 'features'
  97. .landing-page__features__action
  98. = link_to t('about.learn_more'), 'https://joinmastodon.org/', class: 'button button-alternative'
  99. .landing-page__footer
  100. %p
  101. = link_to t('about.source_code'), @instance_presenter.source_url
  102. = " (#{@instance_presenter.version_number})"
  103. - else
  104. .column-4.non-preview.landing-page__information
  105. .landing-page__features
  106. .features-list
  107. %div
  108. %h3= t 'about.what_is_mastodon'
  109. %p= t 'about.about_mastodon_html'
  110. %div.contact
  111. %h3= t 'about.administered_by'
  112. = account_link_to(@instance_presenter.contact_account, link_to(t('about.learn_more'), about_more_path, class: 'button button-alternative'))
  113. = render 'features'
  114. .landing-page__features__action
  115. = link_to t('about.learn_more'), 'https://joinmastodon.org/', class: 'button button-alternative'
  116. .landing-page__footer
  117. %p
  118. = link_to t('about.source_code'), @instance_presenter.source_url
  119. = " (#{@instance_presenter.version_number})"
  120. #modal-container