bug in support link

bug in support link

      <%= link [fa_icon("headphones"), " ", @episode.title],
               to: episode_frontend_path(@conn, :show, @episode),
               class: "btn btn-primary btn-xs",
               style: "color: #fff",
               id: "detail-#{@episode.id}" %>

        <%= link [fa_icon("headphones"), " Listen"],
                 to: episode_frontend_path(@conn, :show, @episode) %>

      <%= if @episode.subtitle do %>

Subtitle

<%= @episode.subtitle %>

      <% end %>
      <%= if @episode.payment_link_url do %>

Support

<%= link(@episode.payment_link_title || "Support", to: @episode.payment_link_url) %>

      <% end %>

Duration

<%= @episode.duration %>

Publishing date

<%= Timex.format!(@episode.publishing_date, "{ISOdate} {h24}:{m}") %>

      <%= if @episode.link do %>

Link

<a href="<%= @episode.link %>"><%= truncate @episode.link, 80 %>

      <% end %>
      <%= if @episode.deep_link do %>

Deep link

<a href="<%= @episode.deep_link %>"><%= @episode.deep_link %>

      <% end %>

    <%= if @episode.description do %>

Description

<%= raw @episode.description %>

    <% end %>

    <%= if @episode.summary && @episode.summary != @episode.description do %>

Summary

<%= @episode.summary %>

    <% end %>

      <%= link [fa_icon("headphones"), " ", @episode.title],
               to: episode_frontend_path(@conn, :show, @episode),
               class: "btn btn-primary btn-xs",
               style: "color: #fff",
               id: "detail-#{@episode.id}" %>

        <%= link [fa_icon("headphones"), " Listen"],
                 to: episode_frontend_path(@conn, :show, @episode) %>

      <%= if @episode.subtitle do %>

Subtitle

<%= @episode.subtitle %>

      <% end %>
      <%= if @episode.payment_link_url do %>

Support

link(@episode.payment_link_title, to: @episode.payment_link_url) %>

      <% end %>

Duration

<%= @episode.duration %>

Publishing date

<%= Timex.format!(@episode.publishing_date, "{ISOdate} {h24}:{m}") %>

      <%= if @episode.link do %>

Link

<a href="<%= @episode.link %>"><%= truncate @episode.link, 80 %>

      <% end %>
      <%= if @episode.deep_link do %>

Deep link

<a href="<%= @episode.deep_link %>"><%= @episode.deep_link %>

      <% end %>

    <%= if @episode.description do %>

Description

<%= raw @episode.description %>

    <% end %>

    <%= if @episode.summary && @episode.summary != @episode.description do %>

Summary

<%= @episode.summary %>

    <% end %>


use class .show-events for sams thing

use class .show-events for sams thing

<div style="padding: 40px;">
  <%= raw(@content) %>
</div>

<script>

  function show (el) {
    el.style.display = 'block';
  }

  function hide (el) {
    el.style.display = 'none';
  }

  function toggle (el) {
    if (el.style.display == 'none') {
      el.style.display = 'block';
    } else {
      el.style.display = 'none';
    }
  }

  function showHiddenContent (ev) {
    var el = document.querySelector('#vol-events');
    var action = el.getAttribute('data-action');

    if (action == 'show') {
      show(el)
    } else if (action == 'hide') {
      hide(el)
    } else {
      toggle(el)
    }
  }

  var buttons = Array.from(document.querySelectorAll('.show-events'));

  buttons.forEach(function (button) {
    button.addEventListener('click', showHiddenContent);
  })

</script>

<div style="padding: 40px;">
  <%= raw(@content) %>
</div>

<script>

  function show (el) {
    el.style.display = 'block';
  }

  function hide (el) {
    el.style.display = 'none';
  }

  function toggle (el) {
    if (el.style.display == 'none') {
      el.style.display = 'block';
    } else {
      el.style.display = 'none';
    }
  }

  function showHiddenContent (ev) {
    var el = document.querySelector('#vol-events');
    var action = el.getAttribute('data-action');

    if (action == 'show') {
      show(el)
    } else if (action == 'hide') {
      hide(el)
    } else {
      toggle(el)
    }
  }

  var buttons = Array.from(document.querySelectorAll('#show-events'));

  buttons.forEach(function (button) {
    button.addEventListener('click', showHiddenContent);
  })

</script>


Bugfix headline display.

Bugfix headline display.

<%# header tag begins in parent template %>
  <div class="profile-header<%= if @user.verified, do: " profile-header--verified" %>">

      <img src="<%= Vutuv.Avatar.binary(@user, :medium) %>">

        <%= full_name(@user) %>
        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "profile-header__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

        <%= current_title(@job) %>
        <%= if(@organization != "" and @organization) do %>
          @ <%= @organization %>
        <% end %>

    <%= if @user.verified do %>
      Verified profile
    <% end %>

        <%= if(@follower_count>0) do %>

<%= String.capitalize(@user.first_name) %> <%= gettext "has" %><%= @follower_count %> <%= gettext "followers" %>

        <% end %>
        <%= if is_visitor?(@conn, @current_user) do %>
          <%= if user_follows_user?(@current_user, @user) do %>
            <%= button to: connection_path(@conn, :delete, user_follows_user?(@current_user, @user)), method: :delete , class: "button button-link button--unfollow", form: [class: "button--unfollow"] do %>
               Unfollow
            <% end %>
          <%= else %>
            <%= button to: connection_path(@conn, :create, connection: %{follower_id: @current_user_id, followee_id: @user.id}), method: :post , class: "button button-link", form: [class: "button--slim"] do %>
               Follow
            <% end %>
          <% end %>
        <% end %>

<%= render Vutuv.LayoutView, "flash.html", assigns %>

  <%= gettext "Users" %> / <%= full_name @user %>

  <%= if @display_welcome_message do %>
    <%= if same_user?(@user, @current_user) do %>
      <%= if Enum.count(@user_skills) == 0 do %>

<%= gettext "Your New vutuv Profile Page" %>

            <%= gettext "Please take a couple of minutes to add information that might be interesting for your future followers. Why don't you start with your skills and work experiences?" %>

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

  <%= if(@user.headline || @user.birthdate || same_user?(@user, @current_user)) do %>

      <%= if same_user?(@user, @current_user) do %>
      <%= link to: user_path(@conn, :edit, @user), class: "card__edit button button--icon button--small" do %>

      <% end %>
      <% end %>
      <%= if @user.headline || same_user?(@user, @current_user) do %>

<%= gettext "Headline" %>

<%= @user.headline %>

      <% end %>

        <%= if(@user.gender != "other" && @user.gender) do %>

