2013-01-11 23:49:59 +00:00
|
|
|
<%#
|
|
|
|
# @file
|
|
|
|
# Main application file. Holds scaffolding present on every page.
|
|
|
|
# Then a certain non-partial view (no _ preceding filename) will be
|
|
|
|
# displayed within, based on URL
|
|
|
|
#%>
|
|
|
|
|
2012-10-10 15:52:50 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
2013-07-09 16:32:13 +00:00
|
|
|
<title><%=h yield(:title) %></title>
|
2012-12-16 00:46:39 +00:00
|
|
|
<% if authenticated? %>
|
|
|
|
<script type="text/javascript">
|
2013-01-23 18:43:01 +00:00
|
|
|
var userid = <%= user.id %>;
|
2012-12-16 00:46:39 +00:00
|
|
|
var username = "<%= user.name %>";
|
|
|
|
</script>
|
2012-12-25 23:29:20 +00:00
|
|
|
<% else %>
|
|
|
|
<script type="text/javascript">
|
|
|
|
var userid = null;
|
|
|
|
var username = null;
|
|
|
|
</script>
|
2012-12-16 00:46:39 +00:00
|
|
|
<% end %>
|
2013-01-26 01:49:40 +00:00
|
|
|
<script>
|
|
|
|
var imgArray = new Object();
|
|
|
|
|
|
|
|
<% Metacode.all.each do |m| %>
|
|
|
|
imgArray['<%= m.name %>'] = new Image(); imgArray['<%= m.name %>'].src = '/assets/<%= m.icon %>';
|
|
|
|
<% end %>
|
|
|
|
</script>
|
2012-10-10 15:52:50 +00:00
|
|
|
<%= stylesheet_link_tag "application", :media => "all" %>
|
|
|
|
<%= javascript_include_tag "application" %>
|
2012-10-26 10:04:52 +00:00
|
|
|
<script type="text/javascript" src="//use.typekit.net/tki2nyo.js"></script>
|
|
|
|
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
|
2012-12-16 20:00:43 +00:00
|
|
|
<script type="text/javascript" src="//use.typekit.net/obp7wss.js"></script>
|
|
|
|
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
|
2012-10-10 15:52:50 +00:00
|
|
|
<%= csrf_meta_tags %>
|
|
|
|
</head>
|
|
|
|
<body>
|
2013-07-10 18:02:38 +00:00
|
|
|
|
|
|
|
<% if notice %>
|
|
|
|
<p class="notice metamaps"><%= notice %></p>
|
|
|
|
<% end %>
|
|
|
|
<% if alert %>
|
|
|
|
<p class="alert metamaps"><%= alert %></p>
|
|
|
|
<% end %>
|
|
|
|
|
2012-10-10 15:52:50 +00:00
|
|
|
<%= content_tag :div, class: authenticated? ? "main authenticated" : "main unauthenticated" do %>
|
|
|
|
|
2012-12-25 23:29:20 +00:00
|
|
|
<div class="wrapper" id="wrapper">
|
2014-01-29 03:46:58 +00:00
|
|
|
<div class="sidebarSearch">
|
|
|
|
<div class="sidebarSearchIcon"></div>
|
|
|
|
<input type="text" class="sidebarSearchField" placeholder="Search..."></input>
|
|
|
|
<div class="clearfloat"></div>
|
|
|
|
<%= render :partial => 'layouts/searchtemplates' %>
|
|
|
|
</div>
|
|
|
|
<div class="sidebarAccount">
|
|
|
|
<div class="sidebarAccountIcon"></div>
|
|
|
|
<div class="sidebarAccountBox <%= authenticated? ? 'loggedin' : 'loggedout' %>">
|
|
|
|
<%= render :partial => 'layouts/account' %>
|
|
|
|
</div>
|
|
|
|
</div>
|
2012-10-10 15:52:50 +00:00
|
|
|
<%= yield %>
|
|
|
|
</div>
|
2012-12-16 03:52:12 +00:00
|
|
|
|
2012-12-16 20:00:43 +00:00
|
|
|
<div class="footer">
|
2012-12-25 23:29:20 +00:00
|
|
|
<div class="logo">
|
2014-01-29 03:46:58 +00:00
|
|
|
<ul class="menu">
|
|
|
|
<li class="beta">
|
|
|
|
<div class="inBeta">beta</div>
|
2014-01-31 00:32:15 +00:00
|
|
|
<button class="button" onclick="BAROMETER.show();">feedback!</button>
|
|
|
|
</li>
|
|
|
|
<li class="meta">
|
|
|
|
<a href="#" target="_blank">about</a>
|
2014-01-29 03:46:58 +00:00
|
|
|
</li>
|
|
|
|
<li class="tutorial"><a href="#" target="_blank">tutorial</a></li>
|
|
|
|
<li class="exploreMaps"><%= link_to "explore maps", maps_url %></li>
|
|
|
|
</ul>
|
|
|
|
<div id="mainTitle"><%= link_to "metamaps", root_url %></div><!--<div id="beta">beta</div>-->
|
2012-12-25 23:29:20 +00:00
|
|
|
</div>
|
2014-01-31 00:32:15 +00:00
|
|
|
<% if authenticated? %>
|
|
|
|
<div class="addMap"></div>
|
|
|
|
<% end %>
|
2012-10-10 15:52:50 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<% end %>
|
2014-01-29 03:46:58 +00:00
|
|
|
|
|
|
|
<% if authenticated? %>
|
2014-01-31 00:32:15 +00:00
|
|
|
<% # this is the create new map form %>
|
|
|
|
<%= render :partial => 'maps/new' %>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<%= render :partial => 'layouts/ga' if Rails.env.production? %>
|
|
|
|
|
2014-01-29 03:46:58 +00:00
|
|
|
<style type='text/css'>@import url('http://getbarometer.s3.amazonaws.com/assets/barometer/css/barometer.css');</style>
|
|
|
|
<script src='http://getbarometer.s3.amazonaws.com/assets/barometer/javascripts/barometer.js' type='text/javascript'></script>
|
|
|
|
<script type="text/javascript" charset="utf-8">
|
|
|
|
BAROMETER.load('6FWffBApknnjr7p3Oxf2L');
|
|
|
|
</script>
|
2012-10-10 15:52:50 +00:00
|
|
|
</body>
|
2012-12-31 04:04:30 +00:00
|
|
|
</html>
|