2024-04-06 13:25:13 +08:00
|
|
|
<!DOCTYPE html>
|
2024-04-07 15:34:49 +08:00
|
|
|
<html lang="zh-CN">
|
2024-04-06 13:25:13 +08:00
|
|
|
<head>
|
|
|
|
<%= favicon_link_tag "favicons/favicon.ico" %>
|
|
|
|
<title><%= yield :title %></title>
|
|
|
|
<meta name="description" content="<%= yield :description %>">
|
|
|
|
<meta name="keywords" content="<%= @name %>, datasets, maps, data visualization, spatial data, geospatial, carto">
|
|
|
|
<meta name="author" content="<%= @name %>">
|
|
|
|
<meta charset='utf-8' />
|
|
|
|
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
|
|
|
|
|
|
|
|
<meta property="og:title" content="<%= yield :title %>" />
|
|
|
|
<meta property="og:description" content="<%= yield :description %>" />
|
|
|
|
<meta property="og:type" content="visualization" />
|
|
|
|
<meta property="og:url" content="<%= request.original_url %>" />
|
|
|
|
<meta property="og:image" content="<%= @avatar_url %>" />
|
|
|
|
|
|
|
|
<% if @has_new_dashboard %>
|
|
|
|
<%= stylesheet_link_tag 'deep_insights_new', 'common_new', 'public_dashboard_new', 'user_feed_new' %>
|
|
|
|
<% else %>
|
|
|
|
<%= editor_stylesheet_link_tag 'cartodb', 'deep_insights', 'common', 'public_dashboard', 'user_feed' %>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<% if @needs_gmaps_lib %>
|
|
|
|
<%= insert_google_maps(@gmaps_query_string) %>
|
|
|
|
<% end %>
|
|
|
|
<%= insert_google_tag_manager('embeds') %>
|
|
|
|
</head>
|
|
|
|
<body class="PublicBody PublicBody--grey">
|
|
|
|
<%= insert_google_tag_manager_no_script('embeds') %>
|
|
|
|
<%= render 'admin/shared/public_header' %>
|
|
|
|
<div class="FavMap FavMap--tall is-pre-loading" id="<%= fav_map_target_id = 'fav-map-container' %>">
|
|
|
|
<div class="Spinner FavMap-spinner js-spinner"></div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<% if @is_org %>
|
|
|
|
<%= render "shared/public_dashboard_org_header" %>
|
|
|
|
<% else %>
|
|
|
|
<%= render "shared/public_dashboard_user_header" %>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<%= yield %>
|
|
|
|
|
|
|
|
<%= render 'admin/shared/footer', { light: true } %>
|
|
|
|
|
|
|
|
<%= insert_trackjs('embeds') %>
|
|
|
|
<script type="text/javascript">
|
|
|
|
var config = <%= safe_js_object frontend_config_public({https_apis: request.protocol == 'https://' }) %>;
|
|
|
|
var account_host = '<%= CartoDB.account_host %>';
|
|
|
|
var base_url = '<%= @base_url %>';
|
|
|
|
var login_url = "<%= CartoDB.url(self, 'login') %>";
|
|
|
|
var avatar_url= '<%= @avatar_url %>';
|
|
|
|
|
|
|
|
var favMapViewAttrs = {
|
|
|
|
fallbackBaselayer: <%= raw @default_fallback_basemap.to_json %>,
|
|
|
|
el: '#<%= fav_map_target_id %>',
|
|
|
|
<% if @most_viewed_vis_map %>
|
|
|
|
createVis: {
|
|
|
|
<% if @has_new_dashboard %>
|
|
|
|
vizJson: <%= safe_js_object named_map_vizjson3(@most_viewed_vis_map).to_json %>,
|
|
|
|
<% else %>
|
|
|
|
url: '<%= vis_json_url(@most_viewed_vis_map.id, self, (@most_viewed_vis_map.user)) %>',
|
|
|
|
<% end %>
|
|
|
|
opts: {
|
|
|
|
no_cdn: <%= Rails.env.production? ? 'false' : 'true' %>
|
|
|
|
}
|
|
|
|
}
|
|
|
|
<% end %>
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<% if @has_new_dashboard %>
|
|
|
|
<%= javascript_include_tag 'common', 'common_vendor', 'user_feed_new' %>
|
|
|
|
<% else %>
|
|
|
|
<%= editor_javascript_include_tag 'cdb.js', 'templates', 'user_feed_deps', 'user_feed' %>
|
|
|
|
<% end %>
|
|
|
|
<%= yield :js %>
|
|
|
|
</body>
|
|
|
|
</html>
|