show.html.haml 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. - content_for :page_title do
  2. = site_hostname
  3. - content_for :header_tags do
  4. %link{ rel: 'canonical', href: about_url }/
  5. = render partial: 'shared/og'
  6. .landing
  7. .landing__brand
  8. = link_to root_url, class: 'brand' do
  9. = image_pack_tag 'logo_full.svg', alt: 'Mastodon'
  10. %span.brand__tagline=t 'about.tagline'
  11. .landing__grid
  12. .landing__grid__column.landing__grid__column-registration
  13. .box-widget
  14. = render 'registration'
  15. .directory
  16. .directory__tag{ class: Setting.profile_directory ? nil : 'disabled' }
  17. = optional_link_to Setting.profile_directory, explore_path do
  18. %h4
  19. = fa_icon 'address-book fw'
  20. = t('about.discover_users')
  21. %small= t('about.browse_directory')
  22. .avatar-stack
  23. - @instance_presenter.sample_accounts.each do |account|
  24. = image_tag current_account&.user&.setting_auto_play_gif ? account.avatar_original_url : account.avatar_static_url, width: 48, height: 48, alt: '', class: 'account__avatar'
  25. .directory__tag{ class: Setting.timeline_preview ? nil : 'disabled' }
  26. = optional_link_to Setting.timeline_preview, public_timeline_path do
  27. %h4
  28. = fa_icon 'globe fw'
  29. = t('about.see_whats_happening')
  30. %small= t('about.browse_public_posts')
  31. .directory__tag
  32. = link_to 'https://joinmastodon.org/apps', target: '_blank', rel: 'noopener' do
  33. %h4
  34. = fa_icon 'tablet fw'
  35. = t('about.get_apps')
  36. %small= t('about.apps_platforms')
  37. .landing__grid__column.landing__grid__column-login
  38. .box-widget
  39. = render 'login'
  40. .hero-widget
  41. .hero-widget__img
  42. = image_tag @instance_presenter.hero&.file&.url || @instance_presenter.thumbnail&.file&.url || asset_pack_path('media/images/preview.jpg'), alt: @instance_presenter.site_title
  43. - if @instance_presenter.site_short_description.present?
  44. .hero-widget__text
  45. %p
  46. = @instance_presenter.site_short_description.html_safe.presence
  47. = link_to about_more_path do
  48. = t('about.learn_more')
  49. = fa_icon 'angle-double-right'
  50. .hero-widget__footer
  51. .hero-widget__footer__column
  52. %h4= t 'about.administered_by'
  53. = account_link_to @instance_presenter.contact_account
  54. .hero-widget__footer__column
  55. %h4= t 'about.server_stats'
  56. %div{ style: 'display: flex' }
  57. .hero-widget__counter{ style: 'width: 50%' }
  58. %strong= number_to_human @instance_presenter.user_count, strip_insignificant_zeros: true
  59. %span= t 'about.user_count_after', count: @instance_presenter.user_count
  60. .hero-widget__counter{ style: 'width: 50%' }
  61. %strong= number_to_human @instance_presenter.active_user_count, strip_insignificant_zeros: true
  62. %span
  63. = t 'about.active_count_after'
  64. %abbr{ title: t('about.active_footnote') } *