diff options
author | Thibaut Girka <thib@sitedethib.com> | 2018-08-10 15:39:06 +0200 |
---|---|---|
committer | Thibaut Girka <thib@sitedethib.com> | 2018-08-10 16:22:31 +0200 |
commit | e5a603206dfa76e2cd1b8a7fbb940fbd844b436c (patch) | |
tree | c3271f86b91ce2d13aea4f111dad6da4d07dcc04 /app/views | |
parent | 90b492143dae5cbaf884b12fbfd823c9f65d392f (diff) | |
parent | 5b8603879f06573d51c5c33edda6f410d1af7a02 (diff) |
Merge branch 'master' into glitch-soc/merge-upstream
Conflicts: app/controllers/accounts_controller.rb app/javascript/mastodon/locales/pl.json app/views/about/more.html.haml Conflicts in `accounts_controller.rb` resolved by taking upstream's version + our `use_pack`. Conflicts in `pl.json` resolved by taking upstream's changes. Conflicts in `aboute/more.html.haml` resolved by taking upstream's changes.
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/about/_administration.html.haml | 19 | ||||
-rw-r--r-- | app/views/about/_contact.html.haml | 22 | ||||
-rw-r--r-- | app/views/about/more.html.haml | 72 | ||||
-rw-r--r-- | app/views/about/show.html.haml | 4 | ||||
-rw-r--r-- | app/views/about/terms.html.haml | 14 | ||||
-rw-r--r-- | app/views/accounts/_header.html.haml | 2 | ||||
-rw-r--r-- | app/views/accounts/show.html.haml | 8 |
7 files changed, 53 insertions, 88 deletions
diff --git a/app/views/about/_administration.html.haml b/app/views/about/_administration.html.haml deleted file mode 100644 index 02286d68b..000000000 --- a/app/views/about/_administration.html.haml +++ /dev/null @@ -1,19 +0,0 @@ -.account - .account__wrapper - - if @instance_presenter.contact_account - = link_to TagManager.instance.url_for(@instance_presenter.contact_account), class: 'account__display-name' do - .account__avatar-wrapper - .account__avatar{ style: "background-image: url(#{@instance_presenter.contact_account.avatar.url})" } - %span.display-name - %bdi - %strong.display-name__html.emojify= display_name(@instance_presenter.contact_account, custom_emojify: true) - %span.display-name__account @#{@instance_presenter.contact_account.acct} - - else - .account__display-name - .account__avatar-wrapper - .account__avatar{ style: "background-image: url(#{full_asset_url('avatars/original/missing.png', skip_pipeline: true)})" } - %span.display-name - %strong= t 'about.contact_missing' - %span.display-name__account= t 'about.contact_unavailable' - - = link_to t('about.learn_more'), about_more_path, class: 'button button-alternative' diff --git a/app/views/about/_contact.html.haml b/app/views/about/_contact.html.haml deleted file mode 100644 index 3215d50b5..000000000 --- a/app/views/about/_contact.html.haml +++ /dev/null @@ -1,22 +0,0 @@ -.panel - .panel-header - = succeed ':' do - = t 'about.contact' - - if contact.site_contact_email.present? - = mail_to contact.site_contact_email, nil, title: contact.site_contact_email - - else - %span= t 'about.contact_unavailable' - .panel-body - - if contact.contact_account - .owner - .avatar= image_tag contact.contact_account.avatar.url - .name - = link_to TagManager.instance.url_for(contact.contact_account) do - %span.display_name.emojify= display_name(contact.contact_account, custom_emojify: true) - %span.username @#{contact.contact_account.acct} - - else - .owner - .avatar= image_tag full_asset_url('avatars/original/missing.png', skip_pipeline: true) - .name - %span.display_name= t 'about.contact_missing' - %span.username= t 'about.contact_unavailable' diff --git a/app/views/about/more.html.haml b/app/views/about/more.html.haml index f86051fbf..bafe618cc 100644 --- a/app/views/about/more.html.haml +++ b/app/views/about/more.html.haml @@ -4,43 +4,43 @@ - content_for :header_tags do = render partial: 'shared/og' -.landing-page - .header-wrapper.compact - .header - = render 'links' +.grid-3 + .column-0 + .public-account-header.public-account-header--no-bar + .public-account-header__image + = image_tag @instance_presenter.hero&.file&.url || @instance_presenter.thumbnail&.file&.url || asset_pack_path('preview.jpg'), alt: @instance_presenter.site_title, class: 'parallax' - .container-alt.hero - .heading - %h3= t('about.description_headline', domain: site_hostname) - %p= @instance_presenter.site_description.html_safe.presence || t('about.generic_description', domain: site_hostname) + .column-1 + .landing-page__call-to-action{ dir: 'ltr' } + .row + .row__information-board + .information-board__section + %span= t 'about.user_count_before' + %strong= number_with_delimiter @instance_presenter.user_count + %span= t 'about.user_count_after' + .information-board__section + %span= t 'about.status_count_before' + %strong= number_with_delimiter @instance_presenter.status_count + %span= t 'about.status_count_after' + .row__mascot + .landing-page__mascot + = image_tag asset_pack_path('elephant_ui_plane.svg') - .information-board - .container-alt - .information-board__sections - .information-board__section - %span= t 'about.user_count_before' - %strong= number_with_delimiter @instance_presenter.user_count - %span= t 'about.user_count_after' - .information-board__section - %span= t 'about.status_count_before' - %strong= number_with_delimiter @instance_presenter.status_count - %span= t 'about.status_count_after' - .information-board__section - %span= t 'about.domain_count_before' - %strong= number_with_delimiter @instance_presenter.domain_count - %span= t 'about.domain_count_after' - = render 'contact', contact: @instance_presenter + .column-2 + .landing-page__information.contact-widget + %p + %strong= t 'about.administered_by' - .extended-description - .container-alt - = @instance_presenter.site_extended_description.html_safe.presence || t('about.extended_description_html') + = account_link_to(@instance_presenter.contact_account) - .footer-links - .container-alt - %p - = link_to t('about.source_code'), @instance_presenter.source_url - - if @instance_presenter.commit_hash == "" - %strong= " (#{@instance_presenter.version_number})" - - else - %strong= "#{@instance_presenter.version_number}, " - %strong= "#{@instance_presenter.commit_hash}" + - if @instance_presenter.site_contact_email.present? + %p.contact-widget__mail + %strong + = succeed ':' do + = t 'about.contact' + %br/ + = mail_to @instance_presenter.site_contact_email, nil, title: @instance_presenter.site_contact_email + + .column-3 + .box-widget + .rich-formatting= @instance_presenter.site_extended_description.html_safe.presence || t('about.extended_description_html') diff --git a/app/views/about/show.html.haml b/app/views/about/show.html.haml index e6d4cd10e..9d40eceeb 100644 --- a/app/views/about/show.html.haml +++ b/app/views/about/show.html.haml @@ -109,7 +109,7 @@ %p= t 'about.about_mastodon_html' %div.contact %h3= t 'about.administered_by' - = render 'administration' + = account_link_to(@instance_presenter.contact_account, link_to(t('about.learn_more'), about_more_path, class: 'button button-alternative')) = render 'features' @@ -130,7 +130,7 @@ %p= t 'about.about_mastodon_html' %div.contact %h3= t 'about.administered_by' - = render 'administration' + = account_link_to(@instance_presenter.contact_account, link_to(t('about.learn_more'), about_more_path, class: 'button button-alternative')) = render 'features' diff --git a/app/views/about/terms.html.haml b/app/views/about/terms.html.haml index c7d36ed47..9d076a91b 100644 --- a/app/views/about/terms.html.haml +++ b/app/views/about/terms.html.haml @@ -1,11 +1,9 @@ - content_for :page_title do = t('terms.title', instance: site_hostname) -.landing-page - .header-wrapper.compact - .header - = render 'links' - - .extended-description - .container-alt - = @instance_presenter.site_terms.html_safe.presence || t('terms.body_html') +.grid + .column-0 + .box-widget + .rich-formatting= @instance_presenter.site_terms.html_safe.presence || t('terms.body_html') + .column-1 + = render 'application/sidebar' diff --git a/app/views/accounts/_header.html.haml b/app/views/accounts/_header.html.haml index e343be820..d3b9893c4 100644 --- a/app/views/accounts/_header.html.haml +++ b/app/views/accounts/_header.html.haml @@ -7,7 +7,7 @@ .public-account-header__tabs .public-account-header__tabs__name %h1 - = display_name(account) + = display_name(account, custom_emojify: true) %small = acct(account) = fa_icon('lock') if account.locked? diff --git a/app/views/accounts/show.html.haml b/app/views/accounts/show.html.haml index b30755d94..e398fc29b 100644 --- a/app/views/accounts/show.html.haml +++ b/app/views/accounts/show.html.haml @@ -55,4 +55,12 @@ = render 'moved', account: @account = render 'bio', account: @account + + - unless @endorsed_accounts.empty? + .endorsements-widget + %h4= t 'accounts.choices_html', name: content_tag(:bdi, display_name(@account, custom_emojify: true)) + + - @endorsed_accounts.each do |account| + = account_link_to account + = render 'application/sidebar' |