about summary refs log tree commit diff
path: root/app/views
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-03-20 03:36:29 +0100
committerEugen Rochko <eugen@zeonfederated.com>2017-03-20 03:36:29 +0100
commit6b1db5c2b202383bd22d40909a68df8cbcb20b36 (patch)
treedc8b9b0144a29302285c70a3e8b12639dfa7162e /app/views
parent56d998cbdbf9743ced5a77895b902ccf33b36332 (diff)
Add landing strip
Diffstat (limited to 'app/views')
-rw-r--r--app/views/accounts/show.html.haml3
-rw-r--r--app/views/shared/_landing_strip.html.haml2
-rw-r--r--app/views/stream_entries/show.html.haml3
3 files changed, 8 insertions, 0 deletions
diff --git a/app/views/accounts/show.html.haml b/app/views/accounts/show.html.haml
index c194ce33d..e1ad2d905 100644
--- a/app/views/accounts/show.html.haml
+++ b/app/views/accounts/show.html.haml
@@ -14,6 +14,9 @@
   %meta{ property: 'og:image:height', content: '120' }/
   %meta{ property: 'twitter:card', content: 'summary' }/
 
+- if !user_signed_in? && !Rails.configuration.x.single_user_mode
+  = render partial: 'shared/landing_strip', locals: { account: @account }
+
 .h-feed
   %data.p-name{ value: "#{@account.username} on #{Rails.configuration.x.local_domain}" }/
 
diff --git a/app/views/shared/_landing_strip.html.haml b/app/views/shared/_landing_strip.html.haml
new file mode 100644
index 000000000..bb081e544
--- /dev/null
+++ b/app/views/shared/_landing_strip.html.haml
@@ -0,0 +1,2 @@
+.landing-strip
+  = t('landing_strip_html', name: display_name(account), domain: Rails.configuration.x.local_domain, sign_up_path: new_user_registration_path)
diff --git a/app/views/stream_entries/show.html.haml b/app/views/stream_entries/show.html.haml
index 6bad45705..7a1afdd96 100644
--- a/app/views/stream_entries/show.html.haml
+++ b/app/views/stream_entries/show.html.haml
@@ -20,5 +20,8 @@
 
   %meta{ property: 'twitter:card', content: 'summary' }/
 
+- if !user_signed_in? && !Rails.configuration.x.single_user_mode
+  = render partial: 'shared/landing_strip', locals: { account: @stream_entry.account }
+
 .activity-stream.activity-stream-headless
   = render partial: @type, locals: { @type.to_sym => @stream_entry.activity, include_threads: true }