added new landing page

This commit is contained in:
albert
2011-10-28 19:21:44 -04:00
parent 47abe4eacd
commit 40745a2e6e
18 changed files with 234 additions and 48 deletions

View File

@@ -0,0 +1 @@
<div class="landing-post"><a href="<%= post_path(post) %>"><img src="<%= post.medium_file_url %>" width="<%= post.medium_image_width %>" height="<%= post.medium_image_height %>"><div class="data"><p><%= post.essential_tag_string %></p></div></a></div>

View File

@@ -0,0 +1,8 @@
<!--
- tag
-->
<div>
<% @explorer.search(tag, 300).each do |post| %>
<%= post.presenter.medium_image_html(self, :max_height => 300) %>
<% end %>
</div>

View File

@@ -0,0 +1,22 @@
<div id="c-landings">
<div id="a-show">
<h1><%= link_to Danbooru.config.app_name, posts_path %></h1>
<p class="slogan">Find good art fast</p>
<div class="column">
<% @explorer.col1.each do |post| %>
<%= render "image", :post => post %>
<% end %>
</div>
<div class="column">
<% @explorer.col2.each do |post| %>
<%= render "image", :post => post %>
<% end %>
</div>
</div>
</div>
<% content_for(:page_title) do %>
<%= Danbooru.config.app_name %>
<% end %>

View File

@@ -0,0 +1,17 @@
<!doctype html>
<html>
<head>
<title><%= yield :page_title %></title>
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
<link rel="top" title="<%= Danbooru.config.app_name %>" href="/">
<%= csrf_meta_tag %>
<%= auto_discovery_link_tag :atom, posts_path(:format => "atom", :tags => params[:tags]) %>
<%= stylesheet_link_tag "application", :media => "screen" %>
<%= javascript_include_tag "application" %>
<%= Danbooru.config.custom_html_header_content %>
<%= yield :html_header %>
</head>
<body>
<%= yield :layout %>
</body>
</html>

View File

@@ -27,7 +27,13 @@
<% @posts.each do |post| %>
<article id="post-<%= post.id %>">
<aside>
<%= link_to(image_tag(post.medium_file_url), post_path(post)) %>
<% if post.is_image? %>
<%= link_to(image_tag(post.medium_file_url), post_path(post)) %>
<% elsif post.is_flash? %>
<div class="text-post-medium">Flash</div>
<% else %>
<div class="text-post-medium">Download</div>
<% end %>
</aside>
<section>