<%= gettext "Gender" %>

<%= @user.gender %>

        <% end %>
        <%= if(@user.birthdate) do %>

<%= gettext "Birthday" %>

<%= @user.birthdate %>

        <% end %>

  <% end %>

    <%= render Vutuv.SharedView, "_ad.html" %>

      <%= if same_user?(@user, @current_user) do %>
      <%= link to: user_email_path(@conn, :index, @user), class: "card__edit button button--icon button--small" do %>

      <% end %>
      <% end %>

<%= gettext "Contact" %>

<%= if (Enum.count(@emails) == 1), do: gettext("Email"), else: gettext("Emails") %>

        <%= for email <- @emails do %>

<a href="mailto:<%= email(@user) %>"><%= email.value %>

        <% end %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_email_path(@conn, :new, @current_user) %>
        <% end %>

<%= gettext "Vcard" %>

<%= link gettext("Download"), to: api_user_v_card_path(@conn, :get, @user) %>

    <%= if Enum.count(@user.social_media_accounts) > 0 or same_user?(@user, @current_user) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_social_media_account_path(@conn, :index, @user), class: "card__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

<%= gettext "Social Media" %>

          <%= for account <- @user.social_media_accounts do %>

<%= account.provider %>

<%= link "@#{account.value}", to: Vutuv.SocialMediaAccount.get_full_url(account) %>

          <% end %>

          <%= if same_user?(@user, @current_user) do %>
            <%= link gettext("Add"), to: user_social_media_account_path(@conn, :new, @current_user) %>
          <% end %>

    <% end %>

  <%= if Enum.count(@user_skills) > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Skills" %>

    <%= if Enum.count(@user_skills) > 0 do %>
    <%= render Vutuv.UserSkillView, "card_list.html", assigns %>
    <% end %>

    <%= if same_user?(@user, @current_user) do %>
      <% #Form for easy skill entry %>
      <%= if Enum.count(@user_skills) == 0 do %>
        <%= form_for @conn, user_path(@conn, :skills_create, @user), [as: :skills, class: "editform"], fn f -> %>
          <div class="editform__field<%= if error_tag(f, :name), do: " editform__field--error"%>">
            <%= label f, :skills, gettext("Enter comma seperated skills here") %>
            <%= text_input f, :skills, placeholder: gettext("PHP, JavaScript, Tap Dancing, Origami"), autofocus: true %>
            <%= error_tag f, :skills %>

            <%= submit gettext("Add"), class: "button button--full" %>

        <% end %>
      <% end %>
    <% end %>
    <%= if Enum.count(@user_skills) > 0 do %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_user_skill_path(@conn, :new, @current_user) %>
        <% end %>
        <%= if same_user?(@user, @current_user) and Enum.count(@user.user_skills) > 4 do %> | <% end %>
        <%= if Enum.count(@user.user_skills) > 4 do %>
          <%= link gettext("View All"), to: user_user_skill_path(@conn, :index, @user)%>
        <% end %>

    <% end %>

  <% end %>

  <section class="card half<%= if @follower_count == 0, do: " card--empty" %>">

<%= gettext "Followers" %>

    <%= if(@follower_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followers, current_user: @current_user, current_user_id: @current_user_id %>

    <% else %>

<%= gettext "No Followers yet!" %>

    <% end %>
    <%= if(@follower_count > 3) do %>
      <%= link "#{@followers_count-3} #{gettext "More"}", to: user_follower_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

<%= gettext "Following" %>

    <%= if(@followee_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followees, current_user: @current_user, current_user_id: @current_user_id %>

    <% else %>

<%= gettext "Not following anyone yet!" %>

    <% end %>
    <%= if(@followee_count > 3) do %>
      <%= link "#{@followee_count-3} #{gettext "More"}", to: user_followee_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

    <%= if @total_jobs > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Experience" %>

    <%= if @total_jobs > 0 do %>
    <%= render Vutuv.WorkExperienceView, "card_list.html", assigns %>

    <% else %>

    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_work_experience_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_jobs>3 do %> | <% end %>
      <%= if @total_jobs>3 do %>
        <%= link gettext("View All"), to: user_work_experience_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_numbers > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Phone Numbers" %>

    <%= if @total_numbers > 0 do %>
    <%= render Vutuv.PhoneNumberView, "card_list.html", phone_numbers: @user.phone_numbers, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_phone_number_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_numbers > 3 do %> | <% end %>
      <%= if @total_numbers>3 do %>
        <%= link gettext("View All"), to: user_phone_number_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_links > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Links" %>

    <%= if @total_links > 0 do %>
    <%= render Vutuv.UrlView, "card_list.html", urls: @user.urls, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_url_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_links > 3 do %> | <% end %>
      <%= if @total_links>3 do %>
        <%= link gettext("View All"), to: user_url_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_addresses > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Addresses" %>

    <%= if @total_addresses > 0 do %>
    <%= render Vutuv.AddressView, "card_list.html", addresses: @user.addresses, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_address_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_addresses > 3 do %> | <% end %>
      <%= if @total_addresses>3 do %>
        <%= link gettext("View All"), to: user_address_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

<%# header tag begins in parent template %>
  <div class="profile-header<%= if @user.verified, do: " profile-header--verified" %>">

      <img src="<%= Vutuv.Avatar.binary(@user, :medium) %>">

        <%= full_name(@user) %>
        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "profile-header__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

        <%= current_title(@job) %>
        <%= if(@organization != "" and @organization) do %>
          @ <%= @organization %>
        <% end %>

    <%= if @user.verified do %>
      Verified profile
    <% end %>

        <%= if(@follower_count>0) do %>

<%= String.capitalize(@user.first_name) %> <%= gettext "has" %><%= @follower_count %> <%= gettext "followers" %>

        <% end %>
        <%= if is_visitor?(@conn, @current_user) do %>
          <%= if user_follows_user?(@current_user, @user) do %>
            <%= button to: connection_path(@conn, :delete, user_follows_user?(@current_user, @user)), method: :delete , class: "button button-link button--unfollow", form: [class: "button--unfollow"] do %>
               Unfollow
            <% end %>
          <%= else %>
            <%= button to: connection_path(@conn, :create, connection: %{follower_id: @current_user_id, followee_id: @user.id}), method: :post , class: "button button-link", form: [class: "button--slim"] do %>
               Follow
            <% end %>
          <% end %>
        <% end %>

<%= render Vutuv.LayoutView, "flash.html", assigns %>

  <%= gettext "Users" %> / <%= full_name @user %>

  <%= if @display_welcome_message do %>
    <%= if same_user?(@user, @current_user) do %>
      <%= if Enum.count(@user_skills) == 0 do %>

<%= gettext "Your New vutuv Profile Page" %>

            <%= gettext "Please take a couple of minutes to add information that might be interesting for your future followers. Why don't you start with your skills and work experiences?" %>

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

  <%= if(@user.headline || @user.birthdate) do %>

    <%= if same_user?(@user, @current_user) do %>
    <%= link to: user_path(@conn, :edit, @user), class: "card__edit button button--icon button--small" do %>

    <% end %>
    <% end %>
    <%= if @user.headline do %>

<%= gettext "Headline" %>

<%= @user.headline %>

    <% end %>

      <%= if(@user.gender != "other" && @user.gender) do %>

<%= gettext "Gender" %>

<%= @user.gender %>

      <% end %>
      <%= if(@user.birthdate) do %>

<%= gettext "Birthday" %>

<%= @user.birthdate %>

      <% end %>

  <% end %>

    <%= render Vutuv.SharedView, "_ad.html" %>

      <%= if same_user?(@user, @current_user) do %>
      <%= link to: user_email_path(@conn, :index, @user), class: "card__edit button button--icon button--small" do %>

      <% end %>
      <% end %>

<%= gettext "Contact" %>

<%= if (Enum.count(@emails) == 1), do: gettext("Email"), else: gettext("Emails") %>

        <%= for email <- @emails do %>

<a href="mailto:<%= email(@user) %>"><%= email.value %>

        <% end %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_email_path(@conn, :new, @current_user) %>
        <% end %>

<%= gettext "Vcard" %>

<%= link gettext("Download"), to: api_user_v_card_path(@conn, :get, @user) %>

    <%= if Enum.count(@user.social_media_accounts) > 0 or same_user?(@user, @current_user) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_social_media_account_path(@conn, :index, @user), class: "card__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

<%= gettext "Social Media" %>

          <%= for account <- @user.social_media_accounts do %>

<%= account.provider %>

<%= link "@#{account.value}", to: Vutuv.SocialMediaAccount.get_full_url(account) %>

          <% end %>

          <%= if same_user?(@user, @current_user) do %>
            <%= link gettext("Add"), to: user_social_media_account_path(@conn, :new, @current_user) %>
          <% end %>

    <% end %>

  <%= if Enum.count(@user_skills) > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Skills" %>

    <%= if Enum.count(@user_skills) > 0 do %>
    <%= render Vutuv.UserSkillView, "card_list.html", assigns %>
    <% end %>

    <%= if same_user?(@user, @current_user) do %>
      <% #Form for easy skill entry %>
      <%= if Enum.count(@user_skills) == 0 do %>
        <%= form_for @conn, user_path(@conn, :skills_create, @user), [as: :skills, class: "editform"], fn f -> %>
          <div class="editform__field<%= if error_tag(f, :name), do: " editform__field--error"%>">
            <%= label f, :skills, gettext("Enter comma seperated skills here") %>
            <%= text_input f, :skills, placeholder: gettext("PHP, JavaScript, Tap Dancing, Origami"), autofocus: true %>
            <%= error_tag f, :skills %>

            <%= submit gettext("Add"), class: "button button--full" %>

        <% end %>
      <% end %>
    <% end %>
    <%= if Enum.count(@user_skills) > 0 do %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_user_skill_path(@conn, :new, @current_user) %>
        <% end %>
        <%= if same_user?(@user, @current_user) and Enum.count(@user.user_skills) > 4 do %> | <% end %>
        <%= if Enum.count(@user.user_skills) > 4 do %>
          <%= link gettext("View All"), to: user_user_skill_path(@conn, :index, @user)%>
        <% end %>

    <% end %>

  <% end %>

  <section class="card half<%= if @follower_count == 0, do: " card--empty" %>">

<%= gettext "Followers" %>

    <%= if(@follower_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followers, current_user: @current_user, current_user_id: @current_user_id %>

    <% else %>

<%= gettext "No Followers yet!" %>

    <% end %>
    <%= if(@follower_count > 3) do %>
      <%= link "#{@followers_count-3} #{gettext "More"}", to: user_follower_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

<%= gettext "Following" %>

    <%= if(@followee_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followees, current_user: @current_user, current_user_id: @current_user_id %>

    <% else %>

<%= gettext "Not following anyone yet!" %>

    <% end %>
    <%= if(@followee_count > 3) do %>
      <%= link "#{@followee_count-3} #{gettext "More"}", to: user_followee_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

    <%= if @total_jobs > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Experience" %>

    <%= if @total_jobs > 0 do %>
    <%= render Vutuv.WorkExperienceView, "card_list.html", assigns %>

    <% else %>

    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_work_experience_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_jobs>3 do %> | <% end %>
      <%= if @total_jobs>3 do %>
        <%= link gettext("View All"), to: user_work_experience_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_numbers > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Phone Numbers" %>

    <%= if @total_numbers > 0 do %>
    <%= render Vutuv.PhoneNumberView, "card_list.html", phone_numbers: @user.phone_numbers, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_phone_number_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_numbers > 3 do %> | <% end %>
      <%= if @total_numbers>3 do %>
        <%= link gettext("View All"), to: user_phone_number_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_links > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Links" %>

    <%= if @total_links > 0 do %>
    <%= render Vutuv.UrlView, "card_list.html", urls: @user.urls, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_url_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_links > 3 do %> | <% end %>
      <%= if @total_links>3 do %>
        <%= link gettext("View All"), to: user_url_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_addresses > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Addresses" %>

    <%= if @total_addresses > 0 do %>
    <%= render Vutuv.AddressView, "card_list.html", addresses: @user.addresses, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_address_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_addresses > 3 do %> | <% end %>
      <%= if @total_addresses>3 do %>
        <%= link gettext("View All"), to: user_address_path(@conn, :index, @user) %>
      <% end %>

  <% end %>


Add aria labels for mergeable column

Add aria labels for mergeable column

    <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/">
      <%= @project.name %>

  Pull requests
  <%= if @mode == :rw do %>
  <%= link "History", to: project_path(@conn, :log, @project), class: "tab" %>
  <%= link "Settings", to: project_path(@conn, :settings, @project), class: "tab" %>
  <% end %>

<%= if empty?(@unbatched_patches) and empty?(@batches) do %>
  Nothing to see here
<% else %>

<%= for batch <- @batches do %>

      <a href="../batches/<%= batch.id %>">Batch <%= batch.id %>

        <%= stringify_state batch.state %>
        <%= Enum.count(batch.patches) %>

#	Mergeable	Title	Priority	Commit

  <%= for patch <- batch.patches do %>

        <%= patch.pr_xref %>

      <td class=span--<%= if patch.is_mergeable do %>ok<% else %>error<% end %> aria-label="<%= if patch.is_mergeable do %><%= if patch.is_draft do %>Draft<% else %>Yes<% end %><% else %>No<% end %>" title="<%= if patch.is_mergeable do %><%= if patch.is_draft do %>Draft<% else %>Yes<% end %><% else %>No<% end %>">
        <%= if patch.is_mergeable do %>
            <%= if patch.is_draft do %>
            ✎ Draft
            <% else %>
            ✓ Yes
            <% end %>
        <% else %>
            ⚠ No
        <% end %>

        <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/pull/<%= patch.pr_xref %>">
          <%= patch.title %>

        <%= patch.priority %>
        <%= if patch.is_single do %>S<% end %>

        <%= truncate_commit(patch.commit) %>

  <% end %>

<% end %>
<%= if @unbatched_patches != [] do %>

        Awaiting review
        <%= Enum.count(@unbatched_patches) %>

#	Mergeable	Title	Priority	Commit

  <%= for patch <- @unbatched_patches do %>

        <%= patch.pr_xref %>

      <td class=span--<%= if patch.is_mergeable do %>ok<% else %>error<% end %> aria-label="<%= if patch.is_mergeable do %><%= if patch.is_draft do %>Draft<% else %>Yes<% end %><% else %>No<% end %>" title="<%= if patch.is_mergeable do %><%= if patch.is_draft do %>Draft<% else %>Yes<% end %><% else %>No<% end %>">
        <%= if patch.is_mergeable do %>
            <%= if patch.is_draft do %>
            ✎ Draft
            <% else %>
            ✓ Yes
            <% end %>
        <% else %>
            ⚠ No
        <% end %>

        <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/pull/<%= patch.pr_xref %>">
          <%= patch.title %>

        <%= patch.priority %>
        <%= if patch.is_single do %>S<% end %>

        <%= truncate_commit(patch.commit) %>

  <% end %>

<% end %>

<% end %>

<%= if @mode == :rw do %>

<%= if @is_synchronizing do %>
  Synchronizing...
<% else %>
  <%= link "Sync pull requests", to: project_path(@conn, :synchronize, @project), method: :put, class: "toolbar-item" %>
<% end %>
<%= if @batches != [] do %>
  <%= link "Cancel all", to: project_path(@conn, :cancel_all, @project), method: :delete, class: "toolbar-item toolbar-item--remove", data: [confirm: "Commenting `bors r-` on a PR will cancel just the one. You asked to cancel all of them, which is a PITA to undo.\n\nAre you sure you want to cancel all running and waiting pull requests?"] %>
<% end %>

<% end %>

    <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/">
      <%= @project.name %>

  Pull requests
  <%= if @mode == :rw do %>
  <%= link "History", to: project_path(@conn, :log, @project), class: "tab" %>
  <%= link "Settings", to: project_path(@conn, :settings, @project), class: "tab" %>
  <% end %>

<%= if empty?(@unbatched_patches) and empty?(@batches) do %>
  Nothing to see here
<% else %>

<%= for batch <- @batches do %>

      <a href="../batches/<%= batch.id %>">Batch <%= batch.id %>

        <%= stringify_state batch.state %>
        <%= Enum.count(batch.patches) %>

#	Mergeable	Title	Priority	Commit

  <%= for patch <- batch.patches do %>

        <%= patch.pr_xref %>

      <td class=span--<%= if patch.is_mergeable do %>ok<% else %>error<% end %>>
        <%= if patch.is_mergeable do %>
            <%= if patch.is_draft do %>
            ✎ Draft
            <% else %>
            ✓ Yes
            <% end %>
        <% else %>
            ⚠ No
        <% end %>

        <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/pull/<%= patch.pr_xref %>">
          <%= patch.title %>

        <%= patch.priority %>
        <%= if patch.is_single do %>S<% end %>

        <%= truncate_commit(patch.commit) %>

  <% end %>

<% end %>
<%= if @unbatched_patches != [] do %>

        Awaiting review
        <%= Enum.count(@unbatched_patches) %>

#	Mergeable	Title	Priority	Commit

  <%= for patch <- @unbatched_patches do %>

        <%= patch.pr_xref %>

      <td class=span--<%= if patch.is_mergeable do %>ok<% else %>error<% end %>>
        <%= if patch.is_mergeable do %>
            <%= if patch.is_draft do %>
            ✎ Draft
            <% else %>
            ✓ Yes
            <% end %>
        <% else %>
            ⚠ No
        <% end %>

        <a href="<%= Confex.fetch_env!(:bors, :html_github_root) %>/<%= @project.name %>/pull/<%= patch.pr_xref %>">
          <%= patch.title %>

        <%= patch.priority %>
        <%= if patch.is_single do %>S<% end %>

        <%= truncate_commit(patch.commit) %>

  <% end %>

<% end %>

<% end %>

<%= if @mode == :rw do %>

<%= if @is_synchronizing do %>
  Synchronizing...
<% else %>
  <%= link "Sync pull requests", to: project_path(@conn, :synchronize, @project), method: :put, class: "toolbar-item" %>
<% end %>
<%= if @batches != [] do %>
  <%= link "Cancel all", to: project_path(@conn, :cancel_all, @project), method: :delete, class: "toolbar-item toolbar-item--remove", data: [confirm: "Commenting `bors r-` on a PR will cancel just the one. You asked to cancel all of them, which is a PITA to undo.\n\nAre you sure you want to cancel all running and waiting pull requests?"] %>
<% end %>

<% end %>


Hide timetables section for contests with no scheduled performances

  <%= name(@contest) %>

  <%= dates(@contest) %>

<%= gettext("Registrations") %>

          <%= icon_link "music", gettext("Manage performances"),
            Routes.internal_contest_performance_path(@conn, :index, @contest)
            %>

          <%= icon_link "user", gettext("Show participants"),
            Routes.internal_contest_participant_path(@conn, :index, @contest)
            %>

          <%= icon_link "tags", gettext("Show categories"),
            Routes.internal_contest_contest_category_path(@conn, :index, @contest)
            %>

<%= gettext("Preparation") %>

          <%= icon_link "time", gettext("Schedule performances"),
            schedule_link_path(@conn, @contest)
            %>

          <%= icon_link "sunglasses", gettext("Create jury material"),
            Routes.internal_contest_performances_path(@conn, :jury_material, @contest)
            %>

<%= gettext("Evaluation") %>

          <%= icon_link "edit", gettext("Enter points"),
            Routes.internal_contest_results_path(@conn, :edit_results, @contest)
            %>

          <%= icon_link "check", gettext("Publish results"),
            Routes.internal_contest_results_path(@conn, :publish_results, @contest)
            %>

          <%= icon_link "certificate", gettext("Create certificates"),
            Routes.internal_contest_performances_path(@conn, :certificates, @contest)
            %>

<% stages = @contest.host.stages %>

<%= if !Enum.empty?(stages) do %>

<%= gettext("Timetables") %>

  <%= for stage <- stages do %>
    <%= link stage.name,
      to: Routes.internal_contest_stage_timetable_path(@conn, :timetable, @contest, stage),
      class: "btn btn-default"
      %>
  <% end %>
<% end %>

  <%= name(@contest) %>

  <%= dates(@contest) %>

<%= gettext("Registrations") %>

          <%= icon_link "music", gettext("Manage performances"),
            Routes.internal_contest_performance_path(@conn, :index, @contest)
            %>

          <%= icon_link "user", gettext("Show participants"),
            Routes.internal_contest_participant_path(@conn, :index, @contest)
            %>

          <%= icon_link "tags", gettext("Show categories"),
            Routes.internal_contest_contest_category_path(@conn, :index, @contest)
            %>

<%= gettext("Preparation") %>

          <%= icon_link "time", gettext("Schedule performances"),
            schedule_link_path(@conn, @contest)
            %>

          <%= icon_link "sunglasses", gettext("Create jury material"),
            Routes.internal_contest_performances_path(@conn, :jury_material, @contest)
            %>

<%= gettext("Evaluation") %>

          <%= icon_link "edit", gettext("Enter points"),
            Routes.internal_contest_results_path(@conn, :edit_results, @contest)
            %>

          <%= icon_link "check", gettext("Publish results"),
            Routes.internal_contest_results_path(@conn, :publish_results, @contest)
            %>

          <%= icon_link "certificate", gettext("Create certificates"),
            Routes.internal_contest_performances_path(@conn, :certificates, @contest)
            %>

<%= gettext("Timetables") %>

<%= for stage <- @contest.host.stages do %>
  <%= link stage.name,
    to: Routes.internal_contest_stage_timetable_path(@conn, :timetable, @contest, stage),
    class: "btn btn-default"
    %>
<% end %>


Workaround for Avatar problem.

Workaround for Avatar problem.

<%# header tag begins in parent template %>
  <div class="profile-header<%= if @user.verified, do: " profile-header--verified" %>">

      <%= if Vutuv.Avatar.sym_link_for_avatar_exists?(@user) do %>
        <img src="<%= Vutuv.Avatar.webserver_static_url(@user, :medium) %>" width="130" height="130" alt="Avatar of <%= full_name(@user) %>">
      <% else %>
        <img src="<%= Vutuv.Avatar.binary(@user, :medium) %>" width="130" height="130" alt="Avatar of <%= full_name(@user) %>">
      <% end %>

        <%= full_name(@user) %>
        <%= if !@user.verified and admin_visitor?(@conn) do %>
          <%= button to: admin_user_path(@conn, :update, user_id: @user.id), class: "button button--icon navigation__icon", form: [class: "button button--icon"], method: "post" do %>
            <i title="<%= gettext("Verify") %>" class="icon icon--lock">
          <% end %>
        <% end %>
        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "profile-header__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

        <%= work_information_string(@user, 50) %>

    <%= if @user.verified do %>
      Verified profile
    <% end %>

        <%= if(@follower_count>0) do %>

<%= short_name(@user) %> <%= gettext "has" %><%= @follower_count %> <%= gettext "followers" %>

        <% end %>
        <%= if is_visitor?(@conn, @current_user) do %>
          <%= if user_follows_user?(@current_user, @user) do %>
            <%= button to: connection_path(@conn, :delete, user_follows_user?(@current_user, @user)), method: :delete , class: "button button-link button--unfollow", form: [class: "button--unfollow"] do %>
               Unfollow
            <% end %>
          <%= else %>
            <%= button to: connection_path(@conn, :create, connection: %{follower_id: @current_user_id, followee_id: @user.id}), method: :post, class: "button button-link", form: [class: "button--slim"] do %>
               Follow
            <% end %>
          <% end %>
        <% end %>

<%= render Vutuv.LayoutView, "flash.html", assigns %>

  <%= gettext "Users" %> / <%= full_name @user %>

  <%= if @display_welcome_message do %>
    <%= if same_user?(@user, @current_user) do %>
      <%= if Enum.count(@user_tags) == 0 do %>

<%= gettext "Your New vutuv Profile Page" %>

            <%= gettext "Please take a couple of minutes to add information that might be interesting for your future followers. Why don't you start with your tags and work experiences?" %>

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

  <%= if Enum.count(@user_tags) > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Tags" %>

    <%= if Enum.count(@user_tags) > 0 do %>
    <%= render Vutuv.UserTagView, "card_list.html", assigns %>
    <% end %>

    <%= if same_user?(@user, @current_user) do %>
      <% #Form for easy tag entry %>
      <%= if Enum.count(@user_tags) == 0 do %>
        <%= form_for @conn, user_path(@conn, :tags_create, @user), [as: :tags, class: "editform"], fn f -> %>
          <div class="editform__field<%= if error_tag(f, :name), do: " editform__field--error"%>">
            <%= label f, :tags, gettext("Enter comma separated tags here. Max length per tag: 45 characters") %>
            <%= text_input f, :tags, placeholder: gettext("PHP, JavaScript, Tap Dancing, Origami, Recruiting"), autofocus: true %>
            <%= error_tag f, :tags %>

            <%= submit gettext("Add"), class: "button button--full" %>

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

    <%= if Enum.count(@user_tags) > 0 && (same_user?(@user, @current_user) || @total_user_tags > 10)do %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_tag_path(@conn, :new, @current_user) %>
        <% end %>
        <%= if same_user?(@user, @current_user) and @total_user_tags > 10 do %> | <% end %>
        <%= if @total_user_tags > 10 do %>
          <%= link gettext("View All"), to: user_tag_path(@conn, :index, @user)%>
        <% end %>

    <% end %>

  <% end %>

    <%= render Vutuv.SharedView, "_ad.html" %>
    <%= render Vutuv.SharedView, "job_ad.html", assigns %>

    <%= if(Enum.count(@emails) > 0 or same_user?(@user, @current_user)) do %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_email_path(@conn, :index, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

          <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
      <% end %>

<%= gettext "Contact" %>

      <%= if(Enum.count(@emails) > 0) do %>

<%= if (Enum.count(@emails) == 1), do: gettext("Email"), else: gettext("Emails") %>

        <%= for email <- @emails do %>

<a href="mailto:<%= email.value %>"><%= email.value %>

        <% end %>

      <% end %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_email_path(@conn, :new, @current_user) %>
        <% end %>

    <% end %>

    <%= if(@user.headline || @user.birthdate || same_user?(@user, @current_user)) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

            <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
        <% end %>

<%= gettext "General Info" %>

        <%= if @user.headline || same_user?(@user, @current_user) do %>

<%= @user.headline %>

        <% end %>

          <%= if(@user.gender != "other" && @user.gender) do %>

<%= gettext "Gender" %>

<%= Vutuv.User.gender_gettext(@user.gender) %>

          <% end %>
          <%= if(@user.birthdate) do %>

<%= gettext "Birthday" %>

<%= format_birthdate(@user) %>

          <% end %>

    <% end %>

    <%= if Enum.count(@user.social_media_accounts) > 0 or same_user?(@user, @current_user) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_social_media_account_path(@conn, :index, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

            <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
        <% end %>

<%= gettext "Social Media" %>

        <%= for account <- @user.social_media_accounts do %>

<%= account.provider %>

<%= Vutuv.SocialMediaAccount.social_media_link account %>

        <% end %>

          <%= if same_user?(@user, @current_user) do %>
            <%= link gettext("Add"), to: user_social_media_account_path(@conn, :new, @current_user) %>
          <% end %>

    <% end %>

<%= gettext "Exports" %>

<%= gettext "Vcard" %>

<%= link gettext("Download"), to: api_user_v_card_path(@conn, :get, @user) %>

  <section class="card half<%= if @follower_count == 0, do: " card--empty" %>">

<%= gettext "Followers" %>

    <%= if(@follower_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followers, current_user: @current_user, current_user_id: @current_user_id, work_string_length: 20 %>

    <% else %>

<%= gettext "No Followers yet!" %>

    <% end %>
    <%= if(@follower_count > 3) do %>
      <%= link "#{@follower_count-3} #{gettext "More"}", to: user_follower_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

<%= gettext "Following" %>

    <%= if(@followee_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followees, current_user: @current_user, current_user_id: @current_user_id, work_string_length: 20 %>

    <% else %>

<%= gettext "Not following anyone yet!" %>

    <% end %>
    <%= if(@followee_count > 3) do %>
      <%= link "#{@followee_count-3} #{gettext "More"}", to: user_followee_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

    <%= if @total_jobs > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Experience" %>

    <%= if @total_jobs > 0 do %>
    <%= render Vutuv.WorkExperienceView, "card_list.html", assigns %>

    <% else %>

    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_work_experience_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_jobs > 5 do %> | <% end %>
      <%= if @total_jobs > 5 do %>
        <%= link gettext("View All"), to: user_work_experience_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_numbers > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Phone Numbers" %>

    <%= if @total_numbers > 0 do %>
    <%= render Vutuv.PhoneNumberView, "card_list.html", phone_numbers: @user.phone_numbers, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_phone_number_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_numbers > 5 do %> | <% end %>
      <%= if @total_numbers > 5 do %>
        <%= link gettext("View All"), to: user_phone_number_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_links > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Links" %>

    <%= if @total_links > 0 do %>
    <%= render Vutuv.UrlView, "card_list.html", urls: @user.urls, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_url_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_links > 5 do %> | <% end %>
      <%= if @total_links > 5 do %>
        <%= link gettext("View All"), to: user_url_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_addresses > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Addresses" %>

    <%= if @total_addresses > 0 do %>
    <%= render Vutuv.AddressView, "card_list.html", addresses: @user.addresses, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_address_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_addresses > 5 do %> | <% end %>
      <%= if @total_addresses > 5 do %>
        <%= link gettext("View All"), to: user_address_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

<%# header tag begins in parent template %>
  <div class="profile-header<%= if @user.verified, do: " profile-header--verified" %>">

      <img src="<%= Vutuv.Avatar.binary(@user, :medium) %>" width="130", height="130" alt="Avatar of <%= full_name(@user) %>">

        <%= full_name(@user) %>
        <%= if !@user.verified and admin_visitor?(@conn) do %>
          <%= button to: admin_user_path(@conn, :update, user_id: @user.id), class: "button button--icon navigation__icon", form: [class: "button button--icon"], method: "post" do %>
            <i title="<%= gettext("Verify") %>" class="icon icon--lock">
          <% end %>
        <% end %>
        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "profile-header__edit button button--icon button--small" do %>

        <% end %>
        <% end %>

        <%= work_information_string(@user, 50) %>

    <%= if @user.verified do %>
      Verified profile
    <% end %>

        <%= if(@follower_count>0) do %>

<%= short_name(@user) %> <%= gettext "has" %><%= @follower_count %> <%= gettext "followers" %>

        <% end %>
        <%= if is_visitor?(@conn, @current_user) do %>
          <%= if user_follows_user?(@current_user, @user) do %>
            <%= button to: connection_path(@conn, :delete, user_follows_user?(@current_user, @user)), method: :delete , class: "button button-link button--unfollow", form: [class: "button--unfollow"] do %>
               Unfollow
            <% end %>
          <%= else %>
            <%= button to: connection_path(@conn, :create, connection: %{follower_id: @current_user_id, followee_id: @user.id}), method: :post, class: "button button-link", form: [class: "button--slim"] do %>
               Follow
            <% end %>
          <% end %>
        <% end %>

<%= render Vutuv.LayoutView, "flash.html", assigns %>

  <%= gettext "Users" %> / <%= full_name @user %>

  <%= if @display_welcome_message do %>
    <%= if same_user?(@user, @current_user) do %>
      <%= if Enum.count(@user_tags) == 0 do %>

<%= gettext "Your New vutuv Profile Page" %>

            <%= gettext "Please take a couple of minutes to add information that might be interesting for your future followers. Why don't you start with your tags and work experiences?" %>

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

  <%= if Enum.count(@user_tags) > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Tags" %>

    <%= if Enum.count(@user_tags) > 0 do %>
    <%= render Vutuv.UserTagView, "card_list.html", assigns %>
    <% end %>

    <%= if same_user?(@user, @current_user) do %>
      <% #Form for easy tag entry %>
      <%= if Enum.count(@user_tags) == 0 do %>
        <%= form_for @conn, user_path(@conn, :tags_create, @user), [as: :tags, class: "editform"], fn f -> %>
          <div class="editform__field<%= if error_tag(f, :name), do: " editform__field--error"%>">
            <%= label f, :tags, gettext("Enter comma separated tags here. Max length per tag: 45 characters") %>
            <%= text_input f, :tags, placeholder: gettext("PHP, JavaScript, Tap Dancing, Origami, Recruiting"), autofocus: true %>
            <%= error_tag f, :tags %>

            <%= submit gettext("Add"), class: "button button--full" %>

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

    <%= if Enum.count(@user_tags) > 0 && (same_user?(@user, @current_user) || @total_user_tags > 10)do %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_tag_path(@conn, :new, @current_user) %>
        <% end %>
        <%= if same_user?(@user, @current_user) and @total_user_tags > 10 do %> | <% end %>
        <%= if @total_user_tags > 10 do %>
          <%= link gettext("View All"), to: user_tag_path(@conn, :index, @user)%>
        <% end %>

    <% end %>

  <% end %>

    <%= render Vutuv.SharedView, "_ad.html" %>
    <%= render Vutuv.SharedView, "job_ad.html", assigns %>

    <%= if(Enum.count(@emails) > 0 or same_user?(@user, @current_user)) do %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_email_path(@conn, :index, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

          <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
      <% end %>

<%= gettext "Contact" %>

      <%= if(Enum.count(@emails) > 0) do %>

<%= if (Enum.count(@emails) == 1), do: gettext("Email"), else: gettext("Emails") %>

        <%= for email <- @emails do %>

<a href="mailto:<%= email.value %>"><%= email.value %>

        <% end %>

      <% end %>

        <%= if same_user?(@user, @current_user) do %>
          <%= link gettext("Add"), to: user_email_path(@conn, :new, @current_user) %>
        <% end %>

    <% end %>

    <%= if(@user.headline || @user.birthdate || same_user?(@user, @current_user)) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_path(@conn, :edit, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

            <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
        <% end %>

<%= gettext "General Info" %>

        <%= if @user.headline || same_user?(@user, @current_user) do %>

<%= @user.headline %>

        <% end %>

          <%= if(@user.gender != "other" && @user.gender) do %>

<%= gettext "Gender" %>

<%= Vutuv.User.gender_gettext(@user.gender) %>

          <% end %>
          <%= if(@user.birthdate) do %>

<%= gettext "Birthday" %>

<%= format_birthdate(@user) %>

          <% end %>

    <% end %>

    <%= if Enum.count(@user.social_media_accounts) > 0 or same_user?(@user, @current_user) do %>

        <%= if same_user?(@user, @current_user) do %>
        <%= link to: user_social_media_account_path(@conn, :index, @user), class: "pull-right btn btn-xs btn-primary btn-icon" do %>

            <%= render Vutuv.IconView, "pencil.html" %>

        <% end %>
        <% end %>

<%= gettext "Social Media" %>

        <%= for account <- @user.social_media_accounts do %>

<%= account.provider %>

<%= Vutuv.SocialMediaAccount.social_media_link account %>

        <% end %>

          <%= if same_user?(@user, @current_user) do %>
            <%= link gettext("Add"), to: user_social_media_account_path(@conn, :new, @current_user) %>
          <% end %>

    <% end %>

<%= gettext "Exports" %>

<%= gettext "Vcard" %>

<%= link gettext("Download"), to: api_user_v_card_path(@conn, :get, @user) %>

  <section class="card half<%= if @follower_count == 0, do: " card--empty" %>">

<%= gettext "Followers" %>

    <%= if(@follower_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followers, current_user: @current_user, current_user_id: @current_user_id, work_string_length: 20 %>

    <% else %>

<%= gettext "No Followers yet!" %>

    <% end %>
    <%= if(@follower_count > 3) do %>
      <%= link "#{@follower_count-3} #{gettext "More"}", to: user_follower_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

<%= gettext "Following" %>

    <%= if(@followee_count > 0) do %>

    <%= render "card_list.html", conn: @conn, users: @user.followees, current_user: @current_user, current_user_id: @current_user_id, work_string_length: 20 %>

    <% else %>

<%= gettext "Not following anyone yet!" %>

    <% end %>
    <%= if(@followee_count > 3) do %>
      <%= link "#{@followee_count-3} #{gettext "More"}", to: user_followee_path(@conn, :index, @user), class: "card__morelink" %>
    <% end %>

    <%= if @total_jobs > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Experience" %>

    <%= if @total_jobs > 0 do %>
    <%= render Vutuv.WorkExperienceView, "card_list.html", assigns %>

    <% else %>

    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_work_experience_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_jobs > 5 do %> | <% end %>
      <%= if @total_jobs > 5 do %>
        <%= link gettext("View All"), to: user_work_experience_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_numbers > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Phone Numbers" %>

    <%= if @total_numbers > 0 do %>
    <%= render Vutuv.PhoneNumberView, "card_list.html", phone_numbers: @user.phone_numbers, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_phone_number_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_numbers > 5 do %> | <% end %>
      <%= if @total_numbers > 5 do %>
        <%= link gettext("View All"), to: user_phone_number_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_links > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Links" %>

    <%= if @total_links > 0 do %>
    <%= render Vutuv.UrlView, "card_list.html", urls: @user.urls, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_url_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_links > 5 do %> | <% end %>
      <%= if @total_links > 5 do %>
        <%= link gettext("View All"), to: user_url_path(@conn, :index, @user) %>
      <% end %>

  <% end %>

  <%= if @total_addresses > 0 or same_user?(@user, @current_user) do %>

<%= gettext "Addresses" %>

    <%= if @total_addresses > 0 do %>
    <%= render Vutuv.AddressView, "card_list.html", addresses: @user.addresses, user: @user, conn: @conn, current_user: @current_user %>
    <% end %>

      <%= if same_user?(@user, @current_user) do %>
        <%= link gettext("Add"), to: user_address_path(@conn, :new, @current_user) %>
      <% end %>
      <%= if same_user?(@user, @current_user) and @total_addresses > 5 do %> | <% end %>
      <%= if @total_addresses > 5 do %>
        <%= link gettext("View All"), to: user_address_path(@conn, :index, @user) %>
      <% end %>

  <% end %>


fix lack detransliteration for categories

  <%= for post <- @posts do %>
  <% img_src = hd(post.json_metadata["image"]) %>

        <a href="/posts/<%= post.permlink %>"> <img src="<%= img_src %>">

<%= format_tag(post.category, @conn.assigns.lang) %>

        <a class="header" href="/posts/<%= post.permlink %>"> <%= post.title %>

            <%= for tag <- post.tags do %>
              <a class="ui  label" href="/tags/<%=tag%>">
                <%= format_tag(tag, @conn.assigns.lang) %>

            <% end %>

  <% end %>

      <%= for {v, i} <- generate_pagination_list(@current_page) do %>

        <a class="<%=if i == @current_page, do: "active" %> item"
           href="<%= @conn.request_path <> "?" <> URI.encode_query(%{"page"=> v}) %>">
          <%= v %>

      <% end %>

  <%= for post <- @posts do %>
  <% img_src = hd(post.json_metadata["image"]) %>

        <a href="/posts/<%= post.permlink %>"> <img src="<%= img_src %>">

<%= post.category %>

        <a class="header" href="/posts/<%= post.permlink %>"> <%= post.title %>

            <%= for tag <- post.tags do %>
              <a class="ui  label" href="/tags/<%=tag%>">
                <%= format_tag(tag, @conn.assigns.lang) %>

            <% end %>

  <% end %>

      <%= for {v, i} <- generate_pagination_list(@current_page) do %>

        <a class="<%=if i == @current_page, do: "active" %> item"
           href="<%= @conn.request_path <> "?" <> URI.encode_query(%{"page"=> v}) %>">
          <%= v %>

      <% end %>


Add home icon to signed-in user's navbar

      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
        Toggle navigation

      </button>
      <%= link to: page_path(@conn, :home), class: "navbar-brand" do %>
        <%= img_tag "/images/jumuball.png", alt: gettext("Jumu logo") %>
      <% end %>

<%= link gettext("Home"), to: page_path(@conn, :home) %>

        <%= if @current_user do %>

            <%= link to: internal_page_path(@conn, :home) do %>
              <%= icon_tag("home") %>

              <%= @current_user.first_name %>
            <% end %>

<%= link gettext("Logout"), to: session_path(@conn, :delete, @current_user), method: :delete %>

        <% else %>

            <%= link gettext("Internal Pages"), to: session_path(@conn, :new) %>

        <% end %>

      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
        Toggle navigation

      </button>
      <%= link to: page_path(@conn, :home), class: "navbar-brand" do %>
        <%= img_tag "/images/jumuball.png", alt: gettext("Jumu logo") %>
      <% end %>

<%= link gettext("Home"), to: page_path(@conn, :home) %>

        <%= if @current_user do %>

<%= link @current_user.first_name, to: internal_page_path(@conn, :home) %>

<%= link gettext("Logout"), to: session_path(@conn, :delete, @current_user), method: :delete %>

        <% else %>

            <%= link gettext("Internal Pages"), to: session_path(@conn, :new) %>

        <% end %>


Fix issue #30 (#31)

Fix issue #30 (#31)

[Unit]
Description=<%= description %>
After=network.target

[Service]
Type=simple

User=<%= uid %>
Group=<%= gid %>

<%= if uid == "root" do %>
Environment=HOME=/root
<% else %>
Environment=HOME=/home/<%= uid %>
<% end %>

WorkingDirectory=/opt/<%= name %>

ExecStart= /opt/<%= name %>/bin/<%= name %> start
ExecStop= /opt/<%= name %>/bin/<%= name %> stop

Restart=on-failure
RemainAfterExit=yes
RestartSec=5

SyslogIdentifier=<%= name %>

[Install]
WantedBy=multi-user.target

[Unit]
Description=<%= description %>
After=network.target

[Service]
Type=forking
TimeoutSec=120
User=<%= uid %>
Group=<%= gid %>

<%= if uid == "root" do %>
Environment=HOME=/root
<% else %>
Environment=HOME=/home/<%= uid %>
<% end %>

ExecStart= /opt/<%= name %>/bin/<%= name %> start
ExecStop= /opt/<%= name %>/bin/<%= name %> stop

[Install]
WantedBy=multi-user.target


Fix color of experiment-delete-button (#117)

* Fix color of experiment-delete-button

* Get rid of redundancy

管理者画面

        <a class="collection-item" href="<%= theme_path(@conn, :explore, "list") %>">実験テーマ一覧
        <a class="collection-item" href="<%= theme_path(@conn, :explore, "category") %>">実験テーマ一覧 (カテゴリ別)

          <%= if Map.has_key?(@conn.params, "intro") do %>
            <a class="collection-item" href="<%= host_path(@conn, :experiment, intro: @conn.params["intro"]=="true") %>">
          <% else %>
            <a class="collection-item" href="<%= host_path(@conn, :experiment, intro: false) %>">
          <% end %>
            実験作成画面

  <%= if @experiment do %>

現在作成中の実験

            タイトル
            実験テーマ
            実験ID

          <%= for exp <- @experiment do %>

                <form method="post" action="/host/remove">
                  <button class="btn-floating red darken-4" type="submit" >delete</button>
                  <input type="hidden" name="_csrf_token" value="<%= @csrf_token %>">
                  <input type="hidden" name="xid" value="<%= exp[:xid] %>">
                </form>

              <%= exp[:name] %>
              <%= exp[:theme] %>
              <a href="/experiment/<%= exp[:xid] %>/host" class="waves-effect waves-light btn" style="text-transform: none"><%= exp[:x_token] %>

            <% end %>

  <% end %>

<%= if Map.has_key?(@conn.params, "intro") do %>

<% end %>

管理者画面

        <a class="collection-item" href="<%= theme_path(@conn, :explore, "list") %>">実験テーマ一覧
        <a class="collection-item" href="<%= theme_path(@conn, :explore, "category") %>">実験テーマ一覧 (カテゴリ別)

          <%= if Map.has_key?(@conn.params, "intro") do %>
            <a class="collection-item" href="<%= host_path(@conn, :experiment, intro: @conn.params["intro"]=="true") %>">
          <% else %>
            <a class="collection-item" href="<%= host_path(@conn, :experiment, intro: false) %>">
          <% end %>
            実験作成画面

  <%= if @experiment do %>

現在作成中の実験

            タイトル
            実験テーマ
            実験ID

          <%= for exp <- @experiment do %>

                <form method="post" action="/host/remove">
                  <button class="btn-floating" type="submit" >delete</button>
                  <input type="hidden" name="_csrf_token" value="<%= @csrf_token %>">
                  <input type="hidden" name="xid" value="<%= exp[:xid] %>">
                </form>

              <%= exp[:name] %>
              <%= exp[:theme] %>
              <a href="/experiment/<%= exp[:xid] %>/host" class="waves-effect waves-light btn" style="text-transform: none"><%= exp[:x_token] %>

            <% end %>

  <% end %>

<%= if Map.has_key?(@conn.params, "intro") do %>

<% end %>


add promises to jsonHTTPrequest

add promises to jsonHTTPrequest

overlay opacity

<!- div id="coords">

<input id="opacity" class="range-slider" type="range" value= "0.8" min="0.0" max="1.0" step="0.05" />