<% show_collections_tab = @user.page_collections.any? || @user.published_in_page_collections.any? %> <%= content_for :full_width_page_header do %>
<% if @user.favorite_page_type? %>
<% else %> <%= image_tag "card-headers/users.png", style: 'height: 200px;' %> <% end %> <%= image_tag @user.image_url.html_safe, class: 'header-avatar materialboxed', data: { caption: "#{@user.display_name}'s avatar" } %> <%= @user.name %> <%= render partial: 'thredded/users/badge', locals: { user: @user } %>
<% end %>
<%= render partial: 'users/profile/actions' %>
<%= render partial: 'users/profile/info' %>
<% if user_signed_in? && @user.blocked_by?(current_user) %>

You've blocked this user.

<% else %> <%= render partial: 'stream/share', collection: @feed %> <% if @feed.empty? %>

There are no posts here yet!

You can follow other worldbuilders from their profiles. Whenever a user you follow shares one of their public pages, it will appear here for you to comment on!

<% end %> <% end %>
<% if user_signed_in? && @user.blocked_by?(current_user) %>

You've blocked this user.

<% else %>
<% @user.universes.is_public.each do |universe| %>
<%= link_to universe do %>
<%= image_tag universe.first_public_image %> <%= universe.name %>

<%= truncate(universe.description, length: 140) %>

<% end %>
<% end %>
You can also browse this user's public pages directly. <% if @content.empty? %> However, they haven't made anything public yet! <% end %>
<%= render partial: 'users/profile/public_pages' %>
<% end %>
<% if user_signed_in? && @user.blocked_by?(current_user) %>

You've blocked this user.

<% else %>
<% if @user.published_in_page_collections.any? %>

Published in

<% @user.published_in_page_collections.each do |page_collection| %>
<%= link_to page_collection do %>
<%= image_tag page_collection.first_public_image %> <%= PageCollection.icon %> <%= page_collection.title %>
<%= page_collection.subtitle %>

<%= truncate(page_collection.description, length: 140) %>

<% end %>
<% end %> <% end %>
<% if @user.page_collections.any? %>

My Collections

<% @user.page_collections.each.with_index do |page_collection, i| %>
<%= link_to page_collection do %>
<%= image_tag page_collection.first_public_image, height: 250 %> <%= PageCollection.icon %> <%= page_collection.title %>
<%= page_collection.subtitle %>

<%= truncate(page_collection.description, length: 140) %>

<% end %>
<% end %> <% end %>
<% end %>