<% if user_signed_in? && current_user.id == @user.id %>
<%= link_to edit_user_registration_path do %>
Edit your profile <%= User.icon %>
<% end %>
<% end %>
Joined Notebook.ai
<%= time_ago_in_words @user.created_at %> ago

Following
<%= link_to following_user_path(@user) do %> <%= pluralize @user.followed_users.count, 'worldbuilder' %> <% end %>

Followed by
<%= link_to followers_user_path(@user) do %> <%= pluralize @user.followed_by_users.count, 'worldbuilder' %> <% end %>
<% if @user.username.present? || @user.other_names.present? %>
<% if @user.username.present? %>
Username
<%= link_to "@#{@user.username}", profile_by_username_path(username: @user.username) %>

<% end %> <% if @user.other_names.present? %>
Also known as
<%= @user.other_names %>

<% end %>
<% end %> <% if @user.website.present? %>
Website
<%= link_to @user.website, @user.website, target: '_new', data: { confirm: "You are about to visit an external website not owned by Notebook.ai. Please only continue if you trust this user." }, ref: 'nofollow' %>

<% end %> <% if @user.favorite_page_type? && @favorite_content.count > 0 %>
<%= link_to send("#{@user.favorite_page_type.downcase.pluralize}_user_path", {id: @user.id}), class: 'black-text' do %>
Favorite page type
<%= @accent_icon %> Check out my <%= pluralize @favorite_content.count, @user.favorite_page_type.downcase %>
<% end %>
<% end %> <% if user_signed_in? && @user.blocked_by?(current_user) %>

You've blocked this user.

<% else %> <% if @user.bio.present? %>
Bio
<%= simple_format truncate(@user.bio, length: 500) %>
<% end %> <% %w(interests favorite_genre favorite_author favorite_book favorite_quote inspirations).each do |field| %> <% next unless @user.send(field).present? %>
<%= field.titleize %>
<%= simple_format @user.send(field) %>
<% end %> <% end %>