← back to Designerrepresentatives

views/public/rep.ejs

55 lines

<%- include('../partials/head', { title }) %>
<%- include('../partials/header') %>

<main class="rep-detail">
  <section class="section">
    <div class="wrap narrow">
      <p class="muted"><a href="/reps">← Back to all reps</a></p>
      <h1><%= rep.agency %></h1>
      <p class="lede"><%= rep.name %><% if (rep.city) { %> · <%= rep.city %><% } %></p>

      <% if (rep.lines && rep.lines.length) { %>
        <h2>Lines represented</h2>
        <ul class="pills">
          <% rep.lines.forEach(function (l) { %><li><%= l %></li><% }) %>
        </ul>
      <% } %>

      <% if (rep.territories && rep.territories.length) { %>
        <h2>Territory</h2>
        <p><%= rep.territories.join(' · ') %></p>
      <% } %>

      <% if (rep.vertical && rep.vertical.length) { %>
        <h2>Verticals</h2>
        <ul class="tags">
          <% rep.vertical.forEach(function (v) { %><li><%= v %></li><% }) %>
        </ul>
      <% } %>

      <% if (rep.bio) { %>
        <h2>About</h2>
        <p><%= rep.bio %></p>
      <% } %>

      <h2>Contact</h2>
      <p>
        <% if (rep.contact_url) { %>
          <a class="btn primary" href="<%= rep.contact_url %>" rel="nofollow noopener noreferrer" target="_blank">Reach out via the agency website →</a>
        <% } else if (rep.email) { %>
          <a class="btn primary" href="mailto:<%= rep.email %>">Email <%= rep.agency %> →</a>
        <% } else { %>
          <em class="muted">Direct contact not yet listed. <a href="/claim">Claim this listing</a> to add it.</em>
        <% } %>
      </p>

      <p class="muted small">
        Is this your agency? <a href="/claim">Claim or update this listing</a>.
        Designer Representatives is independent of the lines and showrooms named on this page.
      </p>
    </div>
  </section>
</main>

<%- include('../partials/footer') %>