2013-01-11 23:49:59 +00:00
|
|
|
<%#
|
|
|
|
# @file
|
|
|
|
# Shows a map as a card.
|
2013-01-18 22:08:06 +00:00
|
|
|
# Any list of maps uses this rendering.
|
2013-01-11 23:49:59 +00:00
|
|
|
#%>
|
2012-10-26 10:04:52 +00:00
|
|
|
<%= div_for map do %>
|
2014-02-10 04:36:23 +00:00
|
|
|
<div class="permission <%= map.authorize_to_edit(user) ? "canEdit" : "cannotEdit" %>">
|
2013-01-18 22:08:06 +00:00
|
|
|
|
2014-02-10 04:36:23 +00:00
|
|
|
<div class="mapCard">
|
|
|
|
<span class="title">
|
2014-06-04 19:24:16 +00:00
|
|
|
<%= best_in_place map, :name, :type => :textarea, :classes => 'best_in_place_name' %>
|
2014-02-10 04:36:23 +00:00
|
|
|
</span>
|
|
|
|
<div class="links">
|
|
|
|
<div class="linkItem icon">
|
|
|
|
<div class="metacodeImage" style="background-image:url(/assets/map.png);"></div>
|
|
|
|
</div>
|
2014-02-10 06:29:02 +00:00
|
|
|
<div class="linkItem contributor hoverForTip">
|
|
|
|
<div class="tip">Created by <%= map.user.name %> on <%= map.created_at.strftime("%m/%d/%Y") %></div>
|
2014-02-10 04:36:23 +00:00
|
|
|
</div>
|
|
|
|
<div class="linkItem topicCount"><%= map.topics.count %></div>
|
|
|
|
<div class="linkItem synapseCount"><%= map.synapses.count %></div>
|
|
|
|
<div class="linkItem mapPerm <%= map.mk_permission %>"></div>
|
|
|
|
<a href="/maps/<%= map.id %>" class="linkItem topicPopout" title="Open Map in New Tab" target="_blank"></a>
|
|
|
|
<div class="clearfloat"></div>
|
|
|
|
</div>
|
|
|
|
<div class="scroll">
|
|
|
|
<div class="desc">
|
2014-06-04 19:24:16 +00:00
|
|
|
<%= best_in_place map, :desc, :type => :textarea, :nil => "Click to add description.", :classes => 'best_in_place_desc' %>
|
2014-02-10 04:36:23 +00:00
|
|
|
<div class="clearfloat"></div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="clearfloat"></div>
|
2013-01-08 00:57:04 +00:00
|
|
|
</div>
|
2013-01-18 22:08:06 +00:00
|
|
|
|
2014-02-10 04:36:23 +00:00
|
|
|
</div>
|
2013-01-11 23:49:59 +00:00
|
|
|
<% end %>
